@wowok/agent-mcp 2.7.8 → 2.7.10
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 +2 -2
- package/dist/config/runtime.d.ts +1 -1
- package/dist/config/runtime.js +1 -1
- package/dist/examples/rental-ziroom-machine-create.json +1 -2
- package/dist/examples/rental-ziroom-permission-create.json +1 -2
- package/dist/examples/rental-ziroom-service-create.json +1 -2
- package/dist/experience/experience-reuse.js +1 -1
- package/dist/experience/index.d.ts +2 -1
- package/dist/experience/index.js +1 -1
- package/dist/experience/persistence-config.d.ts +6 -0
- package/dist/experience/persistence-config.js +1 -0
- package/dist/experience/persistence.d.ts +21 -0
- package/dist/experience/persistence.js +1 -0
- package/dist/experience/realtime-feedback.js +1 -1
- package/dist/experience/user-profile.js +1 -1
- package/dist/extensions/business-modules.d.ts +1 -1
- package/dist/extensions/capability-manifest.d.ts +1 -1
- package/dist/extensions/types.d.ts +1 -1
- package/dist/goal/GoalClassifier.d.ts +17 -0
- package/dist/goal/GoalClassifier.js +1 -0
- package/dist/goal/GoalEngine.d.ts +120 -0
- package/dist/goal/GoalEngine.js +1 -0
- package/dist/goal/GoalStore.d.ts +27 -0
- package/dist/goal/GoalStore.js +1 -0
- package/dist/goal/plan-approval.d.ts +5 -0
- package/dist/goal/plan-approval.js +1 -0
- package/dist/goal/types.d.ts +76 -0
- package/dist/goal/types.js +1 -0
- package/dist/harness/index.d.ts +2 -7
- package/dist/harness/index.js +1 -1
- package/dist/harness/plan.d.ts +1 -1
- package/dist/harness/types.d.ts +0 -35
- package/dist/index.js +1 -1
- package/dist/knowledge/account-marks.d.ts +35 -0
- package/dist/knowledge/account-marks.js +1 -0
- package/dist/knowledge/audit-rules.d.ts +3 -1
- package/dist/knowledge/audit-rules.js +1 -1
- package/dist/knowledge/examples-scanner-cli.js +1 -1
- package/dist/knowledge/examples-scanner.js +1 -1
- package/dist/knowledge/goal-completion.d.ts +19 -0
- package/dist/knowledge/goal-completion.js +1 -0
- package/dist/knowledge/guard-translation.js +1 -1
- package/dist/knowledge/index.d.ts +3 -2
- package/dist/knowledge/index.js +1 -1
- package/dist/knowledge/industry-registry.js +1 -1
- package/dist/knowledge/mcp-schema-audit-cli.js +1 -1
- package/dist/knowledge/mcp-schema-audit.js +1 -1
- package/dist/knowledge/operation-dictionary.js +1 -1
- package/dist/knowledge/passport-confirm.js +1 -1
- package/dist/knowledge/passport-puzzle.js +1 -1
- package/dist/knowledge/passport-translation.js +1 -1
- package/dist/knowledge/proof-risk.js +1 -1
- package/dist/knowledge/safety-rules.js +1 -1
- package/dist/knowledge/service-translation.js +1 -1
- package/dist/knowledge/template-registry.js +1 -1
- package/dist/knowledge/tools-reference.js +1 -1
- package/dist/knowledge/workflow-guidance.d.ts +1 -0
- package/dist/knowledge/workflow-guidance.js +1 -1
- package/dist/knowledge/workspace-lists.d.ts +56 -0
- package/dist/knowledge/workspace-lists.js +1 -0
- package/dist/loop-engineering/context-collect.d.ts +1 -1
- package/dist/monitor/EventRouter.d.ts +10 -0
- package/dist/monitor/EventRouter.js +1 -0
- package/dist/monitor/EventStore.d.ts +32 -12
- package/dist/monitor/EventStore.js +1 -1
- package/dist/monitor/MonitorLoop.d.ts +79 -0
- package/dist/monitor/MonitorLoop.js +1 -0
- package/dist/monitor/ProblemBridge.d.ts +32 -0
- package/dist/monitor/ProblemBridge.js +1 -0
- package/dist/monitor/ScopeResolver.d.ts +59 -0
- package/dist/monitor/ScopeResolver.js +1 -0
- package/dist/monitor/SubscriptionStore.d.ts +13 -0
- package/dist/monitor/SubscriptionStore.js +1 -0
- package/dist/monitor/normalize.d.ts +8 -0
- package/dist/monitor/normalize.js +1 -0
- package/dist/monitor/types.d.ts +89 -0
- package/dist/monitor/types.js +1 -0
- package/dist/persona/address-format.d.ts +1 -1
- package/dist/persona/address-format.js +1 -1
- package/dist/persona/distill-goal.d.ts +20 -0
- package/dist/persona/distill-goal.js +1 -0
- package/dist/persona/index.d.ts +2 -0
- package/dist/persona/index.js +1 -1
- package/dist/persona/model.js +1 -1
- package/dist/playbooks/service-build/business-puzzle.js +1 -0
- package/dist/{project → playbooks/service-build}/context-assembly.d.ts +9 -4
- package/dist/playbooks/service-build/context-assembly.js +1 -0
- package/dist/{project → playbooks/service-build}/game-theory.d.ts +1 -1
- package/dist/playbooks/service-build/index.d.ts +14 -0
- package/dist/playbooks/service-build/index.js +1 -0
- package/dist/{project → playbooks/service-build}/intent-analyzer.d.ts +1 -1
- package/dist/playbooks/service-build/intent-analyzer.js +1 -0
- package/dist/{project → playbooks/service-build}/machine-panorama.d.ts +5 -3
- package/dist/playbooks/service-build/machine-panorama.js +1 -0
- package/dist/{project → playbooks/service-build}/merchant-guide.d.ts +1 -1
- package/dist/playbooks/service-build/merchant-guide.js +1 -0
- package/dist/{project → playbooks/service-build}/mode-actions.d.ts +2 -2
- package/dist/playbooks/service-build/mode-actions.js +1 -0
- package/dist/playbooks/service-build/namespace.d.ts +2 -0
- package/dist/playbooks/service-build/namespace.js +1 -0
- package/dist/{project → playbooks/service-build}/object-panorama.d.ts +2 -3
- package/dist/playbooks/service-build/object-panorama.js +1 -0
- package/dist/{project → playbooks/service-build}/participation-radar.d.ts +4 -5
- package/dist/playbooks/service-build/participation-radar.js +1 -0
- package/dist/{project → playbooks/service-build}/pipeline-actions.d.ts +9 -9
- package/dist/playbooks/service-build/pipeline-actions.js +1 -0
- package/dist/playbooks/service-build/process.d.ts +6 -0
- package/dist/playbooks/service-build/process.js +1 -0
- package/dist/playbooks/service-build/risk-aggregator.js +1 -0
- package/dist/{project → playbooks/service-build}/semantic-graph.d.ts +2 -2
- package/dist/{project → playbooks/service-build}/service-panorama.d.ts +3 -19
- package/dist/playbooks/service-build/service-panorama.js +1 -0
- package/dist/review/arb.d.ts +6 -0
- package/dist/review/arb.js +1 -0
- package/dist/review/demand.d.ts +3 -0
- package/dist/review/demand.js +1 -0
- package/dist/review/index.d.ts +3 -0
- package/dist/review/index.js +1 -0
- package/dist/review/machine.d.ts +3 -0
- package/dist/review/machine.js +1 -0
- package/dist/review/order.d.ts +9 -0
- package/dist/review/order.js +1 -0
- package/dist/review/progress.d.ts +3 -0
- package/dist/review/progress.js +1 -0
- package/dist/review/repository.d.ts +3 -0
- package/dist/review/repository.js +1 -0
- package/dist/review/service.d.ts +5 -0
- package/dist/review/service.js +1 -0
- package/dist/review/types.d.ts +156 -0
- package/dist/review/types.js +1 -0
- package/dist/rules.d.ts +2 -2
- package/dist/rules.js +1 -1
- package/dist/safety/confirm-gate.js +1 -1
- package/dist/safety/index.d.ts +1 -1
- package/dist/safety/index.js +1 -1
- package/dist/safety/preview.d.ts +1 -0
- package/dist/safety/preview.js +1 -1
- package/dist/schema/call/allocation.d.ts +1 -1
- package/dist/schema/call/arbitration.d.ts +1 -1
- package/dist/schema/call/base.d.ts +1 -1
- package/dist/schema/call/base.js +1 -1
- package/dist/schema/call/bridge.d.ts +4 -4
- package/dist/schema/call/contact.d.ts +1 -1
- package/dist/schema/call/contact.js +1 -1
- package/dist/schema/call/demand.d.ts +1 -1
- package/dist/schema/call/demand.js +1 -1
- package/dist/schema/call/guard.d.ts +3 -3
- package/dist/schema/call/handler.d.ts +0 -3
- package/dist/schema/call/handler.js +1 -1
- package/dist/schema/call/machine.d.ts +2 -2
- package/dist/schema/call/order.d.ts +1 -1
- package/dist/schema/call/payment.d.ts +1 -1
- package/dist/schema/call/permission.d.ts +1 -1
- package/dist/schema/call/personal.d.ts +1 -1
- package/dist/schema/call/progress.d.ts +1 -1
- package/dist/schema/call/proof.d.ts +2 -2
- package/dist/schema/call/repository.d.ts +1 -1
- package/dist/schema/call/repository.js +1 -1
- package/dist/schema/call/reward.d.ts +1 -1
- package/dist/schema/call/semantic.js +1 -1
- package/dist/schema/call/service.d.ts +1 -1
- package/dist/schema/call/service.js +1 -1
- package/dist/schema/call/treasury.d.ts +1 -1
- package/dist/schema/common/index.js +1 -1
- package/dist/schema/goal/index.d.ts +317 -0
- package/dist/schema/goal/index.js +1 -0
- package/dist/schema/goal/planning.d.ts +465 -0
- package/dist/schema/goal/planning.js +1 -0
- package/dist/schema/index.d.ts +1 -2
- package/dist/schema/index.js +1 -1
- package/dist/schema/industry-pack/index.d.ts +265 -1
- package/dist/schema/industry-pack/index.js +1 -1
- package/dist/schema/industry-pack/modes.d.ts +268 -0
- package/dist/schema/industry-pack/modes.js +1 -0
- package/dist/schema/local/index.js +1 -1
- package/dist/schema/operations.d.ts +216 -19
- package/dist/schema/operations.js +1 -1
- package/dist/schema/permission/index.d.ts +1 -0
- package/dist/schema/permission/index.js +1 -1
- package/dist/schema/persona/index.d.ts +40 -0
- package/dist/schema/persona/index.js +1 -1
- package/dist/schema/query/bi.d.ts +783 -0
- package/dist/schema/query/bi.js +1 -0
- package/dist/schema/query/index.d.ts +661 -0
- package/dist/schema/query/index.js +1 -1
- package/dist/schema/schema-version.js +1 -1
- package/dist/schema/utils/skills-recommendation.d.ts +0 -1
- package/dist/schema/utils/skills-recommendation.js +1 -1
- package/dist/schema-query-impl/index.js +1 -1
- package/dist/schemas/account_operation.output.json +3 -3
- package/dist/schemas/account_operation.schema.json +2 -2
- package/dist/schemas/bridge_operation.output.json +2 -2
- package/dist/schemas/bridge_operation.schema.json +12 -12
- package/dist/schemas/config_operation.output.json +1 -1
- package/dist/schemas/config_operation.schema.json +1 -1
- package/dist/schemas/goal_operation.schema.json +1016 -0
- package/dist/schemas/guard2file.schema.json +3 -3
- package/dist/schemas/index.json +12 -13
- package/dist/schemas/industry_pack_operation.output.json +898 -0
- package/dist/schemas/industry_pack_operation.schema.json +217 -2
- package/dist/schemas/local_info_operation.output.json +2 -2
- package/dist/schemas/local_mark_operation.output.json +2 -2
- package/dist/schemas/machineNode2file.schema.json +3 -3
- package/dist/schemas/messenger_operation.output.json +2 -2
- package/dist/schemas/monitor_events.output.json +78 -3
- package/dist/schemas/monitor_events.schema.json +24 -1
- package/dist/schemas/monitor_subscription.output.json +1462 -0
- package/dist/schemas/monitor_subscription.schema.json +327 -0
- package/dist/schemas/onchain_events.output.json +4 -4
- package/dist/schemas/onchain_operations.output.json +2 -2
- package/dist/schemas/onchain_operations.schema.json +59 -59
- package/dist/schemas/onchain_operations_allocation.schema.json +3 -3
- package/dist/schemas/onchain_operations_arbitration.schema.json +3 -3
- package/dist/schemas/onchain_operations_contact.schema.json +4 -4
- package/dist/schemas/onchain_operations_demand.schema.json +4 -4
- package/dist/schemas/onchain_operations_gen_passport.schema.json +3 -3
- package/dist/schemas/onchain_operations_gen_proof.schema.json +3 -3
- package/dist/schemas/onchain_operations_guard.schema.json +3 -3
- package/dist/schemas/onchain_operations_machine.schema.json +3 -3
- package/dist/schemas/onchain_operations_order.schema.json +3 -3
- package/dist/schemas/onchain_operations_payment.schema.json +3 -3
- package/dist/schemas/onchain_operations_permission.schema.json +3 -3
- package/dist/schemas/onchain_operations_personal.schema.json +3 -3
- package/dist/schemas/onchain_operations_progress.schema.json +3 -3
- package/dist/schemas/onchain_operations_proof.schema.json +3 -3
- package/dist/schemas/onchain_operations_repository.schema.json +5 -5
- package/dist/schemas/onchain_operations_reward.schema.json +3 -3
- package/dist/schemas/onchain_operations_service.schema.json +4 -4
- package/dist/schemas/onchain_operations_treasury.schema.json +3 -3
- package/dist/schemas/onchain_table_data.output.json +346 -2
- package/dist/schemas/onchain_table_data.schema.json +22 -22
- package/dist/schemas/permission_operation.schema.json +6 -2
- package/dist/schemas/persona_operation.output.json +145 -0
- package/dist/schemas/persona_operation.schema.json +28 -2
- package/dist/schemas/query_toolkit.output.json +1274 -15
- package/dist/schemas/query_toolkit.schema.json +412 -11
- package/dist/schemas/workflow_operation.schema.json +4 -4
- package/dist/task/ProcessStore.d.ts +81 -0
- package/dist/task/ProcessStore.js +1 -0
- package/dist/task/playbook.d.ts +11 -0
- package/dist/task/playbook.js +1 -0
- package/dist/task/stage-gate.d.ts +22 -0
- package/dist/task/stage-gate.js +1 -0
- package/dist/{project → task}/substep-trace.d.ts +6 -45
- package/dist/task/types.d.ts +120 -0
- package/dist/task/types.js +1 -0
- package/dist/tools/handlers/config.js +1 -1
- package/dist/tools/handlers/goal.d.ts +4 -0
- package/dist/tools/handlers/goal.js +1 -0
- package/dist/tools/handlers/industry-pack.js +1 -1
- package/dist/tools/handlers/monitor.d.ts +24 -0
- package/dist/tools/handlers/monitor.js +1 -1
- package/dist/tools/handlers/network.d.ts +1 -0
- package/dist/tools/handlers/network.js +1 -0
- package/dist/tools/handlers/onchain.js +1 -1
- package/dist/tools/handlers/permission.js +1 -1
- package/dist/tools/handlers/persona.js +1 -1
- package/dist/tools/handlers/query.js +1 -1
- package/dist/tools/handlers/watch.js +1 -1
- package/dist/tools/index.d.ts +2 -0
- package/dist/tools/index.js +1 -1
- package/dist/tools/shared.js +1 -1
- package/dist/tools/wrap.js +1 -1
- package/package.json +5 -4
- package/dist/harness/checkpoint.d.ts +0 -8
- package/dist/harness/checkpoint.js +0 -1
- package/dist/knowledge/deployment-scanner.d.ts +0 -66
- package/dist/knowledge/deployment-scanner.js +0 -1
- package/dist/project/business-puzzle.js +0 -1
- package/dist/project/context-assembly.js +0 -1
- package/dist/project/deployment-bridge.d.ts +0 -5
- package/dist/project/deployment-bridge.js +0 -1
- package/dist/project/deployment-doc.d.ts +0 -190
- package/dist/project/deployment-doc.js +0 -1
- package/dist/project/edit-planner.d.ts +0 -123
- package/dist/project/edit-planner.js +0 -1
- package/dist/project/evaluation-fix.spec.d.ts +0 -1
- package/dist/project/evaluation-fix.spec.js +0 -1
- package/dist/project/evaluation.d.ts +0 -127
- package/dist/project/evaluation.js +0 -1
- package/dist/project/graph-builder.d.ts +0 -51
- package/dist/project/graph-builder.js +0 -1
- package/dist/project/graph.d.ts +0 -70
- package/dist/project/graph.js +0 -1
- package/dist/project/handlers.d.ts +0 -524
- package/dist/project/handlers.js +0 -1
- package/dist/project/index.d.ts +0 -91
- package/dist/project/index.js +0 -1
- package/dist/project/intent-analyzer.js +0 -1
- package/dist/project/machine-panorama.js +0 -1
- package/dist/project/merchant-guide.js +0 -1
- package/dist/project/mode-actions.js +0 -1
- package/dist/project/namespace.d.ts +0 -72
- package/dist/project/namespace.js +0 -1
- package/dist/project/object-panorama.js +0 -1
- package/dist/project/participation-radar.js +0 -1
- package/dist/project/pipeline-actions.js +0 -1
- package/dist/project/project-store.d.ts +0 -110
- package/dist/project/project-store.js +0 -1
- package/dist/project/query.d.ts +0 -43
- package/dist/project/query.js +0 -1
- package/dist/project/risk-aggregator.js +0 -1
- package/dist/project/semantic-assembler.d.ts +0 -93
- package/dist/project/semantic-assembler.js +0 -1
- package/dist/project/service-panorama.js +0 -1
- package/dist/project/stage-gate.d.ts +0 -52
- package/dist/project/stage-gate.js +0 -1
- package/dist/project/task-tracker.d.ts +0 -30
- package/dist/project/task-tracker.js +0 -1
- package/dist/schema/project/index.d.ts +0 -2021
- package/dist/schema/project/index.js +0 -1
- package/dist/schema/task-status.d.ts +0 -62
- package/dist/schema/task-status.js +0 -1
- package/dist/schemas/project_operation.output.json +0 -7877
- package/dist/schemas/project_operation.schema.json +0 -1139
- package/dist/schemas/query_task_status.output.json +0 -211
- package/dist/schemas/query_task_status.schema.json +0 -18
- package/dist/tools/handlers/project.d.ts +0 -2
- package/dist/tools/handlers/project.js +0 -1
- package/dist/tools/handlers/task-status.d.ts +0 -2
- package/dist/tools/handlers/task-status.js +0 -1
- /package/dist/{project → playbooks/service-build}/business-puzzle.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/game-theory.js +0 -0
- /package/dist/{project → playbooks/service-build}/machine-nodes.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/machine-nodes.js +0 -0
- /package/dist/{project → playbooks/service-build}/object-type.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/object-type.js +0 -0
- /package/dist/{project → playbooks/service-build}/reverse-mapping.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/reverse-mapping.js +0 -0
- /package/dist/{project → playbooks/service-build}/risk-aggregator.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/semantic-graph.js +0 -0
- /package/dist/{project → playbooks/service-build}/workflow-design-assessment.d.ts +0 -0
- /package/dist/{project → playbooks/service-build}/workflow-design-assessment.js +0 -0
- /package/dist/{project → task}/substep-trace.js +0 -0
|
@@ -1,5 +1,61 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const IndustryPackOperationInputSchema: z.ZodObject<{
|
|
3
|
+
intent: z.ZodOptional<z.ZodString>;
|
|
4
|
+
mode_source: z.ZodOptional<z.ZodString>;
|
|
5
|
+
mode_name: z.ZodOptional<z.ZodString>;
|
|
6
|
+
mode_display_name: z.ZodOptional<z.ZodString>;
|
|
7
|
+
mode_changes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
8
|
+
mode_change_description: z.ZodOptional<z.ZodString>;
|
|
9
|
+
mode_bump_version: z.ZodOptional<z.ZodBoolean>;
|
|
10
|
+
metric_id: z.ZodOptional<z.ZodString>;
|
|
11
|
+
metric_display_name: z.ZodOptional<z.ZodString>;
|
|
12
|
+
metric_description: z.ZodOptional<z.ZodString>;
|
|
13
|
+
metric_type: z.ZodOptional<z.ZodEnum<{
|
|
14
|
+
risk: "risk";
|
|
15
|
+
benefit: "benefit";
|
|
16
|
+
}>>;
|
|
17
|
+
metric_scale: z.ZodOptional<z.ZodEnum<{
|
|
18
|
+
level: "level";
|
|
19
|
+
numeric: "numeric";
|
|
20
|
+
percentage: "percentage";
|
|
21
|
+
}>>;
|
|
22
|
+
metric_weight: z.ZodOptional<z.ZodNumber>;
|
|
23
|
+
constraint_id: z.ZodOptional<z.ZodString>;
|
|
24
|
+
constraint_display_name: z.ZodOptional<z.ZodString>;
|
|
25
|
+
constraint_description: z.ZodOptional<z.ZodString>;
|
|
26
|
+
constraint_rule: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
27
|
+
type: z.ZodLiteral<"capability_required">;
|
|
28
|
+
capability_id: z.ZodString;
|
|
29
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
30
|
+
type: z.ZodLiteral<"capability_forbidden">;
|
|
31
|
+
capability_id: z.ZodString;
|
|
32
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
33
|
+
type: z.ZodLiteral<"numeric_limit">;
|
|
34
|
+
field: z.ZodString;
|
|
35
|
+
max: z.ZodOptional<z.ZodNumber>;
|
|
36
|
+
min: z.ZodOptional<z.ZodNumber>;
|
|
37
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
38
|
+
type: z.ZodLiteral<"condition_required">;
|
|
39
|
+
condition: z.ZodString;
|
|
40
|
+
ai_evaluated: z.ZodLiteral<true>;
|
|
41
|
+
}, z.core.$strict>], "type">>;
|
|
42
|
+
constraint_severity: z.ZodOptional<z.ZodEnum<{
|
|
43
|
+
hard: "hard";
|
|
44
|
+
soft: "soft";
|
|
45
|
+
}>>;
|
|
46
|
+
constraint_on_violation: z.ZodOptional<z.ZodEnum<{
|
|
47
|
+
warn: "warn";
|
|
48
|
+
block: "block";
|
|
49
|
+
log: "log";
|
|
50
|
+
}>>;
|
|
51
|
+
metric_type_filter: z.ZodOptional<z.ZodEnum<{
|
|
52
|
+
risk: "risk";
|
|
53
|
+
benefit: "benefit";
|
|
54
|
+
}>>;
|
|
55
|
+
scope_filter: z.ZodOptional<z.ZodEnum<{
|
|
56
|
+
custom: "custom";
|
|
57
|
+
builtin: "builtin";
|
|
58
|
+
}>>;
|
|
3
59
|
action: z.ZodEnum<{
|
|
4
60
|
rename: "rename";
|
|
5
61
|
get: "get";
|
|
@@ -17,6 +73,15 @@ export declare const IndustryPackOperationInputSchema: z.ZodObject<{
|
|
|
17
73
|
create_dir: "create_dir";
|
|
18
74
|
copy: "copy";
|
|
19
75
|
move: "move";
|
|
76
|
+
recommend_industry: "recommend_industry";
|
|
77
|
+
list_modes: "list_modes";
|
|
78
|
+
derive_user_mode: "derive_user_mode";
|
|
79
|
+
evolve_user_mode: "evolve_user_mode";
|
|
80
|
+
register_user_mode: "register_user_mode";
|
|
81
|
+
unregister_user_mode: "unregister_user_mode";
|
|
82
|
+
register_custom_metric: "register_custom_metric";
|
|
83
|
+
register_custom_constraint: "register_custom_constraint";
|
|
84
|
+
list_metrics_constraints: "list_metrics_constraints";
|
|
20
85
|
}>;
|
|
21
86
|
name: z.ZodOptional<z.ZodString>;
|
|
22
87
|
path: z.ZodOptional<z.ZodString>;
|
|
@@ -128,5 +193,204 @@ export declare const IndustryPackOperationOutputSchema: z.ZodObject<{
|
|
|
128
193
|
from: z.ZodString;
|
|
129
194
|
to: z.ZodString;
|
|
130
195
|
ok: z.ZodBoolean;
|
|
131
|
-
}, z.core.$strip
|
|
196
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
197
|
+
action: z.ZodLiteral<"recommend_industry">;
|
|
198
|
+
intent: z.ZodString;
|
|
199
|
+
inferred_traits: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
200
|
+
inference_confidence: z.ZodNumber;
|
|
201
|
+
matched_keywords: z.ZodArray<z.ZodString>;
|
|
202
|
+
recommendations: z.ZodArray<z.ZodObject<{
|
|
203
|
+
industry: z.ZodString;
|
|
204
|
+
similarity: z.ZodNumber;
|
|
205
|
+
matched_traits: z.ZodArray<z.ZodString>;
|
|
206
|
+
reference_examples: z.ZodArray<z.ZodObject<{
|
|
207
|
+
file: z.ZodString;
|
|
208
|
+
title: z.ZodString;
|
|
209
|
+
operation_type: z.ZodString;
|
|
210
|
+
verified: z.ZodBoolean;
|
|
211
|
+
}, z.core.$strict>>;
|
|
212
|
+
}, z.core.$strict>>;
|
|
213
|
+
hint: z.ZodString;
|
|
214
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
215
|
+
action: z.ZodLiteral<"list_modes">;
|
|
216
|
+
builtin_modes: z.ZodArray<z.ZodObject<{
|
|
217
|
+
name: z.ZodString;
|
|
218
|
+
display_name: z.ZodString;
|
|
219
|
+
version: z.ZodString;
|
|
220
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
221
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
222
|
+
key_risk: z.ZodString;
|
|
223
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
224
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
225
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
226
|
+
version: z.ZodString;
|
|
227
|
+
changed_at: z.ZodNumber;
|
|
228
|
+
changes: z.ZodArray<z.ZodString>;
|
|
229
|
+
}, z.core.$strict>>>;
|
|
230
|
+
}, z.core.$strict>>;
|
|
231
|
+
user_modes: z.ZodArray<z.ZodObject<{
|
|
232
|
+
name: z.ZodString;
|
|
233
|
+
display_name: z.ZodString;
|
|
234
|
+
version: z.ZodString;
|
|
235
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
236
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
237
|
+
key_risk: z.ZodString;
|
|
238
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
239
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
240
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
241
|
+
version: z.ZodString;
|
|
242
|
+
changed_at: z.ZodNumber;
|
|
243
|
+
changes: z.ZodArray<z.ZodString>;
|
|
244
|
+
}, z.core.$strict>>>;
|
|
245
|
+
}, z.core.$strict>>;
|
|
246
|
+
owner: z.ZodString;
|
|
247
|
+
hint: z.ZodString;
|
|
248
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
249
|
+
action: z.ZodLiteral<"derive_user_mode">;
|
|
250
|
+
mode: z.ZodObject<{
|
|
251
|
+
name: z.ZodString;
|
|
252
|
+
display_name: z.ZodString;
|
|
253
|
+
version: z.ZodString;
|
|
254
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
255
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
256
|
+
key_risk: z.ZodString;
|
|
257
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
258
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
259
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
260
|
+
version: z.ZodString;
|
|
261
|
+
changed_at: z.ZodNumber;
|
|
262
|
+
changes: z.ZodArray<z.ZodString>;
|
|
263
|
+
}, z.core.$strict>>>;
|
|
264
|
+
}, z.core.$strict>;
|
|
265
|
+
hint: z.ZodString;
|
|
266
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
267
|
+
action: z.ZodLiteral<"evolve_user_mode">;
|
|
268
|
+
mode: z.ZodObject<{
|
|
269
|
+
name: z.ZodString;
|
|
270
|
+
display_name: z.ZodString;
|
|
271
|
+
version: z.ZodString;
|
|
272
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
273
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
274
|
+
key_risk: z.ZodString;
|
|
275
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
276
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
277
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
278
|
+
version: z.ZodString;
|
|
279
|
+
changed_at: z.ZodNumber;
|
|
280
|
+
changes: z.ZodArray<z.ZodString>;
|
|
281
|
+
}, z.core.$strict>>>;
|
|
282
|
+
}, z.core.$strict>;
|
|
283
|
+
hint: z.ZodString;
|
|
284
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
285
|
+
action: z.ZodLiteral<"register_user_mode">;
|
|
286
|
+
mode: z.ZodObject<{
|
|
287
|
+
name: z.ZodString;
|
|
288
|
+
display_name: z.ZodString;
|
|
289
|
+
version: z.ZodString;
|
|
290
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
291
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
292
|
+
key_risk: z.ZodString;
|
|
293
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
294
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
295
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
296
|
+
version: z.ZodString;
|
|
297
|
+
changed_at: z.ZodNumber;
|
|
298
|
+
changes: z.ZodArray<z.ZodString>;
|
|
299
|
+
}, z.core.$strict>>>;
|
|
300
|
+
}, z.core.$strict>;
|
|
301
|
+
hint: z.ZodString;
|
|
302
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
303
|
+
action: z.ZodLiteral<"unregister_user_mode">;
|
|
304
|
+
removed: z.ZodLiteral<true>;
|
|
305
|
+
mode_name: z.ZodString;
|
|
306
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
307
|
+
action: z.ZodLiteral<"register_custom_metric">;
|
|
308
|
+
metric: z.ZodObject<{
|
|
309
|
+
metric_id: z.ZodString;
|
|
310
|
+
display_name: z.ZodString;
|
|
311
|
+
description: z.ZodString;
|
|
312
|
+
type: z.ZodEnum<{
|
|
313
|
+
risk: "risk";
|
|
314
|
+
benefit: "benefit";
|
|
315
|
+
}>;
|
|
316
|
+
scale: z.ZodEnum<{
|
|
317
|
+
level: "level";
|
|
318
|
+
numeric: "numeric";
|
|
319
|
+
percentage: "percentage";
|
|
320
|
+
}>;
|
|
321
|
+
weight: z.ZodNumber;
|
|
322
|
+
scope: z.ZodEnum<{
|
|
323
|
+
custom: "custom";
|
|
324
|
+
builtin: "builtin";
|
|
325
|
+
}>;
|
|
326
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
327
|
+
}, z.core.$strict>;
|
|
328
|
+
hint: z.ZodString;
|
|
329
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
330
|
+
action: z.ZodLiteral<"register_custom_constraint">;
|
|
331
|
+
constraint: z.ZodObject<{
|
|
332
|
+
constraint_id: z.ZodString;
|
|
333
|
+
display_name: z.ZodString;
|
|
334
|
+
description: z.ZodString;
|
|
335
|
+
rule: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
336
|
+
severity: z.ZodEnum<{
|
|
337
|
+
hard: "hard";
|
|
338
|
+
soft: "soft";
|
|
339
|
+
}>;
|
|
340
|
+
on_violation: z.ZodEnum<{
|
|
341
|
+
warn: "warn";
|
|
342
|
+
block: "block";
|
|
343
|
+
log: "log";
|
|
344
|
+
}>;
|
|
345
|
+
scope: z.ZodEnum<{
|
|
346
|
+
custom: "custom";
|
|
347
|
+
builtin: "builtin";
|
|
348
|
+
}>;
|
|
349
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
350
|
+
}, z.core.$strict>;
|
|
351
|
+
hint: z.ZodString;
|
|
352
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
353
|
+
action: z.ZodLiteral<"list_metrics_constraints">;
|
|
354
|
+
metrics: z.ZodArray<z.ZodObject<{
|
|
355
|
+
metric_id: z.ZodString;
|
|
356
|
+
display_name: z.ZodString;
|
|
357
|
+
description: z.ZodString;
|
|
358
|
+
type: z.ZodEnum<{
|
|
359
|
+
risk: "risk";
|
|
360
|
+
benefit: "benefit";
|
|
361
|
+
}>;
|
|
362
|
+
scale: z.ZodEnum<{
|
|
363
|
+
level: "level";
|
|
364
|
+
numeric: "numeric";
|
|
365
|
+
percentage: "percentage";
|
|
366
|
+
}>;
|
|
367
|
+
weight: z.ZodNumber;
|
|
368
|
+
scope: z.ZodEnum<{
|
|
369
|
+
custom: "custom";
|
|
370
|
+
builtin: "builtin";
|
|
371
|
+
}>;
|
|
372
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
373
|
+
}, z.core.$strict>>;
|
|
374
|
+
constraints: z.ZodArray<z.ZodObject<{
|
|
375
|
+
constraint_id: z.ZodString;
|
|
376
|
+
display_name: z.ZodString;
|
|
377
|
+
description: z.ZodString;
|
|
378
|
+
rule: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
379
|
+
severity: z.ZodEnum<{
|
|
380
|
+
hard: "hard";
|
|
381
|
+
soft: "soft";
|
|
382
|
+
}>;
|
|
383
|
+
on_violation: z.ZodEnum<{
|
|
384
|
+
warn: "warn";
|
|
385
|
+
block: "block";
|
|
386
|
+
log: "log";
|
|
387
|
+
}>;
|
|
388
|
+
scope: z.ZodEnum<{
|
|
389
|
+
custom: "custom";
|
|
390
|
+
builtin: "builtin";
|
|
391
|
+
}>;
|
|
392
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
393
|
+
}, z.core.$strict>>;
|
|
394
|
+
hint: z.ZodString;
|
|
395
|
+
}, z.core.$strict>], "action">;
|
|
132
396
|
}, z.core.$strict>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from'zod';export const IndustryPackOperationInputSchema=z['object']({'action':z['enum'](['scaffold','list','scan','resolve','list_files','read_file','write_file','get','diff','reset','delete_file','create_file','create_dir','copy','move','rename'])['describe']('Action:\x20\x27scaffold\x27\x20=\x20generate\x20a\x20pack\x20template\x20skeleton\x20(requires\x20name);\x20'+'\x27list\x27\x20=\x20list\x20registered\x20packs;\x20\x27scan\x27\x20=\x20scan\x20+\x20register\x20packs\x20under\x20the\x20default\x20directory;\x20'+'\x27resolve\x27\x20=\x20return\x20the\x20industry\x20root\x20directory;\x20\x27list_files\x27\x20=\x20list\x20files\x20under\x20the\x20industry\x20directory;\x20'+'\x27read_file\x27\x20=\x20read\x20a\x20file\x20under\x20the\x20industry\x20directory\x20(path\x20required);\x20'+'\x27write_file\x27\x20=\x20write\x20content\x20to\x20a\x20file\x20under\x20the\x20industry\x20directory\x20(path\x20+\x20content\x20required);\x20'+'\x27get\x27\x20=\x20return\x20registered\x20layer\x20data\x20for\x20an\x20industry\x20(name\x20required;\x20dispute/compliance/supply/rules/playbook);\x20'+'\x27diff\x27\x20=\x20compare\x20registered\x20vs\x20on-disk\x20manifest\x20version/layers\x20(name\x20required);\x20'+'\x27reset\x27\x20=\x20restore\x20a\x20file\x20or\x20entire\x20pack\x20folder\x20to\x20its\x20pristine\x20annotated\x20template\x20(path\x20required).\x20'+'\x27delete_file\x27\x20=\x20delete\x20a\x20file\x20or\x20directory\x20(path\x20required).\x20'+'\x27create_file\x27\x20=\x20create\x20an\x20empty\x20file\x20(path\x20required;\x20content\x20optional).\x20'+'\x27create_dir\x27\x20=\x20create\x20a\x20directory\x20recursively\x20(path\x20required).\x20'+'\x27copy\x27\x20=\x20copy\x20a\x20file\x20or\x20directory\x20(from\x20+\x20to\x20required).\x20'+'\x27move\x27\x20/\x20\x27rename\x27\x20=\x20move\x20or\x20rename\x20a\x20file\x20or\x20directory\x20(from\x20+\x20to\x20required).'),'name':z['string']()['optional']()['describe']('Industry\x20name\x20(lowercase\x20snake_case,\x20e.g.\x20\x27life_service\x27);\x20required\x20for\x20scaffold\x20and\x20get.'),'path':z['string']()['optional']()['describe']('Path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20read_file,\x20write_file,\x20reset,\x20create_file,\x20create_dir).'),'content':z['string']()['optional']()['describe']('Text\x20content\x20to\x20write\x20(required\x20for\x20write_file;\x20optional\x20for\x20create_file).'),'from':z['string']()['optional']()['describe']('Source\x20path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20copy/move/rename).'),'to':z['string']()['optional']()['describe']('Destination\x20path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20copy/move/rename).')})['strict']();export const IndustryPackOperationOutputSchema=z['object']({'result':z['discriminatedUnion']('action',[z['object']({'action':z['literal']('scaffold'),'ok':z['boolean']()['describe']('Whether\x20the\x20skeleton\x20was\x20created.'),'dir':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20pack\x20directory.'),'files':z['array'](z['string']())['describe']('Created\x20file\x20paths\x20(relative\x20to\x20dir).'),'errors':z['array'](z['string']())['describe']('Validation/creation\x20errors\x20(empty\x20=\x20ok).')}),z['object']({'action':z['literal']('list'),'packs':z['array'](z['object']({'name':z['string'](),'version':z['string'](),'layers':z['array'](z['string']()),'registered_at':z['number']()}))['describe']('Currently\x20registered\x20packs.')}),z['object']({'action':z['literal']('scan'),'results':z['array'](z['object']({'ok':z['boolean'](),'errors':z['array'](z['string']()),'registered':z['array'](z['string']())}))['describe']('One\x20registration\x20result\x20per\x20scanned\x20pack\x20directory.')}),z['object']({'action':z['literal']('resolve'),'dir':z['string']()['describe']('Absolute\x20industry\x20root\x20directory.')}),z['object']({'action':z['literal']('list_files'),'dir':z['string']()['describe']('Absolute\x20industry\x20root\x20directory.'),'files':z['array'](z['object']({'path':z['string']()['describe']('Path\x20relative\x20to\x20the\x20industry\x20root.'),'is_dir':z['boolean'](),'size':z['number']()['describe']('File\x20size\x20in\x20bytes\x20(0\x20for\x20directories).'),'mtime':z['number']()['describe']('Last-modified\x20time\x20(epoch\x20ms).')}))['describe']('Files\x20under\x20the\x20industry\x20root.')}),z['object']({'action':z['literal']('read_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20read\x20file.'),'content':z['string']()['describe']('File\x20content\x20(text).')}),z['object']({'action':z['literal']('write_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20written\x20file.'),'ok':z['boolean']()['describe']('Whether\x20the\x20file\x20was\x20written.')}),z['object']({'action':z['literal']('get'),'category':z['string']()['describe']('Industry\x20name.'),'dispute':z['unknown']()['optional']()['describe']('Registered\x20dispute\x20rules\x20(if\x20any).'),'compliance':z['unknown']()['optional']()['describe']('Registered\x20compliance\x20rules\x20(if\x20any).'),'supply':z['unknown']()['optional']()['describe']('Registered\x20supply\x20rules\x20(if\x20any).'),'rules':z['unknown']()['optional']()['describe']('Registered\x20declarative\x20industry\x20rules\x20(if\x20any).'),'playbook':z['unknown']()['optional']()['describe']('Registered\x20playbook\x20(if\x20any).')}),z['object']({'action':z['literal']('diff'),'name':z['string']()['describe']('Industry\x20name.'),'registered':z['object']({'version':z['string'](),'layers':z['array'](z['string']()),'registered_at':z['number']()})['nullable']()['describe']('Currently\x20registered\x20metadata.'),'disk':z['object']({'version':z['string'](),'layers':z['array'](z['string']())})['nullable']()['describe']('On-disk\x20manifest\x20metadata.'),'upgradable':z['boolean']()['describe']('Whether\x20the\x20on-disk\x20version\x20differs\x20from\x20registered.'),'layer_diff':z['object']({'added':z['array'](z['string']()),'removed':z['array'](z['string']())})['describe']('Layer\x20difference\x20(disk\x20vs\x20registered).')}),z['object']({'action':z['literal']('reset'),'ok':z['boolean']()['describe']('Whether\x20reset\x20succeeded.'),'layout':z['enum'](['merged','legacy'])['describe']('Layout\x20format\x20that\x20was\x20restored:\x20\x27merged\x27\x20(single\x20pack.json\x20+\x20playbook.md)\x20or\x20\x27legacy\x27\x20(split\x20files).'),'target':z['string']()['describe']('Normalised\x20reset\x20target\x20path\x20(pack\x20name\x20or\x20file).'),'restored_files':z['array'](z['string']())['describe']('Files\x20that\x20were\x20restored\x20to\x20pristine\x20annotated\x20templates.'),'errors':z['array'](z['string']())['describe']('Errors\x20encountered\x20during\x20reset.')}),z['object']({'action':z['literal']('delete_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20deleted\x20file\x20or\x20directory.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('create_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20file.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('create_dir'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20directory.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('copy'),'from':z['string']()['describe']('Absolute\x20source\x20path.'),'to':z['string']()['describe']('Absolute\x20destination\x20path.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('move'),'from':z['string']()['describe']('Absolute\x20source\x20path.'),'to':z['string']()['describe']('Absolute\x20destination\x20path.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('rename'),'from':z['string']()['describe']('Absolute\x20old\x20path.'),'to':z['string']()['describe']('Absolute\x20new\x20path.'),'ok':z['boolean']()})])})['strict']();
|
|
1
|
+
import{z}from'zod';import{MODE_REGISTRY_ACTIONS,ModeRegistryFields,RecommendIndustryResultSchema,ListModesResultSchema,DeriveUserModeResultSchema,EvolveUserModeResultSchema,RegisterUserModeResultSchema,UnregisterUserModeResultSchema,RegisterCustomMetricResultSchema,RegisterCustomConstraintResultSchema,ListMetricsConstraintsResultSchema}from'./modes.js';export const IndustryPackOperationInputSchema=z['object']({'action':z['enum'](['scaffold','list','scan','resolve','list_files','read_file','write_file','get','diff','reset','delete_file','create_file','create_dir','copy','move','rename',...MODE_REGISTRY_ACTIONS])['describe']('Action:\x20\x27scaffold\x27\x20=\x20generate\x20a\x20pack\x20template\x20skeleton\x20(requires\x20name);\x20'+'\x27list\x27\x20=\x20list\x20registered\x20packs;\x20\x27scan\x27\x20=\x20scan\x20+\x20register\x20packs\x20under\x20the\x20default\x20directory;\x20'+'\x27resolve\x27\x20=\x20return\x20the\x20industry\x20root\x20directory;\x20\x27list_files\x27\x20=\x20list\x20files\x20under\x20the\x20industry\x20directory;\x20'+'\x27read_file\x27\x20=\x20read\x20a\x20file\x20under\x20the\x20industry\x20directory\x20(path\x20required);\x20'+'\x27write_file\x27\x20=\x20write\x20content\x20to\x20a\x20file\x20under\x20the\x20industry\x20directory\x20(path\x20+\x20content\x20required);\x20'+'\x27get\x27\x20=\x20return\x20registered\x20layer\x20data\x20for\x20an\x20industry\x20(name\x20required;\x20dispute/compliance/supply/rules/playbook);\x20'+'\x27diff\x27\x20=\x20compare\x20registered\x20vs\x20on-disk\x20manifest\x20version/layers\x20(name\x20required);\x20'+'\x27reset\x27\x20=\x20restore\x20a\x20file\x20or\x20entire\x20pack\x20folder\x20to\x20its\x20pristine\x20annotated\x20template\x20(path\x20required).\x20'+'\x27delete_file\x27\x20=\x20delete\x20a\x20file\x20or\x20directory\x20(path\x20required).\x20'+'\x27create_file\x27\x20=\x20create\x20an\x20empty\x20file\x20(path\x20required;\x20content\x20optional).\x20'+'\x27create_dir\x27\x20=\x20create\x20a\x20directory\x20recursively\x20(path\x20required).\x20'+'\x27copy\x27\x20=\x20copy\x20a\x20file\x20or\x20directory\x20(from\x20+\x20to\x20required).\x20'+'\x27move\x27\x20/\x20\x27rename\x27\x20=\x20move\x20or\x20rename\x20a\x20file\x20or\x20directory\x20(from\x20+\x20to\x20required).\x20'+'Mode\x20registry\x20(industry/scenario\x20configuration):\x20\x27recommend_industry\x27\x20=\x20business\x20intent\x20→\x20top-3\x20'+'similar\x20industries\x20+\x20reference\x20examples;\x20\x27list_modes\x27\x20=\x20builtin\x20+\x20custom\x20modes;\x20\x27derive_user_mode\x27\x20=\x20'+'derive\x20a\x20custom\x20mode\x20from\x20a\x20builtin;\x20\x27evolve_user_mode\x27\x20=\x20iterate\x20an\x20existing\x20custom\x20mode;\x20'+'\x27register_user_mode\x27\x20=\x20register\x20a\x20fully\x20custom\x20mode;\x20\x27unregister_user_mode\x27\x20=\x20delete\x20a\x20custom\x20mode;\x20'+'\x27register_custom_metric\x27\x20/\x20\x27register_custom_constraint\x27\x20=\x20register\x20global\x20evaluation\x20metric/constraint;\x20'+'\x27list_metrics_constraints\x27\x20=\x20list\x20metrics\x20+\x20constraints\x20(filterable).'),'name':z['string']()['optional']()['describe']('Industry\x20name\x20(lowercase\x20snake_case,\x20e.g.\x20\x27life_service\x27);\x20required\x20for\x20scaffold\x20and\x20get.'),'path':z['string']()['optional']()['describe']('Path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20read_file,\x20write_file,\x20reset,\x20create_file,\x20create_dir).'),'content':z['string']()['optional']()['describe']('Text\x20content\x20to\x20write\x20(required\x20for\x20write_file;\x20optional\x20for\x20create_file).'),'from':z['string']()['optional']()['describe']('Source\x20path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20copy/move/rename).'),'to':z['string']()['optional']()['describe']('Destination\x20path\x20relative\x20to\x20the\x20industry\x20root\x20(required\x20for\x20copy/move/rename).'),...ModeRegistryFields})['strict']();export const IndustryPackOperationOutputSchema=z['object']({'result':z['discriminatedUnion']('action',[z['object']({'action':z['literal']('scaffold'),'ok':z['boolean']()['describe']('Whether\x20the\x20skeleton\x20was\x20created.'),'dir':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20pack\x20directory.'),'files':z['array'](z['string']())['describe']('Created\x20file\x20paths\x20(relative\x20to\x20dir).'),'errors':z['array'](z['string']())['describe']('Validation/creation\x20errors\x20(empty\x20=\x20ok).')}),z['object']({'action':z['literal']('list'),'packs':z['array'](z['object']({'name':z['string'](),'version':z['string'](),'layers':z['array'](z['string']()),'registered_at':z['number']()}))['describe']('Currently\x20registered\x20packs.')}),z['object']({'action':z['literal']('scan'),'results':z['array'](z['object']({'ok':z['boolean'](),'errors':z['array'](z['string']()),'registered':z['array'](z['string']())}))['describe']('One\x20registration\x20result\x20per\x20scanned\x20pack\x20directory.')}),z['object']({'action':z['literal']('resolve'),'dir':z['string']()['describe']('Absolute\x20industry\x20root\x20directory.')}),z['object']({'action':z['literal']('list_files'),'dir':z['string']()['describe']('Absolute\x20industry\x20root\x20directory.'),'files':z['array'](z['object']({'path':z['string']()['describe']('Path\x20relative\x20to\x20the\x20industry\x20root.'),'is_dir':z['boolean'](),'size':z['number']()['describe']('File\x20size\x20in\x20bytes\x20(0\x20for\x20directories).'),'mtime':z['number']()['describe']('Last-modified\x20time\x20(epoch\x20ms).')}))['describe']('Files\x20under\x20the\x20industry\x20root.')}),z['object']({'action':z['literal']('read_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20read\x20file.'),'content':z['string']()['describe']('File\x20content\x20(text).')}),z['object']({'action':z['literal']('write_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20written\x20file.'),'ok':z['boolean']()['describe']('Whether\x20the\x20file\x20was\x20written.')}),z['object']({'action':z['literal']('get'),'category':z['string']()['describe']('Industry\x20name.'),'dispute':z['unknown']()['optional']()['describe']('Registered\x20dispute\x20rules\x20(if\x20any).'),'compliance':z['unknown']()['optional']()['describe']('Registered\x20compliance\x20rules\x20(if\x20any).'),'supply':z['unknown']()['optional']()['describe']('Registered\x20supply\x20rules\x20(if\x20any).'),'rules':z['unknown']()['optional']()['describe']('Registered\x20declarative\x20industry\x20rules\x20(if\x20any).'),'playbook':z['unknown']()['optional']()['describe']('Registered\x20playbook\x20(if\x20any).')}),z['object']({'action':z['literal']('diff'),'name':z['string']()['describe']('Industry\x20name.'),'registered':z['object']({'version':z['string'](),'layers':z['array'](z['string']()),'registered_at':z['number']()})['nullable']()['describe']('Currently\x20registered\x20metadata.'),'disk':z['object']({'version':z['string'](),'layers':z['array'](z['string']())})['nullable']()['describe']('On-disk\x20manifest\x20metadata.'),'upgradable':z['boolean']()['describe']('Whether\x20the\x20on-disk\x20version\x20differs\x20from\x20registered.'),'layer_diff':z['object']({'added':z['array'](z['string']()),'removed':z['array'](z['string']())})['describe']('Layer\x20difference\x20(disk\x20vs\x20registered).')}),z['object']({'action':z['literal']('reset'),'ok':z['boolean']()['describe']('Whether\x20reset\x20succeeded.'),'layout':z['enum'](['merged','legacy'])['describe']('Layout\x20format\x20that\x20was\x20restored:\x20\x27merged\x27\x20(single\x20pack.json\x20+\x20playbook.md)\x20or\x20\x27legacy\x27\x20(split\x20files).'),'target':z['string']()['describe']('Normalised\x20reset\x20target\x20path\x20(pack\x20name\x20or\x20file).'),'restored_files':z['array'](z['string']())['describe']('Files\x20that\x20were\x20restored\x20to\x20pristine\x20annotated\x20templates.'),'errors':z['array'](z['string']())['describe']('Errors\x20encountered\x20during\x20reset.')}),z['object']({'action':z['literal']('delete_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20deleted\x20file\x20or\x20directory.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('create_file'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20file.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('create_dir'),'path':z['string']()['describe']('Absolute\x20path\x20of\x20the\x20created\x20directory.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('copy'),'from':z['string']()['describe']('Absolute\x20source\x20path.'),'to':z['string']()['describe']('Absolute\x20destination\x20path.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('move'),'from':z['string']()['describe']('Absolute\x20source\x20path.'),'to':z['string']()['describe']('Absolute\x20destination\x20path.'),'ok':z['boolean']()}),z['object']({'action':z['literal']('rename'),'from':z['string']()['describe']('Absolute\x20old\x20path.'),'to':z['string']()['describe']('Absolute\x20new\x20path.'),'ok':z['boolean']()}),...[RecommendIndustryResultSchema,ListModesResultSchema,DeriveUserModeResultSchema,EvolveUserModeResultSchema,RegisterUserModeResultSchema,UnregisterUserModeResultSchema,RegisterCustomMetricResultSchema,RegisterCustomConstraintResultSchema,ListMetricsConstraintsResultSchema]])})['strict']();
|
|
@@ -0,0 +1,268 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export declare const MODE_REGISTRY_ACTIONS: readonly ["recommend_industry", "list_modes", "derive_user_mode", "evolve_user_mode", "register_user_mode", "unregister_user_mode", "register_custom_metric", "register_custom_constraint", "list_metrics_constraints"];
|
|
3
|
+
export declare const ModeRegistryFields: {
|
|
4
|
+
readonly intent: z.ZodOptional<z.ZodString>;
|
|
5
|
+
readonly mode_source: z.ZodOptional<z.ZodString>;
|
|
6
|
+
readonly mode_name: z.ZodOptional<z.ZodString>;
|
|
7
|
+
readonly mode_display_name: z.ZodOptional<z.ZodString>;
|
|
8
|
+
readonly mode_changes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
9
|
+
readonly mode_change_description: z.ZodOptional<z.ZodString>;
|
|
10
|
+
readonly mode_bump_version: z.ZodOptional<z.ZodBoolean>;
|
|
11
|
+
readonly metric_id: z.ZodOptional<z.ZodString>;
|
|
12
|
+
readonly metric_display_name: z.ZodOptional<z.ZodString>;
|
|
13
|
+
readonly metric_description: z.ZodOptional<z.ZodString>;
|
|
14
|
+
readonly metric_type: z.ZodOptional<z.ZodEnum<{
|
|
15
|
+
risk: "risk";
|
|
16
|
+
benefit: "benefit";
|
|
17
|
+
}>>;
|
|
18
|
+
readonly metric_scale: z.ZodOptional<z.ZodEnum<{
|
|
19
|
+
level: "level";
|
|
20
|
+
numeric: "numeric";
|
|
21
|
+
percentage: "percentage";
|
|
22
|
+
}>>;
|
|
23
|
+
readonly metric_weight: z.ZodOptional<z.ZodNumber>;
|
|
24
|
+
readonly constraint_id: z.ZodOptional<z.ZodString>;
|
|
25
|
+
readonly constraint_display_name: z.ZodOptional<z.ZodString>;
|
|
26
|
+
readonly constraint_description: z.ZodOptional<z.ZodString>;
|
|
27
|
+
readonly constraint_rule: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
28
|
+
type: z.ZodLiteral<"capability_required">;
|
|
29
|
+
capability_id: z.ZodString;
|
|
30
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
31
|
+
type: z.ZodLiteral<"capability_forbidden">;
|
|
32
|
+
capability_id: z.ZodString;
|
|
33
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
34
|
+
type: z.ZodLiteral<"numeric_limit">;
|
|
35
|
+
field: z.ZodString;
|
|
36
|
+
max: z.ZodOptional<z.ZodNumber>;
|
|
37
|
+
min: z.ZodOptional<z.ZodNumber>;
|
|
38
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
39
|
+
type: z.ZodLiteral<"condition_required">;
|
|
40
|
+
condition: z.ZodString;
|
|
41
|
+
ai_evaluated: z.ZodLiteral<true>;
|
|
42
|
+
}, z.core.$strict>], "type">>;
|
|
43
|
+
readonly constraint_severity: z.ZodOptional<z.ZodEnum<{
|
|
44
|
+
hard: "hard";
|
|
45
|
+
soft: "soft";
|
|
46
|
+
}>>;
|
|
47
|
+
readonly constraint_on_violation: z.ZodOptional<z.ZodEnum<{
|
|
48
|
+
warn: "warn";
|
|
49
|
+
block: "block";
|
|
50
|
+
log: "log";
|
|
51
|
+
}>>;
|
|
52
|
+
readonly metric_type_filter: z.ZodOptional<z.ZodEnum<{
|
|
53
|
+
risk: "risk";
|
|
54
|
+
benefit: "benefit";
|
|
55
|
+
}>>;
|
|
56
|
+
readonly scope_filter: z.ZodOptional<z.ZodEnum<{
|
|
57
|
+
custom: "custom";
|
|
58
|
+
builtin: "builtin";
|
|
59
|
+
}>>;
|
|
60
|
+
};
|
|
61
|
+
export declare const RecommendIndustryResultSchema: z.ZodObject<{
|
|
62
|
+
action: z.ZodLiteral<"recommend_industry">;
|
|
63
|
+
intent: z.ZodString;
|
|
64
|
+
inferred_traits: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
65
|
+
inference_confidence: z.ZodNumber;
|
|
66
|
+
matched_keywords: z.ZodArray<z.ZodString>;
|
|
67
|
+
recommendations: z.ZodArray<z.ZodObject<{
|
|
68
|
+
industry: z.ZodString;
|
|
69
|
+
similarity: z.ZodNumber;
|
|
70
|
+
matched_traits: z.ZodArray<z.ZodString>;
|
|
71
|
+
reference_examples: z.ZodArray<z.ZodObject<{
|
|
72
|
+
file: z.ZodString;
|
|
73
|
+
title: z.ZodString;
|
|
74
|
+
operation_type: z.ZodString;
|
|
75
|
+
verified: z.ZodBoolean;
|
|
76
|
+
}, z.core.$strict>>;
|
|
77
|
+
}, z.core.$strict>>;
|
|
78
|
+
hint: z.ZodString;
|
|
79
|
+
}, z.core.$strict>;
|
|
80
|
+
export declare const ListModesResultSchema: z.ZodObject<{
|
|
81
|
+
action: z.ZodLiteral<"list_modes">;
|
|
82
|
+
builtin_modes: z.ZodArray<z.ZodObject<{
|
|
83
|
+
name: z.ZodString;
|
|
84
|
+
display_name: z.ZodString;
|
|
85
|
+
version: z.ZodString;
|
|
86
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
87
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
88
|
+
key_risk: z.ZodString;
|
|
89
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
90
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
91
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
92
|
+
version: z.ZodString;
|
|
93
|
+
changed_at: z.ZodNumber;
|
|
94
|
+
changes: z.ZodArray<z.ZodString>;
|
|
95
|
+
}, z.core.$strict>>>;
|
|
96
|
+
}, z.core.$strict>>;
|
|
97
|
+
user_modes: z.ZodArray<z.ZodObject<{
|
|
98
|
+
name: z.ZodString;
|
|
99
|
+
display_name: z.ZodString;
|
|
100
|
+
version: z.ZodString;
|
|
101
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
102
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
103
|
+
key_risk: z.ZodString;
|
|
104
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
105
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
106
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
107
|
+
version: z.ZodString;
|
|
108
|
+
changed_at: z.ZodNumber;
|
|
109
|
+
changes: z.ZodArray<z.ZodString>;
|
|
110
|
+
}, z.core.$strict>>>;
|
|
111
|
+
}, z.core.$strict>>;
|
|
112
|
+
owner: z.ZodString;
|
|
113
|
+
hint: z.ZodString;
|
|
114
|
+
}, z.core.$strict>;
|
|
115
|
+
export declare const DeriveUserModeResultSchema: z.ZodObject<{
|
|
116
|
+
action: z.ZodLiteral<"derive_user_mode">;
|
|
117
|
+
mode: z.ZodObject<{
|
|
118
|
+
name: z.ZodString;
|
|
119
|
+
display_name: z.ZodString;
|
|
120
|
+
version: z.ZodString;
|
|
121
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
122
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
123
|
+
key_risk: z.ZodString;
|
|
124
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
125
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
126
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
127
|
+
version: z.ZodString;
|
|
128
|
+
changed_at: z.ZodNumber;
|
|
129
|
+
changes: z.ZodArray<z.ZodString>;
|
|
130
|
+
}, z.core.$strict>>>;
|
|
131
|
+
}, z.core.$strict>;
|
|
132
|
+
hint: z.ZodString;
|
|
133
|
+
}, z.core.$strict>;
|
|
134
|
+
export declare const EvolveUserModeResultSchema: z.ZodObject<{
|
|
135
|
+
action: z.ZodLiteral<"evolve_user_mode">;
|
|
136
|
+
mode: z.ZodObject<{
|
|
137
|
+
name: z.ZodString;
|
|
138
|
+
display_name: z.ZodString;
|
|
139
|
+
version: z.ZodString;
|
|
140
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
141
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
142
|
+
key_risk: z.ZodString;
|
|
143
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
144
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
145
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
146
|
+
version: z.ZodString;
|
|
147
|
+
changed_at: z.ZodNumber;
|
|
148
|
+
changes: z.ZodArray<z.ZodString>;
|
|
149
|
+
}, z.core.$strict>>>;
|
|
150
|
+
}, z.core.$strict>;
|
|
151
|
+
hint: z.ZodString;
|
|
152
|
+
}, z.core.$strict>;
|
|
153
|
+
export declare const RegisterUserModeResultSchema: z.ZodObject<{
|
|
154
|
+
action: z.ZodLiteral<"register_user_mode">;
|
|
155
|
+
mode: z.ZodObject<{
|
|
156
|
+
name: z.ZodString;
|
|
157
|
+
display_name: z.ZodString;
|
|
158
|
+
version: z.ZodString;
|
|
159
|
+
derived_from: z.ZodNullable<z.ZodString>;
|
|
160
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
161
|
+
key_risk: z.ZodString;
|
|
162
|
+
machine_nodes: z.ZodArray<z.ZodString>;
|
|
163
|
+
similar_industries: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
164
|
+
evolution_history: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
165
|
+
version: z.ZodString;
|
|
166
|
+
changed_at: z.ZodNumber;
|
|
167
|
+
changes: z.ZodArray<z.ZodString>;
|
|
168
|
+
}, z.core.$strict>>>;
|
|
169
|
+
}, z.core.$strict>;
|
|
170
|
+
hint: z.ZodString;
|
|
171
|
+
}, z.core.$strict>;
|
|
172
|
+
export declare const UnregisterUserModeResultSchema: z.ZodObject<{
|
|
173
|
+
action: z.ZodLiteral<"unregister_user_mode">;
|
|
174
|
+
removed: z.ZodLiteral<true>;
|
|
175
|
+
mode_name: z.ZodString;
|
|
176
|
+
}, z.core.$strict>;
|
|
177
|
+
export declare const RegisterCustomMetricResultSchema: z.ZodObject<{
|
|
178
|
+
action: z.ZodLiteral<"register_custom_metric">;
|
|
179
|
+
metric: z.ZodObject<{
|
|
180
|
+
metric_id: z.ZodString;
|
|
181
|
+
display_name: z.ZodString;
|
|
182
|
+
description: z.ZodString;
|
|
183
|
+
type: z.ZodEnum<{
|
|
184
|
+
risk: "risk";
|
|
185
|
+
benefit: "benefit";
|
|
186
|
+
}>;
|
|
187
|
+
scale: z.ZodEnum<{
|
|
188
|
+
level: "level";
|
|
189
|
+
numeric: "numeric";
|
|
190
|
+
percentage: "percentage";
|
|
191
|
+
}>;
|
|
192
|
+
weight: z.ZodNumber;
|
|
193
|
+
scope: z.ZodEnum<{
|
|
194
|
+
custom: "custom";
|
|
195
|
+
builtin: "builtin";
|
|
196
|
+
}>;
|
|
197
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
198
|
+
}, z.core.$strict>;
|
|
199
|
+
hint: z.ZodString;
|
|
200
|
+
}, z.core.$strict>;
|
|
201
|
+
export declare const RegisterCustomConstraintResultSchema: z.ZodObject<{
|
|
202
|
+
action: z.ZodLiteral<"register_custom_constraint">;
|
|
203
|
+
constraint: z.ZodObject<{
|
|
204
|
+
constraint_id: z.ZodString;
|
|
205
|
+
display_name: z.ZodString;
|
|
206
|
+
description: z.ZodString;
|
|
207
|
+
rule: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
208
|
+
severity: z.ZodEnum<{
|
|
209
|
+
hard: "hard";
|
|
210
|
+
soft: "soft";
|
|
211
|
+
}>;
|
|
212
|
+
on_violation: z.ZodEnum<{
|
|
213
|
+
warn: "warn";
|
|
214
|
+
block: "block";
|
|
215
|
+
log: "log";
|
|
216
|
+
}>;
|
|
217
|
+
scope: z.ZodEnum<{
|
|
218
|
+
custom: "custom";
|
|
219
|
+
builtin: "builtin";
|
|
220
|
+
}>;
|
|
221
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
222
|
+
}, z.core.$strict>;
|
|
223
|
+
hint: z.ZodString;
|
|
224
|
+
}, z.core.$strict>;
|
|
225
|
+
export declare const ListMetricsConstraintsResultSchema: z.ZodObject<{
|
|
226
|
+
action: z.ZodLiteral<"list_metrics_constraints">;
|
|
227
|
+
metrics: z.ZodArray<z.ZodObject<{
|
|
228
|
+
metric_id: z.ZodString;
|
|
229
|
+
display_name: z.ZodString;
|
|
230
|
+
description: z.ZodString;
|
|
231
|
+
type: z.ZodEnum<{
|
|
232
|
+
risk: "risk";
|
|
233
|
+
benefit: "benefit";
|
|
234
|
+
}>;
|
|
235
|
+
scale: z.ZodEnum<{
|
|
236
|
+
level: "level";
|
|
237
|
+
numeric: "numeric";
|
|
238
|
+
percentage: "percentage";
|
|
239
|
+
}>;
|
|
240
|
+
weight: z.ZodNumber;
|
|
241
|
+
scope: z.ZodEnum<{
|
|
242
|
+
custom: "custom";
|
|
243
|
+
builtin: "builtin";
|
|
244
|
+
}>;
|
|
245
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
246
|
+
}, z.core.$strict>>;
|
|
247
|
+
constraints: z.ZodArray<z.ZodObject<{
|
|
248
|
+
constraint_id: z.ZodString;
|
|
249
|
+
display_name: z.ZodString;
|
|
250
|
+
description: z.ZodString;
|
|
251
|
+
rule: z.ZodRecord<z.ZodString, z.ZodUnknown>;
|
|
252
|
+
severity: z.ZodEnum<{
|
|
253
|
+
hard: "hard";
|
|
254
|
+
soft: "soft";
|
|
255
|
+
}>;
|
|
256
|
+
on_violation: z.ZodEnum<{
|
|
257
|
+
warn: "warn";
|
|
258
|
+
block: "block";
|
|
259
|
+
log: "log";
|
|
260
|
+
}>;
|
|
261
|
+
scope: z.ZodEnum<{
|
|
262
|
+
custom: "custom";
|
|
263
|
+
builtin: "builtin";
|
|
264
|
+
}>;
|
|
265
|
+
owner: z.ZodOptional<z.ZodString>;
|
|
266
|
+
}, z.core.$strict>>;
|
|
267
|
+
hint: z.ZodString;
|
|
268
|
+
}, z.core.$strict>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{z}from'zod';export const MODE_REGISTRY_ACTIONS=['recommend_industry','list_modes','derive_user_mode','evolve_user_mode','register_user_mode','unregister_user_mode','register_custom_metric','register_custom_constraint','list_metrics_constraints'];export const ModeRegistryFields={'intent':z['string']()['max'](0x7d0)['optional']()['describe']('Business\x20intent\x20text\x20for\x20recommend_industry\x20(e.g.\x20\x27I\x20rent\x20cameras\x20to\x20photographers\x20'+'with\x20deposit\x20and\x20damage\x20inspection\x27).\x20Falls\x20back\x20to\x20project_description\x20/\x20project_name\x20when\x20omitted.'),'mode_source':z['string']()['optional']()['describe']('Source\x20builtin\x20mode\x20name\x20for\x20derive_user_mode\x20(e.g.\x20\x27freelance\x27).\x20Call\x20list_modes\x20to\x20see\x20available\x20modes.'),'mode_name':z['string']()['max'](0x64)['optional']()['describe']('Mode\x20name\x20for\x20derive_user_mode\x20(new\x20mode\x20name),\x20evolve_user_mode\x20/\x20unregister_user_mode\x20(existing\x20'+'custom\x20mode),\x20register_user_mode\x20(new\x20mode\x20name).\x20Must\x20NOT\x20conflict\x20with\x20builtin\x20mode\x20names.'),'mode_display_name':z['string']()['max'](0xc8)['optional']()['describe']('Display\x20name\x20for\x20derive_user_mode\x20/\x20register_user_mode.\x20Defaults\x20to\x20mode_name.'),'mode_changes':z['record'](z['string'](),z['unknown']())['optional']()['describe']('Mode\x20field\x20overrides\x20for\x20derive_user_mode\x20/\x20evolve_user_mode\x20/\x20register_user_mode.\x20'+'For\x20register_user_mode,\x20REQUIRED\x20fields:\x20machine_shape\x20(non-empty\x20array\x20of\x20{name,\x20role})\x20and\x20key_risk\x20(string).\x20'+'Common\x20overrides:\x20machine_shape\x20(array\x20of\x20{name:string,\x20role:string}),\x20config_overrides\x20(per-object\x20config),\x20'+'allocator,\x20guards,\x20build_notes,\x20risk_appetite.\x20'+'R-M1-11\x20ENFORCED:\x20machine_shape\x20node\x20names\x20must\x20NOT\x20contain\x20dispute/refund/arb\x20terms.'),'mode_change_description':z['string']()['max'](0x1f4)['optional']()['describe']('Change\x20description\x20for\x20evolve_user_mode\x20(recorded\x20in\x20evolution\x20history).'),'mode_bump_version':z['boolean']()['optional']()['describe']('Whether\x20evolve_user_mode\x20bumps\x20the\x20patch\x20version\x20(default\x20true:\x20v1.0\x20→\x20v1.1).'),'metric_id':z['string']()['max'](0x64)['optional']()['describe']('Unique\x20metric\x20ID\x20for\x20register_custom_metric\x20(e.g.\x20\x27seasonality_risk\x27).'),'metric_display_name':z['string']()['max'](0xc8)['optional']()['describe']('Display\x20name\x20for\x20register_custom_metric.'),'metric_description':z['string']()['max'](0x3e8)['optional']()['describe']('Description\x20for\x20register_custom_metric.'),'metric_type':z['enum'](['risk','benefit'])['optional']()['describe']('Metric\x20type\x20for\x20register_custom_metric:\x20\x27risk\x27\x20(negative)\x20or\x20\x27benefit\x27\x20(positive).'),'metric_scale':z['enum'](['level','numeric','percentage'])['optional']()['describe']('Metric\x20scale\x20for\x20register_custom_metric:\x20\x27level\x27\x20(high/medium/low),\x20\x27numeric\x27,\x20or\x20\x27percentage\x27.'),'metric_weight':z['number']()['min'](0x0)['max'](0xa)['optional']()['describe']('Metric\x20weight\x20for\x20register_custom_metric\x20(default\x201.0).'),'constraint_id':z['string']()['max'](0x64)['optional']()['describe']('Unique\x20constraint\x20ID\x20for\x20register_custom_constraint.'),'constraint_display_name':z['string']()['max'](0xc8)['optional']()['describe']('Display\x20name\x20for\x20register_custom_constraint.'),'constraint_description':z['string']()['max'](0x3e8)['optional']()['describe']('Description\x20for\x20register_custom_constraint.'),'constraint_rule':z['discriminatedUnion']('type',[z['object']({'type':z['literal']('capability_required'),'capability_id':z['string']()})['strict'](),z['object']({'type':z['literal']('capability_forbidden'),'capability_id':z['string']()})['strict'](),z['object']({'type':z['literal']('numeric_limit'),'field':z['string'](),'max':z['number']()['optional'](),'min':z['number']()['optional']()})['strict'](),z['object']({'type':z['literal']('condition_required'),'condition':z['string'](),'ai_evaluated':z['literal'](!![])})['strict']()])['optional']()['describe']('Constraint\x20rule\x20for\x20register_custom_constraint.\x204\x20types:\x20'+'capability_required/capability_forbidden\x20(capability_id),\x20numeric_limit\x20(field\x20+\x20max/min),\x20'+'condition_required\x20(natural-language\x20condition,\x20AI-evaluated).'),'constraint_severity':z['enum'](['hard','soft'])['optional']()['describe']('Constraint\x20severity\x20for\x20register_custom_constraint:\x20\x27hard\x27\x20blocks\x20applyTemplate\x20on\x20violation;\x20\x27soft\x27\x20only\x20warns\x20(default\x20\x27soft\x27).'),'constraint_on_violation':z['enum'](['block','warn','log'])['optional']()['describe']('Violation\x20action\x20for\x20register_custom_constraint\x20(default\x20\x27warn\x27).'),'metric_type_filter':z['enum'](['risk','benefit'])['optional']()['describe']('Filter\x20list_metrics_constraints\x20by\x20metric\x20type.'),'scope_filter':z['enum'](['builtin','custom'])['optional']()['describe']('Filter\x20list_metrics_constraints\x20by\x20scope\x20(builtin\x20or\x20custom).')};const RecommendedIndustryItemSchema=z['object']({'industry':z['string']()['describe']('Recommended\x20builtin\x20industry\x20mode\x20name.'),'similarity':z['number']()['describe']('Trait\x20similarity\x200-1\x20(10-dim\x20industry\x20trait\x20match).'),'matched_traits':z['array'](z['string']())['describe']('Trait\x20dimensions\x20that\x20matched.'),'reference_examples':z['array'](z['object']({'file':z['string']()['describe']('Example\x20file\x20name\x20(fetch\x20via\x20schema_query\x20search_examples).'),'title':z['string'](),'operation_type':z['string'](),'verified':z['boolean']()})['strict']())['describe']('Verified\x20reference\x20examples\x20for\x20this\x20industry\x20(top\x203).')})['strict']();export const RecommendIndustryResultSchema=z['object']({'action':z['literal']('recommend_industry'),'intent':z['string']()['describe']('The\x20intent\x20text\x20used\x20for\x20inference.'),'inferred_traits':z['record'](z['string'](),z['unknown']())['describe']('10-dim\x20industry\x20traits\x20inferred\x20from\x20intent.'),'inference_confidence':z['number']()['describe']('Inference\x20confidence\x200-1\x20(matched\x20trait\x20count\x20/\x2010).'),'matched_keywords':z['array'](z['string']())['describe']('Keywords\x20that\x20triggered\x20trait\x20inference.'),'recommendations':z['array'](RecommendedIndustryItemSchema)['describe']('Top-3\x20similar\x20industries\x20+\x20reference\x20examples.'),'hint':z['string']()['describe']('How\x20to\x20apply\x20the\x20recommendation\x20(pass\x20the\x20industry\x20to\x20analyze_intent\x20/\x20merchant_guide\x20via\x20project_industry).')})['strict']();const ModeSummarySchema=z['object']({'name':z['string'](),'display_name':z['string'](),'version':z['string'](),'derived_from':z['string']()['nullable']()['describe']('Source\x20builtin\x20mode\x20(derive_user_mode)\x20or\x20null.'),'owner':z['string']()['optional']()['describe']('Mode\x20owner\x20(custom\x20modes\x20only).'),'key_risk':z['string'](),'machine_nodes':z['array'](z['string']())['describe']('Machine\x20shape\x20node\x20names.'),'similar_industries':z['array'](z['string']())['optional'](),'evolution_history':z['array'](z['object']({'version':z['string'](),'changed_at':z['number'](),'changes':z['array'](z['string']())})['strict']())['optional']()})['strict']();export const ListModesResultSchema=z['object']({'action':z['literal']('list_modes'),'builtin_modes':z['array'](ModeSummarySchema)['describe']('Builtin\x20industry\x20modes\x20(use\x20name\x20as\x20project_industry).'),'user_modes':z['array'](ModeSummarySchema)['describe']('Caller\x27s\x20custom\x20modes\x20(derive/evolve/register).'),'owner':z['string']()['describe']('Owner\x20key\x20for\x20custom\x20modes\x20(local\x20single-user).'),'hint':z['string']()})['strict']();export const DeriveUserModeResultSchema=z['object']({'action':z['literal']('derive_user_mode'),'mode':ModeSummarySchema['describe']('The\x20derived\x20(and\x20registered)\x20custom\x20mode.'),'hint':z['string']()})['strict']();export const EvolveUserModeResultSchema=z['object']({'action':z['literal']('evolve_user_mode'),'mode':ModeSummarySchema['describe']('The\x20evolved\x20custom\x20mode\x20(version\x20bumped).'),'hint':z['string']()})['strict']();export const RegisterUserModeResultSchema=z['object']({'action':z['literal']('register_user_mode'),'mode':ModeSummarySchema['describe']('The\x20registered\x20fully-custom\x20mode.'),'hint':z['string']()})['strict']();export const UnregisterUserModeResultSchema=z['object']({'action':z['literal']('unregister_user_mode'),'removed':z['literal'](!![]),'mode_name':z['string']()})['strict']();const MetricInfoSchema=z['object']({'metric_id':z['string'](),'display_name':z['string'](),'description':z['string'](),'type':z['enum'](['risk','benefit']),'scale':z['enum'](['level','numeric','percentage']),'weight':z['number'](),'scope':z['enum'](['builtin','custom']),'owner':z['string']()['optional']()})['strict']();export const RegisterCustomMetricResultSchema=z['object']({'action':z['literal']('register_custom_metric'),'metric':MetricInfoSchema['describe']('The\x20registered\x20custom\x20metric\x20(globally\x20effective).'),'hint':z['string']()})['strict']();const ConstraintInfoSchema=z['object']({'constraint_id':z['string'](),'display_name':z['string'](),'description':z['string'](),'rule':z['record'](z['string'](),z['unknown']())['describe']('Constraint\x20rule\x20(4\x20types\x20—\x20see\x20constraint_rule\x20input).'),'severity':z['enum'](['hard','soft']),'on_violation':z['enum'](['block','warn','log']),'scope':z['enum'](['builtin','custom']),'owner':z['string']()['optional']()})['strict']();export const RegisterCustomConstraintResultSchema=z['object']({'action':z['literal']('register_custom_constraint'),'constraint':ConstraintInfoSchema['describe']('The\x20registered\x20custom\x20constraint.'),'hint':z['string']()})['strict']();export const ListMetricsConstraintsResultSchema=z['object']({'action':z['literal']('list_metrics_constraints'),'metrics':z['array'](MetricInfoSchema),'constraints':z['array'](ConstraintInfoSchema),'hint':z['string']()})['strict']();
|