@adhdev/mesh-shared 1.0.82-rc.4 → 1.0.82-rc.41
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assistant-protocol.d.ts +161 -6
- package/dist/decision-push-relay.d.ts +20 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +1197 -118
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1107 -118
- package/dist/index.mjs.map +1 -1
- package/dist/launch-defaults.d.ts +196 -0
- package/dist/mesh-tool-names.d.ts +2 -2
- package/dist/mesh-vocabulary.d.ts +13 -4
- package/dist/mission-git-state.d.ts +83 -0
- package/dist/mission-items.d.ts +202 -0
- package/dist/node-facts.d.ts +75 -1
- package/dist/outbound-message.d.ts +9 -2
- package/dist/path-ownership.d.ts +1 -1
- package/dist/protocol/daemon-server.d.ts +42 -2
- package/dist/protocol/dashboard-daemon-p2p.d.ts +1 -1
- package/dist/protocol/dashboard-server.d.ts +20 -2
- package/dist/provider-approval.d.ts +36 -0
- package/dist/provider-question.d.ts +19 -0
- package/dist/quota-freshness.d.ts +65 -0
- package/dist/relay-reprobe.d.ts +52 -0
- package/dist/release.d.ts +90 -0
- package/dist/role-launch.d.ts +11 -0
- package/dist/session-launch.d.ts +10 -22
- package/dist/slot-proposal.d.ts +14 -0
- package/dist/task-source-phase.d.ts +75 -0
- package/dist/turn-evidence.d.ts +29 -13
- package/dist/turn-ipc-mission.d.ts +68 -1
- package/dist/turn-ipc-queue.d.ts +19 -0
- package/dist/turn-ipc.d.ts +2 -2
- package/dist/types.d.ts +1 -0
- package/dist/worker-protocol.d.ts +1 -1
- package/package.json +1 -1
- package/src/assistant-protocol.ts +302 -6
- package/src/daemon-normalize.ts +7 -5
- package/src/decision-push-relay.ts +23 -0
- package/src/index.ts +12 -0
- package/src/keyed-doc-delta.ts +9 -1
- package/src/launch-defaults.ts +170 -0
- package/src/mesh-tool-names.ts +16 -0
- package/src/mesh-vocabulary.ts +12 -2
- package/src/mission-git-state.ts +112 -0
- package/src/mission-items.ts +421 -0
- package/src/node-facts.ts +70 -1
- package/src/outbound-message.ts +19 -0
- package/src/path-ownership.ts +4 -6
- package/src/protocol/daemon-server.ts +37 -2
- package/src/protocol/dashboard-server.ts +13 -2
- package/src/provider-approval.ts +59 -0
- package/src/provider-question.ts +31 -0
- package/src/quota-freshness.ts +139 -0
- package/src/relay-reprobe.ts +117 -0
- package/src/release.ts +121 -0
- package/src/role-launch.ts +51 -0
- package/src/session-launch.ts +17 -1
- package/src/slot-proposal.ts +61 -2
- package/src/task-source-phase.ts +61 -0
- package/src/turn-evidence.ts +27 -20
- package/src/turn-ipc-mission.ts +121 -11
- package/src/turn-ipc-queue.ts +29 -1
- package/src/turn-ipc-turn.ts +1 -1
- package/src/turn-ipc.ts +1 -0
- package/src/types.ts +1 -0
- package/src/worker-protocol.ts +15 -0
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
/** Daemon-local launch intent and command wire contract. P2P/local only;
|
|
2
|
+
* never include this document or its history in cloud status_report.
|
|
3
|
+
* Publication through mesh-shared's barrel is a later integration step. */
|
|
4
|
+
export declare const LAUNCH_DEFAULT_ROLES: readonly ["assistant", "coordinator"];
|
|
5
|
+
export type LaunchDefaultRole = typeof LAUNCH_DEFAULT_ROLES[number];
|
|
6
|
+
export declare const LAUNCH_DEFAULT_SOURCES: readonly ["user", "stored_default", "project_default", "provider_default"];
|
|
7
|
+
export type LaunchDefaultSource = typeof LAUNCH_DEFAULT_SOURCES[number];
|
|
8
|
+
export declare const LAUNCH_DEFAULTS_NEXT_LAUNCH_NOTE = "Applies to the next launch; running sessions are unchanged.";
|
|
9
|
+
export declare function isLaunchDefaultRole(value: unknown): value is LaunchDefaultRole;
|
|
10
|
+
export declare function isLaunchDefaultSource(value: unknown): value is LaunchDefaultSource;
|
|
11
|
+
export interface LaunchDefaultSelection {
|
|
12
|
+
provider: string;
|
|
13
|
+
/** Omission means pass no model/thinking argument, not inherit another provider. */
|
|
14
|
+
model?: string;
|
|
15
|
+
thinkingLevel?: string;
|
|
16
|
+
}
|
|
17
|
+
export type LaunchDefaultToolRestriction = 'enforced' | 'prompt_only';
|
|
18
|
+
export type LaunchDefaultOrigin = 'owner' | 'human' | 'relay' | 'review' | 'review_tainted';
|
|
19
|
+
export interface LaunchDefaultEntry extends LaunchDefaultSelection {
|
|
20
|
+
revision: number;
|
|
21
|
+
setBy: 'owner' | 'assistant';
|
|
22
|
+
setAt: number;
|
|
23
|
+
/** Ordered quota-failover alternatives (<= 3, distinct providers). Absent = none. */
|
|
24
|
+
fallback?: LaunchDefaultSelection[];
|
|
25
|
+
}
|
|
26
|
+
export interface LaunchDefaultChange {
|
|
27
|
+
at: number;
|
|
28
|
+
role: LaunchDefaultRole;
|
|
29
|
+
by: 'owner' | 'assistant';
|
|
30
|
+
origin: LaunchDefaultOrigin;
|
|
31
|
+
from: LaunchDefaultEntry | null;
|
|
32
|
+
to: LaunchDefaultEntry | null;
|
|
33
|
+
}
|
|
34
|
+
export interface LaunchDefaultsDocument {
|
|
35
|
+
version: 1;
|
|
36
|
+
/** Global document token, including clears; distinct from entry revisions. */
|
|
37
|
+
revision: number;
|
|
38
|
+
assistant?: LaunchDefaultEntry;
|
|
39
|
+
coordinator?: LaunchDefaultEntry;
|
|
40
|
+
history: LaunchDefaultChange[];
|
|
41
|
+
}
|
|
42
|
+
export interface LaunchDefaultRef {
|
|
43
|
+
role: LaunchDefaultRole;
|
|
44
|
+
scope: 'global' | 'project';
|
|
45
|
+
/** Entry revision for global defaults; host project token for project defaults. */
|
|
46
|
+
revision: number;
|
|
47
|
+
projectId?: string;
|
|
48
|
+
}
|
|
49
|
+
export type LaunchDefaultField = keyof LaunchDefaultSelection;
|
|
50
|
+
export interface LaunchDefaultAxis {
|
|
51
|
+
value: string | null;
|
|
52
|
+
source: LaunchDefaultSource;
|
|
53
|
+
defaultRef?: LaunchDefaultRef;
|
|
54
|
+
}
|
|
55
|
+
export type LaunchDefaultWarning = 'catalog_unverified' | 'manual_mcp_setup_required';
|
|
56
|
+
export type LaunchDefaultValidationReason = 'invalid_schema' | 'provider_unknown' | 'provider_not_cli' | 'provider_disabled' | 'provider_not_detected' | 'provider_not_eligible' | 'provider_quota_gated' | 'model_unsupported' | 'model_provider_mismatch' | 'model_not_offered' | 'thinking_unsupported' | 'thinking_not_offered' | 'catalog_unavailable';
|
|
57
|
+
export type LaunchDefaultResolution = {
|
|
58
|
+
ok: true;
|
|
59
|
+
selection: LaunchDefaultSelection;
|
|
60
|
+
applied: Record<LaunchDefaultField, LaunchDefaultAxis>;
|
|
61
|
+
defaultRef?: LaunchDefaultRef;
|
|
62
|
+
documentRevision: number;
|
|
63
|
+
warnings: LaunchDefaultWarning[];
|
|
64
|
+
toolRestriction: LaunchDefaultToolRestriction;
|
|
65
|
+
} | {
|
|
66
|
+
ok: false;
|
|
67
|
+
code: 'launch_default_required' | 'launch_default_unavailable' | 'launch_selection_invalid';
|
|
68
|
+
role: LaunchDefaultRole;
|
|
69
|
+
field: LaunchDefaultField;
|
|
70
|
+
reason: string;
|
|
71
|
+
source?: LaunchDefaultSource;
|
|
72
|
+
value?: string | null;
|
|
73
|
+
defaultRef?: LaunchDefaultRef;
|
|
74
|
+
candidates?: readonly string[];
|
|
75
|
+
hint: string;
|
|
76
|
+
};
|
|
77
|
+
export interface LaunchDefaultsRoleView {
|
|
78
|
+
stored: LaunchDefaultEntry | null;
|
|
79
|
+
/** The existing daemon resolver's result, including loud failures. */
|
|
80
|
+
effective: LaunchDefaultResolution;
|
|
81
|
+
}
|
|
82
|
+
type Target = {
|
|
83
|
+
role: 'assistant';
|
|
84
|
+
project?: never;
|
|
85
|
+
} | {
|
|
86
|
+
role: 'coordinator';
|
|
87
|
+
project?: string;
|
|
88
|
+
};
|
|
89
|
+
export type LaunchDefaultsReadRequest = ({
|
|
90
|
+
action?: 'get';
|
|
91
|
+
} & (Target | {
|
|
92
|
+
role?: never;
|
|
93
|
+
project?: never;
|
|
94
|
+
})) | ({
|
|
95
|
+
action: 'check';
|
|
96
|
+
} & Target & LaunchDefaultSelection);
|
|
97
|
+
/** Mandatory CAS: global document token, or host project token for project writes.
|
|
98
|
+
* 0 is explicit first setup; clears advance the token and never restore fallback. */
|
|
99
|
+
export type LaunchDefaultsSetRequest = Target & {
|
|
100
|
+
expectedRevision: number;
|
|
101
|
+
} & (({
|
|
102
|
+
action: 'set';
|
|
103
|
+
} & LaunchDefaultSelection) | {
|
|
104
|
+
action: 'clear';
|
|
105
|
+
provider?: never;
|
|
106
|
+
model?: never;
|
|
107
|
+
thinkingLevel?: never;
|
|
108
|
+
});
|
|
109
|
+
/** Existing assistant routing envelope; session identity never supplies origin. */
|
|
110
|
+
export type AssistantLaunchDefaultsReadRequest = LaunchDefaultsReadRequest & {
|
|
111
|
+
assistantSessionId?: string;
|
|
112
|
+
};
|
|
113
|
+
export type AssistantLaunchDefaultsSetRequest = LaunchDefaultsSetRequest & {
|
|
114
|
+
assistantSessionId?: string;
|
|
115
|
+
};
|
|
116
|
+
export declare const LAUNCH_DEFAULT_ERROR_CODES: readonly ["invalid_args", "launch_default_required", "launch_default_unavailable", "launch_selection_invalid", "launch_default_invalid", "revision_conflict", "store_unavailable", "store_busy", "persistence_failed", "project_not_found", "project_ambiguous", "project_not_hosted", "project_storage_unavailable", "staging_unavailable", "staging_failed", "review_turn_tool_denied"];
|
|
117
|
+
export type LaunchDefaultsErrorCode = typeof LAUNCH_DEFAULT_ERROR_CODES[number];
|
|
118
|
+
export interface LaunchDefaultsError {
|
|
119
|
+
success: false;
|
|
120
|
+
code: LaunchDefaultsErrorCode;
|
|
121
|
+
error: string;
|
|
122
|
+
reason?: string;
|
|
123
|
+
role?: LaunchDefaultRole;
|
|
124
|
+
field?: LaunchDefaultField;
|
|
125
|
+
source?: LaunchDefaultSource;
|
|
126
|
+
value?: string | null;
|
|
127
|
+
defaultRef?: LaunchDefaultRef;
|
|
128
|
+
candidates?: readonly string[];
|
|
129
|
+
actualRevision?: number;
|
|
130
|
+
/** 0 for an absent global document; absent when it cannot be read. */
|
|
131
|
+
documentRevision?: number;
|
|
132
|
+
/** A persistence failure can replace intent without confirming durability.
|
|
133
|
+
* Re-read before retrying; never report applied on committed:true alone. */
|
|
134
|
+
committed?: boolean;
|
|
135
|
+
}
|
|
136
|
+
export interface LaunchDefaultsReadSuccess {
|
|
137
|
+
success: true;
|
|
138
|
+
result: 'get';
|
|
139
|
+
documentRevision: number;
|
|
140
|
+
roles: Partial<Record<LaunchDefaultRole, LaunchDefaultsRoleView>>;
|
|
141
|
+
project?: {
|
|
142
|
+
projectId: string;
|
|
143
|
+
revision: number;
|
|
144
|
+
entry: LaunchDefaultEntry | null;
|
|
145
|
+
};
|
|
146
|
+
}
|
|
147
|
+
export interface LaunchDefaultsCheckSuccess {
|
|
148
|
+
success: true;
|
|
149
|
+
result: 'check';
|
|
150
|
+
role: LaunchDefaultRole;
|
|
151
|
+
selection: LaunchDefaultSelection;
|
|
152
|
+
warnings: LaunchDefaultWarning[];
|
|
153
|
+
toolRestriction: LaunchDefaultToolRestriction;
|
|
154
|
+
lowersToolLock: boolean;
|
|
155
|
+
}
|
|
156
|
+
export interface LaunchDefaultsApplied {
|
|
157
|
+
success: true;
|
|
158
|
+
result: 'applied';
|
|
159
|
+
role: LaunchDefaultRole;
|
|
160
|
+
scope: 'global' | 'project';
|
|
161
|
+
projectId?: string;
|
|
162
|
+
entry: LaunchDefaultEntry | null;
|
|
163
|
+
previous: LaunchDefaultEntry | null;
|
|
164
|
+
/** CAS token returned by the authority that performed the write. */
|
|
165
|
+
revision: number;
|
|
166
|
+
warnings: LaunchDefaultWarning[];
|
|
167
|
+
durable: true;
|
|
168
|
+
note: string;
|
|
169
|
+
}
|
|
170
|
+
export interface LaunchDefaultsStaged {
|
|
171
|
+
success: true;
|
|
172
|
+
result: 'staged';
|
|
173
|
+
role: LaunchDefaultRole;
|
|
174
|
+
stagedId: string;
|
|
175
|
+
previous: LaunchDefaultEntry | null;
|
|
176
|
+
selection: LaunchDefaultSelection | null;
|
|
177
|
+
expectedRevision: number;
|
|
178
|
+
warnings: LaunchDefaultWarning[];
|
|
179
|
+
note: string;
|
|
180
|
+
}
|
|
181
|
+
/** Existing owner Inbox adapter stores this proposal; it is not another default.
|
|
182
|
+
* Applying it must revalidate on the host and CAS via the same set handler. */
|
|
183
|
+
export interface LaunchDefaultsProposal {
|
|
184
|
+
kind: 'launch_defaults';
|
|
185
|
+
role: LaunchDefaultRole;
|
|
186
|
+
project?: string;
|
|
187
|
+
selection: LaunchDefaultSelection | null;
|
|
188
|
+
previous: LaunchDefaultEntry | null;
|
|
189
|
+
expectedRevision: number;
|
|
190
|
+
origin: LaunchDefaultOrigin;
|
|
191
|
+
callerSessionId?: string;
|
|
192
|
+
}
|
|
193
|
+
export type LaunchDefaultsReadResponse = LaunchDefaultsReadSuccess | LaunchDefaultsCheckSuccess | LaunchDefaultsError;
|
|
194
|
+
export type LaunchDefaultsSetResponse = LaunchDefaultsApplied | LaunchDefaultsStaged | LaunchDefaultsError;
|
|
195
|
+
export type LaunchDefaultsResponse = LaunchDefaultsReadResponse | LaunchDefaultsSetResponse;
|
|
196
|
+
export {};
|
|
@@ -18,10 +18,10 @@
|
|
|
18
18
|
* Order mirrors mcp-server `ALL_MESH_TOOLS` for easy visual diffing, but the consistency
|
|
19
19
|
* checks are set-based (order-insensitive).
|
|
20
20
|
*/
|
|
21
|
-
export declare const CANONICAL_MESH_TOOL_NAMES: readonly ["mesh_status", "mesh_route_preview", "mesh_list_nodes", "mesh_enqueue_batch", "mesh_enqueue_task", "mesh_view_queue", "mesh_queue_cancel", "mesh_queue_requeue", "mesh_send_task", "mesh_read_chat", "mesh_read_debug", "mesh_read_terminal", "mesh_send_keys", "mesh_launch_session", "mesh_git_status", "mesh_read_node_logs", "mesh_fast_forward_node", "mesh_restart_daemon", "mesh_checkpoint", "mesh_approve", "mesh_answer_question", "mesh_list_pending_approvals", "mesh_create", "mesh_add_node", "mesh_clone_node", "mesh_remove_node", "mesh_cleanup_worktree_nodes", "mesh_refine_node", "mesh_refine_batch", "mesh_config", "mesh_init", "mesh_cleanup_sessions", "mesh_task_history", "mesh_ledger_query", "mesh_note", "mesh_reconcile_ledger", "mesh_mission_upsert", "mesh_mission_list", "mesh_review_inbox", "mesh_node_slots"];
|
|
21
|
+
export declare const CANONICAL_MESH_TOOL_NAMES: readonly ["mesh_status", "mesh_route_preview", "mesh_list_nodes", "mesh_enqueue_batch", "mesh_enqueue_task", "mesh_view_queue", "mesh_queue_cancel", "mesh_direct_cancel", "mesh_queue_requeue", "mesh_queue_revise", "mesh_send_task", "mesh_read_chat", "mesh_read_debug", "mesh_read_terminal", "mesh_send_keys", "mesh_launch_session", "mesh_git_status", "mesh_read_node_logs", "mesh_fast_forward_node", "mesh_restart_daemon", "mesh_checkpoint", "mesh_approve", "mesh_answer_question", "mesh_list_pending_approvals", "mesh_create", "mesh_add_node", "mesh_reattach_source_parent", "mesh_attach_remote", "mesh_clone_node", "mesh_remove_node", "mesh_retry_node_bootstrap", "mesh_cleanup_worktree_nodes", "mesh_refine_node", "mesh_refine_batch", "mesh_config", "mesh_init", "mesh_cleanup_sessions", "mesh_task_history", "mesh_ledger_query", "mesh_note", "mesh_reconcile_ledger", "mesh_mission_upsert", "mesh_mission_list", "mesh_mission_git_eval", "mesh_release_upsert", "mesh_release_scope", "mesh_release_list", "mesh_release_record_deploy", "mesh_release_changelog_draft", "mesh_review_inbox", "mesh_node_slots", "driver_list", "driver_describe", "artifact_list", "artifact_read", "artifact_register"];
|
|
22
22
|
export type CanonicalMeshToolName = typeof CANONICAL_MESH_TOOL_NAMES[number];
|
|
23
23
|
/** The count the `NN tools` barrel doc comments and consistency test assert against. */
|
|
24
|
-
export declare const CANONICAL_MESH_TOOL_COUNT:
|
|
24
|
+
export declare const CANONICAL_MESH_TOOL_COUNT: 56;
|
|
25
25
|
/**
|
|
26
26
|
* Tool names retired by the 2026-09-26 tool-surface consolidation (60 → 48).
|
|
27
27
|
* Every capability behind them is still reachable: each retired name maps to the
|
|
@@ -15,9 +15,11 @@
|
|
|
15
15
|
* ./brain-routing.ts and are re-exported here for one-stop discovery.
|
|
16
16
|
*/
|
|
17
17
|
export { MESH_TASK_DIFFICULTIES, type MeshTaskDifficulty } from './brain-routing';
|
|
18
|
-
|
|
18
|
+
/** `blocked` ends a worker attempt pending external follow-up; only completed satisfies dependencies.
|
|
19
|
+
* Branch convergence (including blocked_review) remains an independent axis. */
|
|
20
|
+
export declare const MESH_TASK_STATUSES: readonly ["pending", "assigned", "completed", "blocked", "failed", "cancelled"];
|
|
19
21
|
export type MeshTaskStatus = typeof MESH_TASK_STATUSES[number];
|
|
20
|
-
export declare const MESH_TERMINAL_TASK_STATUSES: readonly ["completed", "failed", "cancelled"];
|
|
22
|
+
export declare const MESH_TERMINAL_TASK_STATUSES: readonly ["completed", "blocked", "failed", "cancelled"];
|
|
21
23
|
export type MeshTerminalTaskStatus = typeof MESH_TERMINAL_TASK_STATUSES[number];
|
|
22
24
|
export declare const MESH_TASK_MODES: readonly ["code_change", "validation", "live_debug_readonly", "launch_app", "convergence"];
|
|
23
25
|
export type MeshTaskMode = typeof MESH_TASK_MODES[number];
|
|
@@ -46,11 +48,18 @@ export type MeshSessionCleanupMode = typeof MESH_SESSION_CLEANUP_MODES[number];
|
|
|
46
48
|
/** Outcome a delegated worker may report through `report_completion`. */
|
|
47
49
|
export declare const WORKER_REPORT_OUTCOMES: readonly ["completed", "blocked", "failed"];
|
|
48
50
|
export type WorkerReportOutcome = typeof WORKER_REPORT_OUTCOMES[number];
|
|
51
|
+
/**
|
|
52
|
+
* Hard cap on a `report_completion` summary (characters, after trim). Over-limit
|
|
53
|
+
* summaries are REJECTED, never truncated. Declared once so the daemon validator
|
|
54
|
+
* and the mcp-server's pre-send check (which keeps an over-limit report out of the
|
|
55
|
+
* durable outbox) cannot drift apart.
|
|
56
|
+
*/
|
|
57
|
+
export declare const WORKER_REPORT_SUMMARY_MAX_CHARS = 8000;
|
|
49
58
|
/** Final branch state a worker reports (see coordinator convergence rules). */
|
|
50
59
|
export declare const WORKER_BRANCH_STATES: readonly ["merged_to_main", "pushed_feature_branch_needs_merge", "blocked_review", "cleanup_candidate", "not_mergeable"];
|
|
51
60
|
export type WorkerBranchState = typeof WORKER_BRANCH_STATES[number];
|
|
52
|
-
export declare const isMeshTaskStatus: (value: unknown) => value is "failed" | "
|
|
53
|
-
export declare const isMeshTerminalTaskStatus: (value: unknown) => value is "failed" | "completed" | "cancelled";
|
|
61
|
+
export declare const isMeshTaskStatus: (value: unknown) => value is "pending" | "failed" | "blocked" | "assigned" | "completed" | "cancelled";
|
|
62
|
+
export declare const isMeshTerminalTaskStatus: (value: unknown) => value is "failed" | "blocked" | "completed" | "cancelled";
|
|
54
63
|
export declare const isMeshTaskMode: (value: unknown) => value is "code_change" | "validation" | "live_debug_readonly" | "launch_app" | "convergence";
|
|
55
64
|
export declare const isMeshTaskPriority: (value: unknown) => value is "low" | "high" | "normal";
|
|
56
65
|
export declare const isMeshDeliveryMode: (value: unknown) => value is "when_idle" | "interrupt";
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* mission-git-state — types and the pure aggregation for "did this mission's
|
|
3
|
+
* referenced commits/branches land on the default branch?"
|
|
4
|
+
* (docs/design/2026-11-01-mission-git-refs.md §3).
|
|
5
|
+
*
|
|
6
|
+
* The facts come from the daemon opening git objects itself (never from
|
|
7
|
+
* commit-message text, branch-name similarity or worker prose). `landed` means
|
|
8
|
+
* ONLY "the referenced changes are on the base"; it never implies live
|
|
9
|
+
* acceptance, mission completion or that remaining items are done, and it is
|
|
10
|
+
* never used to change a mission's status.
|
|
11
|
+
*
|
|
12
|
+
* Dependency-free leaf: plain data in, plain data out.
|
|
13
|
+
*/
|
|
14
|
+
/** Per-ref verdict. `unknown` is never folded into `not_contained` nor promoted to `contained_*`. */
|
|
15
|
+
export declare const MISSION_REF_GIT_STATUSES: readonly ["contained_ancestor", "contained_patch_equivalent", "not_contained", "unknown"];
|
|
16
|
+
export type MissionRefGitStatus = typeof MISSION_REF_GIT_STATUSES[number];
|
|
17
|
+
/** How a contained verdict was reached. */
|
|
18
|
+
export declare const MISSION_REF_GIT_METHODS: readonly ["ancestry", "cherry", "residual_patch"];
|
|
19
|
+
export type MissionRefGitMethod = typeof MISSION_REF_GIT_METHODS[number];
|
|
20
|
+
/** Mission-level projection. */
|
|
21
|
+
export declare const MISSION_GIT_STATES: readonly ["no_refs", "landed", "partial", "not_landed", "unknown"];
|
|
22
|
+
export type MissionGitStateValue = typeof MISSION_GIT_STATES[number];
|
|
23
|
+
export declare function isMissionRefContained(status: MissionRefGitStatus): boolean;
|
|
24
|
+
/** Why a ref is `unknown` (detail.unknownReason). Free-form strings are tolerated on read. */
|
|
25
|
+
export type MissionRefUnknownReason = 'object_missing' | 'shallow' | 'undeterminable' | 'base_missing' | 'branch_not_found' | 'base_branch_ref' | 'gitlink_undeterminable' | 'merge_tree_failed' | 'node_offline' | 'no_repo' | 'budget' | 'not_a_git_ref';
|
|
26
|
+
export interface MissionRefGitDetail {
|
|
27
|
+
reasonCode?: string;
|
|
28
|
+
unknownReason?: MissionRefUnknownReason | string;
|
|
29
|
+
/** `modified_since_landing_possible`: main later touched the same lines — shown as a hint, not a verdict. */
|
|
30
|
+
note?: string;
|
|
31
|
+
nodeId?: string;
|
|
32
|
+
residualPatchId?: string;
|
|
33
|
+
ahead?: number;
|
|
34
|
+
behind?: number;
|
|
35
|
+
}
|
|
36
|
+
/** One stored per-ref evaluation (a row of `mesh_mission_ref_evals`). */
|
|
37
|
+
export interface MissionRefGitEval {
|
|
38
|
+
itemId: string;
|
|
39
|
+
/** `kind:repo:value` (normalized, lower-case SHA). */
|
|
40
|
+
refKey: string;
|
|
41
|
+
kind: 'commit' | 'branch';
|
|
42
|
+
value: string;
|
|
43
|
+
repo?: string;
|
|
44
|
+
/** Branch refs: the SHA the name resolved to at first evaluation (re-evaluation keeps using it). */
|
|
45
|
+
pinnedSha?: string;
|
|
46
|
+
baseRef: string;
|
|
47
|
+
baseSha?: string;
|
|
48
|
+
status: MissionRefGitStatus;
|
|
49
|
+
method?: MissionRefGitMethod;
|
|
50
|
+
detail?: MissionRefGitDetail;
|
|
51
|
+
evaluatedAt: string;
|
|
52
|
+
}
|
|
53
|
+
export interface MissionGitState {
|
|
54
|
+
missionId: string;
|
|
55
|
+
state: MissionGitStateValue;
|
|
56
|
+
/** `partial` only: some refs were `unknown` (not just `not_contained`). */
|
|
57
|
+
partialUnknown: boolean;
|
|
58
|
+
counts: {
|
|
59
|
+
total: number;
|
|
60
|
+
contained: number;
|
|
61
|
+
notContained: number;
|
|
62
|
+
unknown: number;
|
|
63
|
+
};
|
|
64
|
+
/** Base the newest evaluation compared against. */
|
|
65
|
+
baseRef?: string;
|
|
66
|
+
baseSha?: string;
|
|
67
|
+
/** Oldest `evaluatedAt` among the refs (the freshness floor). */
|
|
68
|
+
evaluatedAt?: string;
|
|
69
|
+
/** True when no row exists yet / the rows are older than the TTL — a refresh was (or can be) triggered. */
|
|
70
|
+
stale: boolean;
|
|
71
|
+
refs: MissionRefGitEval[];
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* Aggregate per-ref statuses (design §3.3):
|
|
75
|
+
* - none → `no_refs`; all contained → `landed`; some contained → `partial`
|
|
76
|
+
* (`partialUnknown` when any of the rest is `unknown`);
|
|
77
|
+
* - none contained: all `not_contained` → `not_landed`, otherwise `unknown`.
|
|
78
|
+
*/
|
|
79
|
+
export declare function aggregateMissionGitState(statuses: readonly MissionRefGitStatus[]): {
|
|
80
|
+
state: MissionGitStateValue;
|
|
81
|
+
partialUnknown: boolean;
|
|
82
|
+
counts: MissionGitState['counts'];
|
|
83
|
+
};
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* mission-items — structured mission records: the item kinds a mission carries
|
|
3
|
+
* (remaining work, live checks, owner decisions, evidence), their normalization
|
|
4
|
+
* and limits, dedupe-key derivation and the close outcome enum
|
|
5
|
+
* (docs/design/2026-10-28-structured-missions-and-owner-decisions.md §4, §5).
|
|
6
|
+
*
|
|
7
|
+
* Philosophy (owner 2026-10-28, design §0): NEVER reject for size or shape —
|
|
8
|
+
* over-long text is truncated, extra refs are dropped, unusable items are
|
|
9
|
+
* reported per-item. The only hard rule lives elsewhere (the daemon): a
|
|
10
|
+
* coordinator or worker can never ANSWER a decision, so `answer`/`delivery`
|
|
11
|
+
* are stripped from every caller-supplied `decision` here.
|
|
12
|
+
*
|
|
13
|
+
* Dependency-free leaf: pure functions over plain data, no storage.
|
|
14
|
+
*/
|
|
15
|
+
export declare const MISSION_ITEM_KINDS: readonly ["remaining", "live_check", "decision", "evidence"];
|
|
16
|
+
export type MissionItemKind = typeof MISSION_ITEM_KINDS[number];
|
|
17
|
+
export declare const MISSION_ITEM_STATES: readonly ["open", "done", "failed", "dropped", "moved", "answered", "expired", "withdrawn", "superseded"];
|
|
18
|
+
export type MissionItemState = typeof MISSION_ITEM_STATES[number];
|
|
19
|
+
/** States a coordinator/worker may SET through items_update, per kind. `answered`/`expired`/`failed` (owner live-check verdict) are daemon-owned. */
|
|
20
|
+
export declare const COORDINATOR_SETTABLE_ITEM_STATES: Readonly<Record<MissionItemKind, readonly MissionItemState[]>>;
|
|
21
|
+
export declare const MISSION_OUTCOMES: readonly ["merged", "verified_live", "superseded", "not_needed", "owner_abandoned", "unspecified"];
|
|
22
|
+
export type MissionOutcome = typeof MISSION_OUTCOMES[number];
|
|
23
|
+
export declare function isMissionOutcome(value: unknown): value is MissionOutcome;
|
|
24
|
+
export declare const MISSION_REF_KINDS: readonly ["commit", "branch", "pr", "task", "artifact", "mission", "url"];
|
|
25
|
+
export type MissionRefKind = typeof MISSION_REF_KINDS[number];
|
|
26
|
+
export declare const MISSION_LIMITS: {
|
|
27
|
+
readonly summary: 300;
|
|
28
|
+
readonly outcomeReason: 500;
|
|
29
|
+
readonly itemText: 300;
|
|
30
|
+
readonly machine: 80;
|
|
31
|
+
readonly refs: 8;
|
|
32
|
+
readonly refValue: 300;
|
|
33
|
+
readonly refRepo: 120;
|
|
34
|
+
readonly refNote: 200;
|
|
35
|
+
readonly dedupeKey: 400;
|
|
36
|
+
readonly question: 300;
|
|
37
|
+
readonly context: 600;
|
|
38
|
+
readonly options: 5;
|
|
39
|
+
readonly optionLabel: 60;
|
|
40
|
+
readonly optionDetail: 200;
|
|
41
|
+
/** Open items per mission before the oldest `remaining` fold into a "N more" summary item. */
|
|
42
|
+
readonly openItemsPerMission: 200;
|
|
43
|
+
/** One event payload (serialized). */
|
|
44
|
+
readonly eventPayloadBytes: number;
|
|
45
|
+
/** items_add / items_update entries honoured per call (extra entries are reported, not applied). */
|
|
46
|
+
readonly itemsPerCall: 50;
|
|
47
|
+
};
|
|
48
|
+
export declare const MISSION_DECISION_OPTION_IDS: readonly ["a", "b", "c", "d", "e"];
|
|
49
|
+
export declare const MISSION_DECISION_URGENCIES: readonly ["normal", "blocking"];
|
|
50
|
+
export type MissionDecisionUrgency = typeof MISSION_DECISION_URGENCIES[number];
|
|
51
|
+
export declare const MISSION_DECISION_ON_DUE: readonly ["remind", "apply_recommended"];
|
|
52
|
+
export type MissionDecisionOnDue = typeof MISSION_DECISION_ON_DUE[number];
|
|
53
|
+
export interface MissionItemRef {
|
|
54
|
+
kind: MissionRefKind;
|
|
55
|
+
repo?: string;
|
|
56
|
+
value: string;
|
|
57
|
+
note?: string;
|
|
58
|
+
}
|
|
59
|
+
export interface MissionDecisionOption {
|
|
60
|
+
id: string;
|
|
61
|
+
label: string;
|
|
62
|
+
detail?: string;
|
|
63
|
+
}
|
|
64
|
+
/** Who/where an answer came from. Written only by the daemon's (owner-side) answer path — never from tool input. */
|
|
65
|
+
export interface MissionDecisionAnswer {
|
|
66
|
+
optionId?: string;
|
|
67
|
+
text?: string;
|
|
68
|
+
by: 'owner' | 'auto_recommended';
|
|
69
|
+
via: 'dashboard' | 'assistant' | 'push' | 'cli' | 'auto';
|
|
70
|
+
interpretedFrom?: string;
|
|
71
|
+
at: string;
|
|
72
|
+
ingress?: string;
|
|
73
|
+
}
|
|
74
|
+
export interface MissionDecisionDelivery {
|
|
75
|
+
messageId: string;
|
|
76
|
+
/**
|
|
77
|
+
* `queued`: the coordinator's input queue accepted it but has not typed it yet — the daemon
|
|
78
|
+
* confirms it against the send receipt (a daemon restart drops that queue). Daemon-written.
|
|
79
|
+
*/
|
|
80
|
+
state: 'pending' | 'queued' | 'sent' | 'acked';
|
|
81
|
+
lastAttemptAt?: string;
|
|
82
|
+
/** Coordinator session + funnel messageId of a `queued` delivery (receipt lookup). Daemon-written. */
|
|
83
|
+
sessionId?: string;
|
|
84
|
+
wireMessageId?: string;
|
|
85
|
+
/** Failed send attempts of this revision (retry backoff). Daemon-written. */
|
|
86
|
+
attempts?: number;
|
|
87
|
+
/** What the coordinator is told: a first answer, a changed answer, or an undone one. Daemon-written. */
|
|
88
|
+
kind?: 'answered' | 'changed' | 'undone';
|
|
89
|
+
}
|
|
90
|
+
export interface MissionDecision {
|
|
91
|
+
question: string;
|
|
92
|
+
context?: string;
|
|
93
|
+
options: MissionDecisionOption[];
|
|
94
|
+
recommended?: string;
|
|
95
|
+
allowFreeText: boolean;
|
|
96
|
+
dueAt?: string;
|
|
97
|
+
onDue: MissionDecisionOnDue;
|
|
98
|
+
urgency: MissionDecisionUrgency;
|
|
99
|
+
answer?: MissionDecisionAnswer;
|
|
100
|
+
delivery?: MissionDecisionDelivery;
|
|
101
|
+
/**
|
|
102
|
+
* Coordinator-prompt watermark (bundle B): ISO time the coordinator last "saw" this item's
|
|
103
|
+
* answer. An answered decision is shown in the coordinator prompt while this is absent or
|
|
104
|
+
* older than `answer.at` (a changed answer re-surfaces). Written only by the daemon.
|
|
105
|
+
*/
|
|
106
|
+
promptAckedAt?: string;
|
|
107
|
+
/** Counts answer writes (answer / change / undo); delivery messageIds are `decision:<itemId>:r<n>`. Daemon-written. */
|
|
108
|
+
answerRevision?: number;
|
|
109
|
+
/** ISO time an `onDue: remind` crossing was recorded (once per dueAt). Daemon-written. */
|
|
110
|
+
remindedAt?: string;
|
|
111
|
+
}
|
|
112
|
+
export interface NormalizedMissionItem {
|
|
113
|
+
kind: MissionItemKind;
|
|
114
|
+
text: string;
|
|
115
|
+
machine?: string;
|
|
116
|
+
refs: MissionItemRef[];
|
|
117
|
+
decision?: MissionDecision;
|
|
118
|
+
dedupeKey: string;
|
|
119
|
+
/** Fields that were truncated/dropped — informational, never an error. */
|
|
120
|
+
truncated: string[];
|
|
121
|
+
}
|
|
122
|
+
export declare function truncateMissionText(value: string, max: number): string;
|
|
123
|
+
export declare function normalizeMissionSummary(value: unknown): {
|
|
124
|
+
value: string;
|
|
125
|
+
truncated: boolean;
|
|
126
|
+
} | null;
|
|
127
|
+
export declare function normalizeOutcomeReason(value: unknown): {
|
|
128
|
+
value: string;
|
|
129
|
+
truncated: boolean;
|
|
130
|
+
} | null;
|
|
131
|
+
/** Refs: ≤8, `{kind, repo?, value, note?}`. Unusable entries are dropped; the 9th and later are dropped. */
|
|
132
|
+
export declare function normalizeMissionRefs(value: unknown): {
|
|
133
|
+
refs: MissionItemRef[];
|
|
134
|
+
truncated: boolean;
|
|
135
|
+
};
|
|
136
|
+
/**
|
|
137
|
+
* Caller-supplied decision → stored shape. `answer`/`delivery` (and any other
|
|
138
|
+
* unknown key) are DROPPED: a coordinator/worker cannot pre-answer its own
|
|
139
|
+
* question. `recommended` must name one of the options, else it is dropped.
|
|
140
|
+
*/
|
|
141
|
+
export declare function normalizeDecisionInput(raw: Record<string, unknown>, truncated: string[]): MissionDecision | null;
|
|
142
|
+
/** Normalized text for dedupe: lower-case, whitespace-collapsed, trailing punctuation trimmed. */
|
|
143
|
+
export declare function normalizeForDedupe(text: string): string;
|
|
144
|
+
export declare function deriveItemDedupeKey(kind: MissionItemKind, parts: {
|
|
145
|
+
text?: string;
|
|
146
|
+
machine?: string;
|
|
147
|
+
refs?: readonly MissionItemRef[];
|
|
148
|
+
question?: string;
|
|
149
|
+
explicit?: string;
|
|
150
|
+
}): string;
|
|
151
|
+
/**
|
|
152
|
+
* Normalize one caller-supplied `items_add[]` entry. Returns `null` + `error`
|
|
153
|
+
* only when nothing usable remains (no text/question) — everything else is
|
|
154
|
+
* clamped, never rejected.
|
|
155
|
+
*/
|
|
156
|
+
export declare function normalizeMissionItemInput(raw: unknown): {
|
|
157
|
+
item: NormalizedMissionItem;
|
|
158
|
+
} | {
|
|
159
|
+
error: string;
|
|
160
|
+
};
|
|
161
|
+
export interface MissionItemUpdateInput {
|
|
162
|
+
id: string;
|
|
163
|
+
state?: MissionItemState;
|
|
164
|
+
text?: string;
|
|
165
|
+
machine?: string | null;
|
|
166
|
+
refs?: MissionItemRef[];
|
|
167
|
+
}
|
|
168
|
+
/** Normalize one `items_update[]` entry (id required). The kind-specific state rule is applied by the daemon, which knows the stored kind. */
|
|
169
|
+
export declare function normalizeMissionItemUpdate(raw: unknown): {
|
|
170
|
+
update: MissionItemUpdateInput;
|
|
171
|
+
truncated: string[];
|
|
172
|
+
} | {
|
|
173
|
+
error: string;
|
|
174
|
+
};
|
|
175
|
+
/** Cap a serialized event payload at {@link MISSION_LIMITS.eventPayloadBytes}; over-size payloads become a stub that says so. */
|
|
176
|
+
export declare function boundEventPayload(payload: Record<string, unknown>): string;
|
|
177
|
+
/** The carry-over mission's fixed title (design §5.1). */
|
|
178
|
+
export declare const CARRY_OVER_MISSION_TITLE = "Carry-over \u2014 open items from closed missions";
|
|
179
|
+
/** The title earlier builds stored; existing DBs still hold it, so it keeps matching (no rename). */
|
|
180
|
+
export declare const LEGACY_CARRY_OVER_MISSION_TITLE = "\uC774\uC6D4 \u2014 \uB2EB\uD78C \uBBF8\uC158\uC5D0\uC11C \uB118\uC5B4\uC628 \uD56D\uBAA9";
|
|
181
|
+
/** Canonical goal text of a newly created carry-over mission. */
|
|
182
|
+
export declare const CARRY_OVER_MISSION_GOAL = "Open items carried over from closed missions, and decisions requested without a mission. Managed automatically \u2014 do not close.";
|
|
183
|
+
/**
|
|
184
|
+
* THE one predicate for "is this the auto carry-over mission". The daemon's `is_carry_over`
|
|
185
|
+
* column (`isCarryOver`) is the source of truth; wire views that cannot carry the flag (older
|
|
186
|
+
* strict decoders reject unknown keys) fall back to the fixed title. Use this everywhere.
|
|
187
|
+
*/
|
|
188
|
+
export declare function isCarryOverMissionRecord(m: {
|
|
189
|
+
isCarryOver?: boolean;
|
|
190
|
+
title?: unknown;
|
|
191
|
+
} | null | undefined): boolean;
|
|
192
|
+
/** The carry-over mission's title is fixed (the daemon ignores renames), so a title match identifies it on wire views that carry no flag. */
|
|
193
|
+
export declare function isCarryOverMissionTitle(title: unknown): boolean;
|
|
194
|
+
/** Prefix of the owner-confirmation decision a coordinator's `owner_abandoned` close creates. */
|
|
195
|
+
export declare const OWNER_ABANDON_CONFIRM_KEY_PREFIX = "owner-abandon-confirm:";
|
|
196
|
+
export declare const OWNER_ABANDON_CONFIRM_QUESTION = "The coordinator closed this as 'owner abandoned' \u2014 correct?";
|
|
197
|
+
export declare const OWNER_ABANDON_CONFIRM_OPTIONS: readonly ["Correct", "Reopen"];
|
|
198
|
+
/** worker `report_completion.decisions_needed` cap. */
|
|
199
|
+
export declare const WORKER_DECISIONS_NEEDED_MAX = 3;
|
|
200
|
+
/** worker `report_completion.commits` cap and shape. */
|
|
201
|
+
export declare const WORKER_COMMITS_MAX = 20;
|
|
202
|
+
export declare function normalizeReportCommits(value: unknown): string[] | null;
|
package/dist/node-facts.d.ts
CHANGED
|
@@ -94,6 +94,20 @@ export interface MeshNodeFactsProviderQuota {
|
|
|
94
94
|
* rather than presenting them as a freshly measured value.
|
|
95
95
|
*/
|
|
96
96
|
lastGoodWindows?: boolean;
|
|
97
|
+
/**
|
|
98
|
+
* Unix ms the reporting node's NEXT scheduled retry of this transient
|
|
99
|
+
* failure is due (HTTP Retry-After wins when later). Re-stamped to the
|
|
100
|
+
* real backoff time on every failure — see daemon-core
|
|
101
|
+
* `updateFailureRetry`. Absent on persistent failures and on daemons
|
|
102
|
+
* predating the stamp.
|
|
103
|
+
*/
|
|
104
|
+
retryAtMs?: number;
|
|
105
|
+
/**
|
|
106
|
+
* True once the node has spent its bounded transient-retry budget and
|
|
107
|
+
* stopped retrying; the next look is the hourly backfill. Readers must
|
|
108
|
+
* stop calling retained numbers "refreshing" (`assessQuotaFreshness`).
|
|
109
|
+
*/
|
|
110
|
+
retryExhausted?: boolean;
|
|
97
111
|
/**
|
|
98
112
|
* Unix ms when the reporting node last ATTEMPTED a refresh of this
|
|
99
113
|
* provider — deliberately distinct from `updatedAt`, which dates the
|
|
@@ -109,6 +123,41 @@ export interface MeshNodeFactsProviderQuota {
|
|
|
109
123
|
* predating the field.
|
|
110
124
|
*/
|
|
111
125
|
fetchedAt?: number;
|
|
126
|
+
/**
|
|
127
|
+
* Provenance of the RETAINED reading when `lastGoodWindows` is true —
|
|
128
|
+
* the source/plan/measurement time of the snapshot that produced the
|
|
129
|
+
* carried numbers, as opposed to the top-level `source`/`planType`,
|
|
130
|
+
* which describe the fresh failed attempt. See daemon-core
|
|
131
|
+
* `QuotaMetadata.lastGood`.
|
|
132
|
+
*/
|
|
133
|
+
lastGood?: {
|
|
134
|
+
measuredAt: number;
|
|
135
|
+
source?: string;
|
|
136
|
+
planType?: string | null;
|
|
137
|
+
collectorScope?: string;
|
|
138
|
+
};
|
|
139
|
+
/**
|
|
140
|
+
* `'background-collector'` when the snapshot came from a daemon-spawned
|
|
141
|
+
* probe rather than an executing CLI session; a failure with this scope
|
|
142
|
+
* is not evidence about a running session's sign-in.
|
|
143
|
+
*/
|
|
144
|
+
collectorScope?: string;
|
|
145
|
+
/**
|
|
146
|
+
* DISPLAY-ONLY copy of the last numbers this node measured when it can
|
|
147
|
+
* no longer prove they belong to the CURRENT account (lineage unknown,
|
|
148
|
+
* or the failure left no confirmed match). Never read by routing, gates
|
|
149
|
+
* or ranking: those keep treating the entry as unknown. Dashboards show
|
|
150
|
+
* it marked "account unconfirmed" with its age. Never set across a
|
|
151
|
+
* CONFIRMED account switch (both accounts known and different).
|
|
152
|
+
*/
|
|
153
|
+
unconfirmedReading?: {
|
|
154
|
+
/** Unix ms the numbers were measured. */
|
|
155
|
+
measuredAt: number;
|
|
156
|
+
session?: MeshNodeFactsQuotaWindow | null;
|
|
157
|
+
weekly?: MeshNodeFactsQuotaWindow | null;
|
|
158
|
+
monthly?: MeshNodeFactsQuotaWindow | null;
|
|
159
|
+
buckets?: MeshNodeFactsProviderQuota['buckets'];
|
|
160
|
+
};
|
|
112
161
|
[extra: string]: unknown;
|
|
113
162
|
};
|
|
114
163
|
[extra: string]: unknown;
|
|
@@ -132,6 +181,13 @@ export interface MeshNodeFactsProviderEnablement {
|
|
|
132
181
|
}
|
|
133
182
|
export interface MeshNodeFacts {
|
|
134
183
|
schemaVersion: number;
|
|
184
|
+
/** Cached CLI detection only; no paths or account data. */
|
|
185
|
+
providerInventory?: {
|
|
186
|
+
observedAt: number;
|
|
187
|
+
providers: Record<string, {
|
|
188
|
+
installed: boolean;
|
|
189
|
+
}>;
|
|
190
|
+
};
|
|
135
191
|
reportedAt: number;
|
|
136
192
|
daemonBuild?: MeshNodeFactsDaemonBuild;
|
|
137
193
|
providerVersions?: Record<string, string>;
|
|
@@ -194,6 +250,24 @@ export interface MeshNodeFacts {
|
|
|
194
250
|
* Booleans keyed by provider type only — no free text, no credentials.
|
|
195
251
|
*/
|
|
196
252
|
providerEnablement?: Record<string, MeshNodeFactsProviderEnablement>;
|
|
253
|
+
/**
|
|
254
|
+
* The reporting machine's stored quota RESERVE (daemon-core
|
|
255
|
+
* `ADHDevConfig.quotaReserve`, sparse, ≤ 2 KB, migration audit trail
|
|
256
|
+
* stripped): the "how much quota to leave for the person" bar that the
|
|
257
|
+
* coordinator's launch gate applies to THIS machine's snapshots.
|
|
258
|
+
* ★ABSENT means "this node did not tell us" (older daemon) and resolves to
|
|
259
|
+
* the code defaults — the same fail-open direction as before the field
|
|
260
|
+
* existed. Percentages, durations and hashed account keys only; no free
|
|
261
|
+
* text, no emails. Resolve with daemon-core `resolveQuotaReserve`; never
|
|
262
|
+
* read its fields directly.
|
|
263
|
+
*/
|
|
264
|
+
quotaReserve?: {
|
|
265
|
+
version: 1;
|
|
266
|
+
defaults?: Record<string, number>;
|
|
267
|
+
pools?: Record<string, Record<string, number>>;
|
|
268
|
+
accounts?: Record<string, Record<string, Record<string, number>>>;
|
|
269
|
+
updatedAt?: string;
|
|
270
|
+
};
|
|
197
271
|
/** Future fields ride through opaquely — do not enumerate them in relays. */
|
|
198
272
|
[extra: string]: unknown;
|
|
199
273
|
}
|
|
@@ -238,7 +312,7 @@ export declare function normalizeMeshNodeFacts(raw: unknown): MeshNodeFacts | un
|
|
|
238
312
|
* the host `agy` itself uses; the unprefixed `cloudcode-pa` host 429s Google
|
|
239
313
|
* AI Pro Antigravity accounts), and its credential lives in the OS keyring,
|
|
240
314
|
* not the stale on-disk token file — see the provenance note in daemon-core
|
|
241
|
-
* `quota/fetchers/antigravity.ts`. Supported on macOS and
|
|
315
|
+
* `quota/fetchers/antigravity.ts`. Supported on macOS, Windows, and Linux; other
|
|
242
316
|
* platforms report `unsupported` rather than guess at a keyring backend
|
|
243
317
|
* nobody has verified.
|
|
244
318
|
*
|