Academic Journal
Large Language Model-Based Text-to-Cypher Generation for Question-Answering on Biomedical Knowledge Graphs.
| Title: | Large Language Model-Based Text-to-Cypher Generation for Question-Answering on Biomedical Knowledge Graphs. |
|---|---|
| Authors: | Seeha S; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital., Abdelmoula A; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital., Boeker M; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital., Modersohn L; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital., Pallaoro P; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.; Technical University of Munich, TUM School of Medicine and Health, Data Integration Center, TUM University Hospital. |
| Source: | Studies in health technology and informatics [Stud Health Technol Inform] 2026 Sep 17; Vol. 340, pp. 179-186. |
| Publication Type: | Journal Article |
| Language: | English |
| Journal Info: | Publisher: IOS Press Country of Publication: Netherlands NLM ID: 9214582 Publication Model: Print Cited Medium: Internet ISSN: 1879-8365 (Electronic) Linking ISSN: 09269630 NLM ISO Abbreviation: Stud Health Technol Inform Subsets: MEDLINE |
| Imprint Name(s): | Original Publication: Amsterdam ; Washington, DC : IOS Press, 1991- |
| MeSH Terms: | Information Storage and Retrieval*/methods , Large Language Models* , Natural Language Processing*, Humans |
| Abstract: | Introduction: Knowledge graphs are widely adopted due to their flexible structure and ability to represent large-scale, heterogeneous data. However, as these graphs grow, the queries used to retrieve information become more complex, making efficient information retrieval and question answering more challenging. Objective: This work investigates (1) the impact of few-shot versus zero-shot prompting on Cypher query generation, and (2) performance differences between small (∼7B) and mid-size (∼32B) large language models (LLMs) on both of these approaches. Methods: We propose a system that translates natural language questions into Cypher queries for execution on a Neo4j knowledge graph and evaluates answer quality on the PrimeKG and BioHopR datasets. To address data protection and cost constraints, we focus on locally deployable LLMs that require no additional training, using zero-shot and few-shot prompting strategies. Results: 32B models generate syntactically valid Cypher queries using only the knowledge graph schema information. Few-shot prompting with four examples improves F1 score by 35.7 percentage points (∼62% relative improvement) compared to zero-shot prompting. While 7B models struggle to generate syntactically valid queries in the zero-shot setting, few-shot prompting substantially improves their performance, enabling high query syntax validity and F1 scores above 80%. Conclusion: Few-shot prompting heavily improves query generation quality and enables effective use of smaller models, supporting the practical deployment of locally hosted LLMs for knowledge graph question answering. |
| Contributed Indexing: | Keywords: Database Management Systems; Factual Database; Information Storage and Retrieval; Large Language Models; Natural Language Processing |
| Entry Date(s): | Date Created: 20260917 Date Completed: 20260917 Latest Revision: 20260917 |
| Update Code: | 20260918 |
| DOI: | 10.3233/SHTI261000 |
| PMID: | 42752482 |
| Database: | MEDLINE |
| FullText | Text: Availability: 0 |
|---|---|
| Header | DbId: cmedm DbLabel: MEDLINE An: 42752482 AccessLevel: 3 PubType: Academic Journal PubTypeId: academicJournal PreciseRelevancyScore: 0 |
| IllustrationInfo | |
| Items | – Name: Title Label: Title Group: Ti Data: Large Language Model-Based Text-to-Cypher Generation for Question-Answering on Biomedical Knowledge Graphs. – Name: Author Label: Authors Group: Au Data: <searchLink fieldCode="AU" term="%22Seeha+S%22">Seeha S</searchLink>; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.<br /><searchLink fieldCode="AU" term="%22Abdelmoula+A%22">Abdelmoula A</searchLink>; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.<br /><searchLink fieldCode="AU" term="%22Boeker+M%22">Boeker M</searchLink>; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.<br /><searchLink fieldCode="AU" term="%22Modersohn+L%22">Modersohn L</searchLink>; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.<br /><searchLink fieldCode="AU" term="%22Pallaoro+P%22">Pallaoro P</searchLink>; Technical University of Munich, TUM School of Medicine and Health, Institute for AI and Informatics in Medicine (AIIM), TUM University Hospital.; Technical University of Munich, TUM School of Medicine and Health, Data Integration Center, TUM University Hospital. – Name: TitleSource Label: Source Group: Src Data: <searchLink fieldCode="JN" term="%229214582%22">Studies in health technology and informatics</searchLink> [Stud Health Technol Inform] 2026 Sep 17; Vol. 340, pp. 179-186. – Name: TypePub Label: Publication Type Group: TypPub Data: Journal Article – Name: Language Label: Language Group: Lang Data: English – Name: TitleSource Label: Journal Info Group: Src Data: <i>Publisher: </i><searchLink fieldCode="PB" term="%22IOS+Press%22">IOS Press </searchLink><i>Country of Publication: </i>Netherlands <i>NLM ID: </i>9214582 <i>Publication Model: </i>Print <i>Cited Medium: </i>Internet <i>ISSN: </i>1879-8365 (Electronic) <i>Linking ISSN: </i><searchLink fieldCode="IS" term="%2209269630%22">09269630 </searchLink><i>NLM ISO Abbreviation: </i>Stud Health Technol Inform <i>Subsets: </i>MEDLINE – Name: PublisherInfo Label: Imprint Name(s) Group: PubInfo Data: <i>Original Publication</i>: Amsterdam ; Washington, DC : IOS Press, 1991- – Name: SubjectMESH Label: MeSH Terms Group: Su Data: <searchLink fieldCode="MM" term="%22Information+Storage+and+Retrieval%22">Information Storage and Retrieval*</searchLink>/<searchLink fieldCode="MM" term="%22Information+Storage+and+Retrieval+methods%22">methods</searchLink> <br /><searchLink fieldCode="MM" term="%22Large+Language+Models%22">Large Language Models*</searchLink> <br /><searchLink fieldCode="MM" term="%22Natural+Language+Processing%22">Natural Language Processing*</searchLink><br /><searchLink fieldCode="MH" term="%22Humans%22">Humans</searchLink> – Name: Abstract Label: Abstract Group: Ab Data: Introduction: Knowledge graphs are widely adopted due to their flexible structure and ability to represent large-scale, heterogeneous data. However, as these graphs grow, the queries used to retrieve information become more complex, making efficient information retrieval and question answering more challenging.<br />Objective: This work investigates (1) the impact of few-shot versus zero-shot prompting on Cypher query generation, and (2) performance differences between small (∼7B) and mid-size (∼32B) large language models (LLMs) on both of these approaches.<br />Methods: We propose a system that translates natural language questions into Cypher queries for execution on a Neo4j knowledge graph and evaluates answer quality on the PrimeKG and BioHopR datasets. To address data protection and cost constraints, we focus on locally deployable LLMs that require no additional training, using zero-shot and few-shot prompting strategies.<br />Results: 32B models generate syntactically valid Cypher queries using only the knowledge graph schema information. Few-shot prompting with four examples improves F1 score by 35.7 percentage points (∼62% relative improvement) compared to zero-shot prompting. While 7B models struggle to generate syntactically valid queries in the zero-shot setting, few-shot prompting substantially improves their performance, enabling high query syntax validity and F1 scores above 80%.<br />Conclusion: Few-shot prompting heavily improves query generation quality and enables effective use of smaller models, supporting the practical deployment of locally hosted LLMs for knowledge graph question answering. – Name: SubjectMinor Label: Contributed Indexing Group: Data: <i>Keywords: </i>Database Management Systems; Factual Database; Information Storage and Retrieval; Large Language Models; Natural Language Processing – Name: DateEntry Label: Entry Date(s) Group: Date Data: <i>Date Created: </i>20260917 <i>Date Completed: </i>20260917 <i>Latest Revision: </i>20260917 – Name: DateUpdate Label: Update Code Group: Date Data: 20260918 – Name: DOI Label: DOI Group: ID Data: 10.3233/SHTI261000 – Name: AN Label: PMID Group: ID Data: 42752482 |
| PLink | https://search.ebscohost.com/login.aspx?direct=true&site=eds-live&db=cmedm&AN=42752482 |
| RecordInfo | BibRecord: BibEntity: Identifiers: – Type: doi Value: 10.3233/SHTI261000 Languages: – Code: eng Text: English PhysicalDescription: Pagination: StartPage: 179 Subjects: – SubjectFull: Humans Type: general – SubjectFull: Information Storage and Retrieval methods Type: general – SubjectFull: Large Language Models Type: general – SubjectFull: Natural Language Processing Type: general Titles: – TitleFull: Large Language Model-Based Text-to-Cypher Generation for Question-Answering on Biomedical Knowledge Graphs. Type: main BibRelationships: HasContributorRelationships: – PersonEntity: Name: NameFull: Seeha S – PersonEntity: Name: NameFull: Abdelmoula A – PersonEntity: Name: NameFull: Boeker M – PersonEntity: Name: NameFull: Modersohn L – PersonEntity: Name: NameFull: Pallaoro P IsPartOfRelationships: – BibEntity: Dates: – D: 17 M: 09 Text: 2026 Sep 17 Type: published Y: 2026 Identifiers: – Type: issn-electronic Value: 1879-8365 Numbering: – Type: volume Value: 340 Titles: – TitleFull: Studies in health technology and informatics Type: main |
| ResultId | 1 |