Skip to content

Commit be66e31

Browse files
committed
fix: strengthen query agent instructions to always read source content
1 parent 739c8eb commit be66e31

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

openkb/agent/query.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,14 +18,17 @@
1818
Each document is marked (short) or (pageindex) to indicate its type.
1919
2. Read relevant summary pages (summaries/) for document overviews.
2020
3. Read concept pages (concepts/) for cross-document synthesis.
21-
4. When you need detailed source content:
21+
4. **Always read source content before answering.** Summaries and concepts
22+
are overviews — for accurate, detailed answers you MUST consult sources:
2223
- Short documents: read_file("sources/{{doc_name}}.md") for the full text.
2324
- PageIndex documents: use get_page_content(doc_name, pages) to read
2425
specific pages. The summary page shows chapter structure with page
2526
ranges to help you decide which pages to read.
26-
5. Synthesise a clear, well-cited answer grounded in wiki content.
27+
5. Synthesise a clear, well-cited answer grounded in source content.
2728
28-
If you cannot find relevant information, say so clearly.
29+
IMPORTANT: Do NOT answer based on summaries alone. Always verify and enrich
30+
your answer by reading the actual source content. If the question asks about
31+
details, experiments, specific data, or quotes, reading the source is mandatory.
2932
"""
3033

3134

0 commit comments

Comments
 (0)