← all repositories
IlyaRice/RAG-Challenge-2

The scrappy Python stack that swept a RAG challenge

A competition-winning retrieval system for annual-report Q&A that trades polish for technique.

2.4k stars Python RAG · SearchLLMOps · Eval
RAG-Challenge-2
Not currently ranked — collecting fresh signals.
star history

What it does This repo holds the code that won both prize categories in the RAG Challenge competition. It answers questions about company annual reports by parsing PDFs with Docling, retrieving chunks via vector search with parent-document fallback, reranking contexts with an LLM, and routing queries that compare multiple companies. The pipeline uses structured chain-of-thought prompting and offers several model configs, including one that simply feeds everything to Gemini’s full-context window instead of retrieving at all.

The interesting bit The author is admirably blunt: this is competition code, full of rough edges and weird workarounds, with no tests and minimal error handling. That honesty is refreshing, and it keeps the focus on the techniques—parent-document retrieval, LLM reranking, and query routing—that actually moved the leaderboard.

Key highlights

  • Won both prize nominations in the RAG Challenge for annual-report Q&A
  • Combines Docling PDF parsing, vector search with parent-document retrieval, and LLM-based reranking
  • Uses structured output prompting with chain-of-thought reasoning
  • Includes a gemini_thinking config that abandons RAG entirely in favor of Gemini’s full-context window
  • Ships with both a small test set and the full ERC2 competition dataset

Caveats

  • IBM Watson integration is hardcoded for the competition and will not work out of the box
  • No tests, minimal error handling, and the author warns of “weird workarounds”
  • Requires your own OpenAI or Gemini API keys, and PDF parsing is slow without a GPU

Verdict Worth studying if you are building document-QA pipelines and want to see which RAG techniques actually win benchmarks. Skip it if you need a polished, production-ready framework to drop into your stack.

Frequently asked

What is IlyaRice/RAG-Challenge-2?
A competition-winning retrieval system for annual-report Q&A that trades polish for technique.
Is RAG-Challenge-2 open source?
Yes — IlyaRice/RAG-Challenge-2 is open source, released under the MIT license.
What language is RAG-Challenge-2 written in?
IlyaRice/RAG-Challenge-2 is primarily written in Python.
How popular is RAG-Challenge-2?
IlyaRice/RAG-Challenge-2 has 2.4k stars on GitHub.
Where can I find RAG-Challenge-2?
IlyaRice/RAG-Challenge-2 is on GitHub at https://github.com/IlyaRice/RAG-Challenge-2.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.