晶文摘智能客服應用實作
作者: 夏肇毅
初稿: 20220820
自然語言處理(Natural language processing)
http://cubicpower.idv.tw/cubicnotes/notes-0000038.html
文字探勘(Text Mining)
Google Tensorflow: Text
Sentiment analysis- IMDB large movie review dataset
Basic text classification
https://www.tensorflow.org/tutorials/keras/text_classification?hl=zh-tw
基本文本分類
情緒分析
下載並探索 IMDB 數據集
加載數據集
準備數據集進行訓練
配置數據集以提高性能
創建模型
損失函數和優化器
訓練模型
評估模型
創建隨時間變化的準確度和損失圖
導出模型
對新數據的推論
練習:關於 Stack Overflow 問題的多類分類
Word embeddings
https://www.tensorflow.org/text/guide/word_embeddings?hl=zh-tw
詞嵌入
將文本表示為數字
One-hot 編碼
用唯一的數字編碼每個單詞
詞嵌入
設置
下載 IMDb 數據集
使用嵌入層
文本預處理
創建分類模型
編譯和訓練模型
檢索經過訓練的詞嵌入並將它們保存到磁碟
可視化嵌入
Text classification with an RNN
https://www.tensorflow.org/text/tutorials/text_classification_rnn?hl=zh-tw
使用 RNN 進行文本分類
設置
設置輸入管道
創建文本編碼器
創建模型
訓練模型
堆疊兩個或多個 LSTM 層
Classify text with BERT
https://www.tensorflow.org/text/tutorials/classify_text_with_bert?hl=zh-tw
使用 BERT 對文本進行分類
關於 BERT
情緒分析
從 TensorFlow Hub 加載模型
選擇一個 BERT 模型進行微調
預處理模型
使用 BERT 模型
定義你的模型
模型訓練
損失函數
優化器
加載 BERT 模型並進行訓練
評估模型
繪製隨時間變化的準確性和損失
導出推理
Search: kaggle 登入
https://nancysw.medium.com › 兩種取用-kaggle-資料...
Search: 聊天機器人 python
在Python 中實作對話型聊天機器人 - WANcatServer
https://wancat.cc › post › python-chatbot-context
Search: chatbot python github
zake7749/Chatbot: 基於向量匹配的情境式聊天機器人 - GitHub
https://github.com › zake7749 › Chatbot
Mianbot
匹配示例
環境需求
使用方式
聊天機器人
計算匹配度
規則格式
問答測試用資料集
Building a Simple Chatbot from Scratch in Python (using NLTK)
https://github.com › parulnith › Building-...
Building a Simple Chatbot from Scratch in Python (using NLTK)
NLP
Import necessary libraries
Downloading and installing NLTK
Installing NLTK Packages
Reading in the corpus
Tokenisation
Preprocessing
Keyword matching
Generating Response
Bag of Words
TF-IDF Approach
Cosine Similarity
Day 13:快速完成一個『對話機器人』(ChatBot) -- 續