Files
smartguide/docs/thesis/README.md
T
arzani 552fa2daaf
LocationBasedServices/smartguide/pipeline/head There was a failure building this commit
Added fakordb tests
2026-11-03 13:50:10 +01:00

117 lines
9.5 KiB
Markdown

# Master's thesis on the INSE knowledge graph: three research plans
Status: proposal, 2026-09-17. Supersedes the engineering-oriented outline
(`~/.claude/plans/consider-the-context-of-robust-hopcroft.md`) as the basis for choosing a topic.
Three alternative six-month theses, one per research community. Pick one; they share data and
infrastructure but differ in research question, method and evaluation.
| | Plan | Community | One-line question |
|---|---|---|---|
| A | [Certain, possible, wrong](plan-a-knowledge-graphs.md) | Knowledge graphs / Semantic Web | What does identity-link error do to answers over a multi-source graph, and can answers carry that uncertainty? |
| B | [Learning when not to answer](plan-b-nlp.md) | NLP | Can reinforcement fine-tuning make a small model reliable at text-to-Cypher, including abstaining and qualifying, in German and English? |
| C | [Does the graph find the right people?](plan-c-information-retrieval.md) | Information retrieval | Does graph evidence improve expert and industry-partner retrieval when evaluated without temporal leakage? |
## Why the original outline is no longer a research topic
The original outline had five parts: build the graph, fix identities, write a benchmark, compare
retrieval setups, fine-tune text-to-Cypher. Two things changed.
**The engineering is done.** `service/scripts/falkordb/bulk_load.py` builds the whole-university graph
in about 20 minutes: 6,176 active UDE researchers, 204,110 works, 693,487 authors, 26,246 institutions,
3,664 projects, 366 patents, 4,402 news articles, 547 companies and 10 million relationships, in 1.3 GB
of FalkorDB memory. A local LLM (LM Studio, qwen3-8b) already queries it through the FalkorDB MCP
server, and `service/scripts/falkordb/QUERIES.md` holds a tested query cookbook.
**The obvious research questions are published.** Literature check, September 2026 (from search
results and abstracts; the student must read and verify each before citing):
| Idea in the original outline | Already covered by |
|---|---|
| Fine-tune a small model for text-to-Cypher, also with RL and execution feedback | Text2Cypher (Ozsoy et al., GenAIK 2025); "Refining Text2Cypher on Small Language Model with Reinforcement Learning" (Applied Sciences 15(15):8206, 2025, GRPO); Multi-Agent GraphRAG text-to-Cypher (arXiv 2511.08274) |
| Generate training and test questions from the graph itself | CypherBench (ACL 2025); PIPE-Cypher (arXiv 2606.08481); KG2Cypher (arXiv 2606.27742); grounded KG data generation (arXiv 2606.14325) |
| Non-English text-to-Cypher | Text2Cypher Across Languages (arXiv 2506.21445; Spanish, Turkish); adapter combination (arXiv 2601.16097). German is still missing, but adding a language alone is incremental |
| Does the graph beat vector search, and on which question types | "When to use Graphs in RAG" / GraphRAG-Bench (ICLR 2026, arXiv 2506.05690); "RAG vs. GraphRAG" (arXiv 2502.11371); "Do We Still Need GraphRAG?" (arXiv 2604.09666); GraphRAG-Router (arXiv 2604.16401) |
| Agentic, multi-step graph retrieval trained with RL | Graph-R1 (arXiv 2507.21892); KG-R1 (arXiv 2509.26383) |
| Robustness of KG-augmented LLMs to a noisy graph | OKGQA-P (ACL 2025, arXiv 2410.08085); KG-RAG under incompleteness (2025); "Less is More: Denoising KGs for RAG" (arXiv 2510.14271). All use random perturbations or LLM-extracted graphs |
## What is still open, and why this project is well placed
Building and querying the `ude` graph produced five observations that the literature does not
address and that the project's data can test:
1. **The links between sources are inferred, with structured error.** Patents carry no person IDs, so
`INVENTOR_OF` rests on name matching (`match_type` institution / name / both). Company officers and
news mentions are exact name matches (`common_name_warning`, `ambiguous`). One researcher named
Thomas Kaiser matches 92 companies. OpenAlex itself over-merges profiles: a cohort profile
"Róbert Langer" carries the MIT chemist's 251 industry partners. Prior robustness work perturbs
graphs at random; nobody measures what realistic identity error does to answers.
2. **Link semantics change numbers by a factor of six.** Industry co-publications of one researcher:
61 with author-level affiliations, 10 when the affiliation must hold on the paper itself. Counting
and ranking answers are fragile in a way lookups are not.
3. **Observed and inferred edges sit side by side** (`DFG_ROLE` via ORCID is verified, `OFFICER_OF` is a
name match), and every inferred edge records its method. That is the raw material for confidence-
and provenance-aware answering, which exists in database theory (certain and possible answers,
identity-linkage uncertainty) but not in LLM-based graph question answering.
4. **A small local model fails silently.** Without the schema, qwen3-8b invented a property
(`a.institution`), got nulls, and told the user the information "is not available". Separately, the
server's 10,000-row result cap truncated a 206k-row read without any error. Neither failure is
visible to the user. Reliability (answer, qualify, or abstain) is unexplored for text-to-Cypher;
TrustSQL (arXiv 2403.15879) and GrailQAbility (ACL 2023) cover SQL and Freebase only, and
abstention-aware RL (TruthRL, arXiv 2509.25760) covers open-domain QA only.
5. **The graph has time.** Works, patents, projects and per-paper affiliations are dated up to 2026, so
"who will start working with industry" can be evaluated on events that happened after a language
model's knowledge cutoff, which is the only leakage-free way to evaluate LLM-based recommendation.
## Assets every plan can use
- The `ude` graph, loader (`bulk_load.py`, twelve idempotent phases), and query cookbook.
- Edge-level evidence: `INVENTOR_OF.match_type`, `OFFICER_OF.common_name_warning`,
`Author.hr_company_matches`, `MENTIONED_IN.ambiguous`, `DFG_ROLE.source`, `AUTHORED.institution_ids`,
`Work.primary_category` (LLM classification of 187k works).
- Existing evaluations to build on: `service/scripts/patents/data/author_patent_evaluation/` (three
experiments on author-patent matching), `llm_evaluations/news_ident_person/` (50 labelled news
articles), `analysis/career_stage/` (60 labelled researchers, 4.6% suspicious profiles),
`service/scripts/profiling/founding_potential/`, `llm_evaluations/sentence_transformer/`.
- LLM access through `inse.integrations.llm` (any OpenAI-compatible endpoint), a terminal harness that
drives an LLM through the FalkorDB MCP tools, and the e5 embedding model in the service image.
## Fixed conditions (decided 2026-09-17)
| | |
|---|---|
| Duration | 26 weeks |
| Annotation | Two annotators, about 40 hours each |
| Data release | Open sources only: OpenAlex (CC0), CORDIS, patent offices; DFG GEPRIS licence to be checked. Handelsregister and news-person links stay internal; results on them are reported in aggregate |
| Compute | One 80 GB GPU: QLoRA supervised fine-tuning and GRPO on 7 to 8B models are feasible |
| Tools | FalkorDB, Unsloth (as in the original outline) |
| Data protection | One agreed paragraph with the chair before week 3; a section in the thesis |
## How to choose
| | A: knowledge graphs | B: NLP | C: information retrieval |
|---|---|---|---|
| Core novelty | Realistic identity error, certain/possible answers, LLM pipelines that use link confidence | Reliability-aware RL for text-to-Cypher, infeasible and uncertain questions, German | Leakage-free evaluation of graph-augmented expert and partner retrieval, graph-supervised reranker |
| Main risk | Gold set quality; possible-worlds cost on aggregates | A close paper appears first; RL instability | Too few post-cutoff events; pooling depth |
| Fine-tuning share | Small (one supervised model) | Central (SFT and GRPO, several models) | Medium (reranker) |
| Annotation use | 500 to 600 identity links, answer-quality ratings | 400 question validations, German naturalness, error taxonomy | 1,500 to 2,000 relevance judgments |
| Value to INSE after the thesis | Confidence on every cross-source link, fixes the biggest data-quality problem | A local model that can be trusted in the UI | A measured answer to "should scouting use the graph" and a reusable test collection |
| Student profile | Data management, statistics, some ML | Deep learning, RL, NLP evaluation | IR evaluation, ranking, some graph ML |
| Venues | ISWC, ESWC, CIKM, K-CAP; Semantic Web Journal, TGDK | ACL / EMNLP / NAACL Findings; TrustNLP, UncertaiNLP, KnowledgeNLP, GenAIK; LREC-COLING for the dataset | SIGIR (short, resource), ECIR, CIKM, ICTIR; JCDL |
Recommendation: Plan A is the most defensible against being scooped, because it depends on data only
this project has (measured cross-source identity error), and it turns the most valuable part of the
original outline (Part 2) into the research question. Plan B is the best fit if the student wants a
model-centric thesis and the 80 GB GPU should be used fully. Plan C has the most direct product value.
Combining is possible but should be resisted: each plan fills 26 weeks. The one sensible overlap is
that Plan B may borrow Plan A's "uncertain evidence" question category, and Plan C may report
Plan A's robustness-to-identity-error as one ablation.
## Common first four weeks
1. Run INSE locally, obtain Elasticsearch read access, rebuild `ude` with `run.sh bulk --graph ude --reset`.
2. Read `service/scripts/falkordb/README.md`, `QUERIES.md`, the profiling READMEs.
3. Literature chapter skeleton from the reading list in the chosen plan; verify every citation.
4. Data-protection paragraph agreed; annotation guidelines drafted; annotators booked.