@dalmia/calibrate-mcp 0.0.40 → 0.0.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/mcp-server.js +1218 -682
- package/bin/mcp-server.js.map +35 -33
- package/esm/funcs/agentTestsListRunsForAgent.js +1 -0
- package/esm/funcs/agentTestsListRunsForAgent.js.map +1 -1
- package/esm/landing-page.js +1 -1
- package/esm/lib/config.d.ts +2 -2
- package/esm/lib/config.js +2 -2
- package/esm/mcp-server/mcp-server.js +1 -1
- package/esm/mcp-server/server.js +1 -1
- package/esm/models/agentcreate.d.ts +26 -0
- package/esm/models/agentcreate.d.ts.map +1 -1
- package/esm/models/agentcreate.js +18 -0
- package/esm/models/agentcreate.js.map +1 -1
- package/esm/models/agentresponse.d.ts +26 -0
- package/esm/models/agentresponse.d.ts.map +1 -1
- package/esm/models/agentresponse.js +17 -0
- package/esm/models/agentresponse.js.map +1 -1
- package/esm/models/agentsummary.d.ts +26 -0
- package/esm/models/agentsummary.d.ts.map +1 -1
- package/esm/models/agentsummary.js +17 -0
- package/esm/models/agentsummary.js.map +1 -1
- package/esm/models/agenttestrunlistitem.d.ts +2 -0
- package/esm/models/agenttestrunlistitem.d.ts.map +1 -1
- package/esm/models/agenttestrunlistitem.js +2 -0
- package/esm/models/agenttestrunlistitem.js.map +1 -1
- package/esm/models/annotationtaskresponse.js +1 -1
- package/esm/models/annotationtaskresponse.js.map +1 -1
- package/esm/models/bulktestitem.d.ts +2 -1
- package/esm/models/bulktestitem.d.ts.map +1 -1
- package/esm/models/bulktestitem.js +4 -2
- package/esm/models/bulktestitem.js.map +1 -1
- package/esm/models/bulktestupload.d.ts +4 -0
- package/esm/models/bulktestupload.d.ts.map +1 -1
- package/esm/models/bulktestupload.js +5 -2
- package/esm/models/bulktestupload.js.map +1 -1
- package/esm/models/evaluatorcreate.d.ts +4 -0
- package/esm/models/evaluatorcreate.d.ts.map +1 -1
- package/esm/models/evaluatorcreate.js +5 -2
- package/esm/models/evaluatorcreate.js.map +1 -1
- package/esm/models/evaluatordetailresponsecompact.d.ts +5 -0
- package/esm/models/evaluatordetailresponsecompact.d.ts.map +1 -1
- package/esm/models/evaluatordetailresponsecompact.js +6 -2
- package/esm/models/evaluatordetailresponsecompact.js.map +1 -1
- package/esm/models/getagenttestrunsagenttestsagentagentuuidrunsgetop.d.ts +1 -0
- package/esm/models/getagenttestrunsagenttestsagentagentuuidrunsgetop.d.ts.map +1 -1
- package/esm/models/getagenttestrunsagenttestsagentagentuuidrunsgetop.js +1 -0
- package/esm/models/getagenttestrunsagenttestsagentagentuuidrunsgetop.js.map +1 -1
- package/esm/models/listevaluatorsevaluatorsgetop.d.ts +2 -0
- package/esm/models/listevaluatorsevaluatorsgetop.d.ts.map +1 -1
- package/esm/models/listevaluatorsevaluatorsgetop.js +2 -0
- package/esm/models/listevaluatorsevaluatorsgetop.js.map +1 -1
- package/esm/models/routersevaluatorsevaluatorresponse.d.ts +5 -0
- package/esm/models/routersevaluatorsevaluatorresponse.d.ts.map +1 -1
- package/esm/models/routersevaluatorsevaluatorresponse.js +6 -2
- package/esm/models/routersevaluatorsevaluatorresponse.js.map +1 -1
- package/esm/models/testcreate.d.ts +4 -0
- package/esm/models/testcreate.d.ts.map +1 -1
- package/esm/models/testcreate.js +6 -3
- package/esm/models/testcreate.js.map +1 -1
- package/esm/models/testlistresponse.d.ts +4 -0
- package/esm/models/testlistresponse.d.ts.map +1 -1
- package/esm/models/testlistresponse.js +5 -2
- package/esm/models/testlistresponse.js.map +1 -1
- package/esm/models/testresponse.d.ts +4 -0
- package/esm/models/testresponse.d.ts.map +1 -1
- package/esm/models/testresponse.js +5 -2
- package/esm/models/testresponse.js.map +1 -1
- package/esm/models/testupdate.d.ts +2 -0
- package/esm/models/testupdate.d.ts.map +1 -1
- package/esm/models/testupdate.js +4 -2
- package/esm/models/testupdate.js.map +1 -1
- package/esm/models/traceingest.d.ts +6 -1
- package/esm/models/traceingest.d.ts.map +1 -1
- package/esm/models/traceingest.js +8 -1
- package/esm/models/traceingest.js.map +1 -1
- package/esm/models/tracetoolcall.d.ts +1 -0
- package/esm/models/tracetoolcall.d.ts.map +1 -1
- package/esm/models/tracetoolcall.js +1 -0
- package/esm/models/tracetoolcall.js.map +1 -1
- package/package.json +1 -1
- package/src/funcs/agentTestsListRunsForAgent.ts +1 -0
- package/src/landing-page.ts +1 -1
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/agentcreate.ts +36 -0
- package/src/models/agentresponse.ts +35 -0
- package/src/models/agentsummary.ts +35 -0
- package/src/models/agenttestrunlistitem.ts +6 -0
- package/src/models/annotationtaskresponse.ts +1 -1
- package/src/models/bulktestitem.ts +10 -5
- package/src/models/bulktestupload.ts +6 -2
- package/src/models/evaluatorcreate.ts +6 -2
- package/src/models/evaluatordetailresponsecompact.ts +10 -2
- package/src/models/getagenttestrunsagenttestsagentagentuuidrunsgetop.ts +4 -0
- package/src/models/listevaluatorsevaluatorsgetop.ts +2 -0
- package/src/models/routersevaluatorsevaluatorresponse.ts +10 -2
- package/src/models/testcreate.ts +7 -3
- package/src/models/testlistresponse.ts +6 -2
- package/src/models/testresponse.ts +6 -2
- package/src/models/testupdate.ts +4 -2
- package/src/models/traceingest.ts +18 -3
- package/src/models/tracetoolcall.ts +4 -0
package/esm/models/testupdate.js
CHANGED
|
@@ -7,17 +7,19 @@ export const TestUpdateType = {
|
|
|
7
7
|
Response: "response",
|
|
8
8
|
ToolCall: "tool_call",
|
|
9
9
|
Conversation: "conversation",
|
|
10
|
+
General: "general",
|
|
10
11
|
};
|
|
11
12
|
export const TestUpdateType$zodSchema = z.enum([
|
|
12
13
|
"response",
|
|
13
14
|
"tool_call",
|
|
14
15
|
"conversation",
|
|
16
|
+
"general",
|
|
15
17
|
]);
|
|
16
18
|
export const TestUpdate$zodSchema = z.object({
|
|
17
|
-
config: z.record(z.string(), z.any()).nullable().optional().describe("The calibrate test config
|
|
19
|
+
config: z.record(z.string(), z.any()).nullable().optional().describe("The calibrate test config.\n\n- `history`: the conversation up to the agent's turn, required for `response` and `conversation` tests and for a `tool_call` test aimed at a conversational agent. Each item is `{role, content}` with `role` one of `user`, `assistant`, `tool`. A `tool` message also carries `tool_call_id` and `name`.\n- `input`: a standalone prompt with no conversation around it, required for `general` tests and for a `tool_call` test aimed at a `general` agent. A string, not a conversation.\n- `evaluation`: the required `{type, ...}`, where `type` matches the test's `type` below.\n- `settings`: an optional object, e.g. `{\"language\": \"en\"}`.\n\nA `tool_call` test carries exactly one of `history` or `input`, and which one it carries decides the agent it can be linked to.\n\n`evaluation` by test type:\n- `response`: judge the agent's reply, graded by the linked evaluators. `{\"type\": \"response\"}`\n- `conversation`: append the reply and judge the whole conversation. `{\"type\": \"conversation\"}`\n- `tool_call`: diff the agent's tool calls against expected ones. Add `tool_calls`, a list of `{tool, arguments, accept_any_arguments?}`.\n- `general`: judge a standalone, non-conversational input/output pair, graded by the linked evaluators. `{\"type\": \"general\"}`\n\nFor `tool_call`, each expected argument value is one of:\n- `{\"match_type\": \"exact\", \"value\": <any>}`: must equal `value`\n- `{\"match_type\": \"llm_judge\", \"criteria\": \"...\"}`: judged against the criteria\n- `{\"match_type\": \"any\"}`: any value, only checks the argument was passed\n\n`response` / `conversation` example:\n```json\n{\n \"history\": [{\"role\": \"user\", \"content\": \"What is your return policy?\"}],\n \"evaluation\": {\"type\": \"response\"},\n \"settings\": {\"language\": \"en\"}\n}\n```\n\n`tool_call` example, for a conversational agent. Swap `history` for `input` to aim it at a `general` agent:\n```json\n{\n \"history\": [{\"role\": \"user\", \"content\": \"Book room 101 for tomorrow\"}],\n \"evaluation\": {\n \"type\": \"tool_call\",\n \"tool_calls\": [\n {\n \"tool\": \"book_room\",\n \"arguments\": {\n \"room\": {\"match_type\": \"exact\", \"value\": \"101\"},\n \"date\": {\"match_type\": \"llm_judge\", \"criteria\": \"tomorrow's date\"}\n },\n \"accept_any_arguments\": false\n }\n ]\n }\n}\n```\n\n`general` example:\n```json\n{\n \"input\": \"Summarize this article: ...\",\n \"evaluation\": {\"type\": \"general\"},\n \"settings\": {\"language\": \"en\"}\n}\n```\n\nEvaluators are linked via the separate `evaluators` field, not inside `config`.\n\nReplaces the stored config. Omit to leave unchanged"),
|
|
18
20
|
evaluators: z.array(RoutersTestsEvaluatorRef$zodSchema).nullable().optional()
|
|
19
21
|
.describe("New evaluator links for the test. Omit to leave unchanged. An empty list clears them, except on `conversation` tests, which must keep at least one"),
|
|
20
22
|
name: z.string().nullable().optional().describe("New test name. Omit to leave unchanged"),
|
|
21
|
-
type: TestUpdateType$zodSchema.nullable().optional().describe("What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n\n\nImmutable. Omit it, or send the current value"),
|
|
23
|
+
type: TestUpdateType$zodSchema.nullable().optional().describe("What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n- `general`: judges a single plain-text input/output pair with no conversation involved (e.g. summarization, extraction, classification)\n\n\nImmutable. Omit it, or send the current value"),
|
|
22
24
|
});
|
|
23
25
|
//# sourceMappingURL=testupdate.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"testupdate.js","sourceRoot":"","sources":["../../src/models/testupdate.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAEL,kCAAkC,GACnC,MAAM,+BAA+B,CAAC;AAEvC,MAAM,CAAC,MAAM,cAAc,GAAG;IAC5B,QAAQ,EAAE,UAAU;IACpB,QAAQ,EAAE,WAAW;IACrB,YAAY,EAAE,cAAc;
|
|
1
|
+
{"version":3,"file":"testupdate.js","sourceRoot":"","sources":["../../src/models/testupdate.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,OAAO,EAEL,kCAAkC,GACnC,MAAM,+BAA+B,CAAC;AAEvC,MAAM,CAAC,MAAM,cAAc,GAAG;IAC5B,QAAQ,EAAE,UAAU;IACpB,QAAQ,EAAE,WAAW;IACrB,YAAY,EAAE,cAAc;IAC5B,OAAO,EAAE,SAAS;CACV,CAAC;AAGX,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,IAAI,CAAC;IAC7C,UAAU;IACV,WAAW;IACX,cAAc;IACd,SAAS;CACV,CAAC,CAAC;AASH,MAAM,CAAC,MAAM,oBAAoB,GAA0B,CAAC,CAAC,MAAM,CAAC;IAClE,MAAM,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAClE,yqFAAyqF,CAC1qF;IACD,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,kCAAkC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;SAC1E,QAAQ,CACP,oJAAoJ,CACrJ;IACH,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC7C,wCAAwC,CACzC;IACD,IAAI,EAAE,wBAAwB,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC3D,+VAA+V,CAChW;CACF,CAAC,CAAC"}
|
|
@@ -2,11 +2,16 @@ import * as z from "zod";
|
|
|
2
2
|
import { TraceMetadataEntry } from "./tracemetadataentry.js";
|
|
3
3
|
import { TraceOutput } from "./traceoutput.js";
|
|
4
4
|
import { TraceTurn } from "./traceturn.js";
|
|
5
|
+
/**
|
|
6
|
+
* What the agent was given for this turn. For a `general` agent, the standalone prompt as a string. For a `conversation` agent, the history up to the reported output, oldest turn first, in OpenAI chat format
|
|
7
|
+
*/
|
|
8
|
+
export type Input = string | Array<TraceTurn>;
|
|
9
|
+
export declare const Input$zodSchema: z.ZodType<Input>;
|
|
5
10
|
export type TraceIngest = {
|
|
6
11
|
agent_id: string;
|
|
7
12
|
message_id?: string | null | undefined;
|
|
8
13
|
conversation_id?: string | null | undefined;
|
|
9
|
-
input: Array<TraceTurn>;
|
|
14
|
+
input: string | Array<TraceTurn>;
|
|
10
15
|
output: TraceOutput;
|
|
11
16
|
metadata?: Array<TraceMetadataEntry> | null | undefined;
|
|
12
17
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"traceingest.d.ts","sourceRoot":"","sources":["../../src/models/traceingest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EACL,kBAAkB,EAEnB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,WAAW,EAAyB,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAE,SAAS,EAAuB,MAAM,gBAAgB,CAAC;AAEhE,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACvC,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAC5C,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"traceingest.d.ts","sourceRoot":"","sources":["../../src/models/traceingest.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EACL,kBAAkB,EAEnB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,WAAW,EAAyB,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAE,SAAS,EAAuB,MAAM,gBAAgB,CAAC;AAEhE;;GAEG;AACH,MAAM,MAAM,KAAK,GAAG,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC,CAAC;AAE9C,eAAO,MAAM,eAAe,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAK5C,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IACvC,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAC;IAC5C,KAAK,EAAE,MAAM,GAAG,KAAK,CAAC,SAAS,CAAC,CAAC;IACjC,MAAM,EAAE,WAAW,CAAC;IACpB,QAAQ,CAAC,EAAE,KAAK,CAAC,kBAAkB,CAAC,GAAG,IAAI,GAAG,SAAS,CAAC;CACzD,CAAC;AAEF,eAAO,MAAM,qBAAqB,EAAE,CAAC,CAAC,OAAO,CAAC,WAAW,CAqBvD,CAAC"}
|
|
@@ -5,10 +5,17 @@ import * as z from "zod";
|
|
|
5
5
|
import { TraceMetadataEntry$zodSchema, } from "./tracemetadataentry.js";
|
|
6
6
|
import { TraceOutput$zodSchema } from "./traceoutput.js";
|
|
7
7
|
import { TraceTurn$zodSchema } from "./traceturn.js";
|
|
8
|
+
export const Input$zodSchema = z.union([
|
|
9
|
+
z.string(),
|
|
10
|
+
z.array(TraceTurn$zodSchema),
|
|
11
|
+
]).describe("What the agent was given for this turn. For a `general` agent, the standalone prompt as a string. For a `conversation` agent, the history up to the reported output, oldest turn first, in OpenAI chat format");
|
|
8
12
|
export const TraceIngest$zodSchema = z.object({
|
|
9
13
|
agent_id: z.string().describe("ID of the agent that produced the turn. Must be an agent in your workspace"),
|
|
10
14
|
conversation_id: z.string().nullable().optional().describe("Your own ID for the conversation this turn belongs to, stored for reference only. Omit if you have none"),
|
|
11
|
-
input: z.
|
|
15
|
+
input: z.union([
|
|
16
|
+
z.string(),
|
|
17
|
+
z.array(TraceTurn$zodSchema),
|
|
18
|
+
]).describe("What the agent was given for this turn. For a `general` agent, the standalone prompt as a string. For a `conversation` agent, the history up to the reported output, oldest turn first, in OpenAI chat format"),
|
|
12
19
|
message_id: z.string().nullable().optional().describe("Your own ID for the last user message in `input`, stored for reference only. Omit if you have none"),
|
|
13
20
|
metadata: z.array(TraceMetadataEntry$zodSchema).nullable().optional()
|
|
14
21
|
.describe("Key-value pairs stored with the trace. Prefer OTel `gen_ai.*` key names where they fit. Omit if you have none"),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"traceingest.js","sourceRoot":"","sources":["../../src/models/traceingest.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAEL,4BAA4B,GAC7B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAe,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAa,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"traceingest.js","sourceRoot":"","sources":["../../src/models/traceingest.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AACzB,OAAO,EAEL,4BAA4B,GAC7B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAe,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AACtE,OAAO,EAAa,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAOhE,MAAM,CAAC,MAAM,eAAe,GAAqB,CAAC,CAAC,KAAK,CAAC;IACvD,CAAC,CAAC,MAAM,EAAE;IACV,CAAC,CAAC,KAAK,CAAC,mBAAmB,CAAC;CAC7B,CAAC,CAAC,QAAQ,CACT,+MAA+M,CAChN,CAAC;AAWF,MAAM,CAAC,MAAM,qBAAqB,GAA2B,CAAC,CAAC,MAAM,CAAC;IACpE,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAC3B,4EAA4E,CAC7E;IACD,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACxD,yGAAyG,CAC1G;IACD,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC;QACb,CAAC,CAAC,MAAM,EAAE;QACV,CAAC,CAAC,KAAK,CAAC,mBAAmB,CAAC;KAC7B,CAAC,CAAC,QAAQ,CACT,+MAA+M,CAChN;IACD,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACnD,oGAAoG,CACrG;IACD,QAAQ,EAAE,CAAC,CAAC,KAAK,CAAC,4BAA4B,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE;SAClE,QAAQ,CACP,+GAA+G,CAChH;IACH,MAAM,EAAE,qBAAqB;CAC9B,CAAC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tracetoolcall.d.ts","sourceRoot":"","sources":["../../src/models/tracetoolcall.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE;QAAE,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,GAAG,IAAI,GAAG,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"tracetoolcall.d.ts","sourceRoot":"","sources":["../../src/models/tracetoolcall.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAEzB,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,CAAC,EAAE;QAAE,CAAC,CAAC,EAAE,MAAM,GAAG,GAAG,CAAA;KAAE,GAAG,IAAI,GAAG,SAAS,CAAC;IACpD,MAAM,CAAC,EAAE,GAAG,GAAG,SAAS,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,CAAC,CAAC,OAAO,CAAC,aAAa,CAQ3D,CAAC"}
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
import * as z from "zod";
|
|
5
5
|
export const TraceToolCall$zodSchema = z.object({
|
|
6
6
|
arguments: z.record(z.string(), z.any()).nullable().optional().describe("Argument values the agent passed to the tool. Omit when the call had none"),
|
|
7
|
+
output: z.any().optional().describe("What the tool returned for this call. Any JSON value. Omit when you do not record it"),
|
|
7
8
|
tool: z.string().describe("Name of the tool the agent called"),
|
|
8
9
|
});
|
|
9
10
|
//# sourceMappingURL=tracetoolcall.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tracetoolcall.js","sourceRoot":"","sources":["../../src/models/tracetoolcall.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"tracetoolcall.js","sourceRoot":"","sources":["../../src/models/tracetoolcall.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,CAAC,MAAM,KAAK,CAAC;AAQzB,MAAM,CAAC,MAAM,uBAAuB,GAA6B,CAAC,CAAC,MAAM,CAAC;IACxE,SAAS,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACrE,2EAA2E,CAC5E;IACD,MAAM,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjC,sFAAsF,CACvF;IACD,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,mCAAmC,CAAC;CAC/D,CAAC,CAAC"}
|
package/package.json
CHANGED
package/src/landing-page.ts
CHANGED
|
@@ -930,7 +930,7 @@ http_headers = { "api-key-auth" = "YOUR_API_KEY_AUTH" }`;
|
|
|
930
930
|
<h1>Instructions</h1>
|
|
931
931
|
<p>One-click installation for Claude Desktop users</p>
|
|
932
932
|
<div class="instruction-item">
|
|
933
|
-
<a href="https://github.com/dalmia/calibrate-mcp/releases/download/v0.0.
|
|
933
|
+
<a href="https://github.com/dalmia/calibrate-mcp/releases/download/v0.0.42/mcp-server.mcpb" download="mcp-server.mcpb" class="action-button header-action" style="display: inline-flex; margin-bottom: 16px;">
|
|
934
934
|
📥 Download MCP Bundle
|
|
935
935
|
</a>
|
|
936
936
|
</div>
|
package/src/lib/config.ts
CHANGED
|
@@ -65,8 +65,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
65
65
|
export const SDK_METADATA = {
|
|
66
66
|
language: "typescript",
|
|
67
67
|
openapiDocVersion: "0.1.0",
|
|
68
|
-
sdkVersion: "0.0.
|
|
68
|
+
sdkVersion: "0.0.42",
|
|
69
69
|
genVersion: "2.915.1",
|
|
70
70
|
userAgent:
|
|
71
|
-
"speakeasy-sdk/mcp-typescript 0.0.
|
|
71
|
+
"speakeasy-sdk/mcp-typescript 0.0.42 2.915.1 0.1.0 @dalmia/calibrate-mcp",
|
|
72
72
|
} as const;
|
package/src/mcp-server/server.ts
CHANGED
|
@@ -30,9 +30,41 @@ export const AgentCreateType$zodSchema = z.enum([
|
|
|
30
30
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
31
31
|
);
|
|
32
32
|
|
|
33
|
+
/**
|
|
34
|
+
* What the agent expects in the request body:
|
|
35
|
+
*
|
|
36
|
+
* @remarks
|
|
37
|
+
*
|
|
38
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
39
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
40
|
+
*/
|
|
41
|
+
export const AgentCreateInteractionType = {
|
|
42
|
+
Conversation: "conversation",
|
|
43
|
+
General: "general",
|
|
44
|
+
} as const;
|
|
45
|
+
/**
|
|
46
|
+
* What the agent expects in the request body:
|
|
47
|
+
*
|
|
48
|
+
* @remarks
|
|
49
|
+
*
|
|
50
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
51
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
52
|
+
*/
|
|
53
|
+
export type AgentCreateInteractionType = ClosedEnum<
|
|
54
|
+
typeof AgentCreateInteractionType
|
|
55
|
+
>;
|
|
56
|
+
|
|
57
|
+
export const AgentCreateInteractionType$zodSchema = z.enum([
|
|
58
|
+
"conversation",
|
|
59
|
+
"general",
|
|
60
|
+
]).describe(
|
|
61
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
62
|
+
);
|
|
63
|
+
|
|
33
64
|
export type AgentCreate = {
|
|
34
65
|
name: string;
|
|
35
66
|
type?: AgentCreateType | undefined;
|
|
67
|
+
interaction_type?: AgentCreateInteractionType | undefined;
|
|
36
68
|
config?: { [k: string]: any } | null | undefined;
|
|
37
69
|
};
|
|
38
70
|
|
|
@@ -40,6 +72,10 @@ export const AgentCreate$zodSchema: z.ZodType<AgentCreate> = z.object({
|
|
|
40
72
|
config: z.record(z.string(), z.any()).nullable().optional().describe(
|
|
41
73
|
"Agent behavioral config. The keys depend on `type`.\n\n**`type=agent`**, built inside Calibrate:\n- `system_prompt`: the agent's instructions\n- `llm.model`: `provider/model`, e.g. `openai/gpt-4.1` or `google/gemini-2.5-flash`\n- `stt.provider`: `deepgram`, `openai`, `cartesia`, `elevenlabs`, `google`, `sarvam`, or `smallest`\n- `tts.provider`: `cartesia`, `openai`, `google`, `elevenlabs`, `sarvam`, or `smallest`\n- `settings.agent_speaks_first`, `settings.max_assistant_turns`\n- `system_tools.end_call`: let the agent end the call\n- `data_extraction_fields`: `[{name, type, description, required}]`\n\n```json\n{\n \"system_prompt\": \"You are a helpful support agent.\",\n \"llm\": {\"model\": \"openai/gpt-4.1\"},\n \"stt\": {\"provider\": \"deepgram\"},\n \"tts\": {\"provider\": \"elevenlabs\"},\n \"settings\": {\"agent_speaks_first\": true, \"max_assistant_turns\": 50}\n}\n```\n\n**`type=connection`**, your own HTTP endpoint:\n- `agent_url`: public HTTP(S) endpoint your agent is called at\n- `agent_headers`: headers sent on each request, e.g. auth\n- `benchmark_provider`: `openrouter` by default. Other values: `openai`, `google`, `anthropic`, `meta-llama`, `mistralai`, `deepseek`, `x-ai`, `cohere`, `qwen`, or `ai21`\n\n```json\n{\n \"agent_url\": \"https://api.example.com/agent\",\n \"agent_headers\": {\"Authorization\": \"Bearer <token>\"},\n \"benchmark_provider\": \"openrouter\"\n}\n```\n\nFor `type=agent`, omitted keys inherit managed defaults. Omit `config` entirely to use all defaults. For `type=connection`, `config` is stored as-is and must contain `agent_url`",
|
|
42
74
|
),
|
|
75
|
+
interaction_type: AgentCreateInteractionType$zodSchema.default("conversation")
|
|
76
|
+
.describe(
|
|
77
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
78
|
+
),
|
|
43
79
|
name: z.string().describe("Agent name, unique within the workspace"),
|
|
44
80
|
type: AgentCreateType$zodSchema.default("agent").describe(
|
|
45
81
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
@@ -30,10 +30,42 @@ export const AgentResponseType$zodSchema = z.enum([
|
|
|
30
30
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
31
31
|
);
|
|
32
32
|
|
|
33
|
+
/**
|
|
34
|
+
* What the agent expects in the request body:
|
|
35
|
+
*
|
|
36
|
+
* @remarks
|
|
37
|
+
*
|
|
38
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
39
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
40
|
+
*/
|
|
41
|
+
export const AgentResponseInteractionType = {
|
|
42
|
+
Conversation: "conversation",
|
|
43
|
+
General: "general",
|
|
44
|
+
} as const;
|
|
45
|
+
/**
|
|
46
|
+
* What the agent expects in the request body:
|
|
47
|
+
*
|
|
48
|
+
* @remarks
|
|
49
|
+
*
|
|
50
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
51
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
52
|
+
*/
|
|
53
|
+
export type AgentResponseInteractionType = ClosedEnum<
|
|
54
|
+
typeof AgentResponseInteractionType
|
|
55
|
+
>;
|
|
56
|
+
|
|
57
|
+
export const AgentResponseInteractionType$zodSchema = z.enum([
|
|
58
|
+
"conversation",
|
|
59
|
+
"general",
|
|
60
|
+
]).describe(
|
|
61
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
62
|
+
);
|
|
63
|
+
|
|
33
64
|
export type AgentResponse = {
|
|
34
65
|
uuid: string;
|
|
35
66
|
name: string;
|
|
36
67
|
type: AgentResponseType;
|
|
68
|
+
interaction_type: AgentResponseInteractionType;
|
|
37
69
|
config?: { [k: string]: any } | null | undefined;
|
|
38
70
|
created_at: string;
|
|
39
71
|
updated_at: string;
|
|
@@ -44,6 +76,9 @@ export const AgentResponse$zodSchema: z.ZodType<AgentResponse> = z.object({
|
|
|
44
76
|
"Agent configuration",
|
|
45
77
|
),
|
|
46
78
|
created_at: z.string().describe("When the agent was created (ISO 8601 UTC)"),
|
|
79
|
+
interaction_type: AgentResponseInteractionType$zodSchema.describe(
|
|
80
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
81
|
+
),
|
|
47
82
|
name: z.string().describe("Name of the agent"),
|
|
48
83
|
type: AgentResponseType$zodSchema.describe(
|
|
49
84
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
@@ -30,10 +30,42 @@ export const AgentSummaryType$zodSchema = z.enum([
|
|
|
30
30
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
31
31
|
);
|
|
32
32
|
|
|
33
|
+
/**
|
|
34
|
+
* What the agent expects in the request body:
|
|
35
|
+
*
|
|
36
|
+
* @remarks
|
|
37
|
+
*
|
|
38
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
39
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
40
|
+
*/
|
|
41
|
+
export const AgentSummaryInteractionType = {
|
|
42
|
+
Conversation: "conversation",
|
|
43
|
+
General: "general",
|
|
44
|
+
} as const;
|
|
45
|
+
/**
|
|
46
|
+
* What the agent expects in the request body:
|
|
47
|
+
*
|
|
48
|
+
* @remarks
|
|
49
|
+
*
|
|
50
|
+
* - `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{"messages": [...]}`
|
|
51
|
+
* - `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{"input": "..."}`
|
|
52
|
+
*/
|
|
53
|
+
export type AgentSummaryInteractionType = ClosedEnum<
|
|
54
|
+
typeof AgentSummaryInteractionType
|
|
55
|
+
>;
|
|
56
|
+
|
|
57
|
+
export const AgentSummaryInteractionType$zodSchema = z.enum([
|
|
58
|
+
"conversation",
|
|
59
|
+
"general",
|
|
60
|
+
]).describe(
|
|
61
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
62
|
+
);
|
|
63
|
+
|
|
33
64
|
export type AgentSummary = {
|
|
34
65
|
uuid: string;
|
|
35
66
|
name: string;
|
|
36
67
|
type: AgentSummaryType;
|
|
68
|
+
interaction_type: AgentSummaryInteractionType;
|
|
37
69
|
created_at: string;
|
|
38
70
|
updated_at: string;
|
|
39
71
|
connection_verified?: boolean | null | undefined;
|
|
@@ -48,6 +80,9 @@ export const AgentSummary$zodSchema: z.ZodType<AgentSummary> = z.object({
|
|
|
48
80
|
has_default_inputs: z.boolean().describe(
|
|
49
81
|
"Whether the agent has custom request fields configured",
|
|
50
82
|
),
|
|
83
|
+
interaction_type: AgentSummaryInteractionType$zodSchema.describe(
|
|
84
|
+
"What the agent expects in the request body:\n\n- `conversation`: a normal back-and-forth agent, answers within an ongoing conversation. Receives `{\"messages\": [...]}`\n- `general`: a one-shot agent, takes a single plain input and produces a single plain output, no conversation. Receives `{\"input\": \"...\"}`",
|
|
85
|
+
),
|
|
51
86
|
name: z.string().describe("Name of the agent"),
|
|
52
87
|
type: AgentSummaryType$zodSchema.describe(
|
|
53
88
|
"- `agent`: built inside Calibrate\n- `connection`: your existing agent connected to Calibrate",
|
|
@@ -48,10 +48,12 @@ export type AgentTestRunListItem = {
|
|
|
48
48
|
name: string;
|
|
49
49
|
status: TaskStatus;
|
|
50
50
|
type: AgentTestRunListItemType;
|
|
51
|
+
created_at: string;
|
|
51
52
|
updated_at: string;
|
|
52
53
|
total_tests?: number | null | undefined;
|
|
53
54
|
passed?: number | null | undefined;
|
|
54
55
|
failed?: number | null | undefined;
|
|
56
|
+
evaluators?: Array<string> | undefined;
|
|
55
57
|
results?: Array<TestRunCaseSummary> | null | undefined;
|
|
56
58
|
latency_ms?: { [k: string]: any } | null | undefined;
|
|
57
59
|
cost?: { [k: string]: any } | null | undefined;
|
|
@@ -67,7 +69,11 @@ export const AgentTestRunListItem$zodSchema: z.ZodType<AgentTestRunListItem> = z
|
|
|
67
69
|
cost: z.record(z.string(), z.any()).nullable().optional().describe(
|
|
68
70
|
"Aggregated cost as `{mean, min, max, count}` (USD)",
|
|
69
71
|
),
|
|
72
|
+
created_at: z.string().describe("When the run was created (ISO 8601 UTC)"),
|
|
70
73
|
error: z.boolean().default(false).describe("True if the run failed"),
|
|
74
|
+
evaluators: z.array(z.string()).optional().describe(
|
|
75
|
+
"Names of the evaluators that judged this run, deduplicated and in display order. `Tool call` is appended when any test in the run was a tool-call test. Empty when the run had no evaluators",
|
|
76
|
+
),
|
|
71
77
|
failed: z.int().nullable().optional().describe(
|
|
72
78
|
"Number of test cases that failed",
|
|
73
79
|
),
|
|
@@ -75,7 +75,7 @@ export const AnnotationTaskResponse$zodSchema: z.ZodType<
|
|
|
75
75
|
"Number of items in the task",
|
|
76
76
|
),
|
|
77
77
|
items: z.array(z.record(z.string(), z.any())).optional().describe(
|
|
78
|
-
"The task's items, each with its agreement stats. You get these when you fetch one task by ID, not when you list tasks",
|
|
78
|
+
"The task's items, each with its agreement stats and an `is_tool_call` flag marking the rows a person labels on the tool call rather than a text reply. You get these when you fetch one task by ID, not when you list tasks",
|
|
79
79
|
),
|
|
80
80
|
jobs: z.array(z.record(z.string(), z.any())).optional().describe(
|
|
81
81
|
"The task's labelling jobs. You get these when you fetch one task by ID, not when you list tasks",
|
|
@@ -15,20 +15,25 @@ import {
|
|
|
15
15
|
|
|
16
16
|
export type BulkTestItem = {
|
|
17
17
|
name: string;
|
|
18
|
-
conversation_history
|
|
18
|
+
conversation_history?: Array<ChatMessage> | null | undefined;
|
|
19
|
+
input?: string | null | undefined;
|
|
19
20
|
evaluators?: Array<RoutersTestsEvaluatorRef> | null | undefined;
|
|
20
21
|
tool_calls?: Array<ExpectedToolCall> | null | undefined;
|
|
21
22
|
inputs?: { [k: string]: any } | null | undefined;
|
|
22
23
|
};
|
|
23
24
|
|
|
24
25
|
export const BulkTestItem$zodSchema: z.ZodType<BulkTestItem> = z.object({
|
|
25
|
-
conversation_history: z.array(ChatMessage$zodSchema).
|
|
26
|
-
|
|
27
|
-
|
|
26
|
+
conversation_history: z.array(ChatMessage$zodSchema).nullable().optional()
|
|
27
|
+
.describe(
|
|
28
|
+
"Ordered messages ending at the user turn the agent should answer. **Required for `response` and `conversation` batches**, and for `tool_call` batches aimed at a conversational agent",
|
|
29
|
+
),
|
|
28
30
|
evaluators: z.array(RoutersTestsEvaluatorRef$zodSchema).nullable().optional()
|
|
29
31
|
.describe(
|
|
30
|
-
"Evaluators to link. Used by `response` and `
|
|
32
|
+
"Evaluators to link. Used by `response`, `conversation`, and `general` tests",
|
|
31
33
|
),
|
|
34
|
+
input: z.string().nullable().optional().describe(
|
|
35
|
+
"Standalone prompt with no conversation around it. **Required for `general` batches**, and for `tool_call` batches aimed at a general agent",
|
|
36
|
+
),
|
|
32
37
|
inputs: z.record(z.string(), z.any()).nullable().optional().describe(
|
|
33
38
|
"Extra request fields for this test, overriding the agent's `default_inputs` per key",
|
|
34
39
|
),
|
|
@@ -14,6 +14,7 @@ import { BulkTestItem, BulkTestItem$zodSchema } from "./bulktestitem.js";
|
|
|
14
14
|
* - `response`: judges the generated reply
|
|
15
15
|
* - `tool_call`: diffs the generated tool calls
|
|
16
16
|
* - `conversation`: judges the full conversation
|
|
17
|
+
* - `general`: judges a single plain-text input/output pair with no conversation involved (e.g. summarization, extraction, classification)
|
|
17
18
|
*
|
|
18
19
|
* Applied to every test in the batch
|
|
19
20
|
*/
|
|
@@ -21,6 +22,7 @@ export const BulkTestUploadType = {
|
|
|
21
22
|
Response: "response",
|
|
22
23
|
ToolCall: "tool_call",
|
|
23
24
|
Conversation: "conversation",
|
|
25
|
+
General: "general",
|
|
24
26
|
} as const;
|
|
25
27
|
/**
|
|
26
28
|
* What the test judges:
|
|
@@ -30,6 +32,7 @@ export const BulkTestUploadType = {
|
|
|
30
32
|
* - `response`: judges the generated reply
|
|
31
33
|
* - `tool_call`: diffs the generated tool calls
|
|
32
34
|
* - `conversation`: judges the full conversation
|
|
35
|
+
* - `general`: judges a single plain-text input/output pair with no conversation involved (e.g. summarization, extraction, classification)
|
|
33
36
|
*
|
|
34
37
|
* Applied to every test in the batch
|
|
35
38
|
*/
|
|
@@ -39,8 +42,9 @@ export const BulkTestUploadType$zodSchema = z.enum([
|
|
|
39
42
|
"response",
|
|
40
43
|
"tool_call",
|
|
41
44
|
"conversation",
|
|
45
|
+
"general",
|
|
42
46
|
]).describe(
|
|
43
|
-
"What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n\n\nApplied to every test in the batch",
|
|
47
|
+
"What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n- `general`: judges a single plain-text input/output pair with no conversation involved (e.g. summarization, extraction, classification)\n\n\nApplied to every test in the batch",
|
|
44
48
|
);
|
|
45
49
|
|
|
46
50
|
export type BulkTestUpload = {
|
|
@@ -61,6 +65,6 @@ export const BulkTestUpload$zodSchema: z.ZodType<BulkTestUpload> = z.object({
|
|
|
61
65
|
"Test items to create, at most 500 per request, with names unique within the batch",
|
|
62
66
|
),
|
|
63
67
|
type: BulkTestUploadType$zodSchema.describe(
|
|
64
|
-
"What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n\n\nApplied to every test in the batch",
|
|
68
|
+
"What the test judges:\n\n- `response`: judges the generated reply\n- `tool_call`: diffs the generated tool calls\n- `conversation`: judges the full conversation\n- `general`: judges a single plain-text input/output pair with no conversation involved (e.g. summarization, extraction, classification)\n\n\nApplied to every test in the batch",
|
|
65
69
|
),
|
|
66
70
|
});
|
|
@@ -19,6 +19,7 @@ import {
|
|
|
19
19
|
* - `llm`: a reply with its conversation history
|
|
20
20
|
* - `llm-general`: a standalone input and output pair
|
|
21
21
|
* - `conversation`: a full conversation
|
|
22
|
+
* - `tool-call`: whether the agent called the right tool, labelled by a person
|
|
22
23
|
*/
|
|
23
24
|
export const EvaluatorCreateEvaluatorType = {
|
|
24
25
|
Tts: "tts",
|
|
@@ -26,6 +27,7 @@ export const EvaluatorCreateEvaluatorType = {
|
|
|
26
27
|
Llm: "llm",
|
|
27
28
|
LlmGeneral: "llm-general",
|
|
28
29
|
Conversation: "conversation",
|
|
30
|
+
ToolCall: "tool-call",
|
|
29
31
|
} as const;
|
|
30
32
|
/**
|
|
31
33
|
* What the evaluator judges:
|
|
@@ -37,6 +39,7 @@ export const EvaluatorCreateEvaluatorType = {
|
|
|
37
39
|
* - `llm`: a reply with its conversation history
|
|
38
40
|
* - `llm-general`: a standalone input and output pair
|
|
39
41
|
* - `conversation`: a full conversation
|
|
42
|
+
* - `tool-call`: whether the agent called the right tool, labelled by a person
|
|
40
43
|
*/
|
|
41
44
|
export type EvaluatorCreateEvaluatorType = ClosedEnum<
|
|
42
45
|
typeof EvaluatorCreateEvaluatorType
|
|
@@ -48,8 +51,9 @@ export const EvaluatorCreateEvaluatorType$zodSchema = z.enum([
|
|
|
48
51
|
"llm",
|
|
49
52
|
"llm-general",
|
|
50
53
|
"conversation",
|
|
54
|
+
"tool-call",
|
|
51
55
|
]).describe(
|
|
52
|
-
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n",
|
|
56
|
+
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n- `tool-call`: whether the agent called the right tool, labelled by a person\n",
|
|
53
57
|
);
|
|
54
58
|
|
|
55
59
|
/**
|
|
@@ -130,7 +134,7 @@ export const EvaluatorCreate$zodSchema: z.ZodType<EvaluatorCreate> = z.object({
|
|
|
130
134
|
),
|
|
131
135
|
evaluator_type: EvaluatorCreateEvaluatorType$zodSchema.default("llm")
|
|
132
136
|
.describe(
|
|
133
|
-
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n",
|
|
137
|
+
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n- `tool-call`: whether the agent called the right tool, labelled by a person\n",
|
|
134
138
|
),
|
|
135
139
|
name: z.string().describe("Evaluator name, unique within your workspace"),
|
|
136
140
|
output_type: EvaluatorCreateOutputType$zodSchema.default("binary").describe(
|
|
@@ -19,6 +19,7 @@ import {
|
|
|
19
19
|
* - `llm`: a reply with its conversation history
|
|
20
20
|
* - `llm-general`: a standalone input and output pair
|
|
21
21
|
* - `conversation`: a full conversation
|
|
22
|
+
* - `tool-call`: whether the agent called the right tool, labelled by a person
|
|
22
23
|
*/
|
|
23
24
|
export const EvaluatorDetailResponseCompactEvaluatorType = {
|
|
24
25
|
Tts: "tts",
|
|
@@ -26,6 +27,7 @@ export const EvaluatorDetailResponseCompactEvaluatorType = {
|
|
|
26
27
|
Llm: "llm",
|
|
27
28
|
LlmGeneral: "llm-general",
|
|
28
29
|
Conversation: "conversation",
|
|
30
|
+
ToolCall: "tool-call",
|
|
29
31
|
} as const;
|
|
30
32
|
/**
|
|
31
33
|
* What the evaluator judges:
|
|
@@ -37,6 +39,7 @@ export const EvaluatorDetailResponseCompactEvaluatorType = {
|
|
|
37
39
|
* - `llm`: a reply with its conversation history
|
|
38
40
|
* - `llm-general`: a standalone input and output pair
|
|
39
41
|
* - `conversation`: a full conversation
|
|
42
|
+
* - `tool-call`: whether the agent called the right tool, labelled by a person
|
|
40
43
|
*/
|
|
41
44
|
export type EvaluatorDetailResponseCompactEvaluatorType = ClosedEnum<
|
|
42
45
|
typeof EvaluatorDetailResponseCompactEvaluatorType
|
|
@@ -48,8 +51,9 @@ export const EvaluatorDetailResponseCompactEvaluatorType$zodSchema = z.enum([
|
|
|
48
51
|
"llm",
|
|
49
52
|
"llm-general",
|
|
50
53
|
"conversation",
|
|
54
|
+
"tool-call",
|
|
51
55
|
]).describe(
|
|
52
|
-
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n",
|
|
56
|
+
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n- `tool-call`: whether the agent called the right tool, labelled by a person\n",
|
|
53
57
|
);
|
|
54
58
|
|
|
55
59
|
/**
|
|
@@ -120,6 +124,7 @@ export type EvaluatorDetailResponseCompact = {
|
|
|
120
124
|
data_type: EvaluatorDetailResponseCompactDataType;
|
|
121
125
|
output_type: EvaluatorDetailResponseCompactOutputType;
|
|
122
126
|
is_default: boolean;
|
|
127
|
+
is_protected: boolean;
|
|
123
128
|
slug?: string | null | undefined;
|
|
124
129
|
source_default_slug?: string | null | undefined;
|
|
125
130
|
live_version_id?: string | null | undefined;
|
|
@@ -142,11 +147,14 @@ export const EvaluatorDetailResponseCompact$zodSchema: z.ZodType<
|
|
|
142
147
|
),
|
|
143
148
|
evaluator_type: EvaluatorDetailResponseCompactEvaluatorType$zodSchema
|
|
144
149
|
.describe(
|
|
145
|
-
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n",
|
|
150
|
+
"What the evaluator judges:\n\n- `tts`: TTS audio\n- `stt`: one transcript\n- `llm`: a reply with its conversation history\n- `llm-general`: a standalone input and output pair\n- `conversation`: a full conversation\n- `tool-call`: whether the agent called the right tool, labelled by a person\n",
|
|
146
151
|
),
|
|
147
152
|
is_default: z.boolean().describe(
|
|
148
153
|
"True when the evaluator is a built-in default or your workspace's editable copy of one. False for an evaluator you created yourself",
|
|
149
154
|
),
|
|
155
|
+
is_protected: z.boolean().describe(
|
|
156
|
+
"True when the evaluator is locked. A locked evaluator cannot be deleted, and only its name, description and rubric can change",
|
|
157
|
+
),
|
|
150
158
|
live_version_id: z.string().nullable().optional().describe(
|
|
151
159
|
"ID of the version that is currently live",
|
|
152
160
|
),
|
|
@@ -49,6 +49,7 @@ export type GetAgentTestRunsAgentTestsAgentAgentUuidRunsGetRequest = {
|
|
|
49
49
|
type?: GetAgentTestRunsAgentTestsAgentAgentUuidRunsGetType | null | undefined;
|
|
50
50
|
status?: TaskStatus | null | undefined;
|
|
51
51
|
has_failures?: boolean | null | undefined;
|
|
52
|
+
around?: string | null | undefined;
|
|
52
53
|
limit?: number | null | undefined;
|
|
53
54
|
offset?: number | undefined;
|
|
54
55
|
xAPIKey?: string | null | undefined;
|
|
@@ -57,6 +58,9 @@ export type GetAgentTestRunsAgentTestsAgentAgentUuidRunsGetRequest = {
|
|
|
57
58
|
export const GetAgentTestRunsAgentTestsAgentAgentUuidRunsGetRequest$zodSchema:
|
|
58
59
|
z.ZodType<GetAgentTestRunsAgentTestsAgentAgentUuidRunsGetRequest> = z.object({
|
|
59
60
|
agent_uuid: z.string().describe("Agent whose test runs to list"),
|
|
61
|
+
around: z.string().describe(
|
|
62
|
+
"ID of a run to jump to, returning the page that contains it instead of the page at `offset`",
|
|
63
|
+
).nullable().optional(),
|
|
60
64
|
has_failures: z.boolean().describe(
|
|
61
65
|
"Filter by whether the run has any failing test case or model. `true` returns only runs with failures (or errors), `false` only clean runs. Omit for both",
|
|
62
66
|
).nullable().optional(),
|
|
@@ -22,6 +22,7 @@ export const ListEvaluatorsEvaluatorsGetEvaluatorType = {
|
|
|
22
22
|
Llm: "llm",
|
|
23
23
|
LlmGeneral: "llm-general",
|
|
24
24
|
Conversation: "conversation",
|
|
25
|
+
ToolCall: "tool-call",
|
|
25
26
|
} as const;
|
|
26
27
|
/**
|
|
27
28
|
* Filter by what the evaluator judges. Omit for all types
|
|
@@ -36,6 +37,7 @@ export const ListEvaluatorsEvaluatorsGetEvaluatorType$zodSchema = z.enum([
|
|
|
36
37
|
"llm",
|
|
37
38
|
"llm-general",
|
|
38
39
|
"conversation",
|
|
40
|
+
"tool-call",
|
|
39
41
|
]).describe("Filter by what the evaluator judges. Omit for all types");
|
|
40
42
|
|
|
41
43
|
/**
|