Skip navigation

DSpace

機構典藏 DSpace 系統致力於保存各式數位資料(如:文字、圖片、PDF)並使其易於取用。

點此認識 DSpace
DSpace logo
English
中文
  • 瀏覽論文
    • 校院系所
    • 出版年
    • 作者
    • 標題
    • 關鍵字
    • 指導教授
  • 搜尋 TDR
  • 授權 Q&A
    • 我的頁面
    • 接受 E-mail 通知
    • 編輯個人資料
  1. NTU Theses and Dissertations Repository
  2. 文學院
  3. 語言學研究所
請用此 Handle URI 來引用此文件: http://tdr.lib.ntu.edu.tw/jspui/handle/123456789/98882
完整後設資料紀錄
DC 欄位值語言
dc.contributor.advisor謝舒凱zh_TW
dc.contributor.advisorShu-Kai Hsiehen
dc.contributor.author紀柔安zh_TW
dc.contributor.authorJou-An Chien
dc.date.accessioned2025-08-20T16:08:42Z-
dc.date.available2025-08-21-
dc.date.copyright2025-08-20-
dc.date.issued2025-
dc.date.submitted2025-08-13-
dc.identifier.citationAlnegheimish, S., Nguyen, L., Berti-Equille, L., & Veeramachaneni, K. (2024). Large language models can be zero-shot anomaly detectors for time series? arXiv preprint arXiv:2405.14755.
Barrasa, J., & Webber, J. (2023). Building knowledge graphs. ” O’Reilly Media, Inc.”
Bommasani, R., Hudson, D. A., Adeli, E., Altman, R., Arora, S., von Arx, S., Bernstein, M. S., Bohg, J., Bosselut, A., Brunskill, E., et al. (2021). On the opportunities and risks of foundation models. arXiv preprint arXiv:2108.07258.
Cai, L., Mao, X., Zhou, Y., Long, Z., Wu, C., & Lan, M. (2024). A survey on temporal knowledge graph: representation learning and applications. arXiv preprint arXiv:2403.04782.
Carta, S., Giuliani, A., Piano, L., Podda, A. S., Pompianu, L., & Tiddia, S. G. (2023). Iterative zero-shot llm prompting for knowledge graph construction. arXiv preprint arXiv:2307.01128.
Chang, H., Wu, J., Tao, Z., Ma, Y., Huang, X., & Chua, T.-S. (2025). Integrate temporal graph learning into llm-based temporal knowledge graph model. https://arxiv.org/abs/2501.11911
Chang, H., Ye, C., Tao, Z., Wu, J., Yang, Z., Ma, Y., Huang, X., & Chua, T.-S. (2024). A comprehensive evaluation of large language models on temporal event forecasting. arXiv preprint arXiv:2407.11638.
Chen, X., Wang, Y., Li, L., & Huang, M. (2023). Kg-llm: injecting knowledge graphs into large language models. ACL.
Dang, W., Zhou, B., Wei, L., Zhang, W., Yang, Z., & Hu, S. (2021). Ts-bert: time series anomaly detection via pre-training model bert. Computational Science–ICCS 2021: 21st International Conference, Krakow, Poland, June 16–18, 2021, Proceedings, Part II 21, 209–223.
Deng, S., Rangwala, H., & Ning, Y. (2020). Dynamic knowledge graph based multievent forecasting. Proceedings of the 26th ACM SIGKDD international conference on knowledge discovery & data mining, 1585–1595.
Deng, S., Rangwala, H., & Ning, Y. (2021). Understanding event predictions via contextualized multilevel feature learning. Proceedings of the 30th ACM International Conference on Information & Knowledge Management, 342–351.
Gao, Y., Qiao, L., Kan, Z., Wen, Z., He, Y., & Li, D. (2024). Two-stage generative question answering on temporal knowledge graph using large language models. arXiv preprint arXiv:2402.16568.
Gastinger, J., Sztyler, T., Sharma, L., & Schuelke, A. (2022). On the evaluation of methods for temporal knowledge graph forecasting. NeurIPS 2022 Temporal Graph Learning Workshop.
Goel, R., Kazemi, S. M., Brubaker, M., & Poupart, P. (2020). Diachronic embedding for temporal knowledge graph completion. Proceedings of the AAAI conference on artificial intelligence, 34(04), 3988–3995.
Gruver, N., Finzi, M., Qiu, S., & Wilson, A. G. (2023). Large language models are zero-shot time series forecasters. Advances in Neural Information Processing Systems, 36, 19622–19635.
Han, X., Liu, Z., & Sun, M. (2021). Robustness of temporal knowledge graph forecasting models to sparsity. Findings of EMNLP.
Huang, H., Chen, C., He, C., Li, Y., Jiang, J., & Zhang, W. (2024). Can llms be good graph judger for knowledge graph construction? arXiv preprint arXiv:2411.17388.
Huang, S., Liu, Y., Fung, C., Wang, H., Yang, H., & Luan, Z. (2023). Improving log-based anomaly detection by pre-training hierarchical transformers. IEEE Transactions on Computers, 72(9), 2656–2667.
Ji, S., Pan, S., Cambria, E., Marttinen, P., & Yu, P. S. (2021). A survey on knowledge graphs: representation, acquisition and applications. IEEE Transactions on Neural Networks and Learning Systems.
Jin, D., Balazevic, I., Allen, C., & Hospedales, T. M. (2020). Re-net: reasoning over knowledge graph paths for temporal knowledge base completion. AAAI.
Jin, M., Wang, S., Ma, L., Chu, Z., Zhang, J. Y., Shi, X., Chen, P.-Y., Liang, Y., Li, Y.-F., Pan, S., et al. (2023). Time-llm: time series forecasting by reprogramming large language models. arXiv preprint arXiv:2310.01728.
Jin, M., Wen, Q., Liang, Y., Zhang, C., Xue, S., Wang, X., Zhang, J., Wang, Y., Chen, H., Li, X., Pan, S., Tseng, V. S., Zheng, Y., Chen, L., & Xiong, H. (2023). Large models for time series and spatio-temporal data: a survey and outlook. https://arxiv.org/abs/2310.10196
Kejriwal, M. (2019). Domain-specific knowledge graph construction. Springer.
Leblay, J., & Chekol, M. W. (2018). Deriving validity time in knowledge graph. Companion proceedings of the the web conference 2018, 1771–1776.
Lee, D.-H., Ahrabian, K., Jin, W., Morstatter, F., & Pujara, J. (2023). Temporal knowledge graph forecasting without knowledge using in-context learning. arXiv preprint arXiv:2305.10613.
Lee, Y., Kim, J., & Kang, P. (2023). Lanobert: system log anomaly detection based on bert masked language model. Applied Soft Computing, 146, 110689.
Leetaru, K., & Schrodt, P. A. (2013). Gdelt: global data on events, location, and tone, 1979–2012. ISA annual convention, 2(4), 1–49.
Li, X., Cheng, L., Tan, Q., Tou Ng, H., Joty, S., & Bing, L. (2023). Unlocking temporal question answering for large language models using code execution. arXiv e-prints, arXiv–2305.
Li, Z., Hou, Z., Guan, S., Jin, X., Peng, W., Bai, L., Lyu, Y., Li, W., Guo, J., & Cheng, X. (2022). Hismatch: historical structure matching based temporal knowledge graph reasoning. arXiv preprint arXiv:2210.09708.
Liao, R., Jia, X., Li, Y., Ma, Y., & Tresp, V. (2023). Gentkg: generative forecasting on temporal knowledge graph with large language models. arXiv preprint arXiv:2310.07793.
Liu, L., Wang, Z., & Tong, H. (2024). Neural-symbolic reasoning over knowledge graphs: a survey from a query perspective. arXiv preprint arXiv:2412.10390.
Liu, N., Zheng, K., Dohan, D., et al. (2023). Lost in the middle: how language models use long contexts. EMNLP.
Liu, Y., Ma, Y., Hildebrandt, M., Joblin, M., & Tresp, V. (2022). Tlogic: temporal logical rules for explainable link forecasting on temporal knowledge graphs. Proceedings of the AAAI conference on artificial intelligence, 36(4), 4120–4127.
Luo, R., Gu, T., Li, H., Li, J., Lin, Z., Li, J., & Yang, Y. (2024). Chain of history: learning and forecasting with llms for temporal knowledge graph completion. arXiv preprint arXiv:2401.06072.
Ma, W., Ding, Y., Yasunaga, M., & Leskovec, J. (2021). Temporal knowledge graph forecasting with sampled historical subgraphs. EMNLP.
Ma, Y., Ye, C., Wu, Z., Wang, X., Cao, Y., & Chua, T.-S. (2023). Context-aware event forecasting via graph disentanglement. Proceedings of the 29th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, 1643–1652.
Ma, Y., Ye, C., Wu, Z., Wang, X., Cao, Y., Pang, L., & Chua, T.-S. (2023). Structured, complex and time-complete temporal event forecasting. CoRR.
O’brien, S. P. (2010). Crisis early warning and decision support: contemporary approaches and thoughts on future research. International studies review, 12(1), 87–104.
Ong, R., Sun, J., Șerban, O., & Guo, Y.-K. (2023). Tkgqa dataset: using question answering to guide and validate the evolution of temporal knowledge graph. Data, 8(3), 61.
Schlichtkrull, M., Kipf, T. N., Bloem, P., van den Berg, R., Titov, I., & Welling, M. (2017). Modeling relational data with graph convolutional networks. https: //arxiv.org/abs/1703.06103
Su, J., Jiang, C., Jin, X., Qiao, Y., Xiao, T., Ma, H., Wei, R., Jing, Z., Xu, J., & Lin, J. (2024a). Large language models for forecasting and anomaly detection: a systematic literature review. https://arxiv.org/abs/2402.10350
Su, J., Jiang, C., Jin, X., Qiao, Y., Xiao, T., Ma, H., Wei, R., Jing, Z., Xu, J., & Lin, J. (2024b). Large language models for forecasting and anomaly detection: a systematic literature review. arXiv preprint arXiv:2402.10350.
Sultani, W., Chen, C., & Shah, M. (2018). Real-world anomaly detection in surveillance videos. Proceedings of the IEEE conference on computer vision and pattern recognition, 6479–6488.
Trivedi, R., Dai, H., Wang, Y., & Song, L. (2017). Know-evolve: deep temporal reasoning for dynamic knowledge graphs. https://arxiv.org/abs/1705.05742
Trivedi, R., Farajtabar, M., Biswal, P., & Zha, H. (2018). Representation learning over dynamic graphs. https://arxiv.org/abs/1803.04051
Trivedi, R., Faruqui, M., Dauphin, Y., & Yogatama, D. (2017). Know-evolve: deep temporal reasoning for dynamic knowledge graphs. ICML.
Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł., & Polosukhin, I. (2017). Attention is all you need. Advances in neural information processing systems, 30.
Wang, D., Zuo, Y., Li, F., & Wu, J. (2024). Llms as zero-shot graph learners: alignment of gnn representations with llm token embeddings. Advances in Neural Information Processing Systems, 37, 5950–5973.
Wei, J., Tay, Y., Bommasani, R., Raffel, C., Zoph, B., Borgeaud, S., Yogatama, D., Bosma, M., Zhou, D., Metzler, D., et al. (2022). Emergent abilities of large language models. arXiv preprint arXiv:2206.07682.
Xiong, S., Payani, A., Kompella, R., & Fekri, F. (2024). Large language models can learn temporal reasoning. arXiv preprint arXiv:2401.06853.
Xiong, S., Yang, Y., Fekri, F., & Kerce, J. C. (2024). Tilp: differentiable learning of temporal logical rules on knowledge graphs. arXiv preprint arXiv:2402.12309.
Xiong, S., Yang, Y., Payani, A., Kerce, J. C., & Fekri, F. (2024). Teilp: time prediction over knowledge graphs via logical reasoning. Proceedings of the AAAI Conference on Artificial Intelligence, 38(14), 16112–16119.
Xue, H., & Salim, F. D. (2023). Promptcast: a new prompt-based learning paradigm for time series forecasting. IEEE Transactions on Knowledge and Data Engineering, 36(11), 6851–6864.
Xue, H., Voutharoja, B. P., & Salim, F. D. (2022). Leveraging language foundation models for human mobility forecasting. Proceedings of the 30th International Conference on Advances in Geographic Information Systems, 1–9.
Yuan, T., Zhang, X., Liu, K., Liu, B., Chen, C., Jin, J., & Jiao, Z. (2023). Towards surveillance video-and-language understanding: new dataset, baselines, and challenges. https://arxiv.org/abs/2309.13925
Zanella, L., Menapace, W., Mancini, M., Wang, Y., & Ricci, E. (2024). Harnessing large language models for training-free video anomaly detection. Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, 18527–18536.
Zha, Z., Qi, P., Bao, X., Tian, M., & Qin, B. (2024). M 3 tqa: multi-view, multi-hop and multi-stage reasoning for temporal question answering. ICASSP 2024-2024 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), 10086–10090.
Zhang, M., Sun, M., Wang, P., Fan, S., Mo, Y., Xu, X., Liu, H., Yang, C., & Shi, C. (2024). Graphtranslator: aligning graph model to large language model for open-ended tasks. Proceedings of the ACM Web Conference 2024, 1003–1014.
Zhang, T., Huang, X., Zhao, W., Bian, S., & Du, P. (2023). Logprompt: a logbased anomaly detection framework using prompts. 2023 International Joint Conference on Neural Networks (IJCNN), 1–8.
Zhang, Y., Chen, Z., Guo, L., Xu, Y., Zhang, W., & Chen, H. (2024). Making large language models perform better in knowledge graph completion. Proceedings of the 32nd ACM International Conference on Multimedia, 233–242.
Zhao, L., Song, Y., Zhang, C., Liu, Y., Wang, P., Lin, Y., & Deng, M. (2019). T-gcn: a temporal graph convolutional network for traffic prediction. AAAI.
Zhou, Z., & Yu, R. (2024). Can llms understand time series anomalies? arXiv preprint arXiv:2410.05440.
-
dc.identifier.urihttp://tdr.lib.ntu.edu.tw/jspui/handle/123456789/98882-
dc.description.abstract大型語言模型(LLMs)近年被廣泛應用於時間知識圖譜(Temporal Knowledge Graph, TKG)預測任務中,作為傳統圖神經網路方法的泛化替代方案。特別是在異常事件預測這類仰賴時間推理與語用合理性的任務中,模型需要理解一連串行為在時間軸上的邏輯與變化,因此如何提供具備結構化時序資訊的輸入成為關鍵挑戰。然而,目前仍不清楚 LLMs 在此任務中,究竟是依賴結構化的 TKG 輸入效果較佳,或是非結構化的自然語言描述表現更好。本研究比較兩種輸入格式(TKG → Text 與 Text → Text)對於語意一致性與語用推理能力的影響。

TKG 以主詞-關係-受詞的三元組表示事件,並附有明確的時間區間,其結構化格式能提升資訊密度、降低語言歧義,並幫助模型掌握事件順序與語用邏輯,特別適合異常行為偵測等需要精確推理的任務。相對地,非結構化的自然語言輸入雖然更接近 LLM 的預訓練分布,也能提供豐富語境,但容易引入冗詞與語意聯想雜訊。

本研究實驗採用 UCA 資料集,該資料集包含具時間標註的影片說明文字與異常事件標籤,為評估語意生成與語用異常判斷能力提供了合適的實驗資料集。此研究分為兩部分進行評估。首先,使用 BGE 嵌入模型計算 LLM 預測輸出與真實描述之間的餘弦相似度。結果顯示,非結構化輸入的語意對齊表現略高(平均值 0.5978),而結構化輸入亦表現接近(平均值 0.5718),顯示即便上下文減少,TKG 輸入亦能維持語意理解能力。

第二部分實驗中,此研究將不同輸入格式作為上下文,判斷當前幀是否異常,並以 AUC 作為評估指標。結果顯示:使用 TKG 作為時間上下文可提升異常判斷準確性,AUC 分數優於原始文本與摘要文本輸入,突顯其在語用推理上的穩健性。

整體而言,非結構化輸入有利於語意連貫與表達,結構化輸入則在語用推理上展現出更高穩健性,特別是在異常事件預測這類高度仰賴時間順序與行為合理性的任務中,TKG 輸入可提供更具邏輯性的語用支撐。本研究結果突顯兩者在上下文學習(in-context learning, ICL)任務上的互補潛力,亦為未來混合式提示輸入設計提供了方向,進一步提升模型對時序事件之語用理解能力。
zh_TW
dc.description.abstractLarge language models (LLMs) have recently been applied to temporal knowledge graph (TKG) forecasting tasks, offering a generalizable alternative to traditional graph-based approaches. Particularly in abnormal event forecasting, where temporal reasoning and pragmatic coherence are essential, models must interpret the logical sequence and behavioral dynamics of actions over time. This raises a key challenge: how to provide input representations that encode structured temporal information. However, it remains unclear whether LLMs perform better in such tasks when guided by structured TKG inputs or by unstructured natural language descriptions. This thesis compares the effectiveness of structured (TKG → Text) and unstructured (Text → Text) inputs in forecasting abnormal events, with a focus on both semantic alignment and pragmatic reasoning.

TKGs represent events using subject–relation–object triples with explicit temporal spans. This structured format provides high information density, reduces linguistic ambiguity, and facilitates reasoning over temporal and causal dependencies—features that are particularly beneficial in tasks such as abnormal event detection. In contrast, unstructured textual descriptions offer rich contextual information and better alignment with LLMs’ pretraining data, but may introduce interpretive noise due to overgeneralization.

Experiments were conducted on the UCA (UCF Crime Annotation) dataset, which contains temporally annotated video captions and ground-truth anomaly labels, serving as a suitable benchmark for evaluating both semantic generation and pragmatic anomaly detection. A two-part evaluation was performed. First, cosine similarity between the LLM-generated and ground-truth descriptions was computed using the BGE embedding model. Results show that unstructured inputs yield slightly higher semantic alignment (mean = 0.5978) compared to structured inputs (mean = 0.5718), suggesting that LLMs remain effective even with reduced contextual cues.

In the second experiment, different input formats were used as temporal context to identify abnormal video frames. Using AUC as the evaluation metric, structured TKG inputs outperformed raw and summarized text, demonstrating stronger grounding and robustness in pragmatic reasoning.

Overall, while unstructured inputs promote semantic fluency, structured representations, such as TKGs, enhance logical grounding, particularly in abnormal event forecasting tasks that rely heavily on temporal reasoning and pragmatic coherence. These findings highlight the potential of hybrid input designs—within text-based in-context learning setups—to combine structural clarity with contextual richness, enabling more accurate and pragmatically coherent reasoning in temporal event forecasting.
en
dc.description.provenanceSubmitted by admin ntu (admin@lib.ntu.edu.tw) on 2025-08-20T16:08:42Z
No. of bitstreams: 0
en
dc.description.provenanceMade available in DSpace on 2025-08-20T16:08:42Z (GMT). No. of bitstreams: 0en
dc.description.tableofcontents目次 Table of Contents
致謝 .................................................... i

摘要 .................................................... iii

Abstract ................................................ v

Contents ................................................ vii

List of Figures ......................................... ix

List of Tables ......................................... x

1 Introduction ........................................ 1
1.1 Background and Research Context .............. 1
1.2 Motivation and Thesis Organization ........... 3

2 Literature Review .................................. 6
2.1 Large Language Models (LLMs) ................. 6
2.2 Knowledge Representation with Knowledge Graphs (KGs) and Temporal Knowledge Graphs (TKGs) .......... 8
 2.2.1 KGs and TKGs ..................................... 8
 2.2.2 TKG Forecasting .................................... 10
2.3 LLM Application in Forecasting and Anomaly Detection Tasks ..... 13
2.4 Input Representations and Prompting Strategies for LLMs ....... 16

3 Methodology ........................................ 19
3.1 Overviews ................................................. 19
3.2 Dataset ................................................... 19
3.3 Models Used .............................................. 21
3.4 Experiment 1: Forecasting ................................. 23
 3.4.1 Objective ............................................ 23
 3.4.2 Input Settings ....................................... 24
 3.4.3 TKG Construction from UCA Captions .................... 24
 3.4.4 Prompt Design ........................................ 25
 3.4.5 Prompted Generation via LLM .......................... 27
 3.4.6 Metrics .............................................. 27
3.5 Experiment 2: Anomaly Detection ........................... 28
 3.5.1 Objective ............................................ 28
 3.5.2 Prompt Design ........................................ 29
 3.5.3 Metrics .............................................. 31
3.6 Summary of Experiments ................................... 32

4 Results ............................................. 34
4.1 Forecasting Experiment Results ........................... 34
4.2 Anomaly Detection Experiment Results ..................... 36

5 Discussion .......................................... 38
5.1 Interpretation of Results and Research Questions ......... 38
5.2 Error Analysis ........................................... 40

6 Conclusion .......................................... 44
Appendix A Aligned Samples from UCF-Crime and UCA .... 48
References ............................................ 52
-
dc.language.isoen-
dc.subject大型語言模型zh_TW
dc.subject語用推理zh_TW
dc.subject非結構化文本zh_TW
dc.subject結構化輸入zh_TW
dc.subject異常事件預測zh_TW
dc.subject時間知識圖譜zh_TW
dc.subjectLarge Language Modelsen
dc.subjectPragmatic Reasoningen
dc.subjectUnstructured Texten
dc.subjectStructured Inputen
dc.subjectAbnormal Event Forecastingen
dc.subjectTemporal Knowledge Graphen
dc.title結構化與非結構化輸入於大型語言模型中之比較:以異常事件預測任務中的語意與語用預測能力評估為例zh_TW
dc.titleStructured vs. Unstructured Inputs in LLMs: Evaluating the Semantic and Pragmatic Predictive Power in Abnormal Event Forecastingen
dc.typeThesis-
dc.date.schoolyear113-2-
dc.description.degree碩士-
dc.contributor.oralexamcommittee張瑜芸;謝吉隆zh_TW
dc.contributor.oralexamcommitteeYu-Yun Chang;Ji-Lung Hsiehen
dc.subject.keyword大型語言模型,時間知識圖譜,異常事件預測,結構化輸入,非結構化文本,語用推理,zh_TW
dc.subject.keywordLarge Language Models,Temporal Knowledge Graph,Abnormal Event Forecasting,Structured Input,Unstructured Text,Pragmatic Reasoning,en
dc.relation.page58-
dc.identifier.doi10.6342/NTU202504087-
dc.rights.note同意授權(全球公開)-
dc.date.accepted2025-08-14-
dc.contributor.author-college文學院-
dc.contributor.author-dept語言學研究所-
dc.date.embargo-lift2025-08-21-
顯示於系所單位:語言學研究所

文件中的檔案:
檔案 大小格式 
ntu-113-2.pdf3.72 MBAdobe PDF檢視/開啟
顯示文件簡單紀錄


系統中的文件,除了特別指名其著作權條款之外,均受到著作權保護,並且保留所有的權利。

社群連結
聯絡資訊
10617臺北市大安區羅斯福路四段1號
No.1 Sec.4, Roosevelt Rd., Taipei, Taiwan, R.O.C. 106
Tel: (02)33662353
Email: ntuetds@ntu.edu.tw
意見箱
相關連結
館藏目錄
國內圖書館整合查詢 MetaCat
臺大學術典藏 NTU Scholars
臺大圖書館數位典藏館
本站聲明
© NTU Library All Rights Reserved