§ 瀏覽學位論文書目資料
  
系統識別號 U0002-2301202411595900
DOI 10.6846/tku202400061
論文名稱(中文) 以深度學習進行文章層級之多維度情緒分析
論文名稱(英文) Document-level Multi-Dimensional Emotion Analysis Using Deeping Learning
第三語言論文名稱
校院名稱 淡江大學
系所名稱(中文) 資訊管理學系碩士班
系所名稱(英文) Department of Information Management
外國學位學校名稱
外國學位學院名稱
外國學位研究所名稱
學年度 112
學期 1
出版年 113
研究生(中文) 李世傑
研究生(英文) Shih-Jie Li
學號 611630038
學位類別 碩士
語言別 繁體中文
第二語言別
口試日期 2024-01-04
論文頁數 43頁
口試委員 指導教授 - 張昭憲(090557@mail.tku.edu.tw)
口試委員 - 壽大衛
口試委員 - 魏世杰
口試委員 - 張昭憲
關鍵字(中) 情緒預測
深度學習
多維度情緒模型
社群網路
關鍵字(英) sentiment analysis
deep learning
multiple-emotion model
community network
第三語言關鍵字
學科別分類
中文摘要
    社群網路已經成為人們生活的一部分,每日在其中進行各項活動。在社群規範的限制下,社群成員大多能和平相處,以正面方式進行發文或回文。然而,在言論自由前提下,仍可能出現各種不當發文,嚴重影響社群的氛圍。因此,社群管理者若能事先瞭解文章所引發情緒類型,便可予以制止(或鼓勵),使社群維持正面發展。換言之,如何有效察覺社群中情緒的變化,進而做出合適的處置,便成為社群管理的重要課題。有鑑於此,為提供更符合實際需求之文章情緒偵測,本研究以多維度情緒模型為基礎,發展有效的情緒偵測方法。
    
    首先,針對文章層級的情緒偵測,本研究提出一套BERT-RE Fusion預測架構。透過情緒維度的縮減與再擴充,使多維度情緒值預測更為準確。其次,我們也發展以單句為基礎的文章情緒預測方法。透過累積文章中單句的情緒,再以不同方式加以組合。有關單句的情緒預測,我們提出了一套BERT-NP-Binary架構,特點為能凸顯文章中情緒較為強烈的單句。此外,本研究也發展了一套全新的情緒彙整方法-Feature Extraction Matching特徵擷取合併法,將單句的情緒以合理方式彙整成為總體文章情緒。

    為驗證提出方法之有效性,我們使用Yelp評論(Yelp, 2023)作為實驗資料集,並與其他多種方法進行比較。在文章層級的實驗中,我們與二種不同架構進行比較,本研究提出之BERT-RE Fusion架構可獲最佳的平均RMSE。在以單句為基礎的文章情緒預測中,本研究提出之BERT-NP-Binary預測架構配合Feature Extraction Matching特徵擷取合併法亦可獲得最好的RMSE。由上述結果驗證了本研究提出方法之有效性,相關結果將可提供社群管理者寶貴的決策依據。
英文摘要
    Social media has become an integral part of people's lives, where they engage in a variety of activities daily. Under the restrictions of community guidelines, community members can generally live together peacefully and post or reply in a positive way. However, under the freedom of speech, inappropriate posts can emerge, which seriously affects the atmosphere of the community. Therefore, if community managers can effectively identify the emotional reactions of article, they can prevent or encourage these reactions immediately, helping to maintain a positive community atmosphere. Detecting emotional changes effectively within a community presents a critical challenge for community management. To provide comprehensive article sentiment detection, this study develops an effective sentiment detection method based on a multidimensional emotion model. First, for Article-Level sentiment detection, this study proposes a BERT-RE Fusion prediction framework. By reducing and expanding the dimensions of emotions, the prediction of multi-dimensional emotion values is more accurate. Second, we also developed a sentiment prediction method based on single sentence. We further develop a sentiment detection method for individual sentences, accumulating and combining their emotions through various methods. For single-sentence sentiment prediction, we propose a BERT-NP-Binary framework, which can highlight the impactful sentences in an article. In addition, this study also develops a novel sentiment aggregation method called Feature Extraction Matching (FEM), which aggregates individual sentence emotions into a representative article sentiment.

     This study evaluates the effectiveness of the proposed method, using Yelp reviews(Yelp, 2023) as the experimental dataset, and compared to several other methods. In the article-level experiment, the study compared the proposed BERT-RE fusion framework with two other frameworks, and the BERT-RE fusion framework proposed in this study achieved the best average RMSE. In single-sentence sentiment prediction, the BERT-NP-Binary framework, combined with Feature Extraction Matching (FEM), outperformed existing methods in single-sentence sentiment prediction based on its RMSE score. These findings validate the effectiveness of the proposed method. These findings offer valuable insights for community managers, empowering them to make informed decisions regarding. 
第三語言摘要
論文目次
目錄
第一章  緒論  1
第二章  文獻探討與相關術語  3 
     2.1  情緒模型  3
          2.1.1情緒沙漏模型  4
     2.2  Bidirectional Encoder Representations from Transformers  5
     2.3  變換器(Transformer)  6
     2.4  SMOTE樣本合成演算法  8
第三章  以多模型為基礎之多維度情緒預測方法  9
     3.1  情緒模型  9
     3.2  文章層級之情緒預測  10
          3.2.1 Naïve BERT Framework  10
          3.2.2 BERT Fusion Framework considering polarity and scale 
               separately  11
          3.2.3 BERT Fusion Framework with Reduction-Expansion
               (BERT-RE Fusion)  12
     3.3  以單句為基礎之文章情緒分析  14
          3.3.1 BERT-NP-Binary Framework  14
          3.3.2以單句為基礎之文章情緒分析架構  16
第四章  實驗結果與討論  19
     4.1  實驗設定  19
     4.2  文章層級情緒預測架構之效能驗證  20
          4.2.1  BERT-RE Fusion之模型建立流程  20
          4.2.2  實驗結果比較  21
     4.3  以單句為基礎之文章情緒預測效能驗證  23
          4.3.1  BERT-NP-Binary模型之建立  23
          4.3.2  以單句為基礎之情緒預測效能比較  25
          4.3.3  以單句為基礎配合SMOTEENN 方法之效能驗證  26
第五章  結論與未來工作  28
參考文獻  29
附錄  31


圖目錄
圖 2-1 二維情緒模型  4
圖 2-2 多維度情緒模型  5
圖 2-3 Bert Mountain  6
圖 2-4 Bert之pre-training與Fine-Tuning概念圖  6
圖 2-5 注意力機制說明範例  7
圖 3-1 Naïve-BERT之單一維度模型架構圖  11
圖 3-2 BERT Fusion Framework considering polarity and scale separately  12
圖 3-3 BERT Fusion Framework with Reduction-Expansion  13
圖 3-4 單句之單維度情緒預測架構(BERT-NP-Binary)  14
圖 3-5 以單句為基礎之文章情緒分析架構  16
圖 3-6 特徵擷取流程之範例  17
圖 3-7 Matching合併法運作流程之範例  18
圖 3-8 使用MLP(左)與LSTM(右)合併單句情緒序列之模型參數  18


表目錄
表 2-1 傳統的情緒分類-以基礎情緒為主  3
表 3-1 情緒沙漏模型之多維度情緒值  10
表 3-2 將GoEmotions資料集中具代表性之情緒標籤映射於情緒沙漏模型  10
表 4-1 本研究使用之軟體套件  19
表 4-2 建立RE-BERT Fusion各模型之各維度資料數量配比  21
表 4-3 文章層級之情緒預測結果比較  21
表 4-4 DEIMB之各層模型之RMSE值  22
表 4-5 BERT-RE Fusion之各層架構之RMSE值  23
表 4-6 BERT-NP模型所使用之訓練、驗證、測試資料數量配比  23
表 4-7 Model_Binary中各模型之訓練、驗證、測試之資料數量配比  24
表 4-8 對應各情緒維度之單一情緒值判別模型之預測平均RMSE  24
表 4-9 單句情緒預測模型配合序列合併之文章情緒預測結果比較  25
表4-10 使用SMOTEENN、SMOTETomek方法調整後的資料集  26
表4-11: 對應各情緒維度之單情緒值判別SMOTEENN模型預測平均RMSE  27
表4-12: 單句情緒預測模型配合序列合併之文章情緒預測結果比較  27
附表1 Go Emotions資料集中具代表性之情緒標籤映射於情緒沙漏模型(中文版)  31
附表2 Yelp資料集文章長度分布狀態(各維度使用相同資料集)  31
附表3 Yelp資料集資料分布狀態  31
附表4 Go Emotions資料集短文長度分布狀態(各維度使用不同資料集)  32
附表5 Go Emotions資料集資料分布狀態  32
附表6 以文章為訓練資料之模型(DEIMB、BERT-RE Fusion)預測案例  33
附表7 以文句為訓練資料之模型(DEIMB、BERT_NP-Binary)搭配Matching合併法預測案例  34
附表8 相關模型之混淆矩陣  36





參考文獻
1.Bandhakavi, A., et al., (2017) "Lexicon based feature extraction for emotion text classification," Pattern Recognition Letters, vol. 93, 2017, pp. 133-142.
2.Chen, B., (2021) "Sentiment Analysis from Machine Learning to Deep Learning,” 2021 International Conference on Electronic Information Engineering and Computer Science, pp. 724-728.
3.Chen, C.-H., Lee, W.-P., Huang, J.-Y., (2018) "tracking and recognizing emotions in short text messages from online chatting services," Information Processing and management, vol. 54, 2018, pp. 1325-1344.
4.Devlin, Jacob, Ming-Wei Chang, Kenton Lee, Kristina Toutanova, (2019) “BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding,” last revised 24 May 2019 (v2), 	arXiv:1810.04805.
5.Dorottya Demszky, Dana Movshovitz-Attias, Jeongwoo Ko, Alan Cowen, Gaurav Nemade, Sujith Ravi,(2020) “ GoEmotions: A Dataset of Fine-Grained Emotions, ” Submitted on 1 May 2020 (v1), last revised 3 Jun 2020 (this version, v2), arXiv:2005.00547.
6.Ekman, P., & Friesen, W. V. (1976). Measuring facial movement. Environmental Psychology & Nonverbal Behavior, 1(1), 56–75.
7.Huang, Z. and Fang, Z., (2020) "An Entity-Level Sentiment Analysis of Financial Text Based on Pre-Trained Language Model," 2020 IEEE 18th International Conference on Industrial Informatics (INDIN), pp. 391-396.
8.Hu, P., et al, (2017) "Valence-Arousal Analysis for Mental-Health Document Retrieval," 2017 International Conference on Orange Technologies (ICOT), pp. 61-64.
9.Khatua, A., et al. (2019), “Tweeting in Support of LGBT?: A Deep Learning Approach,” Proceedings of the ACM India Joint International Conference on Data Science and Management of Data, pp. 342–345.
10.Kumar, A. J., Tina Esther Trueman, Erik Cambria (2021), “A Convolutional Stacked Bidirectional LSTM with a Multiplicative Attention Mechanism for Aspect Category and Sentiment Detection,” Cognitive Computation volume 13, pages1423–1432.
11.McCormick, Chris, (2019) "BERT Research - Ep. 1 - Key Concepts & Sources, " 2019/11/1, URL:https://mccormickml.com/2019/11/11/bert-research-ep-1-key-concepts-and-sources/ 
12.Plutchik, R. (2001), "The Nature of Emotions," American Scientist Vol. 89, No. 4, pp. 344-350.
13.Plutchik (2001), The Nature of Emotions, American Scientist, 89(4), pp. 344 - 350, 2001.
14.Poria, S., et al. (2015), "Sentiment Data Flow Analysis by Means of Dynamic Linguistic Patterns," IEEE Computational Intelligence Magazine, Volume: 10, Issue: 4, pp. 26-36.


15.Purba, S., A., et al., (2021)"Document Level Emotion Detection from Bangla Text using Machine Learning Techniques," 2021 International Conference on Information and Communication Technology for Sustainable Development (ICICT4SD), pp. 406-411.
16.Russell JA. (1980), "A circumplex model of affect. Journal of Personality and Social Psychology," 1980; 39:1161–1178.
17.Soleimaninejadian, P., et al., (2018) "Mood detection and prediction based on user daily activities," The First Asian Conference on Affective Computing and Intelligent Interaction, 2018.
18.Susanto, Y., Livingstone, A. G., Ng, B. C., and Cambria E. (2020), "The Hourglass Model Revisited," IEEE Intelligent Systems, Volume: 35, Issue: 5, 96 - 102.
19.Socher, R., Alex Perelygin, Jean Wu, Jason Chuang, Christopher D. Manning, Andrew Ng, Christopher Potts (2013), "Recursive Deep Models for Semantic Compositionality Over a Sentiment Treebank," Proceedings of the 2013 Conference on Empirical Methods in Natural Language Processing, 1631-1642.
20.Vaswani, Ashish, Noam Shazeer, Niki Parmar, Jakob Uszkoreit, Llion Jones, Aidan N. Gomez, Lukasz Kaiser, Illia Polosukhin, (2017) " Attention Is All You Need," Submitted on 12 Jun 2017 (v1), last revised 2 Aug 2023 (this version, v7), arXiv:1706.03762. 
21.Whissell, C. “The dictionary of affect in language,” Emotion: Theory, Research, and Experience 4, 113–131 (1989)
22.Yelp, (2023) "Yelp Dataset," https://www.yelp.com/dataset, last retrieved on 2023.
論文全文使用權限
國家圖書館
同意無償授權國家圖書館,書目與全文電子檔於繳交授權書後, 於網際網路立即公開
校內
校內紙本論文立即公開
同意電子論文全文授權於全球公開
校內電子論文立即公開
校外
同意授權予資料庫廠商
校外電子論文立即公開

如有問題,歡迎洽詢!
圖書館數位資訊組 (02)2621-5656 轉 2487 或 來信