@agent-factory-platform/agent-react 0.6.0 → 0.7.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/README.md +6 -0
- package/dist/agent-react.css +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +843 -640
- package/dist/workflow.d.ts +56 -0
- package/package.json +3 -3
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { createAgentFactoryClients, workflowV1 } from "@agent-factory-platform/client";
|
|
2
|
+
type WorkflowClient = ReturnType<typeof createAgentFactoryClients>["workflow"];
|
|
3
|
+
export type WorkflowWorkbenchTransport = Pick<WorkflowClient, "getCatalog" | "listDefinitions" | "listInstances" | "listRevisions" | "listRuns" | "listSteps" | "listActionFacts" | "inspectInstance" | "explainInstance" | "controlInstance">;
|
|
4
|
+
export type WorkflowWorkbenchState = {
|
|
5
|
+
scope: string;
|
|
6
|
+
definitions: readonly workflowV1.Definition[];
|
|
7
|
+
instances: readonly workflowV1.Instance[];
|
|
8
|
+
revisions: readonly workflowV1.Revision[];
|
|
9
|
+
runs: readonly workflowV1.Run[];
|
|
10
|
+
steps: readonly workflowV1.Step[];
|
|
11
|
+
actionFacts: readonly workflowV1.ActionFact[];
|
|
12
|
+
capabilities: readonly workflowV1.Capability[];
|
|
13
|
+
nodeSchemas: readonly workflowV1.NodeConfigSchema[];
|
|
14
|
+
selectedDefinitionId?: string;
|
|
15
|
+
selectedInstanceId?: string;
|
|
16
|
+
inspection?: unknown;
|
|
17
|
+
explanation?: unknown;
|
|
18
|
+
loading: boolean;
|
|
19
|
+
error?: Error;
|
|
20
|
+
};
|
|
21
|
+
export declare class WorkflowWorkbenchController {
|
|
22
|
+
private readonly transport;
|
|
23
|
+
private state;
|
|
24
|
+
private readonly listeners;
|
|
25
|
+
private generation;
|
|
26
|
+
constructor(transport: WorkflowWorkbenchTransport, scope?: string);
|
|
27
|
+
getSnapshot: () => WorkflowWorkbenchState;
|
|
28
|
+
subscribe: (listener: () => void) => () => boolean;
|
|
29
|
+
setScope(scope: string): void;
|
|
30
|
+
refresh(): Promise<{
|
|
31
|
+
capabilities: workflowV1.Capability[];
|
|
32
|
+
nodeSchemas: workflowV1.NodeConfigSchema[];
|
|
33
|
+
definitions: workflowV1.Definition[];
|
|
34
|
+
instances: workflowV1.Instance[];
|
|
35
|
+
}>;
|
|
36
|
+
openDefinition(definitionId: string): Promise<{
|
|
37
|
+
selectedDefinitionId: string;
|
|
38
|
+
revisions: workflowV1.Revision[];
|
|
39
|
+
}>;
|
|
40
|
+
openInstance(instanceId: string): Promise<{
|
|
41
|
+
selectedInstanceId: string;
|
|
42
|
+
runs: workflowV1.Run[];
|
|
43
|
+
steps: workflowV1.Step[];
|
|
44
|
+
actionFacts: workflowV1.ActionFact[];
|
|
45
|
+
inspection: unknown;
|
|
46
|
+
explanation: unknown;
|
|
47
|
+
}>;
|
|
48
|
+
control(action: workflowV1.InstanceControlAction, reason?: string, actionId?: string): Promise<void>;
|
|
49
|
+
private run;
|
|
50
|
+
private update;
|
|
51
|
+
}
|
|
52
|
+
export declare const useWorkflowWorkbench: (controller: WorkflowWorkbenchController) => WorkflowWorkbenchState;
|
|
53
|
+
export declare function WorkflowWorkbench({ controller }: {
|
|
54
|
+
controller: WorkflowWorkbenchController;
|
|
55
|
+
}): import("react").JSX.Element;
|
|
56
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agent-factory-platform/agent-react",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Agent runtime bindings and themeable React conversation surfaces.",
|
|
5
5
|
"license": "MIT OR Apache-2.0",
|
|
6
6
|
"repository": {
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
"react": "^19.0.0"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@agent-factory-platform/client": "0.
|
|
33
|
-
"@agent-factory-platform/ui-kit": "0.
|
|
32
|
+
"@agent-factory-platform/client": "0.7.0",
|
|
33
|
+
"@agent-factory-platform/ui-kit": "0.7.0",
|
|
34
34
|
"@bufbuild/protobuf": "^2.2.3",
|
|
35
35
|
"lucide-react": "^1.23.0"
|
|
36
36
|
},
|