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
traits: z.string().describe('Trait name to adjust behavior. For example, "bravery", "cautiousness", "friendliness".'),
58
-
})).nullable().describe('Personas can be used to adjust the behavior of sub-agents. For example, when using as NPC in games, or player in Minecraft, the persona can help define the character\'s traits and decision-making style.'),
58
+
}).strict()).nullable().describe('Personas can be used to adjust the behavior of sub-agents. For example, when using as NPC in games, or player in Minecraft, the persona can help define the character\'s traits and decision-making style.'),
59
59
options: z.array(z.object({
60
60
label: z.string().describe('Short and brief label for this option, used for identification, should be within a sentence.'),
61
61
steps: z.array(z.string()).describe('Step-by-step instructions for the sub-agent to follow, useful when providing detailed guidance.'),
fallback: z.array(z.string()).nullable().describe('Fallback steps if the main steps cannot be completed.'),
66
66
// TODO: consider to remove or enrich how triggers should work later
67
67
triggers: z.array(z.string()).nullable().describe('Conditions or events that would trigger this option.'),
68
-
})),
69
-
}).nullable().describe('Guidance for the sub-agent on how to interpret and execute the command with given context, persona settings, and reasoning.'),
70
-
})).describe('List of commands to issue to sub-agents, you may produce multiple commands in response to multiple sub-agents by specifying their IDs in destination field. Empty array can be used for zero commands.'),
71
-
})
68
+
}).strict()),
69
+
}).strict().nullable().describe('Guidance for the sub-agent on how to interpret and execute the command with given context, persona settings, and reasoning.'),
70
+
}).strict()).describe('List of commands to issue to sub-agents, you may produce multiple commands in response to multiple sub-agents by specifying their IDs in destination field. Empty array can be used for zero commands.'),
Copy file name to clipboardExpand all lines: packages/stage-ui/src/tools/mcp.ts
+5-5Lines changed: 5 additions & 5 deletions
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,7 @@ const tools = [
9
9
execute: async(_,__)=>{
10
10
returnawaitlistTools()
11
11
},
12
-
parameters: z.object({}),
12
+
parameters: z.object({}).strict(),
13
13
}),
14
14
tool({
15
15
name: 'mcp_connect_server',
@@ -21,7 +21,7 @@ const tools = [
21
21
parameters: z.object({
22
22
command: z.string().describe('The command to connect to the MCP server'),
23
23
args: z.array(z.string()).describe('The arguments to pass to the MCP server'),
24
-
}),
24
+
}).strict(),
25
25
}),
26
26
tool({
27
27
name: 'mcp_disconnect_server',
@@ -30,7 +30,7 @@ const tools = [
30
30
awaitdisconnectServer()
31
31
return'success'
32
32
},
33
-
parameters: z.object({}),
33
+
parameters: z.object({}).strict(),
34
34
}),
35
35
tool({
36
36
name: 'mcp_call_tool',
@@ -50,8 +50,8 @@ const tools = [
50
50
name: z.string().describe('The name of the tool to call'),
51
51
parameters: z.array(z.object({
52
52
name: z.string().describe('The name of the parameter'),
53
-
value: z.union([z.string(),z.number(),z.boolean(),z.object({})]).describe('The value of the parameter, it can be a string, a number, a boolean, or an object'),
54
-
})).describe('The parameters to pass to the tool'),
53
+
value: z.union([z.string(),z.number(),z.boolean(),z.object({}).strict()]).describe('The value of the parameter, it can be a string, a number, a boolean, or an object'),
54
+
}).strict()).describe('The parameters to pass to the tool'),
0 commit comments