How zhengtat/final-year-project works
CUMAP builds an expert knowledge graph from textbook material, extracts student-answer graphs, and compares them to diagnose correct, incomplete, or contradictory understanding. The README documents data preparation, gold annotation, evaluation, and review/demo capabilities as additional branches. Sampled pipeline and LLM code supports the expert-graph stages and shared model-call layer; student extraction and diagnosis internals were not sampled, so those components and their links are represented only at the documented subsystem level.
Main entry points: cli.py CLI workflows · pipeline.py Expert KG pipeline · suggest_expert.py Gold annotation tools · client.py LLM client
Components 22
Corpus preparation
- Dataset preparation
src/cumap/data - Textbook fetch
src/cumap/textbook/fetch.py - Textbook parsing
src/cumap/textbook/parse.py - Textbook coverage
src/cumap/textbook/coverage.py
Knowledge graphs
- Expert KG pipeline
src/cumap/expert_kg/pipeline.py - Concept canonicalization
src/cumap/expert_kg/canonicalize.py - Relation extraction
src/cumap/expert_kg/relations.py - KG snapshots
src/cumap/expert_kg/snapshots.py
Student diagnosis
- Student graph extraction
src/cumap - Graph diagnosis
src/cumap/schemas/diagnosis.py - Relation registry
src/cumap/schemas/relations.py
Shared platform
- Graph schemas
src/cumap/schemas/edges.py - LLM client
src/cumap/llm/client.py - Prompt templates
src/cumap/llm/prompts.py - Configuration
src/cumap/config.py
Review and evaluation
- Gold annotation tools
src/cumap/gold/suggest_expert.py - Gold validation
src/cumap/gold/validate.py - Evaluation
src/cumap/eval - Reports and visualization
src/cumap/report/build.py - Gold review app
src/cumap/app/gold_editor.py
Other components
- Engineer / educator
- CLI workflows
src/cumap/cli.py
Connections 27
- Engineer / educator → CLI workflows: runs commands
README.md - CLI workflows → Dataset preparation: prepares datasets
src/cumap/cli.py - CLI workflows → Textbook fetch: fetches source
src/cumap/cli.py - CLI workflows → Textbook parsing: parses sections
src/cumap/cli.py - CLI workflows → Textbook coverage: checks coverage
src/cumap/cli.py - Textbook fetch → Textbook parsing: provides source
- CLI workflows → Expert KG pipeline: builds expert graph
- Expert KG pipeline → Concept canonicalization: canonicalizes mentions
src/cumap/expert_kg/pipeline.py - Expert KG pipeline → Relation extraction: resolves relations
src/cumap/expert_kg/pipeline.py - Expert KG pipeline → KG snapshots: creates snapshots
src/cumap/expert_kg/pipeline.py - CLI workflows → Student graph extraction: extracts answer graph
src/cumap/cli.py - Student graph extraction → Graph diagnosis: supplies student graph
- Expert KG pipeline → Graph diagnosis: supplies expert graph
- Graph diagnosis → Relation registry: aligns relations
- CLI workflows → Gold annotation tools: suggests annotations
src/cumap/cli.py - Gold annotation tools → LLM client: requests suggestions
src/cumap/gold/suggest_expert.py - Gold annotation tools → Gold validation: verifies quotes
src/cumap/gold/suggest_expert.py - CLI workflows → Gold validation: validates gold
src/cumap/cli.py - CLI workflows → Evaluation: runs evaluation
src/cumap/cli.py - CLI workflows → Reports and visualization: builds demo reports
src/cumap/cli.py - Reports and visualization → KG snapshots: loads snapshots
src/cumap/report/build.py - Engineer / educator → Gold review app: reviews annotations
- Gold review app → Gold validation: validates edits
src/cumap/app/gold_editor.py - Gold annotation tools → Graph schemas: constructs graph records
src/cumap/gold/suggest_expert.py - LLM client → Configuration: reads settings
src/cumap/llm/client.py - Gold annotation tools → Prompt templates: renders prompts
src/cumap/gold/suggest_expert.py - LLM client → Prompt templates: uses templates