Skip to content

Commit 4a047b1

Browse files
docs: clarify task name is optional in adk.acp.create_task
task/create is get-or-create by name, so reusing an existing name returns that task with its prior history rather than creating a new one. Document on the hand-written ADK entry point that name is optional: omit it (or make it unique) for a fresh task each call. Avoids accidental duplicate/stale tasks, especially in multi-agent delegation. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 2df25c7 commit 4a047b1

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

  • src/agentex/lib/adk/_modules

src/agentex/lib/adk/_modules/acp.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,11 @@ async def create_task(
6868
Create a new task.
6969
7070
Args:
71-
name: The name of the task.
71+
name: Optional human-readable name for the task. task/create is
72+
get-or-create by name: omit it (or make it unique, e.g. append a
73+
UUID) for a fresh task on each call; passing a name that already
74+
exists returns that task with its prior history instead of
75+
creating a new one. Keep it globally unique when set.
7276
agent_id: The ID of the agent to create the task for.
7377
agent_name: The name of the agent to create the task for.
7478
params: The parameters for the task.

0 commit comments

Comments
 (0)