@ftai/dsh-plugin-acn 0.0.0-stage → 0.1.1
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/CHANGELOG.md +90 -0
- package/LICENSE-APACHE +201 -0
- package/LICENSE-MIT +19 -0
- package/README.md +82 -2
- package/README_EN.md +83 -0
- package/cordis.patch.yml +29 -0
- package/docs/acn-compat.md +33 -0
- package/docs/architecture.md +130 -0
- package/docs/assets/acn-claim-reuse.png +0 -0
- package/docs/assets/activity-view.png +0 -0
- package/docs/assets/install-package.png +0 -0
- package/docs/assets/knowledge-model.png +0 -0
- package/docs/assets/knowledge-view.png +0 -0
- package/docs/assets/personal-configuration.png +0 -0
- package/docs/assets/session-upstream.png +0 -0
- package/docs/assets/upstream-settings.png +0 -0
- package/docs/assets/upstream-team.png +0 -0
- package/docs/command-reference.md +201 -0
- package/docs/config.md +253 -0
- package/docs/development.md +197 -0
- package/docs/dsh-compat.md +59 -0
- package/docs/index.md +16 -0
- package/docs/outstanding-issues.md +61 -0
- package/docs/user_guide.md +185 -0
- package/icon.svg +8 -0
- package/lib/activities-B8U-iW4-.js +407 -0
- package/lib/alignment-CwH0nBf-.js +80 -0
- package/lib/auth-DFI9yowX.js +71 -0
- package/lib/checkpoint-CPFPOxBM.js +188 -0
- package/lib/checkpoint-c7aI4D-X.js +318 -0
- package/lib/claim-DOAGe8ZK.js +168 -0
- package/lib/client.js +18417 -0
- package/lib/deliver-C-dmhkfm.js +168 -0
- package/lib/delivery-status-M7-Rwoyj.js +89 -0
- package/lib/dispute-CtrInHzf.js +20 -0
- package/lib/disputes-ByEmi43j.js +51 -0
- package/lib/dream-agent-BVqxbKFc.js +249 -0
- package/lib/dream.js +4 -0
- package/lib/effects-DX1iy6FM.js +268 -0
- package/lib/errors-Bp_2WXBr.js +19 -0
- package/lib/errors-pPumDOGD.js +18 -0
- package/lib/evidence-store-DW7kj20i.js +1030 -0
- package/lib/formation-D4LO31WW.js +187 -0
- package/lib/formation-replay-Bf4TSBiz.js +87 -0
- package/lib/formation.js +9 -0
- package/lib/history-DPMHX3ZE.js +214 -0
- package/lib/inbox-2CugZZQm.js +188 -0
- package/lib/inbox-DFtE2fOp.js +71 -0
- package/lib/inbox.js +3 -0
- package/lib/index.js +1373 -0
- package/lib/lock-DbmlKOoX.js +332 -0
- package/lib/pages-BEWC3kmZ.js +51 -0
- package/lib/paths-B7NI9Ano.js +157 -0
- package/lib/plugins/commands.js +590 -0
- package/lib/plugins/dream.js +66 -0
- package/lib/plugins/formation.js +66 -0
- package/lib/plugins/inbox.js +53 -0
- package/lib/plugins/knowledge.js +1109 -0
- package/lib/plugins/prompt.js +102 -0
- package/lib/plugins/tools.js +280 -0
- package/lib/policy-DnyHh7Bl.js +16 -0
- package/lib/prepare-CGXwBEcu.js +134 -0
- package/lib/protocol.js +8 -0
- package/lib/queue-M917xHPS.js +153 -0
- package/lib/regular-file-BFpqMoub.js +136 -0
- package/lib/render-CJaVcKKC.js +48 -0
- package/lib/reported-sets-DdEKdeVb.js +122 -0
- package/lib/revision-DeoL_IUN.js +11 -0
- package/lib/scheduler-BfJSY1eq.js +64 -0
- package/lib/service-BPwaZzFF.js +1106 -0
- package/lib/service-BQaszW_v.js +344 -0
- package/lib/service-BhniAHLo.js +305 -0
- package/lib/service-C2lXoygJ.js +505 -0
- package/lib/session-binding-zCSuizHs.js +342 -0
- package/lib/session-state-CYqUhC95.js +38 -0
- package/lib/sessions-C2xuPFQv.js +218 -0
- package/lib/store.js +16 -0
- package/lib/structured-C9byFuzm.js +453 -0
- package/lib/subagent-yJsFxHmH.js +9 -0
- package/lib/team.js +3 -0
- package/lib/tool-schema-3b4gH1zf.js +28 -0
- package/lib/trace-Da0RnL5R.js +14 -0
- package/lib/traces-CHBo8y1z.js +11 -0
- package/lib/types/activities.d.ts +73 -0
- package/lib/types/advanced-configuration.d.ts +11 -0
- package/lib/types/client/ActivityCard.d.ts +14 -0
- package/lib/types/client/ActivityDetails.d.ts +18 -0
- package/lib/types/client/AdvancedPreferences.d.ts +8 -0
- package/lib/types/client/BlankCommandFeedback.d.ts +10 -0
- package/lib/types/client/ComposerMenu.d.ts +24 -0
- package/lib/types/client/ConfigurationPage.d.ts +11 -0
- package/lib/types/client/ConnectionCheckDialog.d.ts +12 -0
- package/lib/types/client/KnowledgeDetail.d.ts +6 -0
- package/lib/types/client/KnowledgeDirectoryField.d.ts +11 -0
- package/lib/types/client/KnowledgePanel.d.ts +12 -0
- package/lib/types/client/KnowledgeReference.d.ts +13 -0
- package/lib/types/client/SessionToolbar.d.ts +16 -0
- package/lib/types/client/SettingsToast.d.ts +3 -0
- package/lib/types/client/SourceSessionLink.d.ts +16 -0
- package/lib/types/client/TeamCredentialField.d.ts +16 -0
- package/lib/types/client/TeamSettingsPage.d.ts +28 -0
- package/lib/types/client/configuration-errors.d.ts +2 -0
- package/lib/types/client/interaction-styles.d.ts +1 -0
- package/lib/types/client/interaction-ui.d.ts +30 -0
- package/lib/types/client/knowledge-labels.d.ts +5 -0
- package/lib/types/client/locales.d.ts +51 -0
- package/lib/types/commands/claim.d.ts +4 -0
- package/lib/types/commands/import.d.ts +10 -0
- package/lib/types/commands/status.d.ts +5 -0
- package/lib/types/config.d.ts +111 -0
- package/lib/types/configuration.d.ts +235 -0
- package/lib/types/credentials.d.ts +59 -0
- package/lib/types/dream/audit.d.ts +4 -0
- package/lib/types/dream/autonomous.d.ts +185 -0
- package/lib/types/dream/candidates.d.ts +34 -0
- package/lib/types/dream/checkpoint.d.ts +35 -0
- package/lib/types/dream/evidence-files.d.ts +10 -0
- package/lib/types/dream/evidence-store.d.ts +103 -0
- package/lib/types/dream/evidence.d.ts +30 -0
- package/lib/types/dream/index.d.ts +10 -0
- package/lib/types/dream/plan.d.ts +18 -0
- package/lib/types/dream/preservation.d.ts +6 -0
- package/lib/types/dream/review.d.ts +10 -0
- package/lib/types/dream/schema.d.ts +1475 -0
- package/lib/types/dream/service.d.ts +56 -0
- package/lib/types/dream/sync.d.ts +147 -0
- package/lib/types/dsh-adapter/configuration-remote.d.ts +1 -0
- package/lib/types/dsh-adapter/configuration-service.d.ts +28 -0
- package/lib/types/dsh-adapter/dream-agent.d.ts +4 -0
- package/lib/types/dsh-adapter/dream-evidence.d.ts +3 -0
- package/lib/types/dsh-adapter/formation-archive.d.ts +3 -0
- package/lib/types/dsh-adapter/formation-replay.d.ts +5 -0
- package/lib/types/dsh-adapter/formation.d.ts +4 -0
- package/lib/types/dsh-adapter/interaction-service.d.ts +13 -0
- package/lib/types/dsh-adapter/knowledge-paths.d.ts +3 -0
- package/lib/types/dsh-adapter/llm.d.ts +10 -0
- package/lib/types/dsh-adapter/project-upstream.d.ts +4 -0
- package/lib/types/dsh-adapter/runtime-pool.d.ts +110 -0
- package/lib/types/dsh-adapter/session-binding.d.ts +43 -0
- package/lib/types/dsh-adapter/source-sessions.d.ts +3 -0
- package/lib/types/dsh-adapter/team-credentials.d.ts +5 -0
- package/lib/types/dsh-adapter/tool-schema.d.ts +4 -0
- package/lib/types/dsh-adapter/tools.d.ts +5 -0
- package/lib/types/formation/capture.d.ts +19 -0
- package/lib/types/formation/checkpoint.d.ts +136 -0
- package/lib/types/formation/index.d.ts +10 -0
- package/lib/types/formation/prepare.d.ts +16 -0
- package/lib/types/formation/schema.d.ts +45 -0
- package/lib/types/formation/service.d.ts +58 -0
- package/lib/types/formation/transcript.d.ts +75 -0
- package/lib/types/formation/triggers.d.ts +3 -0
- package/lib/types/inbox/cascade.d.ts +3 -0
- package/lib/types/inbox/effects.d.ts +275 -0
- package/lib/types/inbox/index.d.ts +5 -0
- package/lib/types/inbox/prepare.d.ts +380 -0
- package/lib/types/inbox/service.d.ts +26 -0
- package/lib/types/inbox/sync.d.ts +9 -0
- package/lib/types/index.d.ts +1 -0
- package/lib/types/interaction-messages.d.ts +69 -0
- package/lib/types/interaction.d.ts +541 -0
- package/lib/types/knowledge/alignment.d.ts +49 -0
- package/lib/types/knowledge/catalog.d.ts +5 -0
- package/lib/types/knowledge/changes.d.ts +32 -0
- package/lib/types/knowledge/disputes.d.ts +3 -0
- package/lib/types/knowledge/errors.d.ts +9 -0
- package/lib/types/knowledge/ordering.d.ts +7 -0
- package/lib/types/knowledge/pages.d.ts +7 -0
- package/lib/types/knowledge/safety.d.ts +2 -0
- package/lib/types/knowledge/service.d.ts +52 -0
- package/lib/types/knowledge/sessions.d.ts +59 -0
- package/lib/types/knowledge/sources.d.ts +2 -0
- package/lib/types/knowledge/timestamps.d.ts +1 -0
- package/lib/types/knowledge/types.d.ts +84 -0
- package/lib/types/llm/response.d.ts +1 -0
- package/lib/types/llm/structured.d.ts +27 -0
- package/lib/types/local-name.d.ts +1 -0
- package/lib/types/plugins/client.d.ts +9 -0
- package/lib/types/plugins/commands.d.ts +11 -0
- package/lib/types/plugins/configuration.d.ts +8 -0
- package/lib/types/plugins/dream.d.ts +16 -0
- package/lib/types/plugins/formation.d.ts +16 -0
- package/lib/types/plugins/inbox.d.ts +16 -0
- package/lib/types/plugins/knowledge.d.ts +19 -0
- package/lib/types/plugins/prompt.d.ts +17 -0
- package/lib/types/plugins/tools.d.ts +10 -0
- package/lib/types/prompt/render.d.ts +2 -0
- package/lib/types/protocol/arbitration.d.ts +154 -0
- package/lib/types/protocol/auth.d.ts +31 -0
- package/lib/types/protocol/claim.d.ts +36 -0
- package/lib/types/protocol/dispute.d.ts +17 -0
- package/lib/types/protocol/ids.d.ts +20 -0
- package/lib/types/protocol/inbox.d.ts +141 -0
- package/lib/types/protocol/index.d.ts +11 -0
- package/lib/types/protocol/policy.d.ts +21 -0
- package/lib/types/protocol/revision.d.ts +2 -0
- package/lib/types/protocol/router.d.ts +114 -0
- package/lib/types/protocol/schema.d.ts +4 -0
- package/lib/types/protocol/time.d.ts +5 -0
- package/lib/types/protocol/trace.d.ts +11 -0
- package/lib/types/store/atomic.d.ts +8 -0
- package/lib/types/store/claim-edits.d.ts +33 -0
- package/lib/types/store/claims.d.ts +7 -0
- package/lib/types/store/context.d.ts +13 -0
- package/lib/types/store/delivery-status.d.ts +48 -0
- package/lib/types/store/disputes.d.ts +6 -0
- package/lib/types/store/entities.d.ts +16 -0
- package/lib/types/store/errors.d.ts +8 -0
- package/lib/types/store/history.d.ts +65 -0
- package/lib/types/store/inbox.d.ts +27 -0
- package/lib/types/store/index.d.ts +16 -0
- package/lib/types/store/jobs.d.ts +5 -0
- package/lib/types/store/library-directory.d.ts +4 -0
- package/lib/types/store/lock.d.ts +11 -0
- package/lib/types/store/path-names.d.ts +2 -0
- package/lib/types/store/paths.d.ts +45 -0
- package/lib/types/store/presentation.d.ts +13 -0
- package/lib/types/store/regular-file.d.ts +2 -0
- package/lib/types/store/rejected-disputes.d.ts +18 -0
- package/lib/types/store/rename.d.ts +1 -0
- package/lib/types/store/reported-sets.d.ts +24 -0
- package/lib/types/store/session-state.d.ts +17 -0
- package/lib/types/store/traces.d.ts +6 -0
- package/lib/types/store/uploads.d.ts +312 -0
- package/lib/types/store/yaml.d.ts +8 -0
- package/lib/types/team/errors.d.ts +10 -0
- package/lib/types/team/http.d.ts +20 -0
- package/lib/types/team/index.d.ts +5 -0
- package/lib/types/team/maintainer-client.d.ts +18 -0
- package/lib/types/team/router-client.d.ts +14 -0
- package/lib/types/team/service.d.ts +28 -0
- package/lib/types/team/system-proxy.d.ts +9 -0
- package/lib/types/tools/claim.d.ts +63 -0
- package/lib/types/tools/consult-router.d.ts +11 -0
- package/lib/types/tools/subagent.d.ts +8 -0
- package/lib/types/tools/validation.d.ts +2 -0
- package/lib/types/upload/consolidation.d.ts +63 -0
- package/lib/types/upload/deliver.d.ts +15 -0
- package/lib/types/upload/index.d.ts +2 -0
- package/lib/types/upload/scheduler.d.ts +19 -0
- package/lib/types/upstreams.d.ts +5 -0
- package/lib/types/worker/queue.d.ts +17 -0
- package/lib/types/worker/types.d.ts +51 -0
- package/lib/types/worker/worker.d.ts +39 -0
- package/lib/types-C2ST2Zdg.js +17 -0
- package/lib/upload.js +3 -0
- package/lib/uploads-BCA2p92b.js +210 -0
- package/lib/upstreams-DEi-56tD.js +495 -0
- package/lib/worker-HMGzJFWd.js +185 -0
- package/locale/commands/en.json +1 -0
- package/locale/commands/zh.json +1 -0
- package/locale/dream/en.json +1 -0
- package/locale/dream/zh.json +1 -0
- package/locale/en.json +7 -0
- package/locale/formation/en.json +1 -0
- package/locale/formation/zh.json +1 -0
- package/locale/inbox/en.json +1 -0
- package/locale/inbox/zh.json +1 -0
- package/locale/knowledge/en.json +1 -0
- package/locale/knowledge/zh.json +1 -0
- package/locale/prompt/en.json +1 -0
- package/locale/prompt/zh.json +1 -0
- package/locale/tools/en.json +1 -0
- package/locale/tools/zh.json +1 -0
- package/locale/zh.json +7 -0
- package/package.json +262 -3
- package/prompts/claim_dream.j2 +77 -0
- package/prompts/claim_dream_legacy.j2 +63 -0
- package/prompts/dream_compaction.j2 +11 -0
- package/prompts/dream_evidence.j2 +5 -0
- package/prompts/inbox_claim_attribute_update_internalize.j2 +112 -0
- package/prompts/inbox_policy_update_internalize.j2 +87 -0
- package/prompts/knowledge.j2 +38 -0
- package/prompts/session_recap.j2 +113 -0
- package/prompts/what_is_claim.j2 +51 -0
- package/prompts/what_is_dispute.j2 +21 -0
- package/prompts/what_is_policy.j2 +22 -0
|
@@ -0,0 +1,541 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const RuntimeChoiceSchema: z.ZodObject<{
|
|
3
|
+
key: z.ZodString;
|
|
4
|
+
name: z.ZodString;
|
|
5
|
+
agentId: z.ZodString;
|
|
6
|
+
enabled: z.ZodBoolean;
|
|
7
|
+
mode: z.ZodEnum<{
|
|
8
|
+
team: "team";
|
|
9
|
+
solo: "solo";
|
|
10
|
+
}>;
|
|
11
|
+
}, z.core.$strip>;
|
|
12
|
+
export declare const SessionViewSchema: z.ZodObject<{
|
|
13
|
+
sessionId: z.ZodString;
|
|
14
|
+
key: z.ZodString;
|
|
15
|
+
name: z.ZodString;
|
|
16
|
+
locked: z.ZodBoolean;
|
|
17
|
+
available: z.ZodBoolean;
|
|
18
|
+
phase: z.ZodEnum<{
|
|
19
|
+
failed: "failed";
|
|
20
|
+
ready: "ready";
|
|
21
|
+
syncing: "syncing";
|
|
22
|
+
blocked: "blocked";
|
|
23
|
+
unbound: "unbound";
|
|
24
|
+
}>;
|
|
25
|
+
message: z.ZodString;
|
|
26
|
+
messageInfo: z.ZodOptional<z.ZodObject<{
|
|
27
|
+
code: z.ZodString;
|
|
28
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
29
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
30
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
31
|
+
}, z.core.$strip>>;
|
|
32
|
+
defaultConnection: z.ZodString;
|
|
33
|
+
needsPreparation: z.ZodDefault<z.ZodBoolean>;
|
|
34
|
+
explicitSelection: z.ZodDefault<z.ZodBoolean>;
|
|
35
|
+
activeMode: z.ZodOptional<z.ZodEnum<{
|
|
36
|
+
team: "team";
|
|
37
|
+
solo: "solo";
|
|
38
|
+
}>>;
|
|
39
|
+
configurationChanged: z.ZodOptional<z.ZodBoolean>;
|
|
40
|
+
choices: z.ZodArray<z.ZodObject<{
|
|
41
|
+
key: z.ZodString;
|
|
42
|
+
name: z.ZodString;
|
|
43
|
+
agentId: z.ZodString;
|
|
44
|
+
enabled: z.ZodBoolean;
|
|
45
|
+
mode: z.ZodEnum<{
|
|
46
|
+
team: "team";
|
|
47
|
+
solo: "solo";
|
|
48
|
+
}>;
|
|
49
|
+
}, z.core.$strip>>;
|
|
50
|
+
showCompletion: z.ZodBoolean;
|
|
51
|
+
}, z.core.$strip>;
|
|
52
|
+
export type SessionView = z.infer<typeof SessionViewSchema>;
|
|
53
|
+
export declare const SourceSessionSchema: z.ZodObject<{
|
|
54
|
+
id: z.ZodString;
|
|
55
|
+
available: z.ZodBoolean;
|
|
56
|
+
title: z.ZodOptional<z.ZodString>;
|
|
57
|
+
}, z.core.$strip>;
|
|
58
|
+
export type SourceSession = z.infer<typeof SourceSessionSchema>;
|
|
59
|
+
export declare const KnowledgeItemSchema: z.ZodObject<{
|
|
60
|
+
kind: z.ZodEnum<{
|
|
61
|
+
claim: "claim";
|
|
62
|
+
trace: "trace";
|
|
63
|
+
dispute: "dispute";
|
|
64
|
+
}>;
|
|
65
|
+
id: z.ZodString;
|
|
66
|
+
name: z.ZodString;
|
|
67
|
+
status: z.ZodString;
|
|
68
|
+
detail: z.ZodString;
|
|
69
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
70
|
+
updatedAt: z.ZodOptional<z.ZodString>;
|
|
71
|
+
delivery: z.ZodOptional<z.ZodEnum<{
|
|
72
|
+
pending: "pending";
|
|
73
|
+
synced: "synced";
|
|
74
|
+
local: "local";
|
|
75
|
+
}>>;
|
|
76
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
77
|
+
id: z.ZodString;
|
|
78
|
+
available: z.ZodBoolean;
|
|
79
|
+
title: z.ZodOptional<z.ZodString>;
|
|
80
|
+
}, z.core.$strip>>>;
|
|
81
|
+
}, z.core.$strip>;
|
|
82
|
+
export declare const ActivitySchema: z.ZodObject<{
|
|
83
|
+
id: z.ZodString;
|
|
84
|
+
kind: z.ZodString;
|
|
85
|
+
state: z.ZodString;
|
|
86
|
+
attempts: z.ZodNumber;
|
|
87
|
+
updatedAt: z.ZodNumber;
|
|
88
|
+
unseen: z.ZodDefault<z.ZodBoolean>;
|
|
89
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
90
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
91
|
+
id: z.ZodString;
|
|
92
|
+
available: z.ZodBoolean;
|
|
93
|
+
title: z.ZodOptional<z.ZodString>;
|
|
94
|
+
}, z.core.$strip>>;
|
|
95
|
+
summary: z.ZodString;
|
|
96
|
+
error: z.ZodOptional<z.ZodString>;
|
|
97
|
+
summaryInfo: z.ZodOptional<z.ZodObject<{
|
|
98
|
+
code: z.ZodString;
|
|
99
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
100
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
101
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
102
|
+
}, z.core.$strip>>;
|
|
103
|
+
errorInfo: z.ZodOptional<z.ZodObject<{
|
|
104
|
+
code: z.ZodString;
|
|
105
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
106
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
107
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
108
|
+
}, z.core.$strip>>;
|
|
109
|
+
counts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
110
|
+
warnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
111
|
+
budgetLimited: z.ZodOptional<z.ZodBoolean>;
|
|
112
|
+
requiresAttention: z.ZodOptional<z.ZodBoolean>;
|
|
113
|
+
incompleteCandidates: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
114
|
+
groupId: z.ZodString;
|
|
115
|
+
claimIds: z.ZodArray<z.core.$ZodBranded<z.ZodString, "ClaimId", "out">>;
|
|
116
|
+
reason: z.ZodString;
|
|
117
|
+
}, z.core.$strip>>>;
|
|
118
|
+
entityIds: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>>>;
|
|
119
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
120
|
+
retryable: z.ZodOptional<z.ZodBoolean>;
|
|
121
|
+
acknowledged: z.ZodOptional<z.ZodBoolean>;
|
|
122
|
+
reportPath: z.ZodOptional<z.ZodString>;
|
|
123
|
+
phase: z.ZodOptional<z.ZodEnum<{
|
|
124
|
+
finished: "finished";
|
|
125
|
+
wrap_up: "wrap_up";
|
|
126
|
+
exploration: "exploration";
|
|
127
|
+
}>>;
|
|
128
|
+
}, z.core.$strip>;
|
|
129
|
+
export type Activity = z.infer<typeof ActivitySchema>;
|
|
130
|
+
export declare const KnowledgeViewSchema: z.ZodObject<{
|
|
131
|
+
key: z.ZodString;
|
|
132
|
+
name: z.ZodString;
|
|
133
|
+
items: z.ZodArray<z.ZodObject<{
|
|
134
|
+
kind: z.ZodEnum<{
|
|
135
|
+
claim: "claim";
|
|
136
|
+
trace: "trace";
|
|
137
|
+
dispute: "dispute";
|
|
138
|
+
}>;
|
|
139
|
+
id: z.ZodString;
|
|
140
|
+
name: z.ZodString;
|
|
141
|
+
status: z.ZodString;
|
|
142
|
+
detail: z.ZodString;
|
|
143
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
144
|
+
updatedAt: z.ZodOptional<z.ZodString>;
|
|
145
|
+
delivery: z.ZodOptional<z.ZodEnum<{
|
|
146
|
+
pending: "pending";
|
|
147
|
+
synced: "synced";
|
|
148
|
+
local: "local";
|
|
149
|
+
}>>;
|
|
150
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
151
|
+
id: z.ZodString;
|
|
152
|
+
available: z.ZodBoolean;
|
|
153
|
+
title: z.ZodOptional<z.ZodString>;
|
|
154
|
+
}, z.core.$strip>>>;
|
|
155
|
+
}, z.core.$strip>>;
|
|
156
|
+
omitted: z.ZodNumber;
|
|
157
|
+
activities: z.ZodArray<z.ZodObject<{
|
|
158
|
+
id: z.ZodString;
|
|
159
|
+
kind: z.ZodString;
|
|
160
|
+
state: z.ZodString;
|
|
161
|
+
attempts: z.ZodNumber;
|
|
162
|
+
updatedAt: z.ZodNumber;
|
|
163
|
+
unseen: z.ZodDefault<z.ZodBoolean>;
|
|
164
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
165
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
166
|
+
id: z.ZodString;
|
|
167
|
+
available: z.ZodBoolean;
|
|
168
|
+
title: z.ZodOptional<z.ZodString>;
|
|
169
|
+
}, z.core.$strip>>;
|
|
170
|
+
summary: z.ZodString;
|
|
171
|
+
error: z.ZodOptional<z.ZodString>;
|
|
172
|
+
summaryInfo: z.ZodOptional<z.ZodObject<{
|
|
173
|
+
code: z.ZodString;
|
|
174
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
175
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
176
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
177
|
+
}, z.core.$strip>>;
|
|
178
|
+
errorInfo: z.ZodOptional<z.ZodObject<{
|
|
179
|
+
code: z.ZodString;
|
|
180
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
181
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
182
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
183
|
+
}, z.core.$strip>>;
|
|
184
|
+
counts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
185
|
+
warnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
186
|
+
budgetLimited: z.ZodOptional<z.ZodBoolean>;
|
|
187
|
+
requiresAttention: z.ZodOptional<z.ZodBoolean>;
|
|
188
|
+
incompleteCandidates: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
189
|
+
groupId: z.ZodString;
|
|
190
|
+
claimIds: z.ZodArray<z.core.$ZodBranded<z.ZodString, "ClaimId", "out">>;
|
|
191
|
+
reason: z.ZodString;
|
|
192
|
+
}, z.core.$strip>>>;
|
|
193
|
+
entityIds: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>>>;
|
|
194
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
195
|
+
retryable: z.ZodOptional<z.ZodBoolean>;
|
|
196
|
+
acknowledged: z.ZodOptional<z.ZodBoolean>;
|
|
197
|
+
reportPath: z.ZodOptional<z.ZodString>;
|
|
198
|
+
phase: z.ZodOptional<z.ZodEnum<{
|
|
199
|
+
finished: "finished";
|
|
200
|
+
wrap_up: "wrap_up";
|
|
201
|
+
exploration: "exploration";
|
|
202
|
+
}>>;
|
|
203
|
+
}, z.core.$strip>>;
|
|
204
|
+
activitiesOmitted: z.ZodOptional<z.ZodNumber>;
|
|
205
|
+
attentionCount: z.ZodOptional<z.ZodNumber>;
|
|
206
|
+
runningCount: z.ZodOptional<z.ZodNumber>;
|
|
207
|
+
activityKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
208
|
+
activitySources: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
209
|
+
pendingClaims: z.ZodNumber;
|
|
210
|
+
pendingDisputes: z.ZodNumber;
|
|
211
|
+
}, z.core.$strip>;
|
|
212
|
+
export type KnowledgeView = z.infer<typeof KnowledgeViewSchema>;
|
|
213
|
+
export declare const KnowledgeReferenceSchema: z.ZodObject<{
|
|
214
|
+
key: z.ZodString;
|
|
215
|
+
id: z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>;
|
|
216
|
+
item: z.ZodOptional<z.ZodObject<{
|
|
217
|
+
kind: z.ZodEnum<{
|
|
218
|
+
claim: "claim";
|
|
219
|
+
trace: "trace";
|
|
220
|
+
dispute: "dispute";
|
|
221
|
+
}>;
|
|
222
|
+
id: z.ZodString;
|
|
223
|
+
name: z.ZodString;
|
|
224
|
+
status: z.ZodString;
|
|
225
|
+
detail: z.ZodString;
|
|
226
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
227
|
+
updatedAt: z.ZodOptional<z.ZodString>;
|
|
228
|
+
delivery: z.ZodOptional<z.ZodEnum<{
|
|
229
|
+
pending: "pending";
|
|
230
|
+
synced: "synced";
|
|
231
|
+
local: "local";
|
|
232
|
+
}>>;
|
|
233
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
234
|
+
id: z.ZodString;
|
|
235
|
+
available: z.ZodBoolean;
|
|
236
|
+
title: z.ZodOptional<z.ZodString>;
|
|
237
|
+
}, z.core.$strip>>>;
|
|
238
|
+
}, z.core.$strip>>;
|
|
239
|
+
}, z.core.$strip>;
|
|
240
|
+
export type KnowledgeReference = z.infer<typeof KnowledgeReferenceSchema>;
|
|
241
|
+
export declare const TeamConnectionInputSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
242
|
+
id: z.ZodString;
|
|
243
|
+
name: z.ZodString;
|
|
244
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
245
|
+
agentId: z.core.$ZodBranded<z.ZodString, "AgentId", "out">;
|
|
246
|
+
routerEndpoint: z.ZodString;
|
|
247
|
+
maintainerEndpoint: z.ZodString;
|
|
248
|
+
keyEnv: z.ZodDefault<z.ZodString>;
|
|
249
|
+
timeoutMs: z.ZodDefault<z.ZodNumber>;
|
|
250
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
251
|
+
name: z.ZodDefault<z.ZodString>;
|
|
252
|
+
agentId: z.core.$ZodBranded<z.ZodString, "AgentId", "out">;
|
|
253
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
254
|
+
routerEndpoint: z.ZodDefault<z.ZodString>;
|
|
255
|
+
maintainerEndpoint: z.ZodDefault<z.ZodString>;
|
|
256
|
+
keyEnv: z.ZodDefault<z.ZodString>;
|
|
257
|
+
timeoutMs: z.ZodDefault<z.ZodNumber>;
|
|
258
|
+
id: z.ZodOptional<z.ZodString>;
|
|
259
|
+
}, z.core.$strict>]>;
|
|
260
|
+
export declare const ConnectionChecksSchema: z.ZodArray<z.ZodObject<{
|
|
261
|
+
service: z.ZodEnum<{
|
|
262
|
+
router: "router";
|
|
263
|
+
maintainer: "maintainer";
|
|
264
|
+
}>;
|
|
265
|
+
state: z.ZodEnum<{
|
|
266
|
+
failed: "failed";
|
|
267
|
+
ok: "ok";
|
|
268
|
+
}>;
|
|
269
|
+
message: z.ZodString;
|
|
270
|
+
}, z.core.$strip>>;
|
|
271
|
+
export declare const InteractionRequestSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
272
|
+
action: z.ZodLiteral<"session">;
|
|
273
|
+
sessionId: z.ZodString;
|
|
274
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
275
|
+
action: z.ZodLiteral<"select">;
|
|
276
|
+
sessionId: z.ZodString;
|
|
277
|
+
key: z.ZodString;
|
|
278
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
279
|
+
action: z.ZodLiteral<"cancel">;
|
|
280
|
+
sessionId: z.ZodString;
|
|
281
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
282
|
+
action: z.ZodLiteral<"sync">;
|
|
283
|
+
sessionId: z.ZodString;
|
|
284
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
285
|
+
action: z.ZodLiteral<"knowledge">;
|
|
286
|
+
key: z.ZodString;
|
|
287
|
+
query: z.ZodDefault<z.ZodString>;
|
|
288
|
+
kind: z.ZodDefault<z.ZodEnum<{
|
|
289
|
+
claim: "claim";
|
|
290
|
+
trace: "trace";
|
|
291
|
+
dispute: "dispute";
|
|
292
|
+
}>>;
|
|
293
|
+
status: z.ZodDefault<z.ZodString>;
|
|
294
|
+
delivery: z.ZodDefault<z.ZodEnum<{
|
|
295
|
+
pending: "pending";
|
|
296
|
+
synced: "synced";
|
|
297
|
+
local: "local";
|
|
298
|
+
all: "all";
|
|
299
|
+
}>>;
|
|
300
|
+
offset: z.ZodDefault<z.ZodNumber>;
|
|
301
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
302
|
+
action: z.ZodLiteral<"activity">;
|
|
303
|
+
key: z.ZodString;
|
|
304
|
+
attentionOnly: z.ZodDefault<z.ZodBoolean>;
|
|
305
|
+
sourceSession: z.ZodDefault<z.ZodString>;
|
|
306
|
+
kind: z.ZodDefault<z.ZodString>;
|
|
307
|
+
state: z.ZodDefault<z.ZodString>;
|
|
308
|
+
offset: z.ZodDefault<z.ZodNumber>;
|
|
309
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
310
|
+
action: z.ZodLiteral<"reference">;
|
|
311
|
+
key: z.ZodString;
|
|
312
|
+
id: z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>;
|
|
313
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
314
|
+
action: z.ZodLiteral<"source_session">;
|
|
315
|
+
sessionId: z.ZodString;
|
|
316
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
317
|
+
action: z.ZodLiteral<"open_directory">;
|
|
318
|
+
path: z.ZodString;
|
|
319
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
320
|
+
action: z.ZodLiteral<"retry_delivery">;
|
|
321
|
+
key: z.ZodString;
|
|
322
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
323
|
+
action: z.ZodLiteral<"dream_again">;
|
|
324
|
+
key: z.ZodString;
|
|
325
|
+
id: z.ZodString;
|
|
326
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
327
|
+
action: z.ZodLiteral<"retry">;
|
|
328
|
+
key: z.ZodString;
|
|
329
|
+
id: z.ZodString;
|
|
330
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
331
|
+
action: z.ZodLiteral<"ack">;
|
|
332
|
+
key: z.ZodString;
|
|
333
|
+
id: z.ZodString;
|
|
334
|
+
version: z.ZodNumber;
|
|
335
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
336
|
+
action: z.ZodLiteral<"recap">;
|
|
337
|
+
sessionId: z.ZodString;
|
|
338
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
339
|
+
action: z.ZodLiteral<"check">;
|
|
340
|
+
connection: z.ZodUnion<readonly [z.ZodObject<{
|
|
341
|
+
id: z.ZodString;
|
|
342
|
+
name: z.ZodString;
|
|
343
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
344
|
+
agentId: z.core.$ZodBranded<z.ZodString, "AgentId", "out">;
|
|
345
|
+
routerEndpoint: z.ZodString;
|
|
346
|
+
maintainerEndpoint: z.ZodString;
|
|
347
|
+
keyEnv: z.ZodDefault<z.ZodString>;
|
|
348
|
+
timeoutMs: z.ZodDefault<z.ZodNumber>;
|
|
349
|
+
}, z.core.$strict>, z.ZodObject<{
|
|
350
|
+
name: z.ZodDefault<z.ZodString>;
|
|
351
|
+
agentId: z.core.$ZodBranded<z.ZodString, "AgentId", "out">;
|
|
352
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
353
|
+
routerEndpoint: z.ZodDefault<z.ZodString>;
|
|
354
|
+
maintainerEndpoint: z.ZodDefault<z.ZodString>;
|
|
355
|
+
keyEnv: z.ZodDefault<z.ZodString>;
|
|
356
|
+
timeoutMs: z.ZodDefault<z.ZodNumber>;
|
|
357
|
+
id: z.ZodOptional<z.ZodString>;
|
|
358
|
+
}, z.core.$strict>]>;
|
|
359
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
360
|
+
action: z.ZodLiteral<"probe">;
|
|
361
|
+
provider: z.ZodString;
|
|
362
|
+
model: z.ZodString;
|
|
363
|
+
}, z.core.$strip>], "action">;
|
|
364
|
+
export type InteractionRequest = z.input<typeof InteractionRequestSchema>;
|
|
365
|
+
export declare const InteractionResultSchema: z.ZodObject<{
|
|
366
|
+
ok: z.ZodBoolean;
|
|
367
|
+
message: z.ZodString;
|
|
368
|
+
messageInfo: z.ZodOptional<z.ZodObject<{
|
|
369
|
+
code: z.ZodString;
|
|
370
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
371
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
372
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
373
|
+
}, z.core.$strip>>;
|
|
374
|
+
serviceAvailable: z.ZodOptional<z.ZodBoolean>;
|
|
375
|
+
session: z.ZodOptional<z.ZodObject<{
|
|
376
|
+
sessionId: z.ZodString;
|
|
377
|
+
key: z.ZodString;
|
|
378
|
+
name: z.ZodString;
|
|
379
|
+
locked: z.ZodBoolean;
|
|
380
|
+
available: z.ZodBoolean;
|
|
381
|
+
phase: z.ZodEnum<{
|
|
382
|
+
failed: "failed";
|
|
383
|
+
ready: "ready";
|
|
384
|
+
syncing: "syncing";
|
|
385
|
+
blocked: "blocked";
|
|
386
|
+
unbound: "unbound";
|
|
387
|
+
}>;
|
|
388
|
+
message: z.ZodString;
|
|
389
|
+
messageInfo: z.ZodOptional<z.ZodObject<{
|
|
390
|
+
code: z.ZodString;
|
|
391
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
392
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
393
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
394
|
+
}, z.core.$strip>>;
|
|
395
|
+
defaultConnection: z.ZodString;
|
|
396
|
+
needsPreparation: z.ZodDefault<z.ZodBoolean>;
|
|
397
|
+
explicitSelection: z.ZodDefault<z.ZodBoolean>;
|
|
398
|
+
activeMode: z.ZodOptional<z.ZodEnum<{
|
|
399
|
+
team: "team";
|
|
400
|
+
solo: "solo";
|
|
401
|
+
}>>;
|
|
402
|
+
configurationChanged: z.ZodOptional<z.ZodBoolean>;
|
|
403
|
+
choices: z.ZodArray<z.ZodObject<{
|
|
404
|
+
key: z.ZodString;
|
|
405
|
+
name: z.ZodString;
|
|
406
|
+
agentId: z.ZodString;
|
|
407
|
+
enabled: z.ZodBoolean;
|
|
408
|
+
mode: z.ZodEnum<{
|
|
409
|
+
team: "team";
|
|
410
|
+
solo: "solo";
|
|
411
|
+
}>;
|
|
412
|
+
}, z.core.$strip>>;
|
|
413
|
+
showCompletion: z.ZodBoolean;
|
|
414
|
+
}, z.core.$strip>>;
|
|
415
|
+
knowledge: z.ZodOptional<z.ZodObject<{
|
|
416
|
+
key: z.ZodString;
|
|
417
|
+
name: z.ZodString;
|
|
418
|
+
items: z.ZodArray<z.ZodObject<{
|
|
419
|
+
kind: z.ZodEnum<{
|
|
420
|
+
claim: "claim";
|
|
421
|
+
trace: "trace";
|
|
422
|
+
dispute: "dispute";
|
|
423
|
+
}>;
|
|
424
|
+
id: z.ZodString;
|
|
425
|
+
name: z.ZodString;
|
|
426
|
+
status: z.ZodString;
|
|
427
|
+
detail: z.ZodString;
|
|
428
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
429
|
+
updatedAt: z.ZodOptional<z.ZodString>;
|
|
430
|
+
delivery: z.ZodOptional<z.ZodEnum<{
|
|
431
|
+
pending: "pending";
|
|
432
|
+
synced: "synced";
|
|
433
|
+
local: "local";
|
|
434
|
+
}>>;
|
|
435
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
436
|
+
id: z.ZodString;
|
|
437
|
+
available: z.ZodBoolean;
|
|
438
|
+
title: z.ZodOptional<z.ZodString>;
|
|
439
|
+
}, z.core.$strip>>>;
|
|
440
|
+
}, z.core.$strip>>;
|
|
441
|
+
omitted: z.ZodNumber;
|
|
442
|
+
activities: z.ZodArray<z.ZodObject<{
|
|
443
|
+
id: z.ZodString;
|
|
444
|
+
kind: z.ZodString;
|
|
445
|
+
state: z.ZodString;
|
|
446
|
+
attempts: z.ZodNumber;
|
|
447
|
+
updatedAt: z.ZodNumber;
|
|
448
|
+
unseen: z.ZodDefault<z.ZodBoolean>;
|
|
449
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
450
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
451
|
+
id: z.ZodString;
|
|
452
|
+
available: z.ZodBoolean;
|
|
453
|
+
title: z.ZodOptional<z.ZodString>;
|
|
454
|
+
}, z.core.$strip>>;
|
|
455
|
+
summary: z.ZodString;
|
|
456
|
+
error: z.ZodOptional<z.ZodString>;
|
|
457
|
+
summaryInfo: z.ZodOptional<z.ZodObject<{
|
|
458
|
+
code: z.ZodString;
|
|
459
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
460
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
461
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
462
|
+
}, z.core.$strip>>;
|
|
463
|
+
errorInfo: z.ZodOptional<z.ZodObject<{
|
|
464
|
+
code: z.ZodString;
|
|
465
|
+
count: z.ZodOptional<z.ZodNumber>;
|
|
466
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
467
|
+
status: z.ZodOptional<z.ZodNumber>;
|
|
468
|
+
}, z.core.$strip>>;
|
|
469
|
+
counts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
470
|
+
warnings: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
471
|
+
budgetLimited: z.ZodOptional<z.ZodBoolean>;
|
|
472
|
+
requiresAttention: z.ZodOptional<z.ZodBoolean>;
|
|
473
|
+
incompleteCandidates: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
474
|
+
groupId: z.ZodString;
|
|
475
|
+
claimIds: z.ZodArray<z.core.$ZodBranded<z.ZodString, "ClaimId", "out">>;
|
|
476
|
+
reason: z.ZodString;
|
|
477
|
+
}, z.core.$strip>>>;
|
|
478
|
+
entityIds: z.ZodOptional<z.ZodArray<z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>>>;
|
|
479
|
+
entityId: z.ZodOptional<z.ZodString>;
|
|
480
|
+
retryable: z.ZodOptional<z.ZodBoolean>;
|
|
481
|
+
acknowledged: z.ZodOptional<z.ZodBoolean>;
|
|
482
|
+
reportPath: z.ZodOptional<z.ZodString>;
|
|
483
|
+
phase: z.ZodOptional<z.ZodEnum<{
|
|
484
|
+
finished: "finished";
|
|
485
|
+
wrap_up: "wrap_up";
|
|
486
|
+
exploration: "exploration";
|
|
487
|
+
}>>;
|
|
488
|
+
}, z.core.$strip>>;
|
|
489
|
+
activitiesOmitted: z.ZodOptional<z.ZodNumber>;
|
|
490
|
+
attentionCount: z.ZodOptional<z.ZodNumber>;
|
|
491
|
+
runningCount: z.ZodOptional<z.ZodNumber>;
|
|
492
|
+
activityKinds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
493
|
+
activitySources: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
494
|
+
pendingClaims: z.ZodNumber;
|
|
495
|
+
pendingDisputes: z.ZodNumber;
|
|
496
|
+
}, z.core.$strip>>;
|
|
497
|
+
reference: z.ZodOptional<z.ZodObject<{
|
|
498
|
+
key: z.ZodString;
|
|
499
|
+
id: z.ZodUnion<readonly [z.core.$ZodBranded<z.ZodString, "ClaimId", "out">, z.core.$ZodBranded<z.ZodString, "DisputeId", "out">, z.core.$ZodBranded<z.ZodString, "TraceId", "out">]>;
|
|
500
|
+
item: z.ZodOptional<z.ZodObject<{
|
|
501
|
+
kind: z.ZodEnum<{
|
|
502
|
+
claim: "claim";
|
|
503
|
+
trace: "trace";
|
|
504
|
+
dispute: "dispute";
|
|
505
|
+
}>;
|
|
506
|
+
id: z.ZodString;
|
|
507
|
+
name: z.ZodString;
|
|
508
|
+
status: z.ZodString;
|
|
509
|
+
detail: z.ZodString;
|
|
510
|
+
summary: z.ZodOptional<z.ZodString>;
|
|
511
|
+
updatedAt: z.ZodOptional<z.ZodString>;
|
|
512
|
+
delivery: z.ZodOptional<z.ZodEnum<{
|
|
513
|
+
pending: "pending";
|
|
514
|
+
synced: "synced";
|
|
515
|
+
local: "local";
|
|
516
|
+
}>>;
|
|
517
|
+
sources: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
518
|
+
id: z.ZodString;
|
|
519
|
+
available: z.ZodBoolean;
|
|
520
|
+
title: z.ZodOptional<z.ZodString>;
|
|
521
|
+
}, z.core.$strip>>>;
|
|
522
|
+
}, z.core.$strip>>;
|
|
523
|
+
}, z.core.$strip>>;
|
|
524
|
+
sourceSession: z.ZodOptional<z.ZodObject<{
|
|
525
|
+
id: z.ZodString;
|
|
526
|
+
available: z.ZodBoolean;
|
|
527
|
+
title: z.ZodOptional<z.ZodString>;
|
|
528
|
+
}, z.core.$strip>>;
|
|
529
|
+
checks: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
530
|
+
service: z.ZodEnum<{
|
|
531
|
+
router: "router";
|
|
532
|
+
maintainer: "maintainer";
|
|
533
|
+
}>;
|
|
534
|
+
state: z.ZodEnum<{
|
|
535
|
+
failed: "failed";
|
|
536
|
+
ok: "ok";
|
|
537
|
+
}>;
|
|
538
|
+
message: z.ZodString;
|
|
539
|
+
}, z.core.$strip>>>;
|
|
540
|
+
}, z.core.$strip>;
|
|
541
|
+
export type InteractionResult = z.infer<typeof InteractionResultSchema>;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import type { Claim } from '../protocol/claim.js';
|
|
2
|
+
import { JobError } from '../worker/types.js';
|
|
3
|
+
export declare const STALE_PLAN_WARNING = "\u6062\u590D\u65F6 Claim \u5DF2\u53D8\u5316\u6216\u7F3A\u5C11\u5206\u6790\u5FEB\u7167\uFF0C\u5DF2\u653E\u5F03\u672C\u6279\u5C1A\u672A\u6267\u884C\u7684 Claim \u4FEE\u6539\u53CA Dispute\uFF1B\u5DF2\u6267\u884C\u7ED3\u679C\u4FDD\u7559\u3002";
|
|
4
|
+
export declare class AnalysisChanged extends JobError {
|
|
5
|
+
constructor();
|
|
6
|
+
}
|
|
7
|
+
export declare const sameClaim: (a: Claim, b: Claim) => boolean;
|
|
8
|
+
export declare function observeApplied(targets: readonly Claim[], current: readonly Claim[], applied: Claim[]): void;
|
|
9
|
+
export declare function claimChanges(analysis: readonly Claim[] | null, targets: readonly Claim[], applied: readonly Claim[], current: readonly Claim[]): {
|
|
10
|
+
id: string & import("zod").$brand<"ClaimId">;
|
|
11
|
+
before: {
|
|
12
|
+
id: string & import("zod").$brand<"ClaimId">;
|
|
13
|
+
name: string;
|
|
14
|
+
statement: string;
|
|
15
|
+
scope: string;
|
|
16
|
+
holder: string & import("zod").$brand<"AgentId">;
|
|
17
|
+
confidence: "high" | "medium" | "low";
|
|
18
|
+
status: "active" | "stale" | "deprecated";
|
|
19
|
+
created_at: string;
|
|
20
|
+
source_claim_ids: ((string & import("zod").$brand<"ClaimId">) | (string & import("zod").$brand<"PolicyId">))[];
|
|
21
|
+
evidence_summary: string;
|
|
22
|
+
updated_at?: string | undefined;
|
|
23
|
+
} | null;
|
|
24
|
+
current: {
|
|
25
|
+
id: string & import("zod").$brand<"ClaimId">;
|
|
26
|
+
name: string;
|
|
27
|
+
statement: string;
|
|
28
|
+
scope: string;
|
|
29
|
+
holder: string & import("zod").$brand<"AgentId">;
|
|
30
|
+
confidence: "high" | "medium" | "low";
|
|
31
|
+
status: "active" | "stale" | "deprecated";
|
|
32
|
+
created_at: string;
|
|
33
|
+
source_claim_ids: ((string & import("zod").$brand<"ClaimId">) | (string & import("zod").$brand<"PolicyId">))[];
|
|
34
|
+
evidence_summary: string;
|
|
35
|
+
updated_at?: string | undefined;
|
|
36
|
+
} | null;
|
|
37
|
+
changed_fields: string[];
|
|
38
|
+
}[];
|
|
39
|
+
export declare function analysisIsStale(analysis: readonly Claim[] | null, changes: readonly unknown[]): boolean;
|
|
40
|
+
export declare class KnowledgeBusy extends JobError {
|
|
41
|
+
constructor();
|
|
42
|
+
}
|
|
43
|
+
export declare function ensureKnowledgeReady(root: string): Promise<void>;
|
|
44
|
+
export declare class AnalysisReadBoundary {
|
|
45
|
+
private readonly state;
|
|
46
|
+
private constructor();
|
|
47
|
+
static begin(root: string): Promise<AnalysisReadBoundary>;
|
|
48
|
+
finish(root: string): Promise<void>;
|
|
49
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import type { Claim } from '../protocol/claim.js';
|
|
3
|
+
export declare const ClaimIdentitySchema: z.ZodObject<{
|
|
4
|
+
name: z.ZodString;
|
|
5
|
+
scope: z.ZodString;
|
|
6
|
+
status: z.ZodEnum<{
|
|
7
|
+
active: "active";
|
|
8
|
+
stale: "stale";
|
|
9
|
+
deprecated: "deprecated";
|
|
10
|
+
}>;
|
|
11
|
+
revision: z.ZodString;
|
|
12
|
+
}, z.core.$strip>;
|
|
13
|
+
export declare const ClaimIndexSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
14
|
+
name: z.ZodString;
|
|
15
|
+
scope: z.ZodString;
|
|
16
|
+
status: z.ZodEnum<{
|
|
17
|
+
active: "active";
|
|
18
|
+
stale: "stale";
|
|
19
|
+
deprecated: "deprecated";
|
|
20
|
+
}>;
|
|
21
|
+
revision: z.ZodString;
|
|
22
|
+
}, z.core.$strip>>;
|
|
23
|
+
export type ClaimIndex = z.infer<typeof ClaimIndexSchema>;
|
|
24
|
+
export declare function claimIndex(claims: readonly Claim[]): ClaimIndex;
|
|
25
|
+
export declare function claimChanges(baseline: ClaimIndex, current: ClaimIndex, known: ClaimIndex): {
|
|
26
|
+
change: string;
|
|
27
|
+
id: string;
|
|
28
|
+
name: string;
|
|
29
|
+
scope: string;
|
|
30
|
+
status: "active" | "stale" | "deprecated";
|
|
31
|
+
}[];
|
|
32
|
+
export declare function changeNotice(revision: string, baseline: ClaimIndex, current: ClaimIndex, known: ClaimIndex): string;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export type KnowledgeErrorKind = 'validation' | 'not_found' | 'ownership' | 'safety' | 'unconfigured' | 'conflict';
|
|
2
|
+
export declare class KnowledgeError extends Error {
|
|
3
|
+
readonly kind: KnowledgeErrorKind;
|
|
4
|
+
constructor(kind: KnowledgeErrorKind, message: string);
|
|
5
|
+
}
|
|
6
|
+
export declare class RevisionConflict extends KnowledgeError {
|
|
7
|
+
readonly currentRevision: string;
|
|
8
|
+
constructor(currentRevision: string);
|
|
9
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Claim } from '../protocol/claim.js';
|
|
2
|
+
import type { Dispute } from '../protocol/dispute.js';
|
|
3
|
+
import type { Trace } from '../protocol/trace.js';
|
|
4
|
+
type Entity = Claim | Dispute | Trace;
|
|
5
|
+
export declare function knowledgeChangedAt(item: Entity): string;
|
|
6
|
+
export declare function compareKnowledge(left: Entity, right: Entity): number;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type { Claim } from '../protocol/claim.js';
|
|
2
|
+
import type { BoundedText, ClaimListPage, ClaimListQuery, Page } from './types.js';
|
|
3
|
+
export declare function boundedText(value: string, limit: number): BoundedText;
|
|
4
|
+
export declare function validatePage(offset: number, limit: number, maximum?: number): void;
|
|
5
|
+
export declare function page<T>(items: T[], offset: number, limit: number): Page<T>;
|
|
6
|
+
export declare function sortClaims(claims: readonly Claim[]): Claim[];
|
|
7
|
+
export declare function claimListPage(claims: readonly Claim[], query: ClaimListQuery): ClaimListPage;
|