You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Anthropic provider: structured-output schema rejected (minimum/maximum on integer/number) #76
Summary
In v2.1.4, the Anthropic provider fails on every LLM-mode scan: the structured-output
schema it sends includes minimum/maximum, which the Anthropic structured-output API
rejects.
What happens
The semantic analyzers fail with two successive HTTP 400s from the Anthropic API — it
rejects minimum/maximum, once on an integer field and once on a number field.
Root cause
The output models declare start_line: int = Field(ge=1) and confidence: float = Field(ge=0, le=1). Pydantic serializes these to JSON-Schema minimum/maximum, and Anthropic's structured-output endpoint does not accept those
keywords on integer/number types.
Repro
Run skillspector scan <path> in LLM mode with SKILLSPECTOR_PROVIDER=anthropic and a
valid ANTHROPIC_API_KEY (no --no-llm). → two 400s, analyzers fail. Static --no-llm
mode is unaffected.
Suggested fix
Keep the Pydantic constraints (they're valid validation) and sanitize the schema sent to
Anthropic — strip minimum/maximum from the structured-output schema in the Anthropic
provider. (Confirmed locally that removing the constraints unblocks all three semantic
analyzers; schema-sanitization is the correct upstream form that preserves validation.)
Great find! I’m currently diving into security automation and analyzing how different LLM providers handle schema validation. It’s insightful to see how these edge cases are being addressed in SkillSpector. Keep up the excellent work! 🙂
Closing as resolved by #85, which adds native Anthropic provider support and resolves the structured-output tool schema failures caused by unsupported minimum/maximum parameters.
Activity
Varrennyyam commentedon Jun 15, 2026
Great find! I’m currently diving into security automation and analyzing how different LLM providers handle schema validation. It’s insightful to see how these edge cases are being addressed in SkillSpector. Keep up the excellent work! 🙂
Sync OSS release snapshot - Merge pull request #85 from NVIDIA/keshav…
keshprad commentedon Jun 16, 2026
Closing as resolved by #85, which adds native Anthropic provider support and resolves the structured-output tool schema failures caused by unsupported minimum/maximum parameters.
Sync OSS release snapshot - Merge pull request NVIDIA#85 from NVIDIA/…