diff --git a/fern/openapi.json b/fern/openapi.json index 994df084..c12370e8 100644 --- a/fern/openapi.json +++ b/fern/openapi.json @@ -7225,9 +7225,9 @@ "/v1/agents/{agent_id}/summarize": { "post": { "tags": ["agents"], - "summary": "Summarize Agent Conversation", + "summary": "Summarize Messages", "description": "Summarize an agent's conversation history to a target message length.\n\nThis endpoint summarizes the current message history for a given agent,\ntruncating and compressing it down to the specified `max_message_length`.", - "operationId": "summarize_agent_conversation", + "operationId": "summarize_messages", "parameters": [ { "name": "agent_id", diff --git a/letta/server/rest_api/routers/v1/agents.py b/letta/server/rest_api/routers/v1/agents.py index 02918925..f69e0a83 100644 --- a/letta/server/rest_api/routers/v1/agents.py +++ b/letta/server/rest_api/routers/v1/agents.py @@ -1681,8 +1681,8 @@ async def preview_raw_payload( ) -@router.post("/{agent_id}/summarize", status_code=204, operation_id="summarize_agent_conversation") -async def summarize_agent_conversation( +@router.post("/{agent_id}/summarize", status_code=204, operation_id="summarize_messages") +async def summarize_messages( request_obj: Request, # FastAPI Request agent_id: AgentId, max_message_length: int = Query(..., description="Maximum number of messages to retain after summarization."),