請用此 Handle URI 來引用此文件:
http://tdr.lib.ntu.edu.tw/jspui/handle/123456789/89093
完整後設資料紀錄
DC 欄位 | 值 | 語言 |
---|---|---|
dc.contributor.advisor | 黃乾綱 | zh_TW |
dc.contributor.advisor | Chien-Kang Huang | en |
dc.contributor.author | 林怡萱 | zh_TW |
dc.contributor.author | Yi-Hsuan Lin | en |
dc.date.accessioned | 2023-08-16T17:06:12Z | - |
dc.date.available | 2023-11-09 | - |
dc.date.copyright | 2023-08-16 | - |
dc.date.issued | 2023 | - |
dc.date.submitted | 2023-08-07 | - |
dc.identifier.citation | 1. Brown, T.B., et al., Language models are few-shot learners, in Proceedings of the 34th International Conference on Neural Information Processing Systems. 2020, Curran Associates Inc.: Vancouver, BC, Canada. p. Article 159.
2. Cao, R., et al. LGESQL: Line Graph Enhanced Text-to-SQL Model with Mixed Local and Non-Local Relations. 2021. Online: Association for Computational Linguistics. 3. Chen, Z., et al. ShadowGNN: Graph Projection Neural Network for Text-to-SQL Parser. 2021. Online: Association for Computational Linguistics. 4. Gan, Y., et al. Natural SQL: Making SQL Easier to Infer from Natural Language Specifications. 2021. Punta Cana, Dominican Republic: Association for Computational Linguistics. 5. Guo, J., et al. Towards Complex Text-to-SQL in Cross-Domain Database with Intermediate Representation. 2019. Florence, Italy: Association for Computational Linguistics. 6. Kojima, T., et al., Large Language Models are Zero-Shot Reasoners. ArXiv, 2022. abs/2205.11916. 7. Lee, J.-O. and D.-K. Baik. SemQL: a semantic query language for multidatabase systems. in International Conference on Information and Knowledge Management. 1999. 8. Lei, W., et al. Re-examining the Role of Schema Linking in Text-to-SQL. 2020. Online: Association for Computational Linguistics. 9. Li, H., et al., Decoupling the Skeleton Parsing and Schema Linking for Text-to-SQL. arXiv preprint arXiv:2302.05965, 2023. 10. Li, J., et al., Graphix-T5: Mixing Pre-Trained Transformers with Graph-Aware Layers for Text-to-SQL Parsing. arXiv preprint arXiv:2301.07507, 2023. 11. Lin, X.V., R. Socher, and C. Xiong. Bridging Textual and Tabular Data for Cross-Domain Text-to-SQL Semantic Parsing. 2020. Online: Association for Computational Linguistics. 12. Liu, A., et al., A comprehensive evaluation of ChatGPT's zero-shot Text-to-SQL capability. arXiv preprint arXiv:2303.13547, 2023. 13. OpenAI, GPT-4 Technical Report. ArXiv, 2023. abs/2303.08774. 14. Pourreza, M. and D. Rafiei, DIN-SQL: Decomposed In-Context Learning of Text-to-SQL with Self-Correction. arXiv preprint arXiv:2304.11015, 2023. 15. Qi, J., et al. RASAT: Integrating Relational Structures into Pretrained Seq2Seq Model for Text-to-SQL. 2022. Abu Dhabi, United Arab Emirates: Association for Computational Linguistics. 16. Raffel, C., et al., Exploring the limits of transfer learning with a unified text-to-text transformer. J. Mach. Learn. Res., 2020. 21(1): p. Article 140. 17. Rajkumar, N., R. Li, and D. Bahdanau, Evaluating the text-to-sql capabilities of large language models. arXiv preprint arXiv:2204.00498, 2022. 18. Scholak, T., N. Schucher, and D. Bahdanau. PICARD: Parsing Incrementally for Constrained Auto-Regressive Decoding from Language Models. 2021. Online and Punta Cana, Dominican Republic: Association for Computational Linguistics. 19. Tang, L.R. and R.J. Mooney, Using multiple clause constructors in inductive logic programming for semantic parsing, in Proceedings of the 12th European Conference on Machine Learning. 2001, Springer-Verlag: Freiburg, Germany. p. 466–477. 20. Wang, B., et al. RAT-SQL: Relation-Aware Schema Encoding and Linking for Text-to-SQL Parsers. 2020. Online: Association for Computational Linguistics. 21. Wei, J., et al., Chain of Thought Prompting Elicits Reasoning in Large Language Models. ArXiv, 2022. abs/2201.11903. 22. Xu, P., et al. Optimizing Deeper Transformers on Small Datasets. 2021. Online: Association for Computational Linguistics. 23. Yu, T., et al. CoSQL: A Conversational Text-to-SQL Challenge Towards Cross-Domain Natural Language Interfaces to Databases. 2019. Hong Kong, China: Association for Computational Linguistics. 24. Yu, T., et al. Spider: A Large-Scale Human-Labeled Dataset for Complex and Cross-Domain Semantic Parsing and Text-to-SQL Task. 2018. Brussels, Belgium: Association for Computational Linguistics. 25. Yu, T., et al. SParC: Cross-Domain Semantic Parsing in Context. 2019. Florence, Italy: Association for Computational Linguistics. 26. Zeng, L., S.H.K. Parthasarathi, and D. Hakkani-Tur. N-Best Hypotheses Reranking for Text-to-SQL Systems. in 2022 IEEE Spoken Language Technology Workshop (SLT). 2023. 27. Zhang, Z., et al., Automatic chain of thought prompting in large language models. arXiv preprint arXiv:2210.03493, 2022. 28. Zhao, Y., et al., Importance of synthesizing high-quality data for text-to-SQL parsing. arXiv preprint arXiv:2212.08785, 2022. 29. Zhong, R., T. Yu, and D. Klein. Semantic Evaluation for Text-to-SQL with Distilled Test Suites. 2020. Online: Association for Computational Linguistics. 30. Zhong, V., C. Xiong, and R. Socher, Seq2sql: Generating structured queries from natural language using reinforcement learning. arXiv preprint arXiv:1709.00103, 2017. 31. Zhuang, L., et al. A Robustly Optimized BERT Pre-training Approach with Post-training. 2021. Huhhot, China: Chinese Information Processing Society of China. | - |
dc.identifier.uri | http://tdr.lib.ntu.edu.tw/jspui/handle/123456789/89093 | - |
dc.description.abstract | 在面臨大量的查詢資料表需求時,減少人工撰寫SQL指令的工作量成為一個重要課題。因此,Text-to-SQL任務逐漸受到學術界及業界的關注。起初,解決Text-to-SQL任務的方法主要是使用seq2seq模型;然而,隨著大型語言模型的迅速發展,近年來一些研究人員開始在大型語言模型進行語境學習,以評估其性能。日後,思維鏈(chain-of-thought, COT)技巧的有效性也受到廣泛關注,促使各領域嘗試將其應用於觀念分解及推理過程,其中DIN-SQL是個典型的例子。然而,即使它在Spider資料集執行準確率(Execution Accurancy, EX)排行榜上表現出色,但在模式連結的處理上仍有不足之處。
本研究主要目的是針對DIN-SQL模型進行優化。首先進行錯誤分析,探討其預測失敗的原因,並提出改善性能的提示(prompt)方法。我們使用GPT-3.5模型進行測試,並提出了三種改善方向,分別是針對模式連結、分解與分類、與自我修正模組進行改善。實驗結果表示,這三種改善方向都成功提升模型性能。其中,針對模式連結的改善方式──將RESDSQL交叉編碼器與DINSQL自我修正模組相結合──被證明是最佳的改善方法,與基線模型相比,這種改進方法可以提高3.82%的性能,應用GPT-3.5與GPT-4模型下,分別達到74.1%與79.79%的準確率。 | zh_TW |
dc.description.abstract | When faced with a large number of query data tables, reducing the workload of manually writing SQL commands has become an important topic. Therefore, the text-to-SQL task has gradually attracted the attention of academia and industry. At first, the method to solve the text-to-SQL task was mainly to use the seq2seq model; however, with the rapid development of large-scale language models (LLMs), some researchers have begun to perform in-context learning on LLMs to evaluate their performance in recent years. After that, the effectiveness of the chain-of-thought (COT) technique has also received widespread attention. It makes more researchers from various fields to try to apply it to the concept decomposition and reasoning process, of which DIN-SQL is a typical example. However, even though it performed well on the Execution Accuracy (EX) leaderboard of the Spider dataset, it still has shortcomings in the processing of schema linking.
The main purpose of this study is to optimize the DIN-SQL model. Firstly, error analysis is carried out to explore the reasons for its prediction failure, and a prompt method to improve performance is proposed. I used the GPT-3.5 model for testing, and proposed three improvement directions, namely for schema linking, decomposition and classification, and self-correction modules for improvement. The experimental results show that all three improvement directions have successfully improved the model performance. Among them, the improvement method for schema linking, combining the RESDSQL cross-encoder with the DINSQL self-correction module proved to be the best improvement method. This method can improve performance by 3.82% compared with the baseline model. When using the GPT-3.5 and GPT-4 models, the EX accuracies were 74.1% and 79.79%, respectively. | en |
dc.description.provenance | Submitted by admin ntu (admin@lib.ntu.edu.tw) on 2023-08-16T17:06:12Z No. of bitstreams: 0 | en |
dc.description.provenance | Made available in DSpace on 2023-08-16T17:06:12Z (GMT). No. of bitstreams: 0 | en |
dc.description.tableofcontents | 誌謝 i
摘要 iii Abstract iv 目錄 vi 圖目錄 ix 表目錄 x 第一章 緒論 1 1.1 研究背景及動機 1 1.2 研究目的 2 1.3 研究貢獻 2 1.4 論文架構 3 第二章 相關背景知識及文獻 4 2.1 Text-to-SQL資料集 4 2.1.1 本研究使用的Spider資料集 5 2.2 應用於Text-to-SQL任務的Seq2seq模型 6 2.3 應用於Text-to-SQL任務的大型語言模型(Large Language Model, LLM) 8 2.4 語境學習(In-Context Learning) 9 2.5 Spider資料集執行準確率最先進模型──「DIN-SQL + GPT-4」 10 2.6 Spider資料集執行準確率最先進的seq2seq模型──「RESDSQL-3B + NatSQL」 12 第三章 問題定義與研究方法 14 3.1 問題定義 14 3.2 最先進模型的錯誤分析 16 3.2.1 GPT-4與GPT-3.5錯誤分析比較 16 3.2.2 本研究的改善策略 20 3.3 研究方法 21 3.3.1 Rev1.1──ReDINSQL:從RESDSQL交叉編碼器取得模式連結結果 21 3.3.2 Rev1.2:新增實體修正模組 23 3.3.3 Rev2:調整分解與分類模組提示架構 24 3.3.4 Rev3:重寫自我修正模組 25 第四章 研究結果與討論 26 4.1 實驗規劃 26 4.2 相關設置 26 4.2 資料集 26 4.3 評估指標 27 4.4 實驗結果 28 4.4.1 Rev1:模式連結優化方式比較 28 4.4.2 Rev2:分解與分類模組改進方式比較 29 4.4.3 Rev3:自我修正模組與生成結果修正方式改進比較 31 4.4.4 最佳性能提示架構與基線提示架構錯誤分析比較 31 4.4.5 最佳性能提示架構在GPT-4上的結果討論 32 4.5 問題討論 34 4.5.1 使用提示於線上的大型語言模型產生回應的穩定性討論 34 4.5.2 DIN-SQL與zero-shot性能討論 35 第五章 結論與未來展望 36 5.1 結論 36 5.2 未來展望 37 參考文獻 38 附錄A──錯誤分析分類說明 41 附錄B──DIN-SQL作者對於數據異議的解釋 42 | - |
dc.language.iso | zh_TW | - |
dc.title | 在語境學習中研究各種提示以改善Text-to-SQL任務分解 | zh_TW |
dc.title | Exploring Diverse Prompts to Improve Text-to-SQL Task Decomposition in In-Context Learning | en |
dc.type | Thesis | - |
dc.date.schoolyear | 111-2 | - |
dc.description.degree | 碩士 | - |
dc.contributor.oralexamcommittee | 丁肇隆;張恆華;駱明凌 | zh_TW |
dc.contributor.oralexamcommittee | Chao-Lung Ting;Herng-Hua Chang;Ming-Ling Lo | en |
dc.subject.keyword | Text-to-SQL,深度學習,大型語言模型,思維鏈, | zh_TW |
dc.subject.keyword | Text-to-SQL,Deep Learning,Large Language Model,chain-of-thought, | en |
dc.relation.page | 42 | - |
dc.identifier.doi | 10.6342/NTU202303187 | - |
dc.rights.note | 同意授權(全球公開) | - |
dc.date.accepted | 2023-08-09 | - |
dc.contributor.author-college | 工學院 | - |
dc.contributor.author-dept | 工程科學及海洋工程學系 | - |
顯示於系所單位: | 工程科學及海洋工程學系 |
文件中的檔案:
檔案 | 大小 | 格式 | |
---|---|---|---|
ntu-111-2.pdf | 1.75 MB | Adobe PDF | 檢視/開啟 |
系統中的文件,除了特別指名其著作權條款之外,均受到著作權保護,並且保留所有的權利。