mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
Python: fix: GroupChat ManagerSelectionResponse JSON Schema for OpenAI Structured Outpu… (#2750)
* fix: ManagerSelectionResponse JSON Schema for OpenAI Structured Output Strict Mode * refactor: install pre-commit then commit again
This commit is contained in:
@@ -132,7 +132,11 @@ class ManagerSelectionResponse(BaseModel):
|
||||
final_message: Optional final message string when finishing conversation (will be converted to ChatMessage)
|
||||
"""
|
||||
|
||||
model_config = {"extra": "forbid"}
|
||||
model_config = {
|
||||
"extra": "forbid",
|
||||
# OpenAI strict mode requires all properties to be in required array
|
||||
"json_schema_extra": {"required": ["selected_participant", "instruction", "finish", "final_message"]},
|
||||
}
|
||||
|
||||
selected_participant: str | None = None
|
||||
instruction: str | None = None
|
||||
|
||||
Reference in New Issue
Block a user