Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
dirkbrnd committed Feb 12, 2025
1 parent 31d7ee6 commit ab696af
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion libs/agno/agno/agent/agent.py
Original file line number Diff line number Diff line change
Expand Up @@ -1490,7 +1490,7 @@ def get_session_data(self) -> Dict[str, Any]:
if self.session_state is not None and len(self.session_state) > 0:
session_data["session_state"] = self.session_state
if self.session_metrics is not None:
session_data["session_metrics"] = self.session_metrics
session_data["session_metrics"] = asdict(self.session_metrics)
if self.team_data is not None:
session_data["team_data"] = self.team_data
if self.images is not None:
Expand Down
1 change: 1 addition & 0 deletions libs/agno/agno/agent/metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,3 +93,4 @@ def __radd__(self, other: Union["SessionMetrics", "MessageMetrics"]) -> "Session
if other == 0: # Handle sum() starting value
return self
return self + other

5 changes: 4 additions & 1 deletion libs/agno/agno/models/google/gemini.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,10 @@ def _convert_schema(schema_dict):
Returns:
types.Schema: The converted schema.
"""
schema_type = schema_dict.get("type", "").upper()
schema_type = schema_dict.get("type", "")
if isinstance(schema_type, list):
schema_type = schema_type[0]
schema_type = schema_type.upper()
description = schema_dict.get("description", "")

if schema_type == "OBJECT" and "properties" in schema_dict:
Expand Down

0 comments on commit ab696af

Please sign in to comment.