@lssm/example.agent-console 0.0.0-canary-20251217063201 → 0.0.0-canary-20251217073102
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/.turbo/turbo-build$colon$bundle.log +201 -166
- package/CHANGELOG.md +6 -6
- package/dist/agent/agent.contracts.d.ts +126 -126
- package/dist/agent/agent.contracts.js +336 -1
- package/dist/agent/agent.entity.d.ts +36 -36
- package/dist/agent/agent.entity.js +136 -1
- package/dist/agent/agent.enum.d.ts +4 -4
- package/dist/agent/agent.enum.js +34 -1
- package/dist/agent/agent.event.d.ts +31 -31
- package/dist/agent/agent.event.js +183 -1
- package/dist/agent/agent.handler.d.ts +1 -1
- package/dist/agent/agent.handler.js +83 -1
- package/dist/agent/agent.presentation.js +75 -1
- package/dist/agent/agent.schema.d.ts +95 -95
- package/dist/agent/agent.schema.js +407 -1
- package/dist/agent/index.js +9 -1
- package/dist/agent.feature.js +295 -1
- package/dist/docs/agent-console.docblock.js +69 -5
- package/dist/docs/index.js +1 -1
- package/dist/example.js +50 -1
- package/dist/handlers/index.js +5 -1
- package/dist/index.js +32 -1
- package/dist/libs/contracts/dist/capabilities/openbanking.js +88 -1
- package/dist/libs/contracts/dist/client/index.js +5 -1
- package/dist/libs/contracts/dist/client/react/feature-render.js +2 -1
- package/dist/libs/contracts/dist/client/react/form-render.js +4 -1
- package/dist/libs/contracts/dist/client/react/index.js +4 -1
- package/dist/libs/contracts/dist/contract-registry/index.js +1 -1
- package/dist/libs/contracts/dist/contract-registry/schemas.js +60 -1
- package/dist/libs/contracts/dist/docs/PUBLISHING.docblock.js +16 -76
- package/dist/libs/contracts/dist/docs/accessibility_wcag_compliance_specs.docblock.js +16 -350
- package/dist/libs/contracts/dist/docs/index.js +29 -1
- package/dist/libs/contracts/dist/docs/presentations.js +71 -1
- package/dist/libs/contracts/dist/docs/registry.js +44 -1
- package/dist/libs/contracts/dist/docs/tech/PHASE_1_QUICKSTART.docblock.js +16 -383
- package/dist/libs/contracts/dist/docs/tech/PHASE_2_AI_NATIVE_OPERATIONS.docblock.js +16 -68
- package/dist/libs/contracts/dist/docs/tech/PHASE_3_AUTO_EVOLUTION.docblock.js +16 -140
- package/dist/libs/contracts/dist/docs/tech/PHASE_4_PERSONALIZATION_ENGINE.docblock.js +16 -86
- package/dist/libs/contracts/dist/docs/tech/PHASE_5_ZERO_TOUCH_OPERATIONS.docblock.js +16 -1
- package/dist/libs/contracts/dist/docs/tech/auth/better-auth-nextjs.docblock.js +24 -2
- package/dist/libs/contracts/dist/docs/tech/contracts/openapi-export.docblock.js +21 -2
- package/dist/libs/contracts/dist/docs/tech/lifecycle-stage-system.docblock.js +16 -213
- package/dist/libs/contracts/dist/docs/tech/llm/llm-integration.docblock.js +73 -5
- package/dist/libs/contracts/dist/docs/tech/mcp-endpoints.docblock.js +37 -1
- package/dist/libs/contracts/dist/docs/tech/presentation-runtime.docblock.js +16 -1
- package/dist/libs/contracts/dist/docs/tech/schema/README.docblock.js +20 -262
- package/dist/libs/contracts/dist/docs/tech/studio/learning-events.docblock.js +48 -1
- package/dist/libs/contracts/dist/docs/tech/studio/learning-journeys.docblock.js +24 -2
- package/dist/libs/contracts/dist/docs/tech/studio/platform-admin-panel.docblock.js +23 -2
- package/dist/libs/contracts/dist/docs/tech/studio/project-access-teams.docblock.js +25 -16
- package/dist/libs/contracts/dist/docs/tech/studio/project-routing.docblock.js +67 -1
- package/dist/libs/contracts/dist/docs/tech/studio/sandbox-unlogged.docblock.js +22 -2
- package/dist/libs/contracts/dist/docs/tech/studio/team-invitations.docblock.js +40 -36
- package/dist/libs/contracts/dist/docs/tech/studio/workspace-ops.docblock.js +47 -1
- package/dist/libs/contracts/dist/docs/tech/studio/workspaces.docblock.js +23 -2
- package/dist/libs/contracts/dist/docs/tech/telemetry-ingest.docblock.js +36 -3
- package/dist/libs/contracts/dist/docs/tech/templates/runtime.docblock.js +20 -1
- package/dist/libs/contracts/dist/docs/tech/vscode-extension.docblock.js +36 -3
- package/dist/libs/contracts/dist/docs/tech/workflows/overview.docblock.js +20 -1
- package/dist/libs/contracts/dist/events.js +10 -1
- package/dist/libs/contracts/dist/experiments/evaluator.js +1 -1
- package/dist/libs/contracts/dist/index.js +71 -1
- package/dist/libs/contracts/dist/install.js +2 -1
- package/dist/libs/contracts/dist/integrations/contracts.js +377 -1
- package/dist/libs/contracts/dist/integrations/index.js +18 -1
- package/dist/libs/contracts/dist/integrations/openbanking/contracts/accounts.js +228 -1
- package/dist/libs/contracts/dist/integrations/openbanking/contracts/balances.js +159 -1
- package/dist/libs/contracts/dist/integrations/openbanking/contracts/index.js +3 -1
- package/dist/libs/contracts/dist/integrations/openbanking/contracts/transactions.js +210 -1
- package/dist/libs/contracts/dist/integrations/openbanking/models.js +242 -1
- package/dist/libs/contracts/dist/integrations/openbanking/telemetry.js +13 -1
- package/dist/libs/contracts/dist/integrations/providers/elevenlabs.js +52 -1
- package/dist/libs/contracts/dist/integrations/providers/gcs-storage.js +75 -1
- package/dist/libs/contracts/dist/integrations/providers/gmail.js +87 -1
- package/dist/libs/contracts/dist/integrations/providers/google-calendar.js +66 -1
- package/dist/libs/contracts/dist/integrations/providers/index.js +11 -1
- package/dist/libs/contracts/dist/integrations/providers/mistral.js +68 -1
- package/dist/libs/contracts/dist/integrations/providers/postmark.js +68 -1
- package/dist/libs/contracts/dist/integrations/providers/powens.js +116 -1
- package/dist/libs/contracts/dist/integrations/providers/qdrant.js +73 -1
- package/dist/libs/contracts/dist/integrations/providers/registry.js +10 -1
- package/dist/libs/contracts/dist/integrations/providers/stripe.js +83 -1
- package/dist/libs/contracts/dist/integrations/providers/twilio-sms.js +61 -1
- package/dist/libs/contracts/dist/jsonschema.js +1 -1
- package/dist/libs/contracts/dist/knowledge/contracts.js +306 -1
- package/dist/libs/contracts/dist/knowledge/index.js +7 -1
- package/dist/libs/contracts/dist/knowledge/spaces/email-threads.js +34 -1
- package/dist/libs/contracts/dist/knowledge/spaces/financial-docs.js +34 -1
- package/dist/libs/contracts/dist/knowledge/spaces/financial-overview.js +38 -1
- package/dist/libs/contracts/dist/knowledge/spaces/index.js +6 -1
- package/dist/libs/contracts/dist/knowledge/spaces/product-canon.js +34 -1
- package/dist/libs/contracts/dist/knowledge/spaces/support-faq.js +37 -1
- package/dist/libs/contracts/dist/knowledge/spaces/uploaded-docs.js +34 -1
- package/dist/libs/contracts/dist/llm/exporters.js +19 -1
- package/dist/libs/contracts/dist/llm/index.js +2 -1
- package/dist/libs/contracts/dist/llm/prompts.js +1 -1
- package/dist/libs/contracts/dist/onboarding-base.js +196 -1
- package/dist/libs/contracts/dist/openapi.js +1 -1
- package/dist/libs/contracts/dist/ownership.js +21 -1
- package/dist/libs/contracts/dist/presentations.js +1 -1
- package/dist/libs/contracts/dist/presentations.v2.js +11 -1
- package/dist/libs/contracts/dist/prompt.js +1 -1
- package/dist/libs/contracts/dist/promptRegistry.js +1 -1
- package/dist/libs/contracts/dist/regenerator/index.js +1 -1
- package/dist/libs/contracts/dist/regenerator/service.js +6 -1
- package/dist/libs/contracts/dist/registry.js +2 -1
- package/dist/libs/contracts/dist/resources.js +1 -1
- package/dist/libs/contracts/dist/schema/dist/EnumType.js +2 -1
- package/dist/libs/contracts/dist/schema/dist/FieldType.js +49 -1
- package/dist/libs/contracts/dist/schema/dist/ScalarTypeEnum.js +236 -1
- package/dist/libs/contracts/dist/schema/dist/SchemaModel.js +39 -1
- package/dist/libs/contracts/dist/schema/dist/entity/defineEntity.js +1 -1
- package/dist/libs/contracts/dist/schema/dist/entity/index.js +2 -1
- package/dist/libs/contracts/dist/schema/dist/entity/types.js +1 -1
- package/dist/libs/contracts/dist/schema/dist/index.js +6 -1
- package/dist/libs/contracts/dist/server/graphql-pothos.js +6 -1
- package/dist/libs/contracts/dist/server/index.js +8 -1
- package/dist/libs/contracts/dist/server/mcp/createMcpServer.js +4 -1
- package/dist/libs/contracts/dist/server/mcp/registerPresentations.js +2 -1
- package/dist/libs/contracts/dist/server/mcp/registerPrompts.js +1 -1
- package/dist/libs/contracts/dist/server/mcp/registerResources.js +2 -1
- package/dist/libs/contracts/dist/server/mcp/registerTools.js +1 -1
- package/dist/libs/contracts/dist/server/provider-mcp.js +1 -1
- package/dist/libs/contracts/dist/server/rest-elysia.js +1 -1
- package/dist/libs/contracts/dist/server/rest-express.js +1 -1
- package/dist/libs/contracts/dist/server/rest-generic.js +1 -1
- package/dist/libs/contracts/dist/server/rest-next-app.js +1 -1
- package/dist/libs/contracts/dist/server/rest-next-pages.js +1 -1
- package/dist/libs/contracts/dist/spec.js +34 -1
- package/dist/libs/contracts/dist/telemetry/index.js +1 -1
- package/dist/libs/contracts/dist/telemetry/tracker.js +1 -1
- package/dist/libs/contracts/dist/tests/index.js +1 -1
- package/dist/libs/contracts/dist/tests/runner.js +2 -1
- package/dist/libs/contracts/dist/workflow/index.js +1 -1
- package/dist/libs/contracts/dist/workflow/runner.js +1 -1
- package/dist/libs/schema/dist/EnumType.js +56 -1
- package/dist/libs/schema/dist/FieldType.js +49 -1
- package/dist/libs/schema/dist/ScalarTypeEnum.js +236 -1
- package/dist/libs/schema/dist/SchemaModel.js +39 -1
- package/dist/libs/schema/dist/entity/defineEntity.js +236 -1
- package/dist/libs/schema/dist/entity/index.js +2 -1
- package/dist/libs/schema/dist/entity/types.js +1 -1
- package/dist/libs/schema/dist/index.js +6 -1
- package/dist/presentations/index.js +5 -1
- package/dist/run/index.js +9 -1
- package/dist/run/run.contracts.d.ts +175 -175
- package/dist/run/run.contracts.js +469 -1
- package/dist/run/run.entity.d.ts +56 -56
- package/dist/run/run.entity.js +205 -1
- package/dist/run/run.enum.d.ts +5 -5
- package/dist/run/run.enum.js +45 -1
- package/dist/run/run.event.d.ts +71 -71
- package/dist/run/run.event.js +389 -1
- package/dist/run/run.handler.js +82 -1
- package/dist/run/run.presentation.js +55 -1
- package/dist/run/run.schema.d.ts +99 -99
- package/dist/run/run.schema.js +339 -1
- package/dist/shared/index.js +5 -1
- package/dist/shared/mock-agents.js +93 -1
- package/dist/shared/mock-runs.js +117 -1
- package/dist/shared/mock-tools.js +180 -1
- package/dist/tool/index.js +9 -1
- package/dist/tool/tool.contracts.d.ts +101 -101
- package/dist/tool/tool.contracts.js +288 -1
- package/dist/tool/tool.entity.d.ts +24 -24
- package/dist/tool/tool.entity.js +105 -1
- package/dist/tool/tool.enum.d.ts +4 -4
- package/dist/tool/tool.enum.js +35 -1
- package/dist/tool/tool.event.d.ts +25 -25
- package/dist/tool/tool.event.js +145 -1
- package/dist/tool/tool.handler.d.ts +1 -1
- package/dist/tool/tool.handler.js +86 -1
- package/dist/tool/tool.presentation.js +55 -1
- package/dist/tool/tool.schema.d.ts +52 -52
- package/dist/tool/tool.schema.js +237 -1
- package/package.json +8 -8
|
@@ -1,125 +1,125 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import * as
|
|
1
|
+
import * as _lssm_lib_contracts16 from "@lssm/lib.contracts";
|
|
2
|
+
import * as _lssm_lib_schema436 from "@lssm/lib.schema";
|
|
3
3
|
|
|
4
4
|
//#region src/agent/agent.event.d.ts
|
|
5
5
|
/**
|
|
6
6
|
* AgentCreatedEvent - A new agent was created.
|
|
7
7
|
*/
|
|
8
|
-
declare const AgentCreatedEvent:
|
|
8
|
+
declare const AgentCreatedEvent: _lssm_lib_contracts16.EventSpec<_lssm_lib_schema436.SchemaModel<{
|
|
9
9
|
id: {
|
|
10
|
-
type:
|
|
10
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
11
11
|
isOptional: false;
|
|
12
12
|
};
|
|
13
13
|
organizationId: {
|
|
14
|
-
type:
|
|
14
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
15
15
|
isOptional: false;
|
|
16
16
|
};
|
|
17
17
|
name: {
|
|
18
|
-
type:
|
|
18
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
19
19
|
isOptional: false;
|
|
20
20
|
};
|
|
21
21
|
slug: {
|
|
22
|
-
type:
|
|
22
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
23
23
|
isOptional: false;
|
|
24
24
|
};
|
|
25
25
|
modelProvider: {
|
|
26
|
-
type:
|
|
26
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
27
27
|
isOptional: false;
|
|
28
28
|
};
|
|
29
29
|
modelName: {
|
|
30
|
-
type:
|
|
30
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
31
31
|
isOptional: false;
|
|
32
32
|
};
|
|
33
33
|
toolCount: {
|
|
34
|
-
type:
|
|
34
|
+
type: _lssm_lib_schema436.FieldType<number, number>;
|
|
35
35
|
isOptional: false;
|
|
36
36
|
};
|
|
37
37
|
createdById: {
|
|
38
|
-
type:
|
|
38
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
39
39
|
isOptional: true;
|
|
40
40
|
};
|
|
41
41
|
createdAt: {
|
|
42
|
-
type:
|
|
42
|
+
type: _lssm_lib_schema436.FieldType<Date, string>;
|
|
43
43
|
isOptional: false;
|
|
44
44
|
};
|
|
45
45
|
}>>;
|
|
46
46
|
/**
|
|
47
47
|
* AgentUpdatedEvent - An agent was updated.
|
|
48
48
|
*/
|
|
49
|
-
declare const AgentUpdatedEvent:
|
|
49
|
+
declare const AgentUpdatedEvent: _lssm_lib_contracts16.EventSpec<_lssm_lib_schema436.SchemaModel<{
|
|
50
50
|
id: {
|
|
51
|
-
type:
|
|
51
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
52
52
|
isOptional: false;
|
|
53
53
|
};
|
|
54
54
|
organizationId: {
|
|
55
|
-
type:
|
|
55
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
56
56
|
isOptional: false;
|
|
57
57
|
};
|
|
58
58
|
name: {
|
|
59
|
-
type:
|
|
59
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
60
60
|
isOptional: false;
|
|
61
61
|
};
|
|
62
62
|
status: {
|
|
63
|
-
type:
|
|
63
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
64
64
|
isOptional: false;
|
|
65
65
|
};
|
|
66
66
|
updatedFields: {
|
|
67
|
-
type:
|
|
67
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
68
68
|
isArray: true;
|
|
69
69
|
isOptional: false;
|
|
70
70
|
};
|
|
71
71
|
updatedAt: {
|
|
72
|
-
type:
|
|
72
|
+
type: _lssm_lib_schema436.FieldType<Date, string>;
|
|
73
73
|
isOptional: false;
|
|
74
74
|
};
|
|
75
75
|
}>>;
|
|
76
76
|
/**
|
|
77
77
|
* AgentToolAssignedEvent - A tool was assigned to an agent.
|
|
78
78
|
*/
|
|
79
|
-
declare const AgentToolAssignedEvent:
|
|
79
|
+
declare const AgentToolAssignedEvent: _lssm_lib_contracts16.EventSpec<_lssm_lib_schema436.SchemaModel<{
|
|
80
80
|
agentId: {
|
|
81
|
-
type:
|
|
81
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
82
82
|
isOptional: false;
|
|
83
83
|
};
|
|
84
84
|
toolId: {
|
|
85
|
-
type:
|
|
85
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
86
86
|
isOptional: false;
|
|
87
87
|
};
|
|
88
88
|
agentName: {
|
|
89
|
-
type:
|
|
89
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
90
90
|
isOptional: false;
|
|
91
91
|
};
|
|
92
92
|
toolName: {
|
|
93
|
-
type:
|
|
93
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
94
94
|
isOptional: false;
|
|
95
95
|
};
|
|
96
96
|
assignedAt: {
|
|
97
|
-
type:
|
|
97
|
+
type: _lssm_lib_schema436.FieldType<Date, string>;
|
|
98
98
|
isOptional: false;
|
|
99
99
|
};
|
|
100
100
|
}>>;
|
|
101
101
|
/**
|
|
102
102
|
* AgentToolRemovedEvent - A tool was removed from an agent.
|
|
103
103
|
*/
|
|
104
|
-
declare const AgentToolRemovedEvent:
|
|
104
|
+
declare const AgentToolRemovedEvent: _lssm_lib_contracts16.EventSpec<_lssm_lib_schema436.SchemaModel<{
|
|
105
105
|
agentId: {
|
|
106
|
-
type:
|
|
106
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
107
107
|
isOptional: false;
|
|
108
108
|
};
|
|
109
109
|
toolId: {
|
|
110
|
-
type:
|
|
110
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
111
111
|
isOptional: false;
|
|
112
112
|
};
|
|
113
113
|
agentName: {
|
|
114
|
-
type:
|
|
114
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
115
115
|
isOptional: false;
|
|
116
116
|
};
|
|
117
117
|
toolName: {
|
|
118
|
-
type:
|
|
118
|
+
type: _lssm_lib_schema436.FieldType<string, string>;
|
|
119
119
|
isOptional: false;
|
|
120
120
|
};
|
|
121
121
|
removedAt: {
|
|
122
|
-
type:
|
|
122
|
+
type: _lssm_lib_schema436.FieldType<Date, string>;
|
|
123
123
|
isOptional: false;
|
|
124
124
|
};
|
|
125
125
|
}>>;
|
|
@@ -1 +1,183 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import { ScalarTypeEnum } from "../libs/schema/dist/ScalarTypeEnum.js";
|
|
2
|
+
import "../libs/schema/dist/index.js";
|
|
3
|
+
import { defineSchemaModel } from "../libs/contracts/dist/schema/dist/SchemaModel.js";
|
|
4
|
+
import { defineEvent } from "../libs/contracts/dist/events.js";
|
|
5
|
+
import "../libs/contracts/dist/index.js";
|
|
6
|
+
|
|
7
|
+
//#region src/agent/agent.event.ts
|
|
8
|
+
/**
|
|
9
|
+
* Payload for agent created event.
|
|
10
|
+
*/
|
|
11
|
+
const AgentCreatedPayload = defineSchemaModel({
|
|
12
|
+
name: "AgentCreatedPayload",
|
|
13
|
+
description: "Payload for agent created event",
|
|
14
|
+
fields: {
|
|
15
|
+
id: {
|
|
16
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
17
|
+
isOptional: false
|
|
18
|
+
},
|
|
19
|
+
organizationId: {
|
|
20
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
21
|
+
isOptional: false
|
|
22
|
+
},
|
|
23
|
+
name: {
|
|
24
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
25
|
+
isOptional: false
|
|
26
|
+
},
|
|
27
|
+
slug: {
|
|
28
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
29
|
+
isOptional: false
|
|
30
|
+
},
|
|
31
|
+
modelProvider: {
|
|
32
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
33
|
+
isOptional: false
|
|
34
|
+
},
|
|
35
|
+
modelName: {
|
|
36
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
37
|
+
isOptional: false
|
|
38
|
+
},
|
|
39
|
+
toolCount: {
|
|
40
|
+
type: ScalarTypeEnum.Int_unsecure(),
|
|
41
|
+
isOptional: false
|
|
42
|
+
},
|
|
43
|
+
createdById: {
|
|
44
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
45
|
+
isOptional: true
|
|
46
|
+
},
|
|
47
|
+
createdAt: {
|
|
48
|
+
type: ScalarTypeEnum.DateTime(),
|
|
49
|
+
isOptional: false
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
/**
|
|
54
|
+
* AgentCreatedEvent - A new agent was created.
|
|
55
|
+
*/
|
|
56
|
+
const AgentCreatedEvent = defineEvent({
|
|
57
|
+
name: "agent.agent.created",
|
|
58
|
+
version: 1,
|
|
59
|
+
description: "A new AI agent was configured.",
|
|
60
|
+
payload: AgentCreatedPayload
|
|
61
|
+
});
|
|
62
|
+
/**
|
|
63
|
+
* Payload for agent updated event.
|
|
64
|
+
*/
|
|
65
|
+
const AgentUpdatedPayload = defineSchemaModel({
|
|
66
|
+
name: "AgentUpdatedPayload",
|
|
67
|
+
description: "Payload for agent updated event",
|
|
68
|
+
fields: {
|
|
69
|
+
id: {
|
|
70
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
71
|
+
isOptional: false
|
|
72
|
+
},
|
|
73
|
+
organizationId: {
|
|
74
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
75
|
+
isOptional: false
|
|
76
|
+
},
|
|
77
|
+
name: {
|
|
78
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
79
|
+
isOptional: false
|
|
80
|
+
},
|
|
81
|
+
status: {
|
|
82
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
83
|
+
isOptional: false
|
|
84
|
+
},
|
|
85
|
+
updatedFields: {
|
|
86
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
87
|
+
isArray: true,
|
|
88
|
+
isOptional: false
|
|
89
|
+
},
|
|
90
|
+
updatedAt: {
|
|
91
|
+
type: ScalarTypeEnum.DateTime(),
|
|
92
|
+
isOptional: false
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
/**
|
|
97
|
+
* AgentUpdatedEvent - An agent was updated.
|
|
98
|
+
*/
|
|
99
|
+
const AgentUpdatedEvent = defineEvent({
|
|
100
|
+
name: "agent.agent.updated",
|
|
101
|
+
version: 1,
|
|
102
|
+
description: "An AI agent configuration was updated.",
|
|
103
|
+
payload: AgentUpdatedPayload
|
|
104
|
+
});
|
|
105
|
+
/**
|
|
106
|
+
* Payload for agent tool assigned event.
|
|
107
|
+
*/
|
|
108
|
+
const AgentToolAssignedPayload = defineSchemaModel({
|
|
109
|
+
name: "AgentToolAssignedPayload",
|
|
110
|
+
description: "Payload for agent tool assigned event",
|
|
111
|
+
fields: {
|
|
112
|
+
agentId: {
|
|
113
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
114
|
+
isOptional: false
|
|
115
|
+
},
|
|
116
|
+
toolId: {
|
|
117
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
118
|
+
isOptional: false
|
|
119
|
+
},
|
|
120
|
+
agentName: {
|
|
121
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
122
|
+
isOptional: false
|
|
123
|
+
},
|
|
124
|
+
toolName: {
|
|
125
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
126
|
+
isOptional: false
|
|
127
|
+
},
|
|
128
|
+
assignedAt: {
|
|
129
|
+
type: ScalarTypeEnum.DateTime(),
|
|
130
|
+
isOptional: false
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
});
|
|
134
|
+
/**
|
|
135
|
+
* AgentToolAssignedEvent - A tool was assigned to an agent.
|
|
136
|
+
*/
|
|
137
|
+
const AgentToolAssignedEvent = defineEvent({
|
|
138
|
+
name: "agent.agent.toolAssigned",
|
|
139
|
+
version: 1,
|
|
140
|
+
description: "A tool was assigned to an agent.",
|
|
141
|
+
payload: AgentToolAssignedPayload
|
|
142
|
+
});
|
|
143
|
+
/**
|
|
144
|
+
* Payload for agent tool removed event.
|
|
145
|
+
*/
|
|
146
|
+
const AgentToolRemovedPayload = defineSchemaModel({
|
|
147
|
+
name: "AgentToolRemovedPayload",
|
|
148
|
+
description: "Payload for agent tool removed event",
|
|
149
|
+
fields: {
|
|
150
|
+
agentId: {
|
|
151
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
152
|
+
isOptional: false
|
|
153
|
+
},
|
|
154
|
+
toolId: {
|
|
155
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
156
|
+
isOptional: false
|
|
157
|
+
},
|
|
158
|
+
agentName: {
|
|
159
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
160
|
+
isOptional: false
|
|
161
|
+
},
|
|
162
|
+
toolName: {
|
|
163
|
+
type: ScalarTypeEnum.String_unsecure(),
|
|
164
|
+
isOptional: false
|
|
165
|
+
},
|
|
166
|
+
removedAt: {
|
|
167
|
+
type: ScalarTypeEnum.DateTime(),
|
|
168
|
+
isOptional: false
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
});
|
|
172
|
+
/**
|
|
173
|
+
* AgentToolRemovedEvent - A tool was removed from an agent.
|
|
174
|
+
*/
|
|
175
|
+
const AgentToolRemovedEvent = defineEvent({
|
|
176
|
+
name: "agent.agent.toolRemoved",
|
|
177
|
+
version: 1,
|
|
178
|
+
description: "A tool was removed from an agent.",
|
|
179
|
+
payload: AgentToolRemovedPayload
|
|
180
|
+
});
|
|
181
|
+
|
|
182
|
+
//#endregion
|
|
183
|
+
export { AgentCreatedEvent, AgentToolAssignedEvent, AgentToolRemovedEvent, AgentUpdatedEvent };
|
|
@@ -1 +1,83 @@
|
|
|
1
|
-
import{MOCK_AGENTS
|
|
1
|
+
import { MOCK_AGENTS } from "../shared/mock-agents.js";
|
|
2
|
+
import { MOCK_TOOLS } from "../shared/mock-tools.js";
|
|
3
|
+
|
|
4
|
+
//#region src/agent/agent.handler.ts
|
|
5
|
+
/**
|
|
6
|
+
* Mock handlers for Agent contracts.
|
|
7
|
+
*/
|
|
8
|
+
/**
|
|
9
|
+
* Mock handler for ListAgentsQuery.
|
|
10
|
+
*/
|
|
11
|
+
async function mockListAgentsHandler(input) {
|
|
12
|
+
const { organizationId, status, modelProvider, search, limit = 20, offset = 0 } = input;
|
|
13
|
+
let filtered = MOCK_AGENTS.filter((a) => a.organizationId === organizationId);
|
|
14
|
+
if (status) filtered = filtered.filter((a) => a.status === status);
|
|
15
|
+
if (modelProvider) filtered = filtered.filter((a) => a.modelProvider === modelProvider);
|
|
16
|
+
if (search) {
|
|
17
|
+
const q = search.toLowerCase();
|
|
18
|
+
filtered = filtered.filter((a) => a.name.toLowerCase().includes(q) || a.description?.toLowerCase().includes(q) || a.tags?.some((t) => t.toLowerCase().includes(q)));
|
|
19
|
+
}
|
|
20
|
+
const total = filtered.length;
|
|
21
|
+
return {
|
|
22
|
+
items: filtered.slice(offset, offset + limit).map((a) => ({
|
|
23
|
+
id: a.id,
|
|
24
|
+
name: a.name,
|
|
25
|
+
slug: a.slug,
|
|
26
|
+
description: a.description,
|
|
27
|
+
status: a.status,
|
|
28
|
+
modelProvider: a.modelProvider,
|
|
29
|
+
modelName: a.modelName,
|
|
30
|
+
version: a.version,
|
|
31
|
+
createdAt: a.createdAt
|
|
32
|
+
})),
|
|
33
|
+
total,
|
|
34
|
+
hasMore: offset + limit < total
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Mock handler for GetAgentQuery.
|
|
39
|
+
*/
|
|
40
|
+
async function mockGetAgentHandler(input) {
|
|
41
|
+
const agent = MOCK_AGENTS.find((a) => a.id === input.agentId);
|
|
42
|
+
if (!agent) throw new Error("AGENT_NOT_FOUND");
|
|
43
|
+
const result = {
|
|
44
|
+
...agent,
|
|
45
|
+
toolIds: ["tool-1", "tool-2"]
|
|
46
|
+
};
|
|
47
|
+
if (input.includeTools) result.tools = MOCK_TOOLS.slice(0, 2).map((t) => ({
|
|
48
|
+
id: t.id,
|
|
49
|
+
name: t.name,
|
|
50
|
+
slug: t.slug,
|
|
51
|
+
description: t.description,
|
|
52
|
+
category: t.category
|
|
53
|
+
}));
|
|
54
|
+
return result;
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* Mock handler for CreateAgentCommand.
|
|
58
|
+
*/
|
|
59
|
+
async function mockCreateAgentHandler(input) {
|
|
60
|
+
if (MOCK_AGENTS.some((a) => a.organizationId === input.organizationId && a.slug === input.slug)) throw new Error("SLUG_EXISTS");
|
|
61
|
+
return {
|
|
62
|
+
id: `agent-${Date.now()}`,
|
|
63
|
+
name: input.name,
|
|
64
|
+
slug: input.slug,
|
|
65
|
+
status: "DRAFT"
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
/**
|
|
69
|
+
* Mock handler for UpdateAgentCommand.
|
|
70
|
+
*/
|
|
71
|
+
async function mockUpdateAgentHandler(input) {
|
|
72
|
+
const agent = MOCK_AGENTS.find((a) => a.id === input.agentId);
|
|
73
|
+
if (!agent) throw new Error("AGENT_NOT_FOUND");
|
|
74
|
+
return {
|
|
75
|
+
id: agent.id,
|
|
76
|
+
name: input.name ?? agent.name,
|
|
77
|
+
status: input.status ?? agent.status,
|
|
78
|
+
updatedAt: /* @__PURE__ */ new Date()
|
|
79
|
+
};
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
//#endregion
|
|
83
|
+
export { mockCreateAgentHandler, mockGetAgentHandler, mockListAgentsHandler, mockUpdateAgentHandler };
|
|
@@ -1 +1,75 @@
|
|
|
1
|
-
import{AgentSummaryModel
|
|
1
|
+
import { AgentSummaryModel } from "./agent.schema.js";
|
|
2
|
+
|
|
3
|
+
//#region src/agent/agent.presentation.ts
|
|
4
|
+
/**
|
|
5
|
+
* Presentation for displaying a list of AI agents.
|
|
6
|
+
*/
|
|
7
|
+
const AgentListPresentation = {
|
|
8
|
+
meta: {
|
|
9
|
+
name: "agent-console.agent.list",
|
|
10
|
+
version: 1,
|
|
11
|
+
description: "List view of AI agents with status, model provider, and version info",
|
|
12
|
+
domain: "agent-console",
|
|
13
|
+
owners: ["@agent-console-team"],
|
|
14
|
+
tags: [
|
|
15
|
+
"agent",
|
|
16
|
+
"list",
|
|
17
|
+
"dashboard"
|
|
18
|
+
]
|
|
19
|
+
},
|
|
20
|
+
source: {
|
|
21
|
+
type: "component",
|
|
22
|
+
framework: "react",
|
|
23
|
+
componentKey: "AgentListView",
|
|
24
|
+
props: AgentSummaryModel
|
|
25
|
+
},
|
|
26
|
+
targets: [
|
|
27
|
+
"react",
|
|
28
|
+
"markdown",
|
|
29
|
+
"application/json"
|
|
30
|
+
],
|
|
31
|
+
policy: { flags: ["agent-console.enabled"] }
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* Presentation for agent detail view.
|
|
35
|
+
*/
|
|
36
|
+
const AgentDetailPresentation = {
|
|
37
|
+
meta: {
|
|
38
|
+
name: "agent-console.agent.detail",
|
|
39
|
+
version: 1,
|
|
40
|
+
description: "Detailed view of an AI agent with configuration, tools, and recent runs",
|
|
41
|
+
domain: "agent-console",
|
|
42
|
+
owners: ["@agent-console-team"],
|
|
43
|
+
tags: ["agent", "detail"]
|
|
44
|
+
},
|
|
45
|
+
source: {
|
|
46
|
+
type: "component",
|
|
47
|
+
framework: "react",
|
|
48
|
+
componentKey: "AgentDetailView"
|
|
49
|
+
},
|
|
50
|
+
targets: ["react", "markdown"],
|
|
51
|
+
policy: { flags: ["agent-console.enabled"] }
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* Dashboard presentation for Agent Console - overview of agents, runs, and tools.
|
|
55
|
+
*/
|
|
56
|
+
const AgentConsoleDashboardPresentation = {
|
|
57
|
+
meta: {
|
|
58
|
+
name: "agent-console.dashboard",
|
|
59
|
+
version: 1,
|
|
60
|
+
description: "Dashboard overview of AI agents, runs, and tools",
|
|
61
|
+
domain: "agent-console",
|
|
62
|
+
owners: ["@agent-console-team"],
|
|
63
|
+
tags: ["dashboard", "overview"]
|
|
64
|
+
},
|
|
65
|
+
source: {
|
|
66
|
+
type: "component",
|
|
67
|
+
framework: "react",
|
|
68
|
+
componentKey: "AgentConsoleDashboard"
|
|
69
|
+
},
|
|
70
|
+
targets: ["react", "markdown"],
|
|
71
|
+
policy: { flags: ["agent-console.enabled"] }
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
//#endregion
|
|
75
|
+
export { AgentConsoleDashboardPresentation, AgentDetailPresentation, AgentListPresentation };
|