@wrongstack/core 0.260.0 → 0.265.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/dist/{agent-bridge-BbskZ7HH.d.ts → agent-bridge-DrkBxszZ.d.ts} +1 -1
- package/dist/{agent-subagent-runner-BNIGZx18.d.ts → agent-subagent-runner-DM2pP-B6.d.ts} +116 -12
- package/dist/{brain-C2yDd7Lw.d.ts → brain-BXd_61kQ.d.ts} +32 -3
- package/dist/{compactor-t0R_AIt_.d.ts → compactor-B8pOf45Y.d.ts} +1 -1
- package/dist/{config-FG6As4H5.d.ts → config-BMCj_XDs.d.ts} +86 -12
- package/dist/{context-JFOVvu6z.d.ts → context-MRk5PhNv.d.ts} +26 -1
- package/dist/coordination/index.d.ts +1737 -15
- package/dist/coordination/index.js +3152 -494
- package/dist/coordination/index.js.map +1 -1
- package/dist/{default-config-CXsDvOmP.d.ts → default-config-B0cj-Hry.d.ts} +11 -1
- package/dist/defaults/index.d.ts +28 -28
- package/dist/defaults/index.js +1804 -1363
- package/dist/defaults/index.js.map +1 -1
- package/dist/dispatcher-types.d-BBeXBQgS.d.ts +66 -0
- package/dist/execution/index.d.ts +16 -16
- package/dist/execution/index.js +933 -672
- package/dist/execution/index.js.map +1 -1
- package/dist/execution/prompt-enhancer.d.ts +1 -1
- package/dist/execution/prompt-enhancer.js +7 -1
- package/dist/execution/prompt-enhancer.js.map +1 -1
- package/dist/extension/index.d.ts +6 -6
- package/dist/extension/index.js.map +1 -1
- package/dist/{goal-preamble-B1IXJtLX.d.ts → goal-preamble-DvHDSKSe.d.ts} +26 -10
- package/dist/{goal-store-CPXz6Mml.d.ts → goal-store-DtLMySNb.d.ts} +1 -1
- package/dist/{index-CebbJB94.d.ts → index-B-ch8K9C.d.ts} +8 -8
- package/dist/{index-BPcg4N3M.d.ts → index-CEDeNodM.d.ts} +5 -5
- package/dist/index.d.ts +189 -104
- package/dist/index.js +24693 -21162
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/index.d.ts +6 -6
- package/dist/infrastructure/index.js +12 -8
- package/dist/infrastructure/index.js.map +1 -1
- package/dist/kernel/index.d.ts +9 -9
- package/dist/kernel/index.js +7 -2
- package/dist/kernel/index.js.map +1 -1
- package/dist/{llm-selector-DXxI2tlu.d.ts → llm-selector-C0tfTCUe.d.ts} +14 -2
- package/dist/{mcp-servers-OwNHo43-.d.ts → mcp-servers-2x4w6Jn9.d.ts} +3 -3
- package/dist/models/index.d.ts +5 -5
- package/dist/models/index.js +80 -31
- package/dist/models/index.js.map +1 -1
- package/dist/{models-registry-Djlmq4uB.d.ts → models-registry-DmJlKuNp.d.ts} +1 -1
- package/dist/{multi-agent-coordinator-CEmrSCMJ.d.ts → multi-agent-coordinator-DyCkCZnU.d.ts} +2 -2
- package/dist/{null-fleet-bus-DT92xqgJ.d.ts → null-fleet-bus-CG9QY2aP.d.ts} +6 -6
- package/dist/observability/index.d.ts +2 -2
- package/dist/observability/index.js +8 -3
- package/dist/observability/index.js.map +1 -1
- package/dist/{parallel-eternal-engine-0SItuq5r.d.ts → parallel-eternal-engine-Jw9uhEoT.d.ts} +9 -9
- package/dist/{path-resolver-DKBh6Jlo.d.ts → path-resolver-Dy2ej-gE.d.ts} +3 -3
- package/dist/{permission-BJ7eO9Vl.d.ts → permission-B9SB45lp.d.ts} +1 -1
- package/dist/{permission-policy-DEXOfnpm.d.ts → permission-policy-CkjSXabK.d.ts} +2 -2
- package/dist/{pipeline-zflkI2dp.d.ts → pipeline-DPDxH_7m.d.ts} +59 -4
- package/dist/{plan-templates-BFXyRkEK.d.ts → plan-templates-CzD9GnAU.d.ts} +32 -8
- package/dist/{provider-runner-BC-uywtT.d.ts → provider-runner-DMa70ODu.d.ts} +3 -3
- package/dist/{retry-policy-Cavrzmtk.d.ts → retry-policy-CN0khdlj.d.ts} +1 -1
- package/dist/sdd/index.d.ts +8 -8
- package/dist/sdd/index.js +313 -122
- package/dist/sdd/index.js.map +1 -1
- package/dist/{secret-vault-CDvDYXWX.d.ts → secret-vault-B2yw84VT.d.ts} +43 -4
- package/dist/secret-vault-BAKpgFw_.d.ts +57 -0
- package/dist/security/index.d.ts +5 -5
- package/dist/security/index.js +411 -225
- package/dist/security/index.js.map +1 -1
- package/dist/{selector-B7AivHsu.d.ts → selector-CzHh_igB.d.ts} +1 -1
- package/dist/{session-event-bridge-BmIDxdJd.d.ts → session-event-bridge-BUI6Jf-4.d.ts} +8 -2
- package/dist/{session-reader-DtofsB-2.d.ts → session-reader-CMgdMSRP.d.ts} +1 -1
- package/dist/skills/index.js +67 -64
- package/dist/skills/index.js.map +1 -1
- package/dist/storage/index.d.ts +132 -16
- package/dist/storage/index.js +851 -432
- package/dist/storage/index.js.map +1 -1
- package/dist/tools/index.d.ts +57 -0
- package/dist/tools/index.js +411 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/types/index.d.ts +21 -21
- package/dist/types/index.js +928 -711
- package/dist/types/index.js.map +1 -1
- package/dist/utils/error.d.ts +7 -0
- package/dist/utils/error.js +8 -0
- package/dist/utils/error.js.map +1 -0
- package/dist/utils/index.d.ts +8 -68
- package/dist/utils/index.js +20 -10
- package/dist/utils/index.js.map +1 -1
- package/dist/{wstack-paths-CJjEwPXn.d.ts → wstack-paths-hOpNLmvf.d.ts} +2 -0
- package/package.json +5 -1
- package/skills/api-design/SKILL.md +1 -1
- package/skills/audit-log/SKILL.md +6 -6
- package/skills/bug-hunter/SKILL.md +5 -5
- package/skills/chimera/SKILL.md +4 -4
- package/skills/docker-deploy/SKILL.md +1 -1
- package/skills/git-flow/SKILL.md +3 -3
- package/skills/multi-agent/SKILL.md +3 -3
- package/skills/node-modern/SKILL.md +1 -0
- package/skills/observability/SKILL.md +2 -2
- package/skills/output-standards/SKILL.md +51 -28
- package/skills/refactor-planner/SKILL.md +3 -3
- package/skills/security-scanner/SKILL.md +4 -3
- package/skills/tech-stack/SKILL.md +1 -2
- package/dist/package-outdated-watcher-C70ag2G9.d.ts +0 -581
- package/dist/secret-vault-BJDY28ev.d.ts +0 -25
package/dist/storage/index.d.ts
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { M as MemoryBackend, j as FileMemoryBackendOptions } from '../plan-templates-
|
|
2
|
-
export { A as AbandonedSession, a as AttachmentStoreOptions, C as ConfigLoaderOptions, b as ConfigMigration, c as ConfigMigrationError, d as ConfigSource, D as DEFAULT_CONFIG_MIGRATIONS, e as DefaultAttachmentStore, f as DefaultConfigLoader, g as DefaultConfigStore, h as DefaultMemoryStore, i as DefaultSessionStore, F as FileMemoryBackend, k as MemoryStoreOptions, l as MigrationContext, m as MigrationResult, P as PersistedQueueItem, n as PlanFile, o as PlanItem, p as PlanTemplate, Q as QueueStore, R as RecoveryLock, q as RecoveryLockOptions, S as SessionAnalyzer, r as SessionStoreOptions, T as TodosCheckpointFile, s as addPlanItem, t as attachPlanCheckpoint, u as attachTodosCheckpoint, v as clearPlan, w as deriveTodosFromPlanItem, x as emptyPlan, y as formatPlan, z as formatPlanTemplates, B as getPlanTemplate, E as listPlanTemplates, G as loadPlan, H as loadTodosCheckpoint, I as mutatePlan, J as parseEntries, K as removePlanItem, L as runConfigMigrations, N as savePlan, O as saveTodosCheckpoint, U as setPlanItemStatus } from '../plan-templates-
|
|
3
|
-
import { M as MemoryScope,
|
|
4
|
-
import { l as AgentExtension, j as AfterRunHook } from '../index-
|
|
5
|
-
import { P as Provider, R as Request, b as Response, S as SessionEvent } from '../context-
|
|
6
|
-
export { D as DefaultSessionReader, f as DefaultSessionReaderOptions, S as SessionReader } from '../session-reader-
|
|
1
|
+
import { M as MemoryBackend, j as FileMemoryBackendOptions } from '../plan-templates-CzD9GnAU.js';
|
|
2
|
+
export { A as AbandonedSession, a as AttachmentStoreOptions, C as ConfigLoaderOptions, b as ConfigMigration, c as ConfigMigrationError, d as ConfigSource, D as DEFAULT_CONFIG_MIGRATIONS, e as DefaultAttachmentStore, f as DefaultConfigLoader, g as DefaultConfigStore, h as DefaultMemoryStore, i as DefaultSessionStore, F as FileMemoryBackend, k as MemoryStoreOptions, l as MigrationContext, m as MigrationResult, P as PersistedQueueItem, n as PlanFile, o as PlanItem, p as PlanTemplate, Q as QueueStore, R as RecoveryLock, q as RecoveryLockOptions, S as SessionAnalyzer, r as SessionStoreOptions, T as TodosCheckpointFile, s as addPlanItem, t as attachPlanCheckpoint, u as attachTodosCheckpoint, v as clearPlan, w as deriveTodosFromPlanItem, x as emptyPlan, y as formatPlan, z as formatPlanTemplates, B as getPlanTemplate, E as listPlanTemplates, G as loadPlan, H as loadTodosCheckpoint, I as mutatePlan, J as parseEntries, K as removePlanItem, L as runConfigMigrations, N as savePlan, O as saveTodosCheckpoint, U as setPlanItemStatus } from '../plan-templates-CzD9GnAU.js';
|
|
3
|
+
import { M as MemoryScope, b as MemoryEntry, c as MemoryStore, E as EventBus } from '../brain-BXd_61kQ.js';
|
|
4
|
+
import { l as AgentExtension, j as AfterRunHook } from '../index-CEDeNodM.js';
|
|
5
|
+
import { P as Provider, R as Request, b as Response, S as SessionEvent } from '../context-MRk5PhNv.js';
|
|
6
|
+
export { D as DefaultSessionReader, f as DefaultSessionReaderOptions, S as SessionReader } from '../session-reader-CMgdMSRP.js';
|
|
7
7
|
import { S as SessionRewinder, C as CheckpointInfo, a as RewindResultExtended } from '../session-rewinder-C9HnMkhP.js';
|
|
8
8
|
import { T as TaskItem } from '../task-format-vGOIftmK.js';
|
|
9
9
|
export { a as DirectorStateCheckpoint, D as DirectorStateSnapshot, b as DirectorSubagentState, c as DirectorTaskState, l as loadDirectorState } from '../director-state-BfeCUbmk.js';
|
|
10
|
-
export { G as GoalFile, J as JournalEntry, M as MAX_JOURNAL_ENTRIES, a as MAX_PROGRESS_HISTORY, P as ProgressSnapshot, b as appendJournal, e as emptyGoal, f as formatGoal, g as goalFilePath, l as loadGoal, p as parseProgressFromText, r as recordProgress, s as saveGoal, c as setProgress, d as summarizeUsage } from '../goal-store-
|
|
11
|
-
import { W as WstackPaths } from '../wstack-paths-
|
|
12
|
-
import {
|
|
13
|
-
export { A as AuditLevel, C as CORE_RECONSTRUCT_EVENTS, a as STANDARD_AUDIT_EVENTS, S as SessionEventBridge, b as SessionEventBridgeOptions, c as SessionSamplingOptions, T as ToolProgressSamplingOptions, d as createSessionEventBridge, r as resolveAuditLevel, e as resolveSessionLoggingConfig } from '../session-event-bridge-
|
|
14
|
-
import '../permission-
|
|
15
|
-
import '../secret-vault-
|
|
10
|
+
export { G as GoalFile, J as JournalEntry, M as MAX_JOURNAL_ENTRIES, a as MAX_PROGRESS_HISTORY, P as ProgressSnapshot, b as appendJournal, e as emptyGoal, f as formatGoal, g as goalFilePath, l as loadGoal, p as parseProgressFromText, r as recordProgress, s as saveGoal, c as setProgress, d as summarizeUsage } from '../goal-store-DtLMySNb.js';
|
|
11
|
+
import { W as WstackPaths } from '../wstack-paths-hOpNLmvf.js';
|
|
12
|
+
import { G as SyncCategory, k as SyncConfig } from '../config-BMCj_XDs.js';
|
|
13
|
+
export { A as AuditLevel, C as CORE_RECONSTRUCT_EVENTS, a as STANDARD_AUDIT_EVENTS, S as SessionEventBridge, b as SessionEventBridgeOptions, c as SessionSamplingOptions, T as ToolProgressSamplingOptions, d as createSessionEventBridge, r as resolveAuditLevel, e as resolveSessionLoggingConfig } from '../session-event-bridge-BUI6Jf-4.js';
|
|
14
|
+
import '../permission-B9SB45lp.js';
|
|
15
|
+
import '../secret-vault-BAKpgFw_.js';
|
|
16
16
|
import '../logger-B63L5bTg.js';
|
|
17
|
-
import '../pipeline-
|
|
17
|
+
import '../pipeline-DPDxH_7m.js';
|
|
18
18
|
import '../observability-D-HZN_mF.js';
|
|
19
19
|
import '../task-graph-u1q9Jkyk.js';
|
|
20
20
|
|
|
@@ -507,6 +507,13 @@ declare class ToolAuditLog {
|
|
|
507
507
|
private readonly tailHash;
|
|
508
508
|
/** In-memory counter for entry indices — avoids re-reading the file on every write. */
|
|
509
509
|
private readonly tailIndex;
|
|
510
|
+
/**
|
|
511
|
+
* File mtime+size recorded after our last write, per session. Used to
|
|
512
|
+
* detect cross-process writes (session handoff, recovery) that would
|
|
513
|
+
* invalidate the in-memory tail cache: if the stat no longer matches
|
|
514
|
+
* we re-read the file to re-establish the chain tip before appending.
|
|
515
|
+
*/
|
|
516
|
+
private readonly tailStat;
|
|
510
517
|
/** Tracks writes since last fsync, per session. */
|
|
511
518
|
private readonly unSyncedWrites;
|
|
512
519
|
private readonly writeChains;
|
|
@@ -526,6 +533,13 @@ declare class ToolAuditLog {
|
|
|
526
533
|
output: unknown;
|
|
527
534
|
isError: boolean;
|
|
528
535
|
}): Promise<AuditEntry>;
|
|
536
|
+
/**
|
|
537
|
+
* Resolve the chain tip (previous hash + next index) for an append.
|
|
538
|
+
* Uses the in-memory `tailHash`/`tailIndex` cache when the file's
|
|
539
|
+
* stat matches our last known write; falls back to a full read on
|
|
540
|
+
* cache miss or when an external writer has extended the file.
|
|
541
|
+
*/
|
|
542
|
+
private _resolveChainTip;
|
|
529
543
|
/**
|
|
530
544
|
* Walk the chain and verify every entry's hash and prevHash.
|
|
531
545
|
* Returns a structured verdict — never throws.
|
|
@@ -535,7 +549,12 @@ declare class ToolAuditLog {
|
|
|
535
549
|
load(sessionId: string): Promise<AuditEntry[]>;
|
|
536
550
|
private filePath;
|
|
537
551
|
private readAll;
|
|
538
|
-
|
|
552
|
+
/**
|
|
553
|
+
* Tracks writes since last fsync and triggers periodic fsync.
|
|
554
|
+
* Called after each O(1) append to maintain the same durability
|
|
555
|
+
* guarantees as the old writeAll approach.
|
|
556
|
+
*/
|
|
557
|
+
private _trackUnsynced;
|
|
539
558
|
/**
|
|
540
559
|
* Explicitly sync the file to disk. Called automatically every
|
|
541
560
|
* `fsyncEvery` writes, and available for callers who want to
|
|
@@ -560,6 +579,22 @@ interface AgentEntry {
|
|
|
560
579
|
iterations: number;
|
|
561
580
|
/** Tool calls so far. */
|
|
562
581
|
toolCalls: number;
|
|
582
|
+
/** Cumulative cost in USD for this agent, when known. */
|
|
583
|
+
costUsd?: number | undefined;
|
|
584
|
+
/** Cumulative input tokens, when known. */
|
|
585
|
+
tokensIn?: number | undefined;
|
|
586
|
+
/** Cumulative output tokens, when known. */
|
|
587
|
+
tokensOut?: number | undefined;
|
|
588
|
+
/** Context window fill 0–100 (may exceed 100 when over limit), when known. */
|
|
589
|
+
ctxPct?: number | undefined;
|
|
590
|
+
/** Model id this agent is running on, when known. */
|
|
591
|
+
model?: string | undefined;
|
|
592
|
+
/**
|
|
593
|
+
* Tail of the assistant text currently being streamed (capped, throttled).
|
|
594
|
+
* Lets a cross-process watcher see the response form in near-real-time
|
|
595
|
+
* instead of waiting for the completed turn to land in the session log.
|
|
596
|
+
*/
|
|
597
|
+
partialText?: string | undefined;
|
|
563
598
|
/** UTC ISO timestamp of last activity. */
|
|
564
599
|
lastActivityAt: string;
|
|
565
600
|
}
|
|
@@ -570,6 +605,12 @@ interface SessionRegistryEntry {
|
|
|
570
605
|
projectRoot: string;
|
|
571
606
|
projectName: string;
|
|
572
607
|
workingDir: string;
|
|
608
|
+
/**
|
|
609
|
+
* Which surface owns this session — `'tui'` / `'webui'` / `'cli'` (one-shot or
|
|
610
|
+
* REPL). Lets cross-process consumers (e.g. the WebUI Fleet HQ office map) label
|
|
611
|
+
* each live session by client kind. Optional for back-compat with older entries.
|
|
612
|
+
*/
|
|
613
|
+
clientType?: 'tui' | 'webui' | 'cli' | 'repl' | string | undefined;
|
|
573
614
|
/** Current git branch, if the project is a git repo. Detected at registration. */
|
|
574
615
|
gitBranch?: string | undefined;
|
|
575
616
|
status: SessionLiveStatus;
|
|
@@ -586,6 +627,12 @@ declare class SessionRegistry {
|
|
|
586
627
|
private readonly filePath;
|
|
587
628
|
private heartbeatTimer;
|
|
588
629
|
private currentSessionId;
|
|
630
|
+
/**
|
|
631
|
+
* Last full entry this process registered. Kept so the heartbeat can
|
|
632
|
+
* re-create our entry if it ever goes missing — e.g. our initial register()
|
|
633
|
+
* write was dropped (a wedged lock), the file was reset, or we were pruned.
|
|
634
|
+
*/
|
|
635
|
+
private lastEntry;
|
|
589
636
|
constructor(globalRoot: string);
|
|
590
637
|
/**
|
|
591
638
|
* Register the current session. Call once on session start.
|
|
@@ -627,6 +674,14 @@ declare class SessionRegistry {
|
|
|
627
674
|
private heartbeat;
|
|
628
675
|
private readAndPrune;
|
|
629
676
|
private atomicUpdate;
|
|
677
|
+
/**
|
|
678
|
+
* Break a contended lock if it is stale: the recorded owner pid is no longer
|
|
679
|
+
* alive, or the lock is older than {@link STALE_LOCK_MS}. Returns true when the
|
|
680
|
+
* lock was removed (caller should retry acquisition). Best-effort and
|
|
681
|
+
* race-tolerant — a fresh lock (age ~0, live owner) is never broken, so the
|
|
682
|
+
* common concurrent case self-heals on the next heartbeat.
|
|
683
|
+
*/
|
|
684
|
+
private breakStaleLock;
|
|
630
685
|
private writeAtomicLocked;
|
|
631
686
|
/** Legacy write without lock — used by heartbeat for performance. */
|
|
632
687
|
private writeAtomic;
|
|
@@ -652,6 +707,12 @@ interface AgentStatusTrackerOptions {
|
|
|
652
707
|
registry: SessionRegistry;
|
|
653
708
|
/** Leader agent name shown in the registry. Default: "leader". */
|
|
654
709
|
leaderName?: string | undefined;
|
|
710
|
+
/**
|
|
711
|
+
* Best-effort callback fired after each registry write settles. Used to nudge
|
|
712
|
+
* local WebUI servers (FleetNotifier) so cross-process status reaches the map
|
|
713
|
+
* without waiting on their file-watch/poll. Never block or throw.
|
|
714
|
+
*/
|
|
715
|
+
onUpdate?: (() => void) | undefined;
|
|
655
716
|
}
|
|
656
717
|
declare class AgentStatusTracker {
|
|
657
718
|
private readonly events;
|
|
@@ -662,13 +723,62 @@ declare class AgentStatusTracker {
|
|
|
662
723
|
private leaderCurrentTool;
|
|
663
724
|
private leaderIterations;
|
|
664
725
|
private leaderToolCalls;
|
|
726
|
+
private leaderCostUsd;
|
|
727
|
+
private leaderTokensIn;
|
|
728
|
+
private leaderTokensOut;
|
|
729
|
+
private leaderCtxPct;
|
|
730
|
+
private leaderModel;
|
|
731
|
+
private leaderPartialText;
|
|
665
732
|
private unsubscribers;
|
|
733
|
+
private readonly onUpdate;
|
|
734
|
+
private sweepTimer;
|
|
735
|
+
private partialTimer;
|
|
666
736
|
constructor(opts: AgentStatusTrackerOptions);
|
|
667
737
|
start(): void;
|
|
668
738
|
stop(): void;
|
|
739
|
+
/**
|
|
740
|
+
* Coalesce streamed-text flushes: at most one registry write per
|
|
741
|
+
* {@link PARTIAL_FLUSH_THROTTLE_MS} while text streams in, so per-token
|
|
742
|
+
* deltas never thrash the cross-process registry file.
|
|
743
|
+
*/
|
|
744
|
+
private schedulePartialFlush;
|
|
745
|
+
/**
|
|
746
|
+
* Remove subagents that have been finished (idle/error) for longer than
|
|
747
|
+
* {@link AGENT_REAP_MS}. Running / streaming / waiting_user agents are kept
|
|
748
|
+
* regardless of age — only *not-working* agents are reaped.
|
|
749
|
+
*/
|
|
750
|
+
private sweep;
|
|
669
751
|
private flush;
|
|
670
752
|
}
|
|
671
753
|
|
|
754
|
+
interface FleetNotifierOptions {
|
|
755
|
+
/** WrongStack global dir (`~/.wrongstack`) holding `webui-instances.json`. */
|
|
756
|
+
baseDir: string;
|
|
757
|
+
/** This process's project root — only WebUIs on the same project are pinged. */
|
|
758
|
+
projectRoot: string;
|
|
759
|
+
/** This process's pid, so a WebUI never pings itself. */
|
|
760
|
+
selfPid?: number | undefined;
|
|
761
|
+
/** Injectable POST for tests. Defaults to a timed `fetch`. */
|
|
762
|
+
post?: ((url: string) => Promise<void>) | undefined;
|
|
763
|
+
}
|
|
764
|
+
declare class FleetNotifier {
|
|
765
|
+
private readonly baseDir;
|
|
766
|
+
private readonly projectRoot;
|
|
767
|
+
private readonly selfPid;
|
|
768
|
+
private readonly doPost;
|
|
769
|
+
private cache;
|
|
770
|
+
private timer;
|
|
771
|
+
private disposed;
|
|
772
|
+
constructor(opts: FleetNotifierOptions);
|
|
773
|
+
/** Coalesced, best-effort nudge. Safe to call on every status change. */
|
|
774
|
+
notify(): void;
|
|
775
|
+
/** Resolve same-project WebUI ping URLs (cached briefly). Exposed for tests. */
|
|
776
|
+
endpoints(): Promise<string[]>;
|
|
777
|
+
dispose(): void;
|
|
778
|
+
private flush;
|
|
779
|
+
private discover;
|
|
780
|
+
}
|
|
781
|
+
|
|
672
782
|
interface SessionRewinderOptions {
|
|
673
783
|
sessionsDir: string;
|
|
674
784
|
/** The project root directory; used to validate rewind targets stay inside it. */
|
|
@@ -701,7 +811,13 @@ declare function loadTasks(filePath: string, events?: EventBus, traceId?: string
|
|
|
701
811
|
* Write the task file atomically. Prefer `mutateTasks` for read-modify-write
|
|
702
812
|
* cycles — this low-level function does NOT acquire a lock.
|
|
703
813
|
*/
|
|
704
|
-
|
|
814
|
+
/**
|
|
815
|
+
* Persist the task file. Returns `true` on success, `false` if the write
|
|
816
|
+
* failed (still emits `storage.error` + warns — does NOT throw). `mutateTasks`
|
|
817
|
+
* inspects the result and throws so the task TOOL can report `ok:false`
|
|
818
|
+
* instead of falsely claiming the tasks were saved.
|
|
819
|
+
*/
|
|
820
|
+
declare function saveTasks(filePath: string, tasks: TaskFile, events?: EventBus, traceId?: string): Promise<boolean>;
|
|
705
821
|
/**
|
|
706
822
|
* Load, modify, and save the task file under a file-level lock.
|
|
707
823
|
* `fn` receives the current TaskFile (or a fresh empty one) and must
|
|
@@ -782,4 +898,4 @@ declare class CloudSync {
|
|
|
782
898
|
private walkDir;
|
|
783
899
|
}
|
|
784
900
|
|
|
785
|
-
export { ALL_SYNC_CATEGORIES, type AgentEntry, type AgentLiveStatus, AgentStatusTracker, type AgentStatusTrackerOptions, type Annotation, AnnotationsStore, type AnnotationsStoreOptions, type AuditEntry, CloudSync, type ConsolidationOp, DefaultPromptStore, DefaultSessionRewinder, FileMemoryBackendOptions, GraphMemoryBackend, type GraphMemoryBackendOptions, MemoryBackend, type MemoryConsolidatorOptions, type PromptEntry, type PromptStore, type RecoveryPlan, type ReplayEntry, ReplayLogStore, type ReplayLogStoreOptions, type SessionLiveStatus, SessionMemoryConsolidator, SessionRecovery, SessionRegistry, type SessionRegistryEntry, type SessionRewinderOptions, type StaleSession, SyncCategory, SyncConfig, type SyncResult, type TaskFile, ToolAuditLog, type ToolAuditLogOptions, type VerifyResult, emptyTaskFile, getSessionRegistry, hasSessionRegistry, loadTasks, mutateTasks, saveTasks };
|
|
901
|
+
export { ALL_SYNC_CATEGORIES, type AgentEntry, type AgentLiveStatus, AgentStatusTracker, type AgentStatusTrackerOptions, type Annotation, AnnotationsStore, type AnnotationsStoreOptions, type AuditEntry, CloudSync, type ConsolidationOp, DefaultPromptStore, DefaultSessionRewinder, FileMemoryBackendOptions, FleetNotifier, type FleetNotifierOptions, GraphMemoryBackend, type GraphMemoryBackendOptions, MemoryBackend, type MemoryConsolidatorOptions, type PromptEntry, type PromptStore, type RecoveryPlan, type ReplayEntry, ReplayLogStore, type ReplayLogStoreOptions, type SessionLiveStatus, SessionMemoryConsolidator, SessionRecovery, SessionRegistry, type SessionRegistryEntry, type SessionRewinderOptions, type StaleSession, SyncCategory, SyncConfig, type SyncResult, type TaskFile, ToolAuditLog, type ToolAuditLogOptions, type VerifyResult, emptyTaskFile, getSessionRegistry, hasSessionRegistry, loadTasks, mutateTasks, saveTasks };
|