@nimble-way/nimble-js 0.19.0 → 1.0.0
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/CHANGELOG.md +20 -0
- package/README.md +10 -10
- package/client.d.mts +10 -39
- package/client.d.mts.map +1 -1
- package/client.d.ts +10 -39
- package/client.d.ts.map +1 -1
- package/client.js +8 -43
- package/client.js.map +1 -1
- package/client.mjs +8 -43
- package/client.mjs.map +1 -1
- package/package.json +1 -1
- package/resources/agents/agents.d.mts +811 -0
- package/resources/agents/agents.d.mts.map +1 -0
- package/resources/agents/agents.d.ts +811 -0
- package/resources/agents/agents.d.ts.map +1 -0
- package/resources/agents/agents.js +67 -0
- package/resources/agents/agents.js.map +1 -0
- package/resources/agents/agents.mjs +62 -0
- package/resources/agents/agents.mjs.map +1 -0
- package/resources/agents/index.d.mts +4 -0
- package/resources/agents/index.d.mts.map +1 -0
- package/resources/agents/index.d.ts +4 -0
- package/resources/agents/index.d.ts.map +1 -0
- package/resources/{task-agent → agents}/index.js +3 -3
- package/resources/agents/index.js.map +1 -0
- package/resources/{task-agent → agents}/index.mjs +1 -1
- package/resources/agents/index.mjs.map +1 -0
- package/resources/{task-agent → agents}/runs.d.mts +413 -128
- package/resources/agents/runs.d.mts.map +1 -0
- package/resources/{task-agent → agents}/runs.d.ts +413 -128
- package/resources/agents/runs.d.ts.map +1 -0
- package/resources/agents/runs.js +63 -0
- package/resources/agents/runs.js.map +1 -0
- package/resources/agents/runs.mjs +59 -0
- package/resources/agents/runs.mjs.map +1 -0
- package/resources/agents/templates.d.mts +258 -0
- package/resources/agents/templates.d.mts.map +1 -0
- package/resources/agents/templates.d.ts +258 -0
- package/resources/agents/templates.d.ts.map +1 -0
- package/resources/{task-agent → agents}/templates.js +5 -4
- package/resources/agents/templates.js.map +1 -0
- package/resources/agents/templates.mjs +19 -0
- package/resources/agents/templates.mjs.map +1 -0
- package/resources/agents.d.mts +2 -0
- package/resources/agents.d.mts.map +1 -0
- package/resources/agents.d.ts +2 -0
- package/resources/agents.d.ts.map +1 -0
- package/resources/{task-agent.js → agents.js} +2 -2
- package/resources/agents.js.map +1 -0
- package/resources/{task-agent.mjs → agents.mjs} +2 -2
- package/resources/agents.mjs.map +1 -0
- package/resources/batches.js +3 -3
- package/resources/batches.mjs +3 -3
- package/resources/crawl.js +4 -4
- package/resources/crawl.mjs +4 -4
- package/resources/domain-knowledge.js +1 -1
- package/resources/domain-knowledge.mjs +1 -1
- package/resources/extract/extract.d.mts +1243 -0
- package/resources/extract/extract.d.mts.map +1 -0
- package/resources/extract/extract.d.ts +1243 -0
- package/resources/extract/extract.d.ts.map +1 -0
- package/resources/extract/extract.js +52 -0
- package/resources/extract/extract.js.map +1 -0
- package/resources/extract/extract.mjs +47 -0
- package/resources/extract/extract.mjs.map +1 -0
- package/resources/extract/index.d.mts +3 -0
- package/resources/extract/index.d.mts.map +1 -0
- package/resources/extract/index.d.ts +3 -0
- package/resources/extract/index.d.ts.map +1 -0
- package/resources/extract/index.js +9 -0
- package/resources/extract/index.js.map +1 -0
- package/resources/extract/index.mjs +4 -0
- package/resources/extract/index.mjs.map +1 -0
- package/resources/extract/templates/generations.d.mts +364 -0
- package/resources/extract/templates/generations.d.mts.map +1 -0
- package/resources/extract/templates/generations.d.ts +364 -0
- package/resources/extract/templates/generations.d.ts.map +1 -0
- package/resources/extract/templates/generations.js +39 -0
- package/resources/extract/templates/generations.js.map +1 -0
- package/resources/extract/templates/generations.mjs +35 -0
- package/resources/extract/templates/generations.mjs.map +1 -0
- package/resources/extract/templates/index.d.mts +4 -0
- package/resources/extract/templates/index.d.mts.map +1 -0
- package/resources/extract/templates/index.d.ts +4 -0
- package/resources/extract/templates/index.d.ts.map +1 -0
- package/resources/extract/templates/index.js +11 -0
- package/resources/extract/templates/index.js.map +1 -0
- package/resources/extract/templates/index.mjs +5 -0
- package/resources/extract/templates/index.mjs.map +1 -0
- package/resources/{agent.d.ts → extract/templates/templates.d.mts} +475 -263
- package/resources/extract/templates/templates.d.mts.map +1 -0
- package/resources/{agent.d.mts → extract/templates/templates.d.ts} +475 -263
- package/resources/extract/templates/templates.d.ts.map +1 -0
- package/resources/extract/templates/templates.js +120 -0
- package/resources/extract/templates/templates.js.map +1 -0
- package/resources/extract/templates/templates.mjs +115 -0
- package/resources/extract/templates/templates.mjs.map +1 -0
- package/resources/extract/templates/versions.d.mts +226 -0
- package/resources/extract/templates/versions.d.mts.map +1 -0
- package/resources/extract/templates/versions.d.ts +226 -0
- package/resources/extract/templates/versions.d.ts.map +1 -0
- package/resources/extract/templates/versions.js +42 -0
- package/resources/extract/templates/versions.js.map +1 -0
- package/resources/extract/templates/versions.mjs +38 -0
- package/resources/extract/templates/versions.mjs.map +1 -0
- package/resources/extract/templates.d.mts +2 -0
- package/resources/extract/templates.d.mts.map +1 -0
- package/resources/extract/templates.d.ts +2 -0
- package/resources/extract/templates.d.ts.map +1 -0
- package/resources/extract/templates.js +6 -0
- package/resources/extract/templates.js.map +1 -0
- package/resources/extract/templates.mjs +3 -0
- package/resources/extract/templates.mjs.map +1 -0
- package/resources/extract.d.mts +2 -0
- package/resources/extract.d.mts.map +1 -0
- package/resources/extract.d.ts +2 -0
- package/resources/extract.d.ts.map +1 -0
- package/resources/extract.js +6 -0
- package/resources/extract.js.map +1 -0
- package/resources/extract.mjs +3 -0
- package/resources/extract.mjs.map +1 -0
- package/resources/fast-serp.js +1 -1
- package/resources/fast-serp.mjs +1 -1
- package/resources/index.d.mts +4 -4
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +4 -4
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -5
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -2
- package/resources/index.mjs.map +1 -1
- package/resources/jobs/index.d.mts +2 -2
- package/resources/jobs/index.d.mts.map +1 -1
- package/resources/jobs/index.d.ts +2 -2
- package/resources/jobs/index.d.ts.map +1 -1
- package/resources/jobs/index.js.map +1 -1
- package/resources/jobs/index.mjs.map +1 -1
- package/resources/jobs/jobs.d.mts +34 -90
- package/resources/jobs/jobs.d.mts.map +1 -1
- package/resources/jobs/jobs.d.ts +34 -90
- package/resources/jobs/jobs.d.ts.map +1 -1
- package/resources/jobs/jobs.js +10 -16
- package/resources/jobs/jobs.js.map +1 -1
- package/resources/jobs/jobs.mjs +11 -17
- package/resources/jobs/jobs.mjs.map +1 -1
- package/resources/jobs/runs/artifacts.d.mts +7 -17
- package/resources/jobs/runs/artifacts.d.mts.map +1 -1
- package/resources/jobs/runs/artifacts.d.ts +7 -17
- package/resources/jobs/runs/artifacts.d.ts.map +1 -1
- package/resources/jobs/runs/artifacts.js +8 -8
- package/resources/jobs/runs/artifacts.mjs +8 -8
- package/resources/jobs/runs/index.d.mts +1 -1
- package/resources/jobs/runs/index.d.mts.map +1 -1
- package/resources/jobs/runs/index.d.ts +1 -1
- package/resources/jobs/runs/index.d.ts.map +1 -1
- package/resources/jobs/runs/index.js.map +1 -1
- package/resources/jobs/runs/index.mjs.map +1 -1
- package/resources/jobs/runs/runs.d.mts +59 -21
- package/resources/jobs/runs/runs.d.mts.map +1 -1
- package/resources/jobs/runs/runs.d.ts +59 -21
- package/resources/jobs/runs/runs.d.ts.map +1 -1
- package/resources/jobs/runs/runs.js +12 -6
- package/resources/jobs/runs/runs.js.map +1 -1
- package/resources/jobs/runs/runs.mjs +12 -6
- package/resources/jobs/runs/runs.mjs.map +1 -1
- package/resources/media.js +2 -2
- package/resources/media.mjs +2 -2
- package/resources/serp.js +3 -3
- package/resources/serp.mjs +3 -3
- package/resources/tasks.js +3 -3
- package/resources/tasks.mjs +3 -3
- package/resources/top-level.d.mts +1 -1208
- package/resources/top-level.d.mts.map +1 -1
- package/resources/top-level.d.ts +1 -1208
- package/resources/top-level.d.ts.map +1 -1
- package/src/client.ts +41 -123
- package/src/resources/agents/agents.ts +1039 -0
- package/src/resources/agents/index.ts +30 -0
- package/src/resources/{task-agent → agents}/runs.ts +450 -154
- package/src/resources/agents/templates.ts +324 -0
- package/src/resources/{task-agent.ts → agents.ts} +1 -1
- package/src/resources/batches.ts +3 -3
- package/src/resources/crawl.ts +4 -4
- package/src/resources/domain-knowledge.ts +1 -1
- package/src/resources/extract/extract.ts +5182 -0
- package/src/resources/extract/index.ts +25 -0
- package/src/resources/extract/templates/generations.ts +435 -0
- package/src/resources/extract/templates/index.ts +29 -0
- package/src/resources/extract/templates/templates.ts +1176 -0
- package/src/resources/extract/templates/versions.ts +284 -0
- package/src/resources/extract/templates.ts +3 -0
- package/src/resources/extract.ts +3 -0
- package/src/resources/fast-serp.ts +1 -1
- package/src/resources/index.ts +16 -36
- package/src/resources/jobs/index.ts +1 -1
- package/src/resources/jobs/jobs.ts +49 -112
- package/src/resources/jobs/runs/artifacts.ts +11 -21
- package/src/resources/jobs/runs/index.ts +1 -0
- package/src/resources/jobs/runs/runs.ts +74 -24
- package/src/resources/media.ts +2 -2
- package/src/resources/serp.ts +3 -3
- package/src/resources/tasks.ts +3 -3
- package/src/resources/top-level.ts +88 -5192
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
- package/resources/agent.d.mts.map +0 -1
- package/resources/agent.d.ts.map +0 -1
- package/resources/agent.js +0 -101
- package/resources/agent.js.map +0 -1
- package/resources/agent.mjs +0 -97
- package/resources/agent.mjs.map +0 -1
- package/resources/task-agent/index.d.mts +0 -4
- package/resources/task-agent/index.d.mts.map +0 -1
- package/resources/task-agent/index.d.ts +0 -4
- package/resources/task-agent/index.d.ts.map +0 -1
- package/resources/task-agent/index.js.map +0 -1
- package/resources/task-agent/index.mjs.map +0 -1
- package/resources/task-agent/runs.d.mts.map +0 -1
- package/resources/task-agent/runs.d.ts.map +0 -1
- package/resources/task-agent/runs.js +0 -65
- package/resources/task-agent/runs.js.map +0 -1
- package/resources/task-agent/runs.mjs +0 -61
- package/resources/task-agent/runs.mjs.map +0 -1
- package/resources/task-agent/task-agent.d.mts +0 -481
- package/resources/task-agent/task-agent.d.mts.map +0 -1
- package/resources/task-agent/task-agent.d.ts +0 -481
- package/resources/task-agent/task-agent.d.ts.map +0 -1
- package/resources/task-agent/task-agent.js +0 -68
- package/resources/task-agent/task-agent.js.map +0 -1
- package/resources/task-agent/task-agent.mjs +0 -63
- package/resources/task-agent/task-agent.mjs.map +0 -1
- package/resources/task-agent/templates.d.mts +0 -107
- package/resources/task-agent/templates.d.mts.map +0 -1
- package/resources/task-agent/templates.d.ts +0 -107
- package/resources/task-agent/templates.d.ts.map +0 -1
- package/resources/task-agent/templates.js.map +0 -1
- package/resources/task-agent/templates.mjs +0 -18
- package/resources/task-agent/templates.mjs.map +0 -1
- package/resources/task-agent.d.mts +0 -2
- package/resources/task-agent.d.mts.map +0 -1
- package/resources/task-agent.d.ts +0 -2
- package/resources/task-agent.d.ts.map +0 -1
- package/resources/task-agent.js.map +0 -1
- package/resources/task-agent.mjs.map +0 -1
- package/src/resources/agent.ts +0 -952
- package/src/resources/task-agent/index.ts +0 -32
- package/src/resources/task-agent/task-agent.ts +0 -746
- package/src/resources/task-agent/templates.ts +0 -172
|
@@ -3,68 +3,137 @@ import { APIPromise } from "../../core/api-promise.mjs";
|
|
|
3
3
|
import { RequestOptions } from "../../internal/request-options.mjs";
|
|
4
4
|
export declare class Runs extends APIResource {
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
6
|
+
* Start an agent run. The run executes asynchronously: the response returns
|
|
7
|
+
* immediately with status `queued`, then poll `GET .../runs/{run_id}` until
|
|
8
|
+
* `completed` and fetch the output from `GET .../runs/{run_id}/result` — or set
|
|
9
|
+
* `enable_events: true` and follow `GET .../runs/{run_id}/events` for live
|
|
10
|
+
* progress.
|
|
7
11
|
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
12
|
+
* To enrich existing records instead of researching from scratch, pass them in
|
|
13
|
+
* `input_data`; this requires an `output_schema` (on the request or the agent).
|
|
10
14
|
*/
|
|
11
|
-
|
|
15
|
+
create(agentID: string, body: RunCreateParams, options?: RequestOptions): APIPromise<RunCreateResponse>;
|
|
12
16
|
/**
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
* Verb is POST + `/cancel` action segment per the AGENTS-1666 spec (replaces the
|
|
16
|
-
* old `DELETE …/runs/{run_id}`).
|
|
17
|
+
* List the runs of an agent, newest first, paginated with `offset`/`limit`.
|
|
17
18
|
*/
|
|
18
|
-
|
|
19
|
+
list(agentID: string, query?: RunListParams | null | undefined, options?: RequestOptions): APIPromise<RunListResponse>;
|
|
19
20
|
/**
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* A run resolves only when (run_id, agent_id) match — otherwise 404. This means a
|
|
23
|
-
* stale URL with a swapped agent_id won't leak runs across instances even if the
|
|
24
|
-
* run_id is real.
|
|
21
|
+
* Retrieve a run's current state. Poll this endpoint after creating a run: the run
|
|
22
|
+
* is finished once `status` is `completed`, `failed`, or `cancelled`.
|
|
25
23
|
*/
|
|
26
24
|
get(runID: string, params: RunGetParams, options?: RequestOptions): APIPromise<RunGetResponse>;
|
|
27
25
|
/**
|
|
28
|
-
* Fetch the
|
|
26
|
+
* Fetch the output of a completed run. The `output` is `type: "text"` (a prose
|
|
27
|
+
* answer) or `type: "json"` (structured data matching the output schema), plus
|
|
28
|
+
* `trust` metadata with per-claim citations for the answer.
|
|
29
29
|
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
* - 404 when the run doesn't belong to the agent.
|
|
33
|
-
* - 408 when the run is still active.
|
|
34
|
-
* - 422 (with TaskRunFailedResult body) when the run failed or was cancelled.
|
|
35
|
-
* - 200 (with TaskRunResult body) on success.
|
|
30
|
+
* While the run is still `queued` or `running` this endpoint returns `409`; if the
|
|
31
|
+
* run `failed` or was `cancelled` it returns `422` with the run and error details.
|
|
36
32
|
*/
|
|
37
|
-
|
|
33
|
+
result(runID: string, params: RunResultParams, options?: RequestOptions): APIPromise<RunResultResponse>;
|
|
38
34
|
/**
|
|
39
|
-
*
|
|
35
|
+
* Stream a run's progress as
|
|
36
|
+
* [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events)
|
|
37
|
+
* (`text/event-stream`). Create the run with `enable_events: true` to have events
|
|
38
|
+
* published. A keep-alive comment is sent every 15 seconds.
|
|
40
39
|
*/
|
|
41
|
-
streamEvents(runID: string, params: RunStreamEventsParams, options?: RequestOptions): APIPromise<
|
|
40
|
+
streamEvents(runID: string, params: RunStreamEventsParams, options?: RequestOptions): APIPromise<void>;
|
|
41
|
+
}
|
|
42
|
+
export interface RunCreateResponse {
|
|
43
|
+
/**
|
|
44
|
+
* Run identifier, format "task*run*{uuid}".
|
|
45
|
+
*/
|
|
46
|
+
id: string;
|
|
47
|
+
/**
|
|
48
|
+
* When the run was created.
|
|
49
|
+
*/
|
|
50
|
+
created_at: string;
|
|
51
|
+
/**
|
|
52
|
+
* Effort level used for the run.
|
|
53
|
+
*/
|
|
54
|
+
effort: 'low' | 'medium' | 'high' | 'x-high' | 'max';
|
|
55
|
+
/**
|
|
56
|
+
* Interaction ID.
|
|
57
|
+
*/
|
|
58
|
+
interaction_id: string;
|
|
59
|
+
/**
|
|
60
|
+
* True while status is 'queued' or 'running'.
|
|
61
|
+
*/
|
|
62
|
+
is_active: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Current run status.
|
|
65
|
+
*/
|
|
66
|
+
status: 'queued' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
67
|
+
/**
|
|
68
|
+
* Web Search Agent instance this run belongs to.
|
|
69
|
+
*/
|
|
70
|
+
web_search_agent_id: string;
|
|
71
|
+
/**
|
|
72
|
+
* When the run completed.
|
|
73
|
+
*/
|
|
74
|
+
completed_at?: string | null;
|
|
75
|
+
/**
|
|
76
|
+
* Error details when the run failed.
|
|
77
|
+
*/
|
|
78
|
+
error?: RunCreateResponse.Error | null;
|
|
79
|
+
/**
|
|
80
|
+
* Prompt submitted for the run.
|
|
81
|
+
*/
|
|
82
|
+
prompt?: string | null;
|
|
83
|
+
/**
|
|
84
|
+
* When the run started executing.
|
|
85
|
+
*/
|
|
86
|
+
started_at?: string | null;
|
|
87
|
+
}
|
|
88
|
+
export declare namespace RunCreateResponse {
|
|
89
|
+
/**
|
|
90
|
+
* Error details when the run failed.
|
|
91
|
+
*/
|
|
92
|
+
interface Error {
|
|
93
|
+
/**
|
|
94
|
+
* Human-readable error description.
|
|
95
|
+
*/
|
|
96
|
+
message: string;
|
|
97
|
+
/**
|
|
98
|
+
* Reference ID (equals the run id).
|
|
99
|
+
*/
|
|
100
|
+
ref_id: string;
|
|
101
|
+
}
|
|
42
102
|
}
|
|
43
|
-
/**
|
|
44
|
-
* Paginated list of task runs for GET /tasks/runs.
|
|
45
|
-
*/
|
|
46
103
|
export interface RunListResponse {
|
|
104
|
+
/**
|
|
105
|
+
* Items returned in this page.
|
|
106
|
+
*/
|
|
47
107
|
items: Array<RunListResponse.Item>;
|
|
108
|
+
/**
|
|
109
|
+
* Maximum number of items returned.
|
|
110
|
+
*/
|
|
111
|
+
limit: number;
|
|
112
|
+
/**
|
|
113
|
+
* Number of items skipped before this page.
|
|
114
|
+
*/
|
|
115
|
+
offset: number;
|
|
116
|
+
/**
|
|
117
|
+
* Total number of items matching the query.
|
|
118
|
+
*/
|
|
48
119
|
total: number;
|
|
49
|
-
limit?: number;
|
|
50
|
-
offset?: number;
|
|
51
120
|
}
|
|
52
121
|
export declare namespace RunListResponse {
|
|
53
|
-
/**
|
|
54
|
-
* Task run status returned by list/create/get endpoints.
|
|
55
|
-
*/
|
|
56
122
|
interface Item {
|
|
57
123
|
/**
|
|
58
124
|
* Run identifier, format "task*run*{uuid}".
|
|
59
125
|
*/
|
|
60
126
|
id: string;
|
|
127
|
+
/**
|
|
128
|
+
* When the run was created.
|
|
129
|
+
*/
|
|
61
130
|
created_at: string;
|
|
62
131
|
/**
|
|
63
|
-
*
|
|
132
|
+
* Effort level used for the run.
|
|
64
133
|
*/
|
|
65
134
|
effort: 'low' | 'medium' | 'high' | 'x-high' | 'max';
|
|
66
135
|
/**
|
|
67
|
-
* Interaction ID
|
|
136
|
+
* Interaction ID.
|
|
68
137
|
*/
|
|
69
138
|
interaction_id: string;
|
|
70
139
|
/**
|
|
@@ -72,31 +141,33 @@ export declare namespace RunListResponse {
|
|
|
72
141
|
*/
|
|
73
142
|
is_active: boolean;
|
|
74
143
|
/**
|
|
75
|
-
*
|
|
76
|
-
* TaskRunStatus enum).
|
|
144
|
+
* Current run status.
|
|
77
145
|
*/
|
|
78
146
|
status: 'queued' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
79
147
|
/**
|
|
80
|
-
* Web Search Agent instance this run belongs to.
|
|
81
|
-
* (see AGENTS-1666). Use this to build the nested URL
|
|
82
|
-
* /api/v2/web-search-agents/{web_search_agent_id}/runs/{id}.
|
|
148
|
+
* Web Search Agent instance this run belongs to.
|
|
83
149
|
*/
|
|
84
150
|
web_search_agent_id: string;
|
|
151
|
+
/**
|
|
152
|
+
* When the run completed.
|
|
153
|
+
*/
|
|
85
154
|
completed_at?: string | null;
|
|
86
155
|
/**
|
|
87
|
-
* Error
|
|
156
|
+
* Error details when the run failed.
|
|
88
157
|
*/
|
|
89
158
|
error?: Item.Error | null;
|
|
90
159
|
/**
|
|
91
|
-
*
|
|
160
|
+
* Prompt submitted for the run.
|
|
92
161
|
*/
|
|
93
162
|
prompt?: string | null;
|
|
163
|
+
/**
|
|
164
|
+
* When the run started executing.
|
|
165
|
+
*/
|
|
94
166
|
started_at?: string | null;
|
|
95
|
-
workspace_id?: string | null;
|
|
96
167
|
}
|
|
97
168
|
namespace Item {
|
|
98
169
|
/**
|
|
99
|
-
* Error
|
|
170
|
+
* Error details when the run failed.
|
|
100
171
|
*/
|
|
101
172
|
interface Error {
|
|
102
173
|
/**
|
|
@@ -110,21 +181,21 @@ export declare namespace RunListResponse {
|
|
|
110
181
|
}
|
|
111
182
|
}
|
|
112
183
|
}
|
|
113
|
-
/**
|
|
114
|
-
* Task run status returned by list/create/get endpoints.
|
|
115
|
-
*/
|
|
116
184
|
export interface RunGetResponse {
|
|
117
185
|
/**
|
|
118
186
|
* Run identifier, format "task*run*{uuid}".
|
|
119
187
|
*/
|
|
120
188
|
id: string;
|
|
189
|
+
/**
|
|
190
|
+
* When the run was created.
|
|
191
|
+
*/
|
|
121
192
|
created_at: string;
|
|
122
193
|
/**
|
|
123
|
-
*
|
|
194
|
+
* Effort level used for the run.
|
|
124
195
|
*/
|
|
125
196
|
effort: 'low' | 'medium' | 'high' | 'x-high' | 'max';
|
|
126
197
|
/**
|
|
127
|
-
* Interaction ID
|
|
198
|
+
* Interaction ID.
|
|
128
199
|
*/
|
|
129
200
|
interaction_id: string;
|
|
130
201
|
/**
|
|
@@ -132,31 +203,33 @@ export interface RunGetResponse {
|
|
|
132
203
|
*/
|
|
133
204
|
is_active: boolean;
|
|
134
205
|
/**
|
|
135
|
-
*
|
|
136
|
-
* TaskRunStatus enum).
|
|
206
|
+
* Current run status.
|
|
137
207
|
*/
|
|
138
208
|
status: 'queued' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
139
209
|
/**
|
|
140
|
-
* Web Search Agent instance this run belongs to.
|
|
141
|
-
* (see AGENTS-1666). Use this to build the nested URL
|
|
142
|
-
* /api/v2/web-search-agents/{web_search_agent_id}/runs/{id}.
|
|
210
|
+
* Web Search Agent instance this run belongs to.
|
|
143
211
|
*/
|
|
144
212
|
web_search_agent_id: string;
|
|
213
|
+
/**
|
|
214
|
+
* When the run completed.
|
|
215
|
+
*/
|
|
145
216
|
completed_at?: string | null;
|
|
146
217
|
/**
|
|
147
|
-
* Error
|
|
218
|
+
* Error details when the run failed.
|
|
148
219
|
*/
|
|
149
220
|
error?: RunGetResponse.Error | null;
|
|
150
221
|
/**
|
|
151
|
-
*
|
|
222
|
+
* Prompt submitted for the run.
|
|
152
223
|
*/
|
|
153
224
|
prompt?: string | null;
|
|
225
|
+
/**
|
|
226
|
+
* When the run started executing.
|
|
227
|
+
*/
|
|
154
228
|
started_at?: string | null;
|
|
155
|
-
workspace_id?: string | null;
|
|
156
229
|
}
|
|
157
230
|
export declare namespace RunGetResponse {
|
|
158
231
|
/**
|
|
159
|
-
* Error
|
|
232
|
+
* Error details when the run failed.
|
|
160
233
|
*/
|
|
161
234
|
interface Error {
|
|
162
235
|
/**
|
|
@@ -169,54 +242,93 @@ export declare namespace RunGetResponse {
|
|
|
169
242
|
ref_id: string;
|
|
170
243
|
}
|
|
171
244
|
}
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
export type RunGetResultResponse = RunGetResultResponse.TaskRunResult | RunGetResultResponse.TaskRunFailedResult;
|
|
176
|
-
export declare namespace RunGetResultResponse {
|
|
177
|
-
/**
|
|
178
|
-
* Response for GET /tasks/runs/{run_id}/result — status 'completed'.
|
|
179
|
-
*/
|
|
180
|
-
interface TaskRunResult {
|
|
245
|
+
export type RunResultResponse = RunResultResponse.TaskRunResultPublicV2 | RunResultResponse.TaskRunFailedResultPublicV2;
|
|
246
|
+
export declare namespace RunResultResponse {
|
|
247
|
+
interface TaskRunResultPublicV2 {
|
|
181
248
|
/**
|
|
182
249
|
* Output from the completed task.
|
|
183
250
|
*/
|
|
184
|
-
output:
|
|
251
|
+
output: TaskRunResultPublicV2.TaskRunTextOutputPublicV2 | TaskRunResultPublicV2.TaskRunJsonOutputPublicV2;
|
|
185
252
|
/**
|
|
186
253
|
* Task run object with status 'completed'.
|
|
187
254
|
*/
|
|
188
|
-
run:
|
|
255
|
+
run: TaskRunResultPublicV2.Run;
|
|
189
256
|
}
|
|
190
|
-
namespace
|
|
191
|
-
|
|
192
|
-
* Text output from a completed task.
|
|
193
|
-
*/
|
|
194
|
-
interface TaskRunTextOutput {
|
|
257
|
+
namespace TaskRunResultPublicV2 {
|
|
258
|
+
interface TaskRunTextOutputPublicV2 {
|
|
195
259
|
/**
|
|
196
260
|
* The final prose answer.
|
|
197
261
|
*/
|
|
198
262
|
content: string;
|
|
199
|
-
|
|
263
|
+
/**
|
|
264
|
+
* Trust and citation metadata for the output.
|
|
265
|
+
*/
|
|
266
|
+
trust: TaskRunTextOutputPublicV2.Trust;
|
|
267
|
+
/**
|
|
268
|
+
* Output content type.
|
|
269
|
+
*/
|
|
200
270
|
type?: 'text';
|
|
201
271
|
}
|
|
202
|
-
namespace
|
|
272
|
+
namespace TaskRunTextOutputPublicV2 {
|
|
273
|
+
/**
|
|
274
|
+
* Trust and citation metadata for the output.
|
|
275
|
+
*/
|
|
203
276
|
interface Trust {
|
|
277
|
+
/**
|
|
278
|
+
* Per-claim trust, keyed by callout markers in the answer text.
|
|
279
|
+
*/
|
|
204
280
|
claims: Array<Trust.Claim>;
|
|
205
|
-
|
|
281
|
+
/**
|
|
282
|
+
* Overall confidence in the answer.
|
|
283
|
+
*/
|
|
284
|
+
confidence: 'high' | 'medium' | 'low' | 'pre_existing';
|
|
285
|
+
/**
|
|
286
|
+
* Why this confidence level was assigned.
|
|
287
|
+
*/
|
|
206
288
|
reasoning: string;
|
|
289
|
+
/**
|
|
290
|
+
* Sources consulted while producing the answer.
|
|
291
|
+
*/
|
|
207
292
|
sources: Array<Trust.Source>;
|
|
208
293
|
}
|
|
209
294
|
namespace Trust {
|
|
295
|
+
/**
|
|
296
|
+
* Trust metadata for one claim in a prose answer, keyed by callout marker.
|
|
297
|
+
*/
|
|
210
298
|
interface Claim {
|
|
299
|
+
/**
|
|
300
|
+
* Callout marker number referencing this claim in the answer text.
|
|
301
|
+
*/
|
|
211
302
|
callout: number;
|
|
303
|
+
/**
|
|
304
|
+
* Citations backing this claim.
|
|
305
|
+
*/
|
|
212
306
|
citations: Array<Claim.Citation>;
|
|
213
|
-
|
|
307
|
+
/**
|
|
308
|
+
* Confidence in this claim.
|
|
309
|
+
*/
|
|
310
|
+
confidence: 'high' | 'medium' | 'low' | 'pre_existing';
|
|
311
|
+
/**
|
|
312
|
+
* Why this confidence level was assigned.
|
|
313
|
+
*/
|
|
214
314
|
reasoning: string;
|
|
215
315
|
}
|
|
216
316
|
namespace Claim {
|
|
317
|
+
/**
|
|
318
|
+
* A citation backing a specific claim in the answer.
|
|
319
|
+
*/
|
|
217
320
|
interface Citation {
|
|
321
|
+
/**
|
|
322
|
+
* URL of the cited page.
|
|
323
|
+
*/
|
|
218
324
|
url: string;
|
|
325
|
+
/**
|
|
326
|
+
* Verbatim excerpts supporting the claim.
|
|
327
|
+
*/
|
|
219
328
|
excerpts?: Array<string> | null;
|
|
329
|
+
/**
|
|
330
|
+
* Extract template used to read the source, when one was used.
|
|
331
|
+
*/
|
|
220
332
|
extract_template_name?: string | null;
|
|
221
333
|
/**
|
|
222
334
|
* What _kind_ of source this is (classified by the compress LLM), independent of
|
|
@@ -240,13 +352,31 @@ export declare namespace RunGetResultResponse {
|
|
|
240
352
|
* directly.
|
|
241
353
|
*/
|
|
242
354
|
source_intent?: 'official' | 'news' | 'social' | 'academic' | 'aggregator' | 'other' | null;
|
|
355
|
+
/**
|
|
356
|
+
* How authoritative the source is: 'primary' or 'secondary'.
|
|
357
|
+
*/
|
|
243
358
|
source_type?: 'primary' | 'secondary' | null;
|
|
359
|
+
/**
|
|
360
|
+
* Title of the cited page.
|
|
361
|
+
*/
|
|
244
362
|
title?: string | null;
|
|
245
363
|
}
|
|
246
364
|
}
|
|
365
|
+
/**
|
|
366
|
+
* A source consulted while producing the answer.
|
|
367
|
+
*/
|
|
247
368
|
interface Source {
|
|
369
|
+
/**
|
|
370
|
+
* How authoritative the source is: 'primary' or 'secondary'.
|
|
371
|
+
*/
|
|
248
372
|
type: 'primary' | 'secondary';
|
|
373
|
+
/**
|
|
374
|
+
* URL of the source page.
|
|
375
|
+
*/
|
|
249
376
|
url: string;
|
|
377
|
+
/**
|
|
378
|
+
* Extract template used to read the source, when one was used.
|
|
379
|
+
*/
|
|
250
380
|
extract_template_name?: string | null;
|
|
251
381
|
/**
|
|
252
382
|
* What _kind_ of source this is (classified by the compress LLM), independent of
|
|
@@ -270,43 +400,89 @@ export declare namespace RunGetResultResponse {
|
|
|
270
400
|
* directly.
|
|
271
401
|
*/
|
|
272
402
|
source_intent?: 'official' | 'news' | 'social' | 'academic' | 'aggregator' | 'other' | null;
|
|
403
|
+
/**
|
|
404
|
+
* Title of the source page.
|
|
405
|
+
*/
|
|
273
406
|
title?: string | null;
|
|
274
407
|
}
|
|
275
408
|
}
|
|
276
409
|
}
|
|
277
|
-
|
|
278
|
-
* Structured JSON output from a completed task, produced when
|
|
279
|
-
* task_spec.output_schema.type is 'json'.
|
|
280
|
-
*/
|
|
281
|
-
interface TaskRunJsonOutput {
|
|
410
|
+
interface TaskRunJsonOutputPublicV2 {
|
|
282
411
|
/**
|
|
283
|
-
*
|
|
284
|
-
* list for array schemas.
|
|
412
|
+
* The final structured output.
|
|
285
413
|
*/
|
|
286
414
|
content: {
|
|
287
415
|
[key: string]: unknown;
|
|
288
416
|
} | Array<unknown>;
|
|
289
|
-
|
|
417
|
+
/**
|
|
418
|
+
* Trust and citation metadata for the output.
|
|
419
|
+
*/
|
|
420
|
+
trust: TaskRunJsonOutputPublicV2.Trust;
|
|
421
|
+
/**
|
|
422
|
+
* Output content type.
|
|
423
|
+
*/
|
|
290
424
|
type?: 'json';
|
|
291
425
|
}
|
|
292
|
-
namespace
|
|
426
|
+
namespace TaskRunJsonOutputPublicV2 {
|
|
427
|
+
/**
|
|
428
|
+
* Trust and citation metadata for the output.
|
|
429
|
+
*/
|
|
293
430
|
interface Trust {
|
|
431
|
+
/**
|
|
432
|
+
* Per-value trust, keyed by JSON path in the structured output.
|
|
433
|
+
*/
|
|
294
434
|
claims: Array<Trust.Claim>;
|
|
295
|
-
|
|
435
|
+
/**
|
|
436
|
+
* Overall confidence in the answer.
|
|
437
|
+
*/
|
|
438
|
+
confidence: 'high' | 'medium' | 'low' | 'pre_existing';
|
|
439
|
+
/**
|
|
440
|
+
* Why this confidence level was assigned.
|
|
441
|
+
*/
|
|
296
442
|
reasoning: string;
|
|
443
|
+
/**
|
|
444
|
+
* Sources consulted while producing the answer.
|
|
445
|
+
*/
|
|
297
446
|
sources: Array<Trust.Source>;
|
|
298
447
|
}
|
|
299
448
|
namespace Trust {
|
|
449
|
+
/**
|
|
450
|
+
* Trust metadata for one value in a structured (JSON) answer, keyed by JSON path.
|
|
451
|
+
*/
|
|
300
452
|
interface Claim {
|
|
453
|
+
/**
|
|
454
|
+
* Citations backing this value.
|
|
455
|
+
*/
|
|
301
456
|
citations: Array<Claim.Citation>;
|
|
302
|
-
|
|
457
|
+
/**
|
|
458
|
+
* Confidence in this value.
|
|
459
|
+
*/
|
|
460
|
+
confidence: 'high' | 'medium' | 'low' | 'pre_existing';
|
|
461
|
+
/**
|
|
462
|
+
* JSON path of the value in the structured output this claim refers to.
|
|
463
|
+
*/
|
|
303
464
|
path: string;
|
|
465
|
+
/**
|
|
466
|
+
* Why this confidence level was assigned.
|
|
467
|
+
*/
|
|
304
468
|
reasoning: string;
|
|
305
469
|
}
|
|
306
470
|
namespace Claim {
|
|
471
|
+
/**
|
|
472
|
+
* A citation backing a specific claim in the answer.
|
|
473
|
+
*/
|
|
307
474
|
interface Citation {
|
|
475
|
+
/**
|
|
476
|
+
* URL of the cited page.
|
|
477
|
+
*/
|
|
308
478
|
url: string;
|
|
479
|
+
/**
|
|
480
|
+
* Verbatim excerpts supporting the claim.
|
|
481
|
+
*/
|
|
309
482
|
excerpts?: Array<string> | null;
|
|
483
|
+
/**
|
|
484
|
+
* Extract template used to read the source, when one was used.
|
|
485
|
+
*/
|
|
310
486
|
extract_template_name?: string | null;
|
|
311
487
|
/**
|
|
312
488
|
* What _kind_ of source this is (classified by the compress LLM), independent of
|
|
@@ -330,13 +506,31 @@ export declare namespace RunGetResultResponse {
|
|
|
330
506
|
* directly.
|
|
331
507
|
*/
|
|
332
508
|
source_intent?: 'official' | 'news' | 'social' | 'academic' | 'aggregator' | 'other' | null;
|
|
509
|
+
/**
|
|
510
|
+
* How authoritative the source is: 'primary' or 'secondary'.
|
|
511
|
+
*/
|
|
333
512
|
source_type?: 'primary' | 'secondary' | null;
|
|
513
|
+
/**
|
|
514
|
+
* Title of the cited page.
|
|
515
|
+
*/
|
|
334
516
|
title?: string | null;
|
|
335
517
|
}
|
|
336
518
|
}
|
|
519
|
+
/**
|
|
520
|
+
* A source consulted while producing the answer.
|
|
521
|
+
*/
|
|
337
522
|
interface Source {
|
|
523
|
+
/**
|
|
524
|
+
* How authoritative the source is: 'primary' or 'secondary'.
|
|
525
|
+
*/
|
|
338
526
|
type: 'primary' | 'secondary';
|
|
527
|
+
/**
|
|
528
|
+
* URL of the source page.
|
|
529
|
+
*/
|
|
339
530
|
url: string;
|
|
531
|
+
/**
|
|
532
|
+
* Extract template used to read the source, when one was used.
|
|
533
|
+
*/
|
|
340
534
|
extract_template_name?: string | null;
|
|
341
535
|
/**
|
|
342
536
|
* What _kind_ of source this is (classified by the compress LLM), independent of
|
|
@@ -360,6 +554,9 @@ export declare namespace RunGetResultResponse {
|
|
|
360
554
|
* directly.
|
|
361
555
|
*/
|
|
362
556
|
source_intent?: 'official' | 'news' | 'social' | 'academic' | 'aggregator' | 'other' | null;
|
|
557
|
+
/**
|
|
558
|
+
* Title of the source page.
|
|
559
|
+
*/
|
|
363
560
|
title?: string | null;
|
|
364
561
|
}
|
|
365
562
|
}
|
|
@@ -372,13 +569,16 @@ export declare namespace RunGetResultResponse {
|
|
|
372
569
|
* Run identifier, format "task*run*{uuid}".
|
|
373
570
|
*/
|
|
374
571
|
id: string;
|
|
572
|
+
/**
|
|
573
|
+
* When the run was created.
|
|
574
|
+
*/
|
|
375
575
|
created_at: string;
|
|
376
576
|
/**
|
|
377
|
-
*
|
|
577
|
+
* Effort level used for the run.
|
|
378
578
|
*/
|
|
379
579
|
effort: 'low' | 'medium' | 'high' | 'x-high' | 'max';
|
|
380
580
|
/**
|
|
381
|
-
* Interaction ID
|
|
581
|
+
* Interaction ID.
|
|
382
582
|
*/
|
|
383
583
|
interaction_id: string;
|
|
384
584
|
/**
|
|
@@ -386,31 +586,33 @@ export declare namespace RunGetResultResponse {
|
|
|
386
586
|
*/
|
|
387
587
|
is_active: boolean;
|
|
388
588
|
/**
|
|
389
|
-
*
|
|
390
|
-
* TaskRunStatus enum).
|
|
589
|
+
* Current run status.
|
|
391
590
|
*/
|
|
392
591
|
status: 'queued' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
393
592
|
/**
|
|
394
|
-
* Web Search Agent instance this run belongs to.
|
|
395
|
-
* (see AGENTS-1666). Use this to build the nested URL
|
|
396
|
-
* /api/v2/web-search-agents/{web_search_agent_id}/runs/{id}.
|
|
593
|
+
* Web Search Agent instance this run belongs to.
|
|
397
594
|
*/
|
|
398
595
|
web_search_agent_id: string;
|
|
596
|
+
/**
|
|
597
|
+
* When the run completed.
|
|
598
|
+
*/
|
|
399
599
|
completed_at?: string | null;
|
|
400
600
|
/**
|
|
401
|
-
* Error
|
|
601
|
+
* Error details when the run failed.
|
|
402
602
|
*/
|
|
403
603
|
error?: Run.Error | null;
|
|
404
604
|
/**
|
|
405
|
-
*
|
|
605
|
+
* Prompt submitted for the run.
|
|
406
606
|
*/
|
|
407
607
|
prompt?: string | null;
|
|
608
|
+
/**
|
|
609
|
+
* When the run started executing.
|
|
610
|
+
*/
|
|
408
611
|
started_at?: string | null;
|
|
409
|
-
workspace_id?: string | null;
|
|
410
612
|
}
|
|
411
613
|
namespace Run {
|
|
412
614
|
/**
|
|
413
|
-
* Error
|
|
615
|
+
* Error details when the run failed.
|
|
414
616
|
*/
|
|
415
617
|
interface Error {
|
|
416
618
|
/**
|
|
@@ -424,23 +626,17 @@ export declare namespace RunGetResultResponse {
|
|
|
424
626
|
}
|
|
425
627
|
}
|
|
426
628
|
}
|
|
427
|
-
|
|
428
|
-
* Response for GET /tasks/runs/{run_id}/result when the run failed.
|
|
429
|
-
*
|
|
430
|
-
* Returned with HTTP 422 so callers can distinguish a failed run from a missing
|
|
431
|
-
* one (404) or an active one (408).
|
|
432
|
-
*/
|
|
433
|
-
interface TaskRunFailedResult {
|
|
629
|
+
interface TaskRunFailedResultPublicV2 {
|
|
434
630
|
/**
|
|
435
631
|
* Structured error detail.
|
|
436
632
|
*/
|
|
437
|
-
error:
|
|
633
|
+
error: TaskRunFailedResultPublicV2.Error;
|
|
438
634
|
/**
|
|
439
635
|
* Task run object with status 'failed'.
|
|
440
636
|
*/
|
|
441
|
-
run:
|
|
637
|
+
run: TaskRunFailedResultPublicV2.Run;
|
|
442
638
|
}
|
|
443
|
-
namespace
|
|
639
|
+
namespace TaskRunFailedResultPublicV2 {
|
|
444
640
|
/**
|
|
445
641
|
* Structured error detail.
|
|
446
642
|
*/
|
|
@@ -462,13 +658,16 @@ export declare namespace RunGetResultResponse {
|
|
|
462
658
|
* Run identifier, format "task*run*{uuid}".
|
|
463
659
|
*/
|
|
464
660
|
id: string;
|
|
661
|
+
/**
|
|
662
|
+
* When the run was created.
|
|
663
|
+
*/
|
|
465
664
|
created_at: string;
|
|
466
665
|
/**
|
|
467
|
-
*
|
|
666
|
+
* Effort level used for the run.
|
|
468
667
|
*/
|
|
469
668
|
effort: 'low' | 'medium' | 'high' | 'x-high' | 'max';
|
|
470
669
|
/**
|
|
471
|
-
* Interaction ID
|
|
670
|
+
* Interaction ID.
|
|
472
671
|
*/
|
|
473
672
|
interaction_id: string;
|
|
474
673
|
/**
|
|
@@ -476,31 +675,33 @@ export declare namespace RunGetResultResponse {
|
|
|
476
675
|
*/
|
|
477
676
|
is_active: boolean;
|
|
478
677
|
/**
|
|
479
|
-
*
|
|
480
|
-
* TaskRunStatus enum).
|
|
678
|
+
* Current run status.
|
|
481
679
|
*/
|
|
482
680
|
status: 'queued' | 'running' | 'completed' | 'failed' | 'cancelled';
|
|
483
681
|
/**
|
|
484
|
-
* Web Search Agent instance this run belongs to.
|
|
485
|
-
* (see AGENTS-1666). Use this to build the nested URL
|
|
486
|
-
* /api/v2/web-search-agents/{web_search_agent_id}/runs/{id}.
|
|
682
|
+
* Web Search Agent instance this run belongs to.
|
|
487
683
|
*/
|
|
488
684
|
web_search_agent_id: string;
|
|
685
|
+
/**
|
|
686
|
+
* When the run completed.
|
|
687
|
+
*/
|
|
489
688
|
completed_at?: string | null;
|
|
490
689
|
/**
|
|
491
|
-
* Error
|
|
690
|
+
* Error details when the run failed.
|
|
492
691
|
*/
|
|
493
692
|
error?: Run.Error | null;
|
|
494
693
|
/**
|
|
495
|
-
*
|
|
694
|
+
* Prompt submitted for the run.
|
|
496
695
|
*/
|
|
497
696
|
prompt?: string | null;
|
|
697
|
+
/**
|
|
698
|
+
* When the run started executing.
|
|
699
|
+
*/
|
|
498
700
|
started_at?: string | null;
|
|
499
|
-
workspace_id?: string | null;
|
|
500
701
|
}
|
|
501
702
|
namespace Run {
|
|
502
703
|
/**
|
|
503
|
-
* Error
|
|
704
|
+
* Error details when the run failed.
|
|
504
705
|
*/
|
|
505
706
|
interface Error {
|
|
506
707
|
/**
|
|
@@ -515,26 +716,110 @@ export declare namespace RunGetResultResponse {
|
|
|
515
716
|
}
|
|
516
717
|
}
|
|
517
718
|
}
|
|
518
|
-
export
|
|
719
|
+
export interface RunCreateParams {
|
|
720
|
+
/**
|
|
721
|
+
* User prompt or task instructions for the run.
|
|
722
|
+
*/
|
|
723
|
+
input: string;
|
|
724
|
+
/**
|
|
725
|
+
* Canonical effort tier names for the research graph.
|
|
726
|
+
*/
|
|
727
|
+
effort?: 'low' | 'medium' | 'high' | 'x-high' | 'max' | null;
|
|
728
|
+
/**
|
|
729
|
+
* Whether to stream run events when supported.
|
|
730
|
+
*/
|
|
731
|
+
enable_events?: boolean;
|
|
732
|
+
/**
|
|
733
|
+
* Existing records to ENRICH: a list of partial rows, or a single object,
|
|
734
|
+
* mirroring output_schema's shape.
|
|
735
|
+
*/
|
|
736
|
+
input_data?: Array<{
|
|
737
|
+
[key: string]: unknown;
|
|
738
|
+
}> | {
|
|
739
|
+
[key: string]: unknown;
|
|
740
|
+
} | null;
|
|
741
|
+
/**
|
|
742
|
+
* JSON schema overriding the agent's default structured output for this run.
|
|
743
|
+
*/
|
|
744
|
+
output_schema?: {
|
|
745
|
+
[key: string]: unknown;
|
|
746
|
+
} | null;
|
|
747
|
+
/**
|
|
748
|
+
* Previous interaction identifier used to continue a conversation.
|
|
749
|
+
*/
|
|
750
|
+
previous_interaction_id?: string | null;
|
|
751
|
+
/**
|
|
752
|
+
* Source guidance overriding the agent default.
|
|
753
|
+
*/
|
|
754
|
+
sources?: RunCreateParams.Sources | null;
|
|
755
|
+
}
|
|
756
|
+
export declare namespace RunCreateParams {
|
|
757
|
+
/**
|
|
758
|
+
* Source guidance overriding the agent default.
|
|
759
|
+
*/
|
|
760
|
+
interface Sources {
|
|
761
|
+
/**
|
|
762
|
+
* Source groups the agent is allowed to use.
|
|
763
|
+
*/
|
|
764
|
+
allow?: Array<Sources.Allow>;
|
|
765
|
+
/**
|
|
766
|
+
* Free-text guidance describing sources or domains to avoid.
|
|
767
|
+
*/
|
|
768
|
+
avoid?: string | null;
|
|
769
|
+
/**
|
|
770
|
+
* Source groups the agent should not use.
|
|
771
|
+
*/
|
|
772
|
+
block?: Array<Sources.Block>;
|
|
773
|
+
/**
|
|
774
|
+
* Free-text guidance describing sources or domains to prioritize.
|
|
775
|
+
*/
|
|
776
|
+
prioritize?: string | null;
|
|
777
|
+
}
|
|
778
|
+
namespace Sources {
|
|
779
|
+
interface Allow {
|
|
780
|
+
/**
|
|
781
|
+
* Domains included in this source group.
|
|
782
|
+
*/
|
|
783
|
+
domains: Array<string>;
|
|
784
|
+
/**
|
|
785
|
+
* Source group title.
|
|
786
|
+
*/
|
|
787
|
+
title: string;
|
|
788
|
+
/**
|
|
789
|
+
* Zero-based source group position.
|
|
790
|
+
*/
|
|
791
|
+
order?: number;
|
|
792
|
+
}
|
|
793
|
+
interface Block {
|
|
794
|
+
/**
|
|
795
|
+
* Domains included in this source group.
|
|
796
|
+
*/
|
|
797
|
+
domains: Array<string>;
|
|
798
|
+
/**
|
|
799
|
+
* Source group title.
|
|
800
|
+
*/
|
|
801
|
+
title: string;
|
|
802
|
+
/**
|
|
803
|
+
* Zero-based source group position.
|
|
804
|
+
*/
|
|
805
|
+
order?: number;
|
|
806
|
+
}
|
|
807
|
+
}
|
|
808
|
+
}
|
|
519
809
|
export interface RunListParams {
|
|
520
810
|
limit?: number;
|
|
521
811
|
offset?: number;
|
|
522
|
-
q?: string | null;
|
|
523
|
-
status?: string | null;
|
|
524
|
-
}
|
|
525
|
-
export interface RunCancelParams {
|
|
526
|
-
agent_id: string;
|
|
527
812
|
}
|
|
528
813
|
export interface RunGetParams {
|
|
529
814
|
agent_id: string;
|
|
530
815
|
}
|
|
531
|
-
export interface
|
|
816
|
+
export interface RunResultParams {
|
|
532
817
|
agent_id: string;
|
|
533
818
|
}
|
|
534
819
|
export interface RunStreamEventsParams {
|
|
535
820
|
agent_id: string;
|
|
536
821
|
}
|
|
537
822
|
export declare namespace Runs {
|
|
538
|
-
export { type
|
|
823
|
+
export { type RunCreateResponse as RunCreateResponse, type RunListResponse as RunListResponse, type RunGetResponse as RunGetResponse, type RunResultResponse as RunResultResponse, type RunCreateParams as RunCreateParams, type RunListParams as RunListParams, type RunGetParams as RunGetParams, type RunResultParams as RunResultParams, type RunStreamEventsParams as RunStreamEventsParams, };
|
|
539
824
|
}
|
|
540
825
|
//# sourceMappingURL=runs.d.mts.map
|