MICROSOFT AGENT FRAMEWORK · 0.16.0-rc.1
Business retrieval and structured sources
Combine similarity, product reference and active procedure before building context.
Objectives
- Business context and filters
- Vectors, lexical signal and RRF
- Local threshold and relevance limits
The question identifies a business object
EP010 asks which quality procedure applies to GX-900 gears after heat treatment. A note containing GX-900 is not necessarily the applicable procedure. Product status and its procedure link belong to structured reference data; document retrieval then supplies the procedure text. Top-K alone does not resolve this relationship.
Two complementary sources
RagProducts retains Product, Status, Procedure and Treatment separately from chunks. DetectProduct recognizes GX references followed by three digits. FindProduct validates the manifest and compares the stored fact with the current corpus. An unknown or retired product yields no usable context. An active product further limits hits to the same reference and procedure before hybrid selection; SQL filtering already applies status, canonical flag, dates and scope.
In a real application, inventory, prices, permissions or order status require current structured data, often an API or SQL. Turning them into embedded paragraphs can delay updates and lose their identity. The fixture keeps these data in the same SQLite file for ease of execution; it is neither an authorization system nor an industrial reference database.
Fuse controlled signals
Dense retrieval captures semantic similarity; lexical matching helps exact references and names. The renovated version computes actual cosine, fuses ranks with RRF and enforces the threshold and overlap. EP010’s old simulated local ranking is not retained as vector evidence. No additional neural reranker is used; final selection is deterministic.
- Question → GX reference → active product fact
- Eligible SQLite sources → product/procedure match
- Vectors + exact terms → RRF rank → at most three excerpts
- Citation contract → host gate → quotations or refusal
Compare known, unknown and out-of-domain requests
dotnet run --project demos/Demo220_BusinessRetrieval/Demo220.App.csproj -c Release --no-build -- --Rag:Action compare --Rag:AsOf 2026-10-23dotnet run --project demos/Demo220_BusinessRetrieval/Demo220.App.csproj -c Release --no-build -- --Rag:Action answer --Rag:AsOf 2026-10-23 --Rag:Question "Which quality control procedure applies to GX-900 gears after heat treatment?"After ingestion in the same working root, compare raw and governed lists. Check Product and Procedure, then actually retained SourceId values. Repeat answer for GX-999 and How do I bake an apple pie?: a missing product or out-of-domain request must not receive a fabricated procedure. A diagnostic probe may show neighbors that answer rejects; displaying them authorizes no conclusion.
Context remains subject to business review
The reference regex is limited to the fixture vocabulary. The model decides neither product status nor authorized procedure. Exact quotations do not prove every manufacturing condition has been addressed. Real decisions require fuller eligibility rules and human validation; no score authorizes manufacturing.
Return to code and evidence
Prerequisites
Continue reading
Previous
Next
