Skip to content

fix: QA prompt instructs LLM to use recall tool#400

Merged
BYK merged 1 commit into
mainfrom
fix-qa-recall
May 19, 2026
Merged

fix: QA prompt instructs LLM to use recall tool#400
BYK merged 1 commit into
mainfrom
fix-qa-recall

Conversation

@BYK
Copy link
Copy Markdown
Owner

@BYK BYK commented May 19, 2026

Summary

The eval QA system prompt told the LLM to answer 'based on the provided context', which made it answer only from the system prompt injection. It never invoked the recall tool — confirmed by zero recall invocations across all CM-1 questions.

Fix

Updated QA_SYSTEM prompt to explicitly instruct the LLM to:

  • Use the recall tool to search for specific details
  • Always invoke recall before answering unless the answer is already in context
  • Follow t:<id> source citations for exact values

Results

Recall is now invoked on every QA question (verified via gateway logs). However, the gateway strips the recall tool after the first call (#399), so the LLM can't follow up on source citations. The scoring impact is limited by this architectural constraint.

Files Changed

  • packages/core/eval/baselines.ts — QA_SYSTEM prompt

The eval QA system prompt said 'based on the provided context' which
made the LLM answer only from the system prompt injection. It never
invoked the recall tool, missing all searchable details.

Now explicitly instructs: use recall to search for specific details,
follow t:<id> source citations for exact values.

Recall now invoked on every QA question (verified via gateway logs).
@BYK BYK self-assigned this May 19, 2026
@BYK BYK merged commit a1cf7d2 into main May 19, 2026
10 checks passed
@BYK BYK deleted the fix-qa-recall branch May 19, 2026 20:04
This was referenced May 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant