You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
These are different than sub agents because they are not "smart tools"
but rather a list of agents that the current agent can hand the
conversation to, the new agent can continue with hte conversation and
has access to the whole history.
Signed-off-by: Djordje Lukic <djordje.lukic@docker.com>
Copy file name to clipboardExpand all lines: cagent-schema.json
+28-5Lines changed: 28 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -92,6 +92,13 @@
92
92
"type": "string"
93
93
}
94
94
},
95
+
"handoffs": {
96
+
"type": "array",
97
+
"description": "List of agents this agent can hand off the conversation to",
98
+
"items": {
99
+
"type": "string"
100
+
}
101
+
},
95
102
"add_date": {
96
103
"type": "boolean",
97
104
"description": "Whether to add date information"
@@ -662,17 +669,26 @@
662
669
"items": {
663
670
"type": "object",
664
671
"description": "Retrieval strategy configuration with type-specific parameters. Structured fields are limited; additional parameters are passed through as-is for strategy-specific use.",
665
-
"required": ["type"],
672
+
"required": [
673
+
"type"
674
+
],
666
675
"properties": {
667
676
"type": {
668
677
"type": "string",
669
678
"description": "Retrieval strategy type",
670
-
"enum": ["chunked-embeddings", "bm25"]
679
+
"enum": [
680
+
"chunked-embeddings",
681
+
"bm25"
682
+
]
671
683
},
672
684
"model": {
673
685
"type": "string",
674
686
"description": "Embedding model reference for chunked-embeddings strategies (looked up in models map, or 'auto' for automatic selection)",
"description": "Similarity metric (chunked-embeddings only). Currently only 'cosine_similarity' is implemented.",
691
-
"enum": ["cosine_similarity"]
707
+
"enum": [
708
+
"cosine_similarity"
709
+
]
692
710
},
693
711
"vector_dimensions": {
694
712
"type": "integer",
695
713
"description": "Vector dimensions for embeddings (chunked-embeddings only). Must match your embedding model's output dimensions and is required for chunked-embeddings strategies.",
You are a helpful assistant that can hand off tasks to other agents.
7
+
Look at the descriptions ofthe avaiable agents, if any of them is better suited to answer the user question, you must call the handoff tool to transfer the task to that agent.
8
+
handoffs:
9
+
- web_search
10
+
11
+
web_search:
12
+
model: openai/gpt-4o
13
+
description: An agent specialized in web searching and information retrieval.
14
+
instruction: You are an agent specialized in web searching and information retrieval.
Output: fmt.Sprintf("The agent %s handed off the conversation to you, look at the history of the conversation and continue where it left off. Once you are done with your task or if the user asks you, handoff the conversation back to %s.", ca, ca),
1272
+
}, nil
1273
+
}
1274
+
1237
1275
// generateSessionTitle generates a title for the session based on the conversation history
Content: "You are part of a multi-agent team. Your goal is to answer the user query in the most helpful way possible.\n\nAvailable agents in your team:\n"+agentsInfo+"\nYou can hand off the conversation to any of these agents at any time by using the `handoff` function with their ID. The valid agent IDs are: "+strings.Join(validAgentIDs, ", ") +".\n\nWhen to hand off:\n- If another agent's description indicates they are better suited for the current task or question\n\n- If any of the tools of the agent indicate that this agent is able to respond correctly- If the user explicitly asks for a specific agent\n- If you need specialized capabilities that another agent provides\n\nIf you are the best agent to handle the current request based on your capabilities, respond directly. When handing off to another agent, only handoff without talking about the handoff.",
0 commit comments