@crewdle/web-sdk-types 1.0.49 → 1.0.51
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/generative-ai/jobs/inference/GenerativeAIInferenceCreateJobParameters.d.ts +4 -0
- package/dist/generative-ai/jobs/inference/GenerativeAIInferenceJob.d.ts +4 -0
- package/dist/generative-ai/jobs/inference/GenerativeAIInferenceWorkerParameters.d.ts +33 -2
- package/dist/generative-ai/jobs/inference/GenerativeAIInferenceWorkerParameters.js +2 -0
- package/dist/generative-ai/jobs/prompt/GenerativeAIPromptCreateJobParameters.d.ts +8 -0
- package/dist/generative-ai/jobs/prompt/GenerativeAIPromptJob.d.ts +8 -0
- package/dist/generative-ai/jobs/prompt/GenerativeAIPromptOptions.d.ts +6 -2
- package/dist/generative-ai/jobs/prompt/GenerativeAIPromptWorkerParameters.d.ts +4 -0
- package/dist/generative-ai/jobs/prompt/options/PromptFunction.d.ts +44 -0
- package/package.json +1 -1
|
@@ -43,6 +43,10 @@ export interface IGenerativeAIInferenceCreateJobParameters extends IGenerativeAI
|
|
|
43
43
|
* Enable reasoning for the AI job.
|
|
44
44
|
*/
|
|
45
45
|
reasoning?: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* The privacy flag for the AI job.
|
|
48
|
+
*/
|
|
49
|
+
privacy?: boolean;
|
|
46
50
|
/**
|
|
47
51
|
* The context for the AI job.
|
|
48
52
|
*/
|
|
@@ -38,6 +38,10 @@ export interface IGenerativeAIInferenceJob extends IGenerativeAIJob {
|
|
|
38
38
|
* Enable reasoning for the AI job.
|
|
39
39
|
*/
|
|
40
40
|
reasoning?: boolean;
|
|
41
|
+
/**
|
|
42
|
+
* The privacy flag for the AI job.
|
|
43
|
+
*/
|
|
44
|
+
privacy?: boolean;
|
|
41
45
|
/**
|
|
42
46
|
* The context for the AI job.
|
|
43
47
|
*/
|
|
@@ -42,6 +42,10 @@ export interface IGenerativeAIInferenceWorkerParameters extends IGenerativeAIWor
|
|
|
42
42
|
* Enable reasoning for the AI job.
|
|
43
43
|
*/
|
|
44
44
|
reasoning?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* The privacy flag for the AI job.
|
|
47
|
+
*/
|
|
48
|
+
privacy?: boolean;
|
|
45
49
|
/**
|
|
46
50
|
* The context for the AI job.
|
|
47
51
|
*/
|
|
@@ -104,7 +108,9 @@ export interface IGenerativeAIInferenceTool {
|
|
|
104
108
|
headers?: {
|
|
105
109
|
name: string;
|
|
106
110
|
value: string;
|
|
107
|
-
}[]
|
|
111
|
+
}[] | {
|
|
112
|
+
[key: string]: string;
|
|
113
|
+
};
|
|
108
114
|
/**
|
|
109
115
|
* The query parameters for the tool.
|
|
110
116
|
*/
|
|
@@ -135,6 +141,10 @@ export interface IGenerativeAIInferenceTool {
|
|
|
135
141
|
* The workflow ID to use for the tool.
|
|
136
142
|
*/
|
|
137
143
|
workflowId?: string;
|
|
144
|
+
/**
|
|
145
|
+
* The user ID to use for the tool.
|
|
146
|
+
*/
|
|
147
|
+
userId?: string;
|
|
138
148
|
/**
|
|
139
149
|
* Whether the tool is async.
|
|
140
150
|
*/
|
|
@@ -171,6 +181,25 @@ export interface IGenerativeAIInferenceTool {
|
|
|
171
181
|
* Whether to emit the tool call result.
|
|
172
182
|
*/
|
|
173
183
|
shouldEmit?: boolean;
|
|
184
|
+
/**
|
|
185
|
+
* The server label for the tool.
|
|
186
|
+
*/
|
|
187
|
+
server_label?: string;
|
|
188
|
+
/**
|
|
189
|
+
* The server URL for the tool.
|
|
190
|
+
*/
|
|
191
|
+
server_url?: string;
|
|
192
|
+
/**
|
|
193
|
+
* The require approval for the tool.
|
|
194
|
+
*/
|
|
195
|
+
require_approval?: string;
|
|
196
|
+
/**
|
|
197
|
+
* The allowed tools for the tool.
|
|
198
|
+
*/
|
|
199
|
+
allowed_tools?: string[];
|
|
200
|
+
/**
|
|
201
|
+
* The headers for the tool.
|
|
202
|
+
*/
|
|
174
203
|
/**
|
|
175
204
|
* The tools for the tool.
|
|
176
205
|
*/
|
|
@@ -196,7 +225,9 @@ export declare enum GenerativeAIInferenceToolType {
|
|
|
196
225
|
FormSkillGetQuestion = "form-skill-get-question",
|
|
197
226
|
FormSkillSetAnswer = "form-skill-set-answer",
|
|
198
227
|
FormSkillSubmitForm = "form-skill-submit-form",
|
|
199
|
-
WorkflowTool = "workflow-tool"
|
|
228
|
+
WorkflowTool = "workflow-tool",
|
|
229
|
+
GenerateImage = "generate-image",
|
|
230
|
+
CrewdleMCP = "crewdle-mcp"
|
|
200
231
|
}
|
|
201
232
|
/**
|
|
202
233
|
* The interface for the generative AI inference form skill question.
|
|
@@ -20,4 +20,6 @@ export var GenerativeAIInferenceToolType;
|
|
|
20
20
|
GenerativeAIInferenceToolType["FormSkillSetAnswer"] = "form-skill-set-answer";
|
|
21
21
|
GenerativeAIInferenceToolType["FormSkillSubmitForm"] = "form-skill-submit-form";
|
|
22
22
|
GenerativeAIInferenceToolType["WorkflowTool"] = "workflow-tool";
|
|
23
|
+
GenerativeAIInferenceToolType["GenerateImage"] = "generate-image";
|
|
24
|
+
GenerativeAIInferenceToolType["CrewdleMCP"] = "crewdle-mcp";
|
|
23
25
|
})(GenerativeAIInferenceToolType || (GenerativeAIInferenceToolType = {}));
|
|
@@ -15,6 +15,10 @@ export interface IGenerativeAIPromptCreateJobParameters extends IGenerativeAICre
|
|
|
15
15
|
* The workflow id to use for the prompt.
|
|
16
16
|
*/
|
|
17
17
|
workflowId: string;
|
|
18
|
+
/**
|
|
19
|
+
* The user id to use for the prompt.
|
|
20
|
+
*/
|
|
21
|
+
userId?: string;
|
|
18
22
|
/**
|
|
19
23
|
* The namespace to use for the prompt.
|
|
20
24
|
*/
|
|
@@ -35,6 +39,10 @@ export interface IGenerativeAIPromptCreateJobParameters extends IGenerativeAICre
|
|
|
35
39
|
* The agent id
|
|
36
40
|
*/
|
|
37
41
|
agentId?: string;
|
|
42
|
+
/**
|
|
43
|
+
* The privacy flag for the AI job.
|
|
44
|
+
*/
|
|
45
|
+
privacy?: boolean;
|
|
38
46
|
/**
|
|
39
47
|
* The context for the AI job.
|
|
40
48
|
*/
|
|
@@ -9,6 +9,10 @@ export interface IGenerativeAIPromptJob extends IGenerativeAIJob {
|
|
|
9
9
|
* The workflow id to use for the prompt.
|
|
10
10
|
*/
|
|
11
11
|
workflowId: string;
|
|
12
|
+
/**
|
|
13
|
+
* The user id to use for the prompt.
|
|
14
|
+
*/
|
|
15
|
+
userId?: string;
|
|
12
16
|
/**
|
|
13
17
|
* The namespace to use for the prompt.
|
|
14
18
|
*/
|
|
@@ -29,6 +33,10 @@ export interface IGenerativeAIPromptJob extends IGenerativeAIJob {
|
|
|
29
33
|
* The agent id
|
|
30
34
|
*/
|
|
31
35
|
agentId?: string;
|
|
36
|
+
/**
|
|
37
|
+
* The privacy flag for the AI job.
|
|
38
|
+
*/
|
|
39
|
+
privacy?: boolean;
|
|
32
40
|
/**
|
|
33
41
|
* The context for the AI job.
|
|
34
42
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IGenerativeAIOptions } from '../generic/GenerativeAIOptions';
|
|
2
|
-
import {
|
|
2
|
+
import { IPromptHistory, PromptFunction } from './options';
|
|
3
3
|
export interface IGenerativeAIPromptFile {
|
|
4
4
|
/**
|
|
5
5
|
* The name of the file.
|
|
@@ -36,6 +36,10 @@ export interface IGenerativeAIPromptOptions extends IGenerativeAIOptions {
|
|
|
36
36
|
* Enable reasoning for the AI job.
|
|
37
37
|
*/
|
|
38
38
|
reasoning?: boolean;
|
|
39
|
+
/**
|
|
40
|
+
* The privacy flag for the AI job.
|
|
41
|
+
*/
|
|
42
|
+
privacy?: boolean;
|
|
39
43
|
/**
|
|
40
44
|
* The context for the AI job.
|
|
41
45
|
*/
|
|
@@ -57,7 +61,7 @@ export interface IGenerativeAIPromptOptions extends IGenerativeAIOptions {
|
|
|
57
61
|
/**
|
|
58
62
|
* The functions that can be called by the LLM.
|
|
59
63
|
*/
|
|
60
|
-
functions?: Map<string,
|
|
64
|
+
functions?: Map<string, PromptFunction>;
|
|
61
65
|
/**
|
|
62
66
|
* The files that will be used by the LLM.
|
|
63
67
|
*/
|
|
@@ -13,6 +13,10 @@ export interface IGenerativeAIPromptWorkerParameters extends IGenerativeAIWorker
|
|
|
13
13
|
* The workflow ID.
|
|
14
14
|
*/
|
|
15
15
|
workflowId: string;
|
|
16
|
+
/**
|
|
17
|
+
* The user id to use for the prompt.
|
|
18
|
+
*/
|
|
19
|
+
userId?: string;
|
|
16
20
|
/**
|
|
17
21
|
* The namespace to use for the prompt.
|
|
18
22
|
*/
|
|
@@ -5,6 +5,10 @@ import { IPromptFunctionParams } from './PromptFunctionParams';
|
|
|
5
5
|
* @category AI
|
|
6
6
|
*/
|
|
7
7
|
export interface IPromptFunction {
|
|
8
|
+
/**
|
|
9
|
+
* The function type.
|
|
10
|
+
*/
|
|
11
|
+
type: 'function';
|
|
8
12
|
/**
|
|
9
13
|
* The function description.
|
|
10
14
|
*/
|
|
@@ -20,3 +24,43 @@ export interface IPromptFunction {
|
|
|
20
24
|
[key: string]: string | number | boolean;
|
|
21
25
|
}) => string | Promise<string>;
|
|
22
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* The MCP function Interface
|
|
29
|
+
* Represents a function that can be called by the LLM.
|
|
30
|
+
* @category AI
|
|
31
|
+
*/
|
|
32
|
+
export interface IMcpFunction {
|
|
33
|
+
type: 'mcp';
|
|
34
|
+
server_label: string;
|
|
35
|
+
server_url: string;
|
|
36
|
+
require_approval: string;
|
|
37
|
+
allowed_tools: string[];
|
|
38
|
+
headers?: {
|
|
39
|
+
[key: string]: string;
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* The code interpreter function Interface
|
|
44
|
+
* Represents a function that can be called by the LLM.
|
|
45
|
+
* @category AI
|
|
46
|
+
*/
|
|
47
|
+
export interface ICodeInterpreterFunction {
|
|
48
|
+
type: 'code_interpreter';
|
|
49
|
+
container: {
|
|
50
|
+
type: 'auto';
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* The image generation function Interface
|
|
55
|
+
* Represents a function that can be called by the LLM.
|
|
56
|
+
* @category AI
|
|
57
|
+
*/
|
|
58
|
+
export interface IImageGenerationFunction {
|
|
59
|
+
type: 'image_generation';
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* The prompt function Type
|
|
63
|
+
* Represents a function that can be called by the LLM.
|
|
64
|
+
* @category AI
|
|
65
|
+
*/
|
|
66
|
+
export type PromptFunction = IPromptFunction | IMcpFunction | ICodeInterpreterFunction | IImageGenerationFunction;
|