M10 · RAG · vector DB · reranking
RAG and retrieval
Hybrid retrieval with metadata filters, reranking, citation and permission checks.
$ python -m fde_toolkit rag --query "..."
Workflow
the order an FDE actually runs it in
- 1Parse and structure the document, then chunk semantically.
- 2Embed and index with tenant, role and date metadata.
- 3Retrieve with hybrid dense plus keyword scoring.
- 4Filter by permission and metadata before reranking.
- 5Select evidence, generate, and cite every claim.
Function output
deterministic trace
query='EDD refresh policy' strategy=sentence top_k=5 dense 0.456 · keyword 0.570 -> hybrid 0.6(0.456) + 0.4(0.570) = 0.502 chunk #4 selected, 1 citation attached, 2 chunks dropped by tenant filter
