@takeshape/schema 11.91.0 → 11.94.3
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/agents.d.ts +24 -1
- package/dist/agents.js +33 -0
- package/dist/builtin-schema.js +3 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/migration/types.d.ts +1 -1
- package/dist/project-schema/latest.d.ts +41 -13
- package/dist/project-schema/v3.48.0.d.ts +41 -13
- package/dist/project-schema/v3.49.0.d.ts +41 -13
- package/dist/project-schema/v3.50.0.d.ts +41 -13
- package/dist/project-schema/v3.51.0.d.ts +41 -13
- package/dist/project-schema/v3.52.0.d.ts +41 -13
- package/dist/project-schema/v3.53.0.d.ts +41 -13
- package/dist/project-schema/v3.54.0.d.ts +41 -13
- package/dist/project-schema/v3.55.0.d.ts +41 -13
- package/dist/schemas/project-schema/experimental.json +127 -59
- package/dist/util/mcp.d.ts +7 -0
- package/dist/util/mcp.js +21 -0
- package/dist/util/patch-schema.js +1 -1
- package/dist/validate/validate.js +24 -7
- package/examples/latest/agent-schema.json +4 -2
- package/examples/source/agent-schema.json +4 -2
- package/package.json +5 -5
package/dist/agents.d.ts
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
|
-
import type { AgentAPI, AgentAPIArgument, AgentJSON, Args, ProjectSchemaJSON } from './project-schema/index.ts';
|
|
1
|
+
import type { AgentAPI, AgentAPIArgument, AgentJSON, Args, GuardJSON, ProjectSchemaJSON } from './project-schema/index.ts';
|
|
2
|
+
/**
|
|
3
|
+
* Special transition destination ID for agent transitions that end the agent execution.
|
|
4
|
+
*/
|
|
2
5
|
export declare const END_AGENT_EXECUTION = "endAgentExecution";
|
|
6
|
+
/**
|
|
7
|
+
* Special history strategy ID that indicates the history should be cleared.
|
|
8
|
+
*/
|
|
9
|
+
export declare const CLEAR_HISTORY_STRATEGY_ID = "clearHistory";
|
|
3
10
|
export declare const BUILT_IN_CHAT_ARGS: AgentAPIArgument[];
|
|
4
11
|
export declare const BUILT_IN_CHAT_ARG_NAMES: string[];
|
|
5
12
|
export type AgentEndTransition = {
|
|
@@ -13,3 +20,19 @@ export declare const removeBuiltInArgs: (args: AgentAPIArgument[]) => AgentAPIAr
|
|
|
13
20
|
export declare function getAgentApiArgs(api: AgentAPI): AgentAPIArgument[];
|
|
14
21
|
export declare const createArgs: (agent: AgentJSON) => Args | undefined;
|
|
15
22
|
export declare function addAiQueries(projectSchema: ProjectSchemaJSON): ProjectSchemaJSON;
|
|
23
|
+
/**
|
|
24
|
+
* Where guards live in the schema.
|
|
25
|
+
*/
|
|
26
|
+
export declare const GUARDS_SCHEMA_PATH: readonly ["ai-experimental", "guards"];
|
|
27
|
+
/**
|
|
28
|
+
* Check if a guard is enabled.
|
|
29
|
+
*/
|
|
30
|
+
export declare const isGuardEnabled: (guard: GuardJSON | undefined) => boolean;
|
|
31
|
+
/**
|
|
32
|
+
* Get a guard configuration from the project schema.
|
|
33
|
+
*/
|
|
34
|
+
export declare function getGuardConfig(schema: ProjectSchemaJSON, guardId: string): GuardJSON | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* Get a guard configuration from the project schema, but only if it is enabled.
|
|
37
|
+
*/
|
|
38
|
+
export declare function getEnabledGuardConfig(schema: ProjectSchemaJSON, guardId: string): GuardJSON | undefined;
|
package/dist/agents.js
CHANGED
|
@@ -1,7 +1,15 @@
|
|
|
1
|
+
import get from 'lodash/get.js';
|
|
1
2
|
import uniq from 'lodash/uniq.js';
|
|
2
3
|
import uniqBy from 'lodash/uniqBy.js';
|
|
3
4
|
import upperFirst from 'lodash/upperFirst.js';
|
|
5
|
+
/**
|
|
6
|
+
* Special transition destination ID for agent transitions that end the agent execution.
|
|
7
|
+
*/
|
|
4
8
|
export const END_AGENT_EXECUTION = 'endAgentExecution';
|
|
9
|
+
/**
|
|
10
|
+
* Special history strategy ID that indicates the history should be cleared.
|
|
11
|
+
*/
|
|
12
|
+
export const CLEAR_HISTORY_STRATEGY_ID = 'clearHistory';
|
|
5
13
|
export const BUILT_IN_CHAT_ARGS = [
|
|
6
14
|
{
|
|
7
15
|
argName: 'input',
|
|
@@ -137,3 +145,28 @@ export function addAiQueries(projectSchema) {
|
|
|
137
145
|
}
|
|
138
146
|
return newSchema;
|
|
139
147
|
}
|
|
148
|
+
/**
|
|
149
|
+
* Where guards live in the schema.
|
|
150
|
+
*/
|
|
151
|
+
export const GUARDS_SCHEMA_PATH = ['ai-experimental', 'guards'];
|
|
152
|
+
/**
|
|
153
|
+
* Check if a guard is enabled.
|
|
154
|
+
*/
|
|
155
|
+
export const isGuardEnabled = (guard) => {
|
|
156
|
+
return Boolean(guard && guard.enabled !== false);
|
|
157
|
+
};
|
|
158
|
+
/**
|
|
159
|
+
* Get a guard configuration from the project schema.
|
|
160
|
+
*/
|
|
161
|
+
export function getGuardConfig(schema, guardId) {
|
|
162
|
+
return get(schema, [...GUARDS_SCHEMA_PATH, guardId]);
|
|
163
|
+
}
|
|
164
|
+
/**
|
|
165
|
+
* Get a guard configuration from the project schema, but only if it is enabled.
|
|
166
|
+
*/
|
|
167
|
+
export function getEnabledGuardConfig(schema, guardId) {
|
|
168
|
+
const config = getGuardConfig(schema, guardId);
|
|
169
|
+
if (config && isGuardEnabled(config)) {
|
|
170
|
+
return config;
|
|
171
|
+
}
|
|
172
|
+
}
|
package/dist/builtin-schema.js
CHANGED
|
@@ -382,7 +382,9 @@ export const builtInShapes = {
|
|
|
382
382
|
chatSessionIds: { type: 'object' },
|
|
383
383
|
sessionMemory: { type: 'object' },
|
|
384
384
|
stateOutputs: { type: 'object' },
|
|
385
|
-
currentValue: { type: 'object' }
|
|
385
|
+
currentValue: { type: 'object' },
|
|
386
|
+
userHistory: { type: 'array', items: { type: 'object' } },
|
|
387
|
+
agentHistory: { type: 'array', items: { type: 'object' } }
|
|
386
388
|
}
|
|
387
389
|
}
|
|
388
390
|
},
|
package/dist/index.d.ts
CHANGED
|
@@ -44,6 +44,7 @@ export * from './util/get-conflicting-properties.ts';
|
|
|
44
44
|
export * from './util/get-return-shape.ts';
|
|
45
45
|
export * from './util/has-arg.ts';
|
|
46
46
|
export * from './util/is-asset-property.ts';
|
|
47
|
+
export * from './util/mcp.ts';
|
|
47
48
|
export * from './util/merge.ts';
|
|
48
49
|
export * from './util/patch-schema.ts';
|
|
49
50
|
export * from './util/shapes.ts';
|
package/dist/index.js
CHANGED
|
@@ -42,6 +42,7 @@ export * from "./util/get-conflicting-properties.js";
|
|
|
42
42
|
export * from "./util/get-return-shape.js";
|
|
43
43
|
export * from "./util/has-arg.js";
|
|
44
44
|
export * from "./util/is-asset-property.js";
|
|
45
|
+
export * from "./util/mcp.js";
|
|
45
46
|
export * from "./util/merge.js";
|
|
46
47
|
export * from "./util/patch-schema.js";
|
|
47
48
|
export * from "./util/shapes.js";
|
|
@@ -11,7 +11,7 @@ export type ProjectSchemaUpdate = {
|
|
|
11
11
|
shapes?: Record<string, ShapeJSON | null>;
|
|
12
12
|
'ai-experimental.agents'?: Record<string, AgentJSON | null>;
|
|
13
13
|
'ai-experimental.guards'?: Record<string, GuardJSON | null>;
|
|
14
|
-
'ai-experimental.tools'?: Record<string, ToolJSON | null>;
|
|
14
|
+
'ai-experimental.mcp.tools'?: Record<string, ToolJSON | null>;
|
|
15
15
|
forms?: Record<string, FormConfig | null>;
|
|
16
16
|
workflows?: Record<string, Workflow | null>;
|
|
17
17
|
services?: Record<string, ServiceConfigJSON | null>;
|
|
@@ -360,10 +360,11 @@ export type RemovePropertyKeyPatterns = MinimatchPattern[];
|
|
|
360
360
|
* Remove Markdown formatting from the LLM response
|
|
361
361
|
*/
|
|
362
362
|
export type StripMarkdown = boolean;
|
|
363
|
-
export type AgentChatHistoryConfig = AgentChatHistoryRetain | AgentChatHistorySummarize | AgentChatHistoryClear;
|
|
364
363
|
export type AgentStateSessionMemoryLocation = AgentStateSessionMemoryLocationContent | AgentStateSessionMemoryLocationArtifact | AgentStateSessionMemoryLocationStaticValue;
|
|
365
364
|
export type AgentStateSessionMemory = AgentStateSessionMemoryLocation[];
|
|
366
365
|
export type GuardID = string;
|
|
366
|
+
export type Variables1 = AgentVariable[];
|
|
367
|
+
export type HistoryStrategyExecution = HistoryStrategyExecutionReplace | HistoryStrategyExecutionSummarize;
|
|
367
368
|
/**
|
|
368
369
|
* The human-readable name of the Guard.
|
|
369
370
|
*/
|
|
@@ -372,6 +373,10 @@ export type Name = string;
|
|
|
372
373
|
* A description of the Guard.
|
|
373
374
|
*/
|
|
374
375
|
export type Description = string;
|
|
376
|
+
/**
|
|
377
|
+
* Guards will not run unless enabled.
|
|
378
|
+
*/
|
|
379
|
+
export type Enabled = boolean;
|
|
375
380
|
/**
|
|
376
381
|
* The remote id of the Guardrail.
|
|
377
382
|
*/
|
|
@@ -1744,7 +1749,7 @@ export interface ShapeSchemaAny {
|
|
|
1744
1749
|
export interface AIExperimental {
|
|
1745
1750
|
agents?: AgentMap;
|
|
1746
1751
|
guards?: GuardMap;
|
|
1747
|
-
|
|
1752
|
+
mcp?: MCPServerConfiguration;
|
|
1748
1753
|
}
|
|
1749
1754
|
export interface AgentMap {
|
|
1750
1755
|
[k: string]: AgentJSON;
|
|
@@ -1763,6 +1768,7 @@ export interface AgentJSON {
|
|
|
1763
1768
|
start: AgentStart;
|
|
1764
1769
|
states: AgentStates;
|
|
1765
1770
|
guards?: AgentGuard[];
|
|
1771
|
+
historyStrategies?: HistoryStrategyMap;
|
|
1766
1772
|
}
|
|
1767
1773
|
export interface AgentAPIChat {
|
|
1768
1774
|
type: 'chat';
|
|
@@ -1800,6 +1806,7 @@ export interface AgentTransitionStep {
|
|
|
1800
1806
|
suspend?: boolean;
|
|
1801
1807
|
condition?: string;
|
|
1802
1808
|
limit?: number;
|
|
1809
|
+
historyStrategy?: string;
|
|
1803
1810
|
}
|
|
1804
1811
|
/**
|
|
1805
1812
|
* States that are traversed during the execution of an agent.
|
|
@@ -1901,19 +1908,8 @@ export interface AgentExecutionChat {
|
|
|
1901
1908
|
input: AgentAIStateInput;
|
|
1902
1909
|
artifact?: string;
|
|
1903
1910
|
tools?: AgentToolConfig[];
|
|
1904
|
-
history?: AgentChatHistoryConfig;
|
|
1905
1911
|
options?: AgentGenerateOptions;
|
|
1906
1912
|
}
|
|
1907
|
-
export interface AgentChatHistoryRetain {
|
|
1908
|
-
type: 'retain';
|
|
1909
|
-
}
|
|
1910
|
-
export interface AgentChatHistorySummarize {
|
|
1911
|
-
type: 'summarize';
|
|
1912
|
-
toolCalls: 'retain' | 'clear';
|
|
1913
|
-
}
|
|
1914
|
-
export interface AgentChatHistoryClear {
|
|
1915
|
-
type: 'clear';
|
|
1916
|
-
}
|
|
1917
1913
|
export interface AgentStateSessionMemoryLocationContent {
|
|
1918
1914
|
type: 'content';
|
|
1919
1915
|
memoryPath?: string;
|
|
@@ -1932,6 +1928,34 @@ export interface AgentStateSessionMemoryLocationStaticValue {
|
|
|
1932
1928
|
export interface AgentGuard {
|
|
1933
1929
|
guardId: GuardID;
|
|
1934
1930
|
}
|
|
1931
|
+
export interface HistoryStrategyMap {
|
|
1932
|
+
[k: string]: HistoryStrategy;
|
|
1933
|
+
}
|
|
1934
|
+
/**
|
|
1935
|
+
* This interface was referenced by `HistoryStrategyMap`'s JSON-Schema definition
|
|
1936
|
+
* via the `patternProperty` "^[0-9A-Za-z_]+$".
|
|
1937
|
+
*/
|
|
1938
|
+
export interface HistoryStrategy {
|
|
1939
|
+
name: string;
|
|
1940
|
+
variables?: Variables1;
|
|
1941
|
+
filter?: HistoryStrategyFilter;
|
|
1942
|
+
execution: HistoryStrategyExecution;
|
|
1943
|
+
}
|
|
1944
|
+
export interface HistoryStrategyFilter {
|
|
1945
|
+
toolCalls?: 'retain' | 'clear';
|
|
1946
|
+
}
|
|
1947
|
+
export interface HistoryStrategyExecutionReplace {
|
|
1948
|
+
type: 'replace';
|
|
1949
|
+
template: string;
|
|
1950
|
+
}
|
|
1951
|
+
export interface HistoryStrategyExecutionSummarize {
|
|
1952
|
+
type: 'generate';
|
|
1953
|
+
service: string;
|
|
1954
|
+
model: string;
|
|
1955
|
+
systemPrompt: string;
|
|
1956
|
+
tools?: AgentToolConfig[];
|
|
1957
|
+
options?: AgentGenerateOptions;
|
|
1958
|
+
}
|
|
1935
1959
|
export interface GuardMap {
|
|
1936
1960
|
[k: string]: GuardJSON;
|
|
1937
1961
|
}
|
|
@@ -1944,6 +1968,7 @@ export interface GuardMap {
|
|
|
1944
1968
|
export interface GuardJSON {
|
|
1945
1969
|
name: Name;
|
|
1946
1970
|
description?: Description;
|
|
1971
|
+
enabled?: Enabled;
|
|
1947
1972
|
guardrailIdentifier?: GuardrailIdentifier;
|
|
1948
1973
|
guardrailVersion?: GuardrailVersion;
|
|
1949
1974
|
blockedInputMessaging?: BlockedInputMessaging;
|
|
@@ -1986,6 +2011,9 @@ export interface SensitiveInformationPolicy {
|
|
|
1986
2011
|
export interface ContextualGroundingPolicy {
|
|
1987
2012
|
filtersConfig: Filter1;
|
|
1988
2013
|
}
|
|
2014
|
+
export interface MCPServerConfiguration {
|
|
2015
|
+
tools?: ToolMap;
|
|
2016
|
+
}
|
|
1989
2017
|
export interface ToolMap {
|
|
1990
2018
|
[k: string]: ToolJSON;
|
|
1991
2019
|
}
|
|
@@ -335,10 +335,11 @@ export type RemovePropertyKeyPatternsV3_48_0 = MinimatchPatternV3_48_0[];
|
|
|
335
335
|
* Remove Markdown formatting from the LLM response
|
|
336
336
|
*/
|
|
337
337
|
export type StripMarkdownV3_48_0 = boolean;
|
|
338
|
-
export type AgentChatHistoryConfigV3_48_0 = AgentChatHistoryRetainV3_48_0 | AgentChatHistorySummarizeV3_48_0 | AgentChatHistoryClearV3_48_0;
|
|
339
338
|
export type AgentStateSessionMemoryLocationV3_48_0 = AgentStateSessionMemoryLocationContentV3_48_0 | AgentStateSessionMemoryLocationArtifactV3_48_0 | AgentStateSessionMemoryLocationStaticValueV3_48_0;
|
|
340
339
|
export type AgentStateSessionMemoryV3_48_0 = AgentStateSessionMemoryLocationV3_48_0[];
|
|
341
340
|
export type GuardIDV3_48_0 = string;
|
|
341
|
+
export type VariablesV3_48_01 = AgentVariableV3_48_0[];
|
|
342
|
+
export type HistoryStrategyExecutionV3_48_0 = HistoryStrategyExecutionReplaceV3_48_0 | HistoryStrategyExecutionSummarizeV3_48_0;
|
|
342
343
|
/**
|
|
343
344
|
* The human-readable name of the Guard.
|
|
344
345
|
*/
|
|
@@ -347,6 +348,10 @@ export type NameV3_48_0 = string;
|
|
|
347
348
|
* A description of the Guard.
|
|
348
349
|
*/
|
|
349
350
|
export type DescriptionV3_48_0 = string;
|
|
351
|
+
/**
|
|
352
|
+
* Guards will not run unless enabled.
|
|
353
|
+
*/
|
|
354
|
+
export type EnabledV3_48_0 = boolean;
|
|
350
355
|
/**
|
|
351
356
|
* The remote id of the Guardrail.
|
|
352
357
|
*/
|
|
@@ -1592,7 +1597,7 @@ export interface ShapeSchemaAnyV3_48_0 {
|
|
|
1592
1597
|
export interface AIExperimentalV3_48_0 {
|
|
1593
1598
|
agents?: AgentMapV3_48_0;
|
|
1594
1599
|
guards?: GuardMapV3_48_0;
|
|
1595
|
-
|
|
1600
|
+
mcp?: MCPServerConfigurationV3_48_0;
|
|
1596
1601
|
}
|
|
1597
1602
|
export interface AgentMapV3_48_0 {
|
|
1598
1603
|
[k: string]: AgentJSONV3_48_0;
|
|
@@ -1611,6 +1616,7 @@ export interface AgentJSONV3_48_0 {
|
|
|
1611
1616
|
start: AgentStartV3_48_0;
|
|
1612
1617
|
states: AgentStatesV3_48_0;
|
|
1613
1618
|
guards?: AgentGuardV3_48_0[];
|
|
1619
|
+
historyStrategies?: HistoryStrategyMapV3_48_0;
|
|
1614
1620
|
}
|
|
1615
1621
|
export interface AgentAPIChatV3_48_0 {
|
|
1616
1622
|
type: 'chat';
|
|
@@ -1648,6 +1654,7 @@ export interface AgentTransitionStepV3_48_0 {
|
|
|
1648
1654
|
suspend?: boolean;
|
|
1649
1655
|
condition?: string;
|
|
1650
1656
|
limit?: number;
|
|
1657
|
+
historyStrategy?: string;
|
|
1651
1658
|
}
|
|
1652
1659
|
/**
|
|
1653
1660
|
* States that are traversed during the execution of an agent.
|
|
@@ -1749,19 +1756,8 @@ export interface AgentExecutionChatV3_48_0 {
|
|
|
1749
1756
|
input: AgentAIStateInputV3_48_0;
|
|
1750
1757
|
artifact?: string;
|
|
1751
1758
|
tools?: AgentToolConfigV3_48_0[];
|
|
1752
|
-
history?: AgentChatHistoryConfigV3_48_0;
|
|
1753
1759
|
options?: AgentGenerateOptionsV3_48_0;
|
|
1754
1760
|
}
|
|
1755
|
-
export interface AgentChatHistoryRetainV3_48_0 {
|
|
1756
|
-
type: 'retain';
|
|
1757
|
-
}
|
|
1758
|
-
export interface AgentChatHistorySummarizeV3_48_0 {
|
|
1759
|
-
type: 'summarize';
|
|
1760
|
-
toolCalls: 'retain' | 'clear';
|
|
1761
|
-
}
|
|
1762
|
-
export interface AgentChatHistoryClearV3_48_0 {
|
|
1763
|
-
type: 'clear';
|
|
1764
|
-
}
|
|
1765
1761
|
export interface AgentStateSessionMemoryLocationContentV3_48_0 {
|
|
1766
1762
|
type: 'content';
|
|
1767
1763
|
memoryPath?: string;
|
|
@@ -1780,6 +1776,34 @@ export interface AgentStateSessionMemoryLocationStaticValueV3_48_0 {
|
|
|
1780
1776
|
export interface AgentGuardV3_48_0 {
|
|
1781
1777
|
guardId: GuardIDV3_48_0;
|
|
1782
1778
|
}
|
|
1779
|
+
export interface HistoryStrategyMapV3_48_0 {
|
|
1780
|
+
[k: string]: HistoryStrategyV3_48_0;
|
|
1781
|
+
}
|
|
1782
|
+
/**
|
|
1783
|
+
* This interface was referenced by `HistoryStrategyMapV3_48_0`'s JSON-Schema definition
|
|
1784
|
+
* via the `patternProperty` "^[0-9A-Za-z_]+$".
|
|
1785
|
+
*/
|
|
1786
|
+
export interface HistoryStrategyV3_48_0 {
|
|
1787
|
+
name: string;
|
|
1788
|
+
variables?: VariablesV3_48_01;
|
|
1789
|
+
filter?: HistoryStrategyFilterV3_48_0;
|
|
1790
|
+
execution: HistoryStrategyExecutionV3_48_0;
|
|
1791
|
+
}
|
|
1792
|
+
export interface HistoryStrategyFilterV3_48_0 {
|
|
1793
|
+
toolCalls?: 'retain' | 'clear';
|
|
1794
|
+
}
|
|
1795
|
+
export interface HistoryStrategyExecutionReplaceV3_48_0 {
|
|
1796
|
+
type: 'replace';
|
|
1797
|
+
template: string;
|
|
1798
|
+
}
|
|
1799
|
+
export interface HistoryStrategyExecutionSummarizeV3_48_0 {
|
|
1800
|
+
type: 'generate';
|
|
1801
|
+
service: string;
|
|
1802
|
+
model: string;
|
|
1803
|
+
systemPrompt: string;
|
|
1804
|
+
tools?: AgentToolConfigV3_48_0[];
|
|
1805
|
+
options?: AgentGenerateOptionsV3_48_0;
|
|
1806
|
+
}
|
|
1783
1807
|
export interface GuardMapV3_48_0 {
|
|
1784
1808
|
[k: string]: GuardJSONV3_48_0;
|
|
1785
1809
|
}
|
|
@@ -1792,6 +1816,7 @@ export interface GuardMapV3_48_0 {
|
|
|
1792
1816
|
export interface GuardJSONV3_48_0 {
|
|
1793
1817
|
name: NameV3_48_0;
|
|
1794
1818
|
description?: DescriptionV3_48_0;
|
|
1819
|
+
enabled?: EnabledV3_48_0;
|
|
1795
1820
|
guardrailIdentifier?: GuardrailIdentifierV3_48_0;
|
|
1796
1821
|
guardrailVersion?: GuardrailVersionV3_48_0;
|
|
1797
1822
|
blockedInputMessaging?: BlockedInputMessagingV3_48_0;
|
|
@@ -1834,6 +1859,9 @@ export interface SensitiveInformationPolicyV3_48_0 {
|
|
|
1834
1859
|
export interface ContextualGroundingPolicyV3_48_0 {
|
|
1835
1860
|
filtersConfig: FilterV3_48_01;
|
|
1836
1861
|
}
|
|
1862
|
+
export interface MCPServerConfigurationV3_48_0 {
|
|
1863
|
+
tools?: ToolMapV3_48_0;
|
|
1864
|
+
}
|
|
1837
1865
|
export interface ToolMapV3_48_0 {
|
|
1838
1866
|
[k: string]: ToolJSONV3_48_0;
|
|
1839
1867
|
}
|
|
@@ -335,10 +335,11 @@ export type RemovePropertyKeyPatternsV3_49_0 = MinimatchPatternV3_49_0[];
|
|
|
335
335
|
* Remove Markdown formatting from the LLM response
|
|
336
336
|
*/
|
|
337
337
|
export type StripMarkdownV3_49_0 = boolean;
|
|
338
|
-
export type AgentChatHistoryConfigV3_49_0 = AgentChatHistoryRetainV3_49_0 | AgentChatHistorySummarizeV3_49_0 | AgentChatHistoryClearV3_49_0;
|
|
339
338
|
export type AgentStateSessionMemoryLocationV3_49_0 = AgentStateSessionMemoryLocationContentV3_49_0 | AgentStateSessionMemoryLocationArtifactV3_49_0 | AgentStateSessionMemoryLocationStaticValueV3_49_0;
|
|
340
339
|
export type AgentStateSessionMemoryV3_49_0 = AgentStateSessionMemoryLocationV3_49_0[];
|
|
341
340
|
export type GuardIDV3_49_0 = string;
|
|
341
|
+
export type VariablesV3_49_01 = AgentVariableV3_49_0[];
|
|
342
|
+
export type HistoryStrategyExecutionV3_49_0 = HistoryStrategyExecutionReplaceV3_49_0 | HistoryStrategyExecutionSummarizeV3_49_0;
|
|
342
343
|
/**
|
|
343
344
|
* The human-readable name of the Guard.
|
|
344
345
|
*/
|
|
@@ -347,6 +348,10 @@ export type NameV3_49_0 = string;
|
|
|
347
348
|
* A description of the Guard.
|
|
348
349
|
*/
|
|
349
350
|
export type DescriptionV3_49_0 = string;
|
|
351
|
+
/**
|
|
352
|
+
* Guards will not run unless enabled.
|
|
353
|
+
*/
|
|
354
|
+
export type EnabledV3_49_0 = boolean;
|
|
350
355
|
/**
|
|
351
356
|
* The remote id of the Guardrail.
|
|
352
357
|
*/
|
|
@@ -1592,7 +1597,7 @@ export interface ShapeSchemaAnyV3_49_0 {
|
|
|
1592
1597
|
export interface AIExperimentalV3_49_0 {
|
|
1593
1598
|
agents?: AgentMapV3_49_0;
|
|
1594
1599
|
guards?: GuardMapV3_49_0;
|
|
1595
|
-
|
|
1600
|
+
mcp?: MCPServerConfigurationV3_49_0;
|
|
1596
1601
|
}
|
|
1597
1602
|
export interface AgentMapV3_49_0 {
|
|
1598
1603
|
[k: string]: AgentJSONV3_49_0;
|
|
@@ -1611,6 +1616,7 @@ export interface AgentJSONV3_49_0 {
|
|
|
1611
1616
|
start: AgentStartV3_49_0;
|
|
1612
1617
|
states: AgentStatesV3_49_0;
|
|
1613
1618
|
guards?: AgentGuardV3_49_0[];
|
|
1619
|
+
historyStrategies?: HistoryStrategyMapV3_49_0;
|
|
1614
1620
|
}
|
|
1615
1621
|
export interface AgentAPIChatV3_49_0 {
|
|
1616
1622
|
type: 'chat';
|
|
@@ -1648,6 +1654,7 @@ export interface AgentTransitionStepV3_49_0 {
|
|
|
1648
1654
|
suspend?: boolean;
|
|
1649
1655
|
condition?: string;
|
|
1650
1656
|
limit?: number;
|
|
1657
|
+
historyStrategy?: string;
|
|
1651
1658
|
}
|
|
1652
1659
|
/**
|
|
1653
1660
|
* States that are traversed during the execution of an agent.
|
|
@@ -1749,19 +1756,8 @@ export interface AgentExecutionChatV3_49_0 {
|
|
|
1749
1756
|
input: AgentAIStateInputV3_49_0;
|
|
1750
1757
|
artifact?: string;
|
|
1751
1758
|
tools?: AgentToolConfigV3_49_0[];
|
|
1752
|
-
history?: AgentChatHistoryConfigV3_49_0;
|
|
1753
1759
|
options?: AgentGenerateOptionsV3_49_0;
|
|
1754
1760
|
}
|
|
1755
|
-
export interface AgentChatHistoryRetainV3_49_0 {
|
|
1756
|
-
type: 'retain';
|
|
1757
|
-
}
|
|
1758
|
-
export interface AgentChatHistorySummarizeV3_49_0 {
|
|
1759
|
-
type: 'summarize';
|
|
1760
|
-
toolCalls: 'retain' | 'clear';
|
|
1761
|
-
}
|
|
1762
|
-
export interface AgentChatHistoryClearV3_49_0 {
|
|
1763
|
-
type: 'clear';
|
|
1764
|
-
}
|
|
1765
1761
|
export interface AgentStateSessionMemoryLocationContentV3_49_0 {
|
|
1766
1762
|
type: 'content';
|
|
1767
1763
|
memoryPath?: string;
|
|
@@ -1780,6 +1776,34 @@ export interface AgentStateSessionMemoryLocationStaticValueV3_49_0 {
|
|
|
1780
1776
|
export interface AgentGuardV3_49_0 {
|
|
1781
1777
|
guardId: GuardIDV3_49_0;
|
|
1782
1778
|
}
|
|
1779
|
+
export interface HistoryStrategyMapV3_49_0 {
|
|
1780
|
+
[k: string]: HistoryStrategyV3_49_0;
|
|
1781
|
+
}
|
|
1782
|
+
/**
|
|
1783
|
+
* This interface was referenced by `HistoryStrategyMapV3_49_0`'s JSON-Schema definition
|
|
1784
|
+
* via the `patternProperty` "^[0-9A-Za-z_]+$".
|
|
1785
|
+
*/
|
|
1786
|
+
export interface HistoryStrategyV3_49_0 {
|
|
1787
|
+
name: string;
|
|
1788
|
+
variables?: VariablesV3_49_01;
|
|
1789
|
+
filter?: HistoryStrategyFilterV3_49_0;
|
|
1790
|
+
execution: HistoryStrategyExecutionV3_49_0;
|
|
1791
|
+
}
|
|
1792
|
+
export interface HistoryStrategyFilterV3_49_0 {
|
|
1793
|
+
toolCalls?: 'retain' | 'clear';
|
|
1794
|
+
}
|
|
1795
|
+
export interface HistoryStrategyExecutionReplaceV3_49_0 {
|
|
1796
|
+
type: 'replace';
|
|
1797
|
+
template: string;
|
|
1798
|
+
}
|
|
1799
|
+
export interface HistoryStrategyExecutionSummarizeV3_49_0 {
|
|
1800
|
+
type: 'generate';
|
|
1801
|
+
service: string;
|
|
1802
|
+
model: string;
|
|
1803
|
+
systemPrompt: string;
|
|
1804
|
+
tools?: AgentToolConfigV3_49_0[];
|
|
1805
|
+
options?: AgentGenerateOptionsV3_49_0;
|
|
1806
|
+
}
|
|
1783
1807
|
export interface GuardMapV3_49_0 {
|
|
1784
1808
|
[k: string]: GuardJSONV3_49_0;
|
|
1785
1809
|
}
|
|
@@ -1792,6 +1816,7 @@ export interface GuardMapV3_49_0 {
|
|
|
1792
1816
|
export interface GuardJSONV3_49_0 {
|
|
1793
1817
|
name: NameV3_49_0;
|
|
1794
1818
|
description?: DescriptionV3_49_0;
|
|
1819
|
+
enabled?: EnabledV3_49_0;
|
|
1795
1820
|
guardrailIdentifier?: GuardrailIdentifierV3_49_0;
|
|
1796
1821
|
guardrailVersion?: GuardrailVersionV3_49_0;
|
|
1797
1822
|
blockedInputMessaging?: BlockedInputMessagingV3_49_0;
|
|
@@ -1834,6 +1859,9 @@ export interface SensitiveInformationPolicyV3_49_0 {
|
|
|
1834
1859
|
export interface ContextualGroundingPolicyV3_49_0 {
|
|
1835
1860
|
filtersConfig: FilterV3_49_01;
|
|
1836
1861
|
}
|
|
1862
|
+
export interface MCPServerConfigurationV3_49_0 {
|
|
1863
|
+
tools?: ToolMapV3_49_0;
|
|
1864
|
+
}
|
|
1837
1865
|
export interface ToolMapV3_49_0 {
|
|
1838
1866
|
[k: string]: ToolJSONV3_49_0;
|
|
1839
1867
|
}
|
|
@@ -347,10 +347,11 @@ export type RemovePropertyKeyPatternsV3_50_0 = MinimatchPatternV3_50_0[];
|
|
|
347
347
|
* Remove Markdown formatting from the LLM response
|
|
348
348
|
*/
|
|
349
349
|
export type StripMarkdownV3_50_0 = boolean;
|
|
350
|
-
export type AgentChatHistoryConfigV3_50_0 = AgentChatHistoryRetainV3_50_0 | AgentChatHistorySummarizeV3_50_0 | AgentChatHistoryClearV3_50_0;
|
|
351
350
|
export type AgentStateSessionMemoryLocationV3_50_0 = AgentStateSessionMemoryLocationContentV3_50_0 | AgentStateSessionMemoryLocationArtifactV3_50_0 | AgentStateSessionMemoryLocationStaticValueV3_50_0;
|
|
352
351
|
export type AgentStateSessionMemoryV3_50_0 = AgentStateSessionMemoryLocationV3_50_0[];
|
|
353
352
|
export type GuardIDV3_50_0 = string;
|
|
353
|
+
export type VariablesV3_50_01 = AgentVariableV3_50_0[];
|
|
354
|
+
export type HistoryStrategyExecutionV3_50_0 = HistoryStrategyExecutionReplaceV3_50_0 | HistoryStrategyExecutionSummarizeV3_50_0;
|
|
354
355
|
/**
|
|
355
356
|
* The human-readable name of the Guard.
|
|
356
357
|
*/
|
|
@@ -359,6 +360,10 @@ export type NameV3_50_0 = string;
|
|
|
359
360
|
* A description of the Guard.
|
|
360
361
|
*/
|
|
361
362
|
export type DescriptionV3_50_0 = string;
|
|
363
|
+
/**
|
|
364
|
+
* Guards will not run unless enabled.
|
|
365
|
+
*/
|
|
366
|
+
export type EnabledV3_50_0 = boolean;
|
|
362
367
|
/**
|
|
363
368
|
* The remote id of the Guardrail.
|
|
364
369
|
*/
|
|
@@ -1644,7 +1649,7 @@ export interface ShapeSchemaAnyV3_50_0 {
|
|
|
1644
1649
|
export interface AIExperimentalV3_50_0 {
|
|
1645
1650
|
agents?: AgentMapV3_50_0;
|
|
1646
1651
|
guards?: GuardMapV3_50_0;
|
|
1647
|
-
|
|
1652
|
+
mcp?: MCPServerConfigurationV3_50_0;
|
|
1648
1653
|
}
|
|
1649
1654
|
export interface AgentMapV3_50_0 {
|
|
1650
1655
|
[k: string]: AgentJSONV3_50_0;
|
|
@@ -1663,6 +1668,7 @@ export interface AgentJSONV3_50_0 {
|
|
|
1663
1668
|
start: AgentStartV3_50_0;
|
|
1664
1669
|
states: AgentStatesV3_50_0;
|
|
1665
1670
|
guards?: AgentGuardV3_50_0[];
|
|
1671
|
+
historyStrategies?: HistoryStrategyMapV3_50_0;
|
|
1666
1672
|
}
|
|
1667
1673
|
export interface AgentAPIChatV3_50_0 {
|
|
1668
1674
|
type: 'chat';
|
|
@@ -1700,6 +1706,7 @@ export interface AgentTransitionStepV3_50_0 {
|
|
|
1700
1706
|
suspend?: boolean;
|
|
1701
1707
|
condition?: string;
|
|
1702
1708
|
limit?: number;
|
|
1709
|
+
historyStrategy?: string;
|
|
1703
1710
|
}
|
|
1704
1711
|
/**
|
|
1705
1712
|
* States that are traversed during the execution of an agent.
|
|
@@ -1801,19 +1808,8 @@ export interface AgentExecutionChatV3_50_0 {
|
|
|
1801
1808
|
input: AgentAIStateInputV3_50_0;
|
|
1802
1809
|
artifact?: string;
|
|
1803
1810
|
tools?: AgentToolConfigV3_50_0[];
|
|
1804
|
-
history?: AgentChatHistoryConfigV3_50_0;
|
|
1805
1811
|
options?: AgentGenerateOptionsV3_50_0;
|
|
1806
1812
|
}
|
|
1807
|
-
export interface AgentChatHistoryRetainV3_50_0 {
|
|
1808
|
-
type: 'retain';
|
|
1809
|
-
}
|
|
1810
|
-
export interface AgentChatHistorySummarizeV3_50_0 {
|
|
1811
|
-
type: 'summarize';
|
|
1812
|
-
toolCalls: 'retain' | 'clear';
|
|
1813
|
-
}
|
|
1814
|
-
export interface AgentChatHistoryClearV3_50_0 {
|
|
1815
|
-
type: 'clear';
|
|
1816
|
-
}
|
|
1817
1813
|
export interface AgentStateSessionMemoryLocationContentV3_50_0 {
|
|
1818
1814
|
type: 'content';
|
|
1819
1815
|
memoryPath?: string;
|
|
@@ -1832,6 +1828,34 @@ export interface AgentStateSessionMemoryLocationStaticValueV3_50_0 {
|
|
|
1832
1828
|
export interface AgentGuardV3_50_0 {
|
|
1833
1829
|
guardId: GuardIDV3_50_0;
|
|
1834
1830
|
}
|
|
1831
|
+
export interface HistoryStrategyMapV3_50_0 {
|
|
1832
|
+
[k: string]: HistoryStrategyV3_50_0;
|
|
1833
|
+
}
|
|
1834
|
+
/**
|
|
1835
|
+
* This interface was referenced by `HistoryStrategyMapV3_50_0`'s JSON-Schema definition
|
|
1836
|
+
* via the `patternProperty` "^[0-9A-Za-z_]+$".
|
|
1837
|
+
*/
|
|
1838
|
+
export interface HistoryStrategyV3_50_0 {
|
|
1839
|
+
name: string;
|
|
1840
|
+
variables?: VariablesV3_50_01;
|
|
1841
|
+
filter?: HistoryStrategyFilterV3_50_0;
|
|
1842
|
+
execution: HistoryStrategyExecutionV3_50_0;
|
|
1843
|
+
}
|
|
1844
|
+
export interface HistoryStrategyFilterV3_50_0 {
|
|
1845
|
+
toolCalls?: 'retain' | 'clear';
|
|
1846
|
+
}
|
|
1847
|
+
export interface HistoryStrategyExecutionReplaceV3_50_0 {
|
|
1848
|
+
type: 'replace';
|
|
1849
|
+
template: string;
|
|
1850
|
+
}
|
|
1851
|
+
export interface HistoryStrategyExecutionSummarizeV3_50_0 {
|
|
1852
|
+
type: 'generate';
|
|
1853
|
+
service: string;
|
|
1854
|
+
model: string;
|
|
1855
|
+
systemPrompt: string;
|
|
1856
|
+
tools?: AgentToolConfigV3_50_0[];
|
|
1857
|
+
options?: AgentGenerateOptionsV3_50_0;
|
|
1858
|
+
}
|
|
1835
1859
|
export interface GuardMapV3_50_0 {
|
|
1836
1860
|
[k: string]: GuardJSONV3_50_0;
|
|
1837
1861
|
}
|
|
@@ -1844,6 +1868,7 @@ export interface GuardMapV3_50_0 {
|
|
|
1844
1868
|
export interface GuardJSONV3_50_0 {
|
|
1845
1869
|
name: NameV3_50_0;
|
|
1846
1870
|
description?: DescriptionV3_50_0;
|
|
1871
|
+
enabled?: EnabledV3_50_0;
|
|
1847
1872
|
guardrailIdentifier?: GuardrailIdentifierV3_50_0;
|
|
1848
1873
|
guardrailVersion?: GuardrailVersionV3_50_0;
|
|
1849
1874
|
blockedInputMessaging?: BlockedInputMessagingV3_50_0;
|
|
@@ -1886,6 +1911,9 @@ export interface SensitiveInformationPolicyV3_50_0 {
|
|
|
1886
1911
|
export interface ContextualGroundingPolicyV3_50_0 {
|
|
1887
1912
|
filtersConfig: FilterV3_50_01;
|
|
1888
1913
|
}
|
|
1914
|
+
export interface MCPServerConfigurationV3_50_0 {
|
|
1915
|
+
tools?: ToolMapV3_50_0;
|
|
1916
|
+
}
|
|
1889
1917
|
export interface ToolMapV3_50_0 {
|
|
1890
1918
|
[k: string]: ToolJSONV3_50_0;
|
|
1891
1919
|
}
|