Skip to content

Leave the Source file name out of the text sent to the Guardrail - #239

Merged
MAOFILHO merged 1 commit into
stagingfrom
sandcastle/guardrail-no-source
Oct 29, 2026
Merged

MAOFILHO merged 1 commit into
stagingfrom
sandcastle/guardrail-no-source

Conversation

@MAOFILHO

Copy link
Copy Markdown
Owner

What

The Guardrail adapter removes the Source: block (the citation file name) from the text it sends. The citation list in the reply is unchanged.

Why

The live Guardrail Triage topic blocked the Emergency Department waiting time answer only when the file name emergency-and-urgent-care-info.md was in the text. Six direct apply-guardrail calls: with the Source block, 6 of 6 blocked; without it, 6 of 6 passed. The file name is system text from retrieval, not answer content. Grounding, relevance, the Safety Lambda and the citation check still see the full draft. The Guardrail config is unchanged.

Tests

New adapter test: the sent text has no Source block. Full suite: 259 tests, same 6 import errors as before (missing dependencies in worktrees).

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@MAOFILHO
MAOFILHO merged commit af183f0 into staging Oct 29, 2026
3 checks passed
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