~/talk

Improving Text2Cypher: Lessons from Schema Filtering and Hard Example Selection

Talkat NODES 2025 · on Thursday, 2025-11-06· [large-language-models, databases]
links:none on file
slides:none on file

Neo4j builds a Text2Cypher pipeline that converts a graph schema to text and selects only relevant elements before calling an LLM, using dynamic schema filtering (regex, named‑entity masking, and similarity embeddings) to cut prompt size from ~2700 tokens to ~500 and raise exactness by ~10% (enhanced→base ≈+5%, dynamic→+5%). For training, hard example selection ranks queries by model failure on a foundation model and by Cypher complexity to keep the hard 40% and trim data, reducing training time and cost by ~60% while dropping a metric from ~75% to ~71%.

AI-written summary · about

  1. 0:00Introduction to Text2Cypher
  2. 1:55Problem of translating natural language to Cypher
  3. 3:23Inference time optimizations with schema filtering
  4. 10:53Training time improvements with hard example selection
  5. 16:57Summary and future work
  6. 19:07Q&A session
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.