@naturali/sdk 0.38.1 → 0.39.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/dist/index.cjs +1 -1
- package/dist/index.d.cts +23 -2
- package/dist/index.d.mts +23 -2
- package/dist/index.mjs +1 -1
- package/package.json +2 -2
package/dist/index.cjs
CHANGED
|
@@ -655,7 +655,7 @@ var Agents = class {
|
|
|
655
655
|
/**
|
|
656
656
|
* Update an agent
|
|
657
657
|
*
|
|
658
|
-
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), or the naturali-side status. At least one field is required.
|
|
658
|
+
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), the structured-output schema (output_schema), or the naturali-side status. At least one field is required.
|
|
659
659
|
*
|
|
660
660
|
*/
|
|
661
661
|
static updateAgent(options) {
|
package/dist/index.d.cts
CHANGED
|
@@ -367,6 +367,13 @@ type Agent = {
|
|
|
367
367
|
*/
|
|
368
368
|
tool_ids: Array<string>;
|
|
369
369
|
tool_choice: ToolChoice;
|
|
370
|
+
/**
|
|
371
|
+
* JSON Schema describing the structured object the model must return. When set, a non-streaming generation is constrained to it and the parsed value comes back as `object` on the generation result. Null (the default) leaves the output unconstrained. Streaming generations are unaffected.
|
|
372
|
+
*
|
|
373
|
+
*/
|
|
374
|
+
output_schema: {
|
|
375
|
+
[key: string]: unknown;
|
|
376
|
+
} | null;
|
|
370
377
|
status: 'active' | 'disabled';
|
|
371
378
|
created_at: Date;
|
|
372
379
|
updated_at: Date;
|
|
@@ -401,6 +408,13 @@ type AgentCreate = {
|
|
|
401
408
|
*/
|
|
402
409
|
tool_ids?: Array<string>;
|
|
403
410
|
tool_choice?: ToolChoice;
|
|
411
|
+
/**
|
|
412
|
+
* JSON Schema describing the structured object the model must return. When set, a non-streaming generation is constrained to it and the parsed value comes back as `object` on the generation result. Omit (the default) to leave the output unconstrained. Streaming generations are unaffected.
|
|
413
|
+
*
|
|
414
|
+
*/
|
|
415
|
+
output_schema?: {
|
|
416
|
+
[key: string]: unknown;
|
|
417
|
+
};
|
|
404
418
|
};
|
|
405
419
|
/**
|
|
406
420
|
* At least one field must be present.
|
|
@@ -422,6 +436,13 @@ type AgentUpdate = {
|
|
|
422
436
|
*/
|
|
423
437
|
tool_ids?: Array<string>;
|
|
424
438
|
tool_choice?: ToolChoice;
|
|
439
|
+
/**
|
|
440
|
+
* Replace the agent's structured-output schema. An object constrains non-streaming generations to it; `null` clears it and leaves the output unconstrained.
|
|
441
|
+
*
|
|
442
|
+
*/
|
|
443
|
+
output_schema?: {
|
|
444
|
+
[key: string]: unknown;
|
|
445
|
+
} | null;
|
|
425
446
|
status?: 'active' | 'disabled';
|
|
426
447
|
};
|
|
427
448
|
type AgentList = {
|
|
@@ -610,7 +631,7 @@ type BoardDispatch = {
|
|
|
610
631
|
type BoardCompletionRule = {
|
|
611
632
|
/**
|
|
612
633
|
* JSON Logic evaluated against `{ task, result }`. `result` is the dispatch's output: for an agent column its generation output; for a tool column the tool's own result object.
|
|
613
|
-
* Routing an agent column on *structured* output (`result.object.…`) needs the agent to declare an
|
|
634
|
+
* Routing an agent column on *structured* output (`result.object.…`) needs the agent to declare an `output_schema` — set one and every field of it is addressable here.
|
|
614
635
|
*
|
|
615
636
|
*/
|
|
616
637
|
when: unknown;
|
|
@@ -6024,7 +6045,7 @@ declare class Agents {
|
|
|
6024
6045
|
/**
|
|
6025
6046
|
* Update an agent
|
|
6026
6047
|
*
|
|
6027
|
-
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), or the naturali-side status. At least one field is required.
|
|
6048
|
+
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), the structured-output schema (output_schema), or the naturali-side status. At least one field is required.
|
|
6028
6049
|
*
|
|
6029
6050
|
*/
|
|
6030
6051
|
static updateAgent<ThrowOnError extends boolean = false>(options: Options<UpdateAgentData, ThrowOnError>): RequestResult<UpdateAgentResponses, UpdateAgentErrors, ThrowOnError>;
|
package/dist/index.d.mts
CHANGED
|
@@ -367,6 +367,13 @@ type Agent = {
|
|
|
367
367
|
*/
|
|
368
368
|
tool_ids: Array<string>;
|
|
369
369
|
tool_choice: ToolChoice;
|
|
370
|
+
/**
|
|
371
|
+
* JSON Schema describing the structured object the model must return. When set, a non-streaming generation is constrained to it and the parsed value comes back as `object` on the generation result. Null (the default) leaves the output unconstrained. Streaming generations are unaffected.
|
|
372
|
+
*
|
|
373
|
+
*/
|
|
374
|
+
output_schema: {
|
|
375
|
+
[key: string]: unknown;
|
|
376
|
+
} | null;
|
|
370
377
|
status: 'active' | 'disabled';
|
|
371
378
|
created_at: Date;
|
|
372
379
|
updated_at: Date;
|
|
@@ -401,6 +408,13 @@ type AgentCreate = {
|
|
|
401
408
|
*/
|
|
402
409
|
tool_ids?: Array<string>;
|
|
403
410
|
tool_choice?: ToolChoice;
|
|
411
|
+
/**
|
|
412
|
+
* JSON Schema describing the structured object the model must return. When set, a non-streaming generation is constrained to it and the parsed value comes back as `object` on the generation result. Omit (the default) to leave the output unconstrained. Streaming generations are unaffected.
|
|
413
|
+
*
|
|
414
|
+
*/
|
|
415
|
+
output_schema?: {
|
|
416
|
+
[key: string]: unknown;
|
|
417
|
+
};
|
|
404
418
|
};
|
|
405
419
|
/**
|
|
406
420
|
* At least one field must be present.
|
|
@@ -422,6 +436,13 @@ type AgentUpdate = {
|
|
|
422
436
|
*/
|
|
423
437
|
tool_ids?: Array<string>;
|
|
424
438
|
tool_choice?: ToolChoice;
|
|
439
|
+
/**
|
|
440
|
+
* Replace the agent's structured-output schema. An object constrains non-streaming generations to it; `null` clears it and leaves the output unconstrained.
|
|
441
|
+
*
|
|
442
|
+
*/
|
|
443
|
+
output_schema?: {
|
|
444
|
+
[key: string]: unknown;
|
|
445
|
+
} | null;
|
|
425
446
|
status?: 'active' | 'disabled';
|
|
426
447
|
};
|
|
427
448
|
type AgentList = {
|
|
@@ -610,7 +631,7 @@ type BoardDispatch = {
|
|
|
610
631
|
type BoardCompletionRule = {
|
|
611
632
|
/**
|
|
612
633
|
* JSON Logic evaluated against `{ task, result }`. `result` is the dispatch's output: for an agent column its generation output; for a tool column the tool's own result object.
|
|
613
|
-
* Routing an agent column on *structured* output (`result.object.…`) needs the agent to declare an
|
|
634
|
+
* Routing an agent column on *structured* output (`result.object.…`) needs the agent to declare an `output_schema` — set one and every field of it is addressable here.
|
|
614
635
|
*
|
|
615
636
|
*/
|
|
616
637
|
when: unknown;
|
|
@@ -6024,7 +6045,7 @@ declare class Agents {
|
|
|
6024
6045
|
/**
|
|
6025
6046
|
* Update an agent
|
|
6026
6047
|
*
|
|
6027
|
-
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), or the naturali-side status. At least one field is required.
|
|
6048
|
+
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), the structured-output schema (output_schema), or the naturali-side status. At least one field is required.
|
|
6028
6049
|
*
|
|
6029
6050
|
*/
|
|
6030
6051
|
static updateAgent<ThrowOnError extends boolean = false>(options: Options<UpdateAgentData, ThrowOnError>): RequestResult<UpdateAgentResponses, UpdateAgentErrors, ThrowOnError>;
|
package/dist/index.mjs
CHANGED
|
@@ -654,7 +654,7 @@ var Agents = class {
|
|
|
654
654
|
/**
|
|
655
655
|
* Update an agent
|
|
656
656
|
*
|
|
657
|
-
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), or the naturali-side status. At least one field is required.
|
|
657
|
+
* Change the bound provider, name, model, instructions, sampling/step config, attached tools (tool_ids/tool_choice), the structured-output schema (output_schema), or the naturali-side status. At least one field is required.
|
|
658
658
|
*
|
|
659
659
|
*/
|
|
660
660
|
static updateAgent(options) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@naturali/sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.39.0",
|
|
4
4
|
"description": "TypeScript SDK for the naturali.ai API, generated from its OpenAPI specs",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"tsx": "^4.23.1",
|
|
38
38
|
"typescript": "~6.0.3",
|
|
39
39
|
"vitest": "^4.1.10",
|
|
40
|
-
"@naturali/api": "0.
|
|
40
|
+
"@naturali/api": "0.39.0"
|
|
41
41
|
},
|
|
42
42
|
"scripts": {
|
|
43
43
|
"generate": "tsx scripts/generate.ts",
|