Problem
providers.json ships an anthropic provider entry (models claude-opus-4-8, claude-sonnet-5, claude-haiku-4-5) with "structured_output": "json_object", and evaluator.py/pdf.py always send temperature and top_p in the request body. Using a real ANTHROPIC_API_KEY against this config fails on the very first request:
400 {"error":{"code":"invalid_request_error","message":"`temperature` is deprecated for this model.","type":"invalid_request_error","param":null}}
After dropping temperature, top_p also fails the same way:
400 {"error":{"code":"invalid_request_error","message":"`top_p` is deprecated for this model.","type":"invalid_request_error","param":null}}
And response_format.type: "json_object" is rejected outright:
400 {"error":{"code":"invalid_request_error","message":"response_format.type: Input should be 'json_schema'","type":"invalid_request_error","param":null}}
Switching to "json_schema" then requires a strict flag and a schema with additionalProperties: false set recursively — which EvaluationData.model_json_schema() (a plain Pydantic export) doesn't produce, so that path also 400s:
400 {"error":{"code":"invalid_request_error","message":"response_format.json_schema.schema: For 'object' type, 'additionalProperties' must be explicitly set to false","type":"invalid_request_error","param":null}}
Net effect: the anthropic entry in providers.json cannot currently complete a single request end-to-end against the real API.
Repro
DEFAULT_MODEL=claude-sonnet-5
ANTHROPIC_API_KEY=<real key>
python score.py ./resume/sample.pdf
Fails with the 400 above on both the GitHub-project-selection call and the final evaluation call.
Fix that worked
- Added a
supports_temperature flag (default true) to the provider config, threaded through config.provider_for() → llm_utils.initialize_llm_provider() → OpenAICompatibleProvider, and skip sending temperature/top_p when it's false.
- Set
"structured_output": "none" for the anthropic entry so no response_format is sent at all — the existing prompt-only JSON instructions (and extract_json_from_response's markdown-fence stripping) are enough; claude-sonnet-5 follows them reliably.
With those two changes, a full score.py run completes end-to-end against real claude-sonnet-5.
Problem
providers.jsonships ananthropicprovider entry (modelsclaude-opus-4-8,claude-sonnet-5,claude-haiku-4-5) with"structured_output": "json_object", andevaluator.py/pdf.pyalways sendtemperatureandtop_pin the request body. Using a realANTHROPIC_API_KEYagainst this config fails on the very first request:After dropping
temperature,top_palso fails the same way:And
response_format.type: "json_object"is rejected outright:Switching to
"json_schema"then requires astrictflag and a schema withadditionalProperties: falseset recursively — whichEvaluationData.model_json_schema()(a plain Pydantic export) doesn't produce, so that path also 400s:Net effect: the
anthropicentry inproviders.jsoncannot currently complete a single request end-to-end against the real API.Repro
Fails with the 400 above on both the GitHub-project-selection call and the final evaluation call.
Fix that worked
supports_temperatureflag (defaulttrue) to the provider config, threaded throughconfig.provider_for()→llm_utils.initialize_llm_provider()→OpenAICompatibleProvider, and skip sendingtemperature/top_pwhen it'sfalse."structured_output": "none"for theanthropicentry so noresponse_formatis sent at all — the existing prompt-only JSON instructions (andextract_json_from_response's markdown-fence stripping) are enough;claude-sonnet-5follows them reliably.With those two changes, a full
score.pyrun completes end-to-end against realclaude-sonnet-5.