Skip to content

Commit 57651b4

Browse files
committed
fix example
1 parent ced3527 commit 57651b4

File tree

1 file changed

+4
-7
lines changed
  • cmd/example/agent_as_utcp_codemode

1 file changed

+4
-7
lines changed

cmd/example/agent_as_utcp_codemode/main.go

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,7 @@ func main() {
4949
// 4. Build an orchestrator agent with CodeMode enabled.
5050

5151
// Use a real Gemini model for the orchestrator
52-
orchestratorModel, err := models.NewGeminiLLM(ctx, "gemini-3-pro-preview", "You orchestrate workflows using CodeMode. Generate ONLY valid Go code. Do not include package main or imports. Use codemode.CallTool to invoke tools.")
53-
if err != nil {
54-
log.Fatalf("Failed to create orchestrator model: %v", err)
55-
}
52+
orchestratorModel := models.NewOpenAILLM("gpt-5.1", "You orchestrate workflows using CodeMode. Generate ONLY valid Go code. Do not include package main or imports. Use codemode.CallTool to invoke tools.")
5653

5754
memOpts := engine.DefaultOptions()
5855
kit, err := adk.New(ctx,
@@ -84,9 +81,9 @@ func main() {
8481
// This prompt describes a multi-step process that the agent would convert into a Go script
8582
// calling the respective UTCP tools (e.g. http.echo, http.timestamp, etc.).
8683
userPrompt := `
87-
Step 1: Ask for a fun fact about the Eiffel Tower using the specialist tool.
88-
Step 2: Ask for a fun fact about the Great Wall of China using the specialist tool.
89-
Step 3: Use the orchestrator tool to summarize the facts from Step 1 and Step 2.
84+
Step 1: Ask for a fun fact about the Eiffel Tower using the specialist.specialist tool.
85+
Step 2: Ask for a fun fact about the Great Wall of China using the specialist.specialist tool.
86+
Step 3: Use the orchestrator.orchestrator tool to summarize the facts from Step 1 and Step 2.
9087
`
9188
fmt.Printf("\nUser Prompt:\n%s\n", userPrompt)
9289

0 commit comments

Comments
 (0)