unsloth/studio/backend/core/rag
Daniel Han b085b37b69 Studio RAG trim: remove cross-encoder reranker
The cross-encoder reranker is off by default (enable_rerank=False everywhere)
and adds a second model download plus a candidate-widening pass on every search.
Removing it keeps the core retrieval (parse, chunk, embed, BM25 + dense, RRF,
search_knowledge_base tool) intact while dropping ~375 lines.

- delete core/rag/reranker.py and its test
- drop enable_rerank / reranker_model from the search tool, tools dispatch,
  and the /rag/search route (candidate_k is now just top_k)
- remove the /rag/reranker/precache endpoint and reranker config knobs
- update tool-handler test to the trimmed rag_scope shape

42 RAG tests pass.
2026-05-31 14:14:52 +00:00
..
parsers Studio: tighten RAG code comments 2026-05-31 08:31:08 +00:00
__init__.py Studio: add RAG with hybrid search, reranker, chat integration 2026-05-23 18:46:15 +04:00
authorization.py Studio: fix RAG correctness bugs 2026-05-31 09:56:23 +00:00
bm25.py Studio: fast RAG path (warm embedder + in-process ingest + FTS5 BM25) behind UNSLOTH_RAG_FAST 2026-05-31 13:31:01 +00:00
bm25_fts.py Studio: fast RAG path (warm embedder + in-process ingest + FTS5 BM25) behind UNSLOTH_RAG_FAST 2026-05-31 13:31:01 +00:00
captioner.py Studio: tighten RAG code comments 2026-05-31 08:31:08 +00:00
chunking.py Studio: tighten RAG code comments 2026-05-31 08:31:08 +00:00
db.py Studio: trim verbose comments/docstrings across RAG code 2026-05-26 13:51:11 +04:00
embeddings.py Studio: tighten RAG code comments 2026-05-31 08:31:08 +00:00
ingestion.py Studio: fast RAG path (warm embedder + in-process ingest + FTS5 BM25) behind UNSLOTH_RAG_FAST 2026-05-31 13:31:01 +00:00
locators.py Studio: fix RAG correctness bugs 2026-05-31 09:56:23 +00:00
retrieval.py Studio: fix RAG correctness bugs 2026-05-31 09:56:23 +00:00
scope.py Studio: fix RAG correctness bugs 2026-05-31 09:56:23 +00:00
tool.py Studio RAG trim: remove cross-encoder reranker 2026-05-31 14:14:52 +00:00
vector_store.py Studio: WIP — RAG preview UI, locator/auth refactor, tests, fixtures (pre-merge snapshot) 2026-05-28 00:13:43 +03:00