Reconstructs a structured warehouse from the 687-document corpus, then answers each question with a deterministic query (no LLM arithmetic). Question→shape routing is deterministic where possible, with an LLM planner (Groq) for the paraphrased tail.
SCORED 91.5% in the actual hackathon
- Extract the corpus into structured JSON warehouses (
build/):works.json— completion certificates (value, client, PM, category, date, grade)references.json— reference letters (work→has-reference, role)personnel.json— personnel certs + CVs (credentials, experience, business unit)financials.json— receivables, trial balance, plant register
- Normalize every rupee value through an exact Indian-currency parser.
- Resolve entities by canonical keys (
Pkg-NN,EMP-ID, client name+state). - Answer each question: classify its shape → extract parameters against known
entities → run the matching deterministic handler → format per
answer_type.
Numbers are computed in Python; the LLM only classifies a question's shape.
pip install -r requirements.txt
# place the organisers' dataset at ./dataset (BITS-Hackathon-Dataset)
python src/extract_works.py && python src/extract_references.py \
&& python src/extract_personnel.py && python src/extract_financials.py
python src/submit.py # -> build/submission.csv (371 rows)
python dataset/evaluate.py --submission build/sample.csv --questions dataset/sample_questions.jsonThe optional LLM planner reads a provider key from .env (GROQ_API_KEY); without a
key it is skipped and only the deterministic router runs.
src/normalize_money.py— exact Cr/Lakh/grouping → rupeessrc/extract_*.py— corpus → warehousessrc/classify.py— deterministic shape classifiersrc/plan.py— LLM shape-planner fallback (cached)src/answer.py— shape handlers + entity resolutionsrc/submit.py— routing, new-family handlers, CSV outputsrc/eval_harness.py— self-scoring against the sample set