Skip to content

armgit / letta

Public Imported from GitHub
0

Platform for stateful agents: AI with advanced memory that can learn and self-improve over time.

feat: deprecate use_assistant_message in list endpoints [LET-5793] (#5662)

cthomas75b3c0bf4d95
diff --git a/fern/openapi.json b/fern/openapi.json
index a29e941a7..994df0847 100644
--- a/fern/openapi.json
+++ b/fern/openapi.json
@@ -6462,10 +6462,12 @@
"schema": {
"type": "boolean",
"description": "Whether to use assistant messages",
+ "deprecated": true,
"default": true,
"title": "Use Assistant Message"
},
- "description": "Whether to use assistant messages"
+ "description": "Whether to use assistant messages",
+ "deprecated": true
},
{
"name": "assistant_message_tool_name",
@@ -6474,10 +6476,12 @@
"schema": {
"type": "string",
"description": "The name of the designated message tool.",
+ "deprecated": true,
"default": "send_message",
"title": "Assistant Message Tool Name"
},
- "description": "The name of the designated message tool."
+ "description": "The name of the designated message tool.",
+ "deprecated": true
},
{
"name": "assistant_message_tool_kwarg",
@@ -6486,10 +6490,12 @@
"schema": {
"type": "string",
"description": "The name of the message argument.",
+ "deprecated": true,
"default": "message",
"title": "Assistant Message Tool Kwarg"
},
- "description": "The name of the message argument."
+ "description": "The name of the message argument.",
+ "deprecated": true
},
{
"name": "include_err",
@@ -7882,10 +7888,12 @@
"schema": {
"type": "boolean",
"description": "Whether to use assistant messages",
+ "deprecated": true,
"default": true,
"title": "Use Assistant Message"
},
- "description": "Whether to use assistant messages"
+ "description": "Whether to use assistant messages",
+ "deprecated": true
},
{
"name": "assistant_message_tool_name",
@@ -7894,10 +7902,12 @@
"schema": {
"type": "string",
"description": "The name of the designated message tool.",
+ "deprecated": true,
"default": "send_message",
"title": "Assistant Message Tool Name"
},
- "description": "The name of the designated message tool."
+ "description": "The name of the designated message tool.",
+ "deprecated": true
},
{
"name": "assistant_message_tool_kwarg",
@@ -7906,10 +7916,12 @@
"schema": {
"type": "string",
"description": "The name of the message argument.",
+ "deprecated": true,
"default": "message",
"title": "Assistant Message Tool Kwarg"
},
- "description": "The name of the message argument."
+ "description": "The name of the message argument.",
+ "deprecated": true
}
],
"responses": {
diff --git a/letta/server/rest_api/routers/v1/agents.py b/letta/server/rest_api/routers/v1/agents.py
index 11d4aeb7d..029189250 100644
--- a/letta/server/rest_api/routers/v1/agents.py
+++ b/letta/server/rest_api/routers/v1/agents.py
@@ -1093,9 +1093,9 @@ async def list_messages(
),
order_by: Literal["created_at"] = Query("created_at", description="Field to sort by"),
group_id: str | None = Query(None, description="Group ID to filter messages by."),
- use_assistant_message: bool = Query(True, description="Whether to use assistant messages"),
- assistant_message_tool_name: str = Query(DEFAULT_MESSAGE_TOOL, description="The name of the designated message tool."),
- assistant_message_tool_kwarg: str = Query(DEFAULT_MESSAGE_TOOL_KWARG, description="The name of the message argument."),
+ use_assistant_message: bool = Query(True, description="Whether to use assistant messages", deprecated=True),
+ assistant_message_tool_name: str = Query(DEFAULT_MESSAGE_TOOL, description="The name of the designated message tool.", deprecated=True),
+ assistant_message_tool_kwarg: str = Query(DEFAULT_MESSAGE_TOOL_KWARG, description="The name of the message argument.", deprecated=True),
include_err: bool | None = Query(
None, description="Whether to include error messages and error statuses. For debugging purposes only."
),
diff --git a/letta/server/rest_api/routers/v1/groups.py b/letta/server/rest_api/routers/v1/groups.py
index fe9f4766b..fd703fbd0 100644
--- a/letta/server/rest_api/routers/v1/groups.py
+++ b/letta/server/rest_api/routers/v1/groups.py
@@ -234,9 +234,9 @@ async def list_group_messages(
"desc", description="Sort order for messages by creation time. 'asc' for oldest first, 'desc' for newest first"
),
order_by: Literal["created_at"] = Query("created_at", description="Field to sort by"),
- use_assistant_message: bool = Query(True, description="Whether to use assistant messages"),
- assistant_message_tool_name: str = Query(DEFAULT_MESSAGE_TOOL, description="The name of the designated message tool."),
- assistant_message_tool_kwarg: str = Query(DEFAULT_MESSAGE_TOOL_KWARG, description="The name of the message argument."),
+ use_assistant_message: bool = Query(True, description="Whether to use assistant messages", deprecated=True),
+ assistant_message_tool_name: str = Query(DEFAULT_MESSAGE_TOOL, description="The name of the designated message tool.", deprecated=True),
+ assistant_message_tool_kwarg: str = Query(DEFAULT_MESSAGE_TOOL_KWARG, description="The name of the message argument.", deprecated=True),
server: "SyncServer" = Depends(get_letta_server),
headers: HeaderParams = Depends(get_headers),
):