Hacker News new | ask | show | jobs
Show HN: Smart Router Kit – Prevent "Garbage in" for RAG Using Pydantic and LLMs (github.com)
1 points by 2dogsanerd 207 days ago
Yesterday I shared my Ingest Kit here. Today I'm releasing the second part: The routing logic.

Problem: Blindly chunking every PDF leads to bad retrieval. Solution: A small LLM pass (Traffic Controller) that routes documents to semantic collections (Finance vs Tech) and selects chunking strategies (Table-Aware vs Standard) before ingestion.

It's a simple pattern using Pydantic to force structured decisions from local LLMs (Ollama).

Repo: https://github.com/2dogsandanerd/smart-router-kit Part1: https://github.com/2dogsandanerd/smart-ingest-kit