Skip to content

Commit

Permalink
chore: add model_config for orm instance
Browse files Browse the repository at this point in the history
  • Loading branch information
polebug committed Jan 25, 2025
1 parent a5e3d3e commit b5ba6cf
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions openagent/router/routes/models/response.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ class AgentListResponse(BaseModel):


class ModelResponse(BaseModel):
model_config = ConfigDict(from_attributes=True)

id: int
name: str
description: str | None = None
Expand All @@ -103,6 +105,8 @@ class ModelListResponse(BaseModel):


class ToolResponse(BaseModel):
model_config = ConfigDict(from_attributes=True)

id: int
name: str
description: str | None = None
Expand Down

0 comments on commit b5ba6cf

Please sign in to comment.