Avoid warnings from pydantic for overriding schema

Also fix structured output in completions
This commit is contained in:
Ashwin Bharambe 2024-10-28 13:36:17 -07:00
parent ed833bb758
commit eccd7dc4a9
7 changed files with 50 additions and 26 deletions

View file

@ -109,7 +109,7 @@ class _HfAdapter(Inference, ModelsProtocolPrivate):
if fmt.type == ResponseFormatType.json_schema.value:
options["grammar"] = {
"type": "json",
"value": fmt.schema,
"value": fmt.json_schema,
}
elif fmt.type == ResponseFormatType.grammar.value:
raise ValueError("Grammar response format not supported yet")