Skip to content

Declare audit_quotes in the attest_response input schema - #92

Open
karpovantonme wants to merge 1 commit into
jonashertner:mainfrom
karpovantonme:attest-response-audit-quotes
Open

Declare audit_quotes in the attest_response input schema#92
karpovantonme wants to merge 1 commit into
jonashertner:mainfrom
karpovantonme:attest-response-audit-quotes

Conversation

@karpovantonme

Copy link
Copy Markdown

What this changes

attest_response declares draft_text and audit_grounding in its input schema. The handler reads a third argument:

audit_quotes=bool(arguments.get("audit_quotes", False)),

Adds audit_quotes to the schema so a client can actually reach it.

Why

_handle_attest_response honours the flag, and its docstring points callers at it: "Callers that still want the whole-document quote audit can pass audit_quotes=True." No MCP client can. The property is not in the schema, so a model never learns it exists, and the call succeeds either way while silently running with the default. The quote audit is unreachable over MCP today.

Nothing in the handler changes; the description text is taken from the reasons already given in _handle_attest_response for why it defaults to off.

Checklist

  • make test passes locally (offline, no live network in tests)
  • New behaviour has a test; a fixed defect has a regression test
  • No figure introduced that contradicts docs/canonical_numbers.md
  • Citation strings come from stored fields, never constructed (R1–R3)
  • If this touches publish.py, DB schemas, base_scraper.py or state/: it does not

tests/test_attest_response_schema.py fails on main and passes here.

The make test box is unchecked on purpose: I ran the two files that touch this area, not the full suite. mcp 2.0 breaks collection for your existing tests as well (AttributeError: 'Server' object has no attribute ...), so I pinned mcp<2 locally; requirements.txt currently says mcp>=1.27.0 with no upper bound, which may be worth a separate look.

The handler reads arguments.get('audit_quotes') and honours it, but the
schema did not declare it, so no MCP client could reach the quote audit.
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