Stop pre-injecting. Let the agent search.
The common pattern is: your system runs RAG or prompt expansion, picks some chunks, and injects them into the prompt. This has three problems:- You guess wrong. Your retrieval heuristic decides what’s relevant before the agent knows what it needs for this specific step.
- It poisons. Injected chunks the agent didn’t ask for are exactly the surface for context poisoning.
- It’s opaque. Neither you nor the user can tell what actually drove the answer.
This is agentic search over all your structured content, not a bolt-on RAG index.
In Open Index the agent gets
navigation_guidelines() (what doc_types,
fields, and relationships exist), search_brain(), and get_entity() — enough to
navigate a domain it’s never seen.Give the agent a map before the first query
Retrieval accuracy jumps when the agent knows the shape of what it’s searching. Before its first query, hand it navigational context:- Which doc_types exist (
service,runbook,incident…) and what each means. - Which fields each carries, and which are searchable.
- Which relationships connect them, so it can traverse on purpose.
search only incidents), follows edges
deliberately, and stops guessing. Without it, every query is a blind shot.
Tune ranking so the right record wins
Precision is also a ranking problem. Two levers matter most:Per-field boosts
Per-field boosts
Weight a match in
name far above a match in a long description. A genuine
multiplier — a hit in a boost: 6 title outranks a boost: 1 body hit
6-to-1 — so the record whose identity matches the query surfaces first. →
Search configurationHybrid keyword + semantic
Hybrid keyword + semantic
Keyword search nails exact names and identifiers; semantic search rescues queries
that describe a thing in different words than the record uses (“checkout is slow”
→ “latency spike at payment”). Blend them — keyword-dominant by default, with a
semantic weight you raise when users describe rather than name.
Design schemas for retrieval
Search accuracy starts at the schema, not the query:- Mark identity fields (
name,owner,status) syntactic — exact/prefix matching, high boost. - Mark prose fields (
description,summary) semantic — matched by meaning. - Mark opaque blobs and internal ids
none— stored but never searched, so they can’t add noise to results.
Checklist
- The agent searches; you don’t pre-inject a guessed context blob.
- It gets navigational meta-info (doc_types, fields, relationships) up front.
- Identity fields are boosted; noise fields are
search: none. - Ranking blends keyword + semantic to match both names and descriptions.
Next: Conflicts & staleness
Keeping retrieved context correct as it grows.