@rpascene/core 0.30.11 → 0.30.13
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/es/agent/agent.mjs.map +1 -1
- package/dist/es/agent/tasks.mjs +10 -0
- package/dist/es/agent/tasks.mjs.map +1 -1
- package/dist/es/agent/utils.mjs +1 -1
- package/dist/es/ai-model/conversation-history.mjs.map +1 -1
- package/dist/es/ai-model/service-caller/index.mjs +15 -4
- package/dist/es/ai-model/service-caller/index.mjs.map +1 -1
- package/dist/es/device/index.mjs.map +1 -1
- package/dist/es/types.mjs.map +1 -1
- package/dist/es/utils.mjs +2 -2
- package/dist/lib/agent/agent.js.map +1 -1
- package/dist/lib/agent/tasks.js +10 -0
- package/dist/lib/agent/tasks.js.map +1 -1
- package/dist/lib/agent/utils.js +1 -1
- package/dist/lib/ai-model/conversation-history.js.map +1 -1
- package/dist/lib/ai-model/service-caller/index.js +15 -4
- package/dist/lib/ai-model/service-caller/index.js.map +1 -1
- package/dist/lib/device/index.js.map +1 -1
- package/dist/lib/types.js.map +1 -1
- package/dist/lib/utils.js +2 -2
- package/dist/types/device/index.d.ts +8 -4
- package/dist/types/types.d.ts +3 -3
- package/package.json +3 -3
|
@@ -19,14 +19,18 @@ export declare abstract class AbstractInterface {
|
|
|
19
19
|
abstract url?: () => string | Promise<string>;
|
|
20
20
|
abstract evaluateJavaScript?<T = any>(script: string): Promise<T>;
|
|
21
21
|
abstract getContext?(): Promise<UIContext>;
|
|
22
|
+
abstract getElementFromPoint?(args: {
|
|
23
|
+
x: number;
|
|
24
|
+
y: number;
|
|
25
|
+
}): any;
|
|
22
26
|
}
|
|
23
|
-
export declare const defineAction: <TSchema extends z.ZodType, TRuntime = z.infer<TSchema
|
|
27
|
+
export declare const defineAction: <TSchema extends z.ZodType | undefined = undefined, TRuntime = TSchema extends z.ZodType ? z.infer<TSchema> : undefined, TReturn = any>(config: {
|
|
24
28
|
name: string;
|
|
25
29
|
description: string;
|
|
26
30
|
interfaceAlias?: string;
|
|
27
|
-
paramSchema
|
|
28
|
-
call: (param: TRuntime) => Promise<
|
|
29
|
-
} & Partial<Omit<DeviceAction<TRuntime>, "name" | "description" | "interfaceAlias" | "paramSchema" | "call">>) => DeviceAction<TRuntime>;
|
|
31
|
+
paramSchema?: TSchema;
|
|
32
|
+
call: (param: TRuntime) => Promise<TReturn> | TReturn;
|
|
33
|
+
} & Partial<Omit<DeviceAction<TRuntime, TReturn>, "name" | "description" | "interfaceAlias" | "paramSchema" | "call">>) => DeviceAction<TRuntime, TReturn>;
|
|
30
34
|
export declare const actionTapParamSchema: z.ZodObject<{
|
|
31
35
|
locate: z.ZodObject<{
|
|
32
36
|
prompt: z.ZodUnion<[z.ZodString, z.ZodIntersection<z.ZodObject<{
|
package/dist/types/types.d.ts
CHANGED
|
@@ -361,12 +361,12 @@ export interface StreamingAIResponse {
|
|
|
361
361
|
/** Whether the response was streamed */
|
|
362
362
|
isStreamed: boolean;
|
|
363
363
|
}
|
|
364
|
-
export interface DeviceAction<
|
|
364
|
+
export interface DeviceAction<TParam = any, TReturn = any> {
|
|
365
365
|
name: string;
|
|
366
366
|
description?: string;
|
|
367
367
|
interfaceAlias?: string;
|
|
368
|
-
paramSchema?: z.ZodType<
|
|
369
|
-
call: (param:
|
|
368
|
+
paramSchema?: z.ZodType<TParam>;
|
|
369
|
+
call: (param: TParam, context: ExecutorContext) => Promise<TReturn> | TReturn;
|
|
370
370
|
}
|
|
371
371
|
/**
|
|
372
372
|
* Web-specific types
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rpascene/core",
|
|
3
3
|
"description": "RPA Automate browser actions, extract data, and perform assertions using AI. It offers JavaScript SDK, Chrome extension, and support for scripting in YAML.",
|
|
4
|
-
"version": "0.30.
|
|
4
|
+
"version": "0.30.13",
|
|
5
5
|
"repository": "",
|
|
6
6
|
"homepage": "",
|
|
7
7
|
"main": "./dist/lib/index.js",
|
|
@@ -92,8 +92,8 @@
|
|
|
92
92
|
"zod": "3.24.3",
|
|
93
93
|
"semver": "7.5.2",
|
|
94
94
|
"js-yaml": "4.1.0",
|
|
95
|
-
"@rpascene/
|
|
96
|
-
"@rpascene/
|
|
95
|
+
"@rpascene/recorder": "0.30.13",
|
|
96
|
+
"@rpascene/shared": "0.30.13"
|
|
97
97
|
},
|
|
98
98
|
"devDependencies": {
|
|
99
99
|
"@rslib/core": "^0.11.2",
|