@wrongstack/core 0.89.1 → 0.104.0
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-B8F2ORwg.d.ts → agent-bridge-mOxbpFcg.d.ts} +1 -1
- package/dist/{agent-subagent-runner-CQaLFNnA.d.ts → agent-subagent-runner-DukQLUcS.d.ts} +433 -433
- package/dist/{events-DzyLtja6.d.ts → brain-Dfv4Y82E.d.ts} +179 -92
- package/dist/{compactor-CJq7LQev.d.ts → compactor-DXLxLcmU.d.ts} +2 -2
- package/dist/{config-_DZ7dN-T.d.ts → config-BSU-6vah.d.ts} +45 -38
- package/dist/{context-ToHAp4-U.d.ts → context-CNRYfhUv.d.ts} +1 -1
- package/dist/coordination/index.d.ts +16 -17
- package/dist/coordination/index.js +128 -37
- package/dist/coordination/index.js.map +1 -1
- package/dist/defaults/index.d.ts +34 -35
- package/dist/defaults/index.js +752 -218
- package/dist/defaults/index.js.map +1 -1
- package/dist/{director-state-CgIc30qi.d.ts → director-state-BfeCUbmk.d.ts} +1 -1
- package/dist/execution/index.d.ts +65 -370
- package/dist/execution/index.js +446 -53
- package/dist/execution/index.js.map +1 -1
- package/dist/extension/index.d.ts +9 -10
- package/dist/extension/index.js +8 -6
- package/dist/extension/index.js.map +1 -1
- package/dist/goal-preamble-CI8lxeY1.d.ts +378 -0
- package/dist/{goal-store-DvWLNu52.d.ts → goal-store-ht0VmR1A.d.ts} +63 -21
- package/dist/{index-Ca_lOmKl.d.ts → index-BWRN6wOb.d.ts} +13 -15
- package/dist/{index-Dx-CnrDN.d.ts → index-DIKEcfgC.d.ts} +9 -10
- package/dist/index.d.ts +188 -176
- package/dist/index.js +1508 -407
- package/dist/index.js.map +1 -1
- package/dist/infrastructure/index.d.ts +9 -9
- package/dist/infrastructure/index.js +4 -2
- package/dist/infrastructure/index.js.map +1 -1
- package/dist/kernel/index.d.ts +14 -16
- package/dist/kernel/index.js.map +1 -1
- package/dist/{logger-B72yyPc6.d.ts → logger-B63L5bTg.d.ts} +1 -1
- package/dist/{logger-C_27pj9i.d.ts → logger-B9J5puGM.d.ts} +1 -1
- package/dist/{mcp-servers-Dck3T85_.d.ts → mcp-servers-CXCsANdY.d.ts} +3 -3
- package/dist/{mode-CHo2XtHs.d.ts → mode-ARA3HrkY.d.ts} +1 -1
- package/dist/models/index.d.ts +5 -5
- package/dist/models/index.js +8 -6
- package/dist/models/index.js.map +1 -1
- package/dist/{models-registry-Be3osGt5.d.ts → models-registry-B6_KfS65.d.ts} +1 -1
- package/dist/{models-registry-Boz639EI.d.ts → models-registry-DU64QxQa.d.ts} +1 -1
- package/dist/{multi-agent-coordinator-Da9nd8Ic.d.ts → multi-agent-coordinator-51LvnXkD.d.ts} +2 -2
- package/dist/{null-fleet-bus-CHJOXv3t.d.ts → null-fleet-bus-D09hMzFQ.d.ts} +32 -31
- package/dist/observability/index.d.ts +3 -3
- package/dist/{observability-CoSNZdhX.d.ts → observability-D-HZN_mF.d.ts} +1 -1
- package/dist/{parallel-eternal-engine-DyMCj2Pw.d.ts → parallel-eternal-engine-CUtmM_0V.d.ts} +54 -35
- package/dist/{path-resolver-TjBlRKyH.d.ts → path-resolver-DDJiMAtX.d.ts} +3 -3
- package/dist/{permission-14CChMmO.d.ts → permission-BDv7z0mk.d.ts} +7 -2
- package/dist/{permission-policy-gW5htOo1.d.ts → permission-policy-dF74EpDp.d.ts} +2 -2
- package/dist/{system-prompt-C0rLCeyn.d.ts → pipeline-BqiA_UMr.d.ts} +73 -73
- package/dist/{plan-templates-D9UhwoGh.d.ts → plan-templates-BdDxl9cI.d.ts} +79 -11
- package/dist/{provider-runner-BEPWwkxH.d.ts → provider-runner-BUunikwY.d.ts} +5 -5
- package/dist/{retry-policy-DSu6O6rD.d.ts → retry-policy-BcmuT_V0.d.ts} +2 -2
- package/dist/sdd/index.d.ts +17 -33
- package/dist/sdd/index.js +145 -36
- package/dist/sdd/index.js.map +1 -1
- package/dist/{secret-scrubber-yGBFQYju.d.ts → secret-vault-DrOhc2i5.d.ts} +7 -7
- package/dist/security/index.d.ts +4 -5
- package/dist/security/index.js +4 -2
- package/dist/security/index.js.map +1 -1
- package/dist/{selector-11-fm95U.d.ts → selector-C7wcdqMA.d.ts} +1 -1
- package/dist/{session-event-bridge-D0u-x576.d.ts → session-event-bridge-BpJ5trO9.d.ts} +2 -2
- package/dist/{session-reader-BQU-toaN.d.ts → session-reader-DDz1Ek4V.d.ts} +2 -2
- package/dist/{skill-BJeF2DwY.d.ts → skill-Bj6Ezqb8.d.ts} +1 -1
- package/dist/skills/index.d.ts +1 -1
- package/dist/skills/index.js +3 -9
- package/dist/skills/index.js.map +1 -1
- package/dist/spec-TBi3Jr6T.d.ts +78 -0
- package/dist/storage/index.d.ts +145 -13
- package/dist/storage/index.js +990 -172
- package/dist/storage/index.js.map +1 -1
- package/dist/task-format-vGOIftmK.d.ts +23 -0
- package/dist/task-graph-u1q9Jkyk.d.ts +84 -0
- package/dist/types/index.d.ts +27 -28
- package/dist/types/index.js +19 -31
- package/dist/types/index.js.map +1 -1
- package/dist/utils/expect-defined.d.ts +7 -0
- package/dist/utils/expect-defined.js +11 -0
- package/dist/utils/expect-defined.js.map +1 -0
- package/dist/utils/index.d.ts +8 -20
- package/dist/utils/index.js +120 -41
- package/dist/utils/index.js.map +1 -1
- package/dist/{wstack-paths-BQMvEllz.d.ts → wstack-paths-_lqjzErq.d.ts} +1 -1
- package/package.json +5 -1
- package/skills/tech-stack/SKILL.md +177 -0
- package/dist/memory-CEXuo7sz.d.ts +0 -16
- package/dist/secret-scrubber-3MHDDAtm.d.ts +0 -6
- package/dist/task-graph-CikNdRTG.d.ts +0 -161
|
@@ -30,8 +30,34 @@ interface JournalEntry {
|
|
|
30
30
|
}
|
|
31
31
|
interface GoalFile {
|
|
32
32
|
version: 1;
|
|
33
|
-
/** The mission statement. */
|
|
33
|
+
/** The raw mission statement as entered by the user. */
|
|
34
34
|
goal: string;
|
|
35
|
+
/**
|
|
36
|
+
* LLM-refined version of the goal — unambiguous, with concrete
|
|
37
|
+
* deliverables and acceptance criteria.
|
|
38
|
+
*/
|
|
39
|
+
refinedGoal?: string | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Concrete, verifiable deliverables extracted from the refined goal.
|
|
42
|
+
*/
|
|
43
|
+
deliverables?: string[] | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* Estimated completion 0-100. Updated by the engine after each
|
|
46
|
+
* iteration. Null means "not yet assessed".
|
|
47
|
+
*/
|
|
48
|
+
progress?: number | undefined;
|
|
49
|
+
/** Human-readable note explaining the current progress estimate. */
|
|
50
|
+
progressNote?: string | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Time-series of progress measurements for trend analysis.
|
|
53
|
+
* Last 200 entries retained. Use `recordProgress()` to append.
|
|
54
|
+
*/
|
|
55
|
+
progressHistory?: ProgressSnapshot[] | undefined;
|
|
56
|
+
/**
|
|
57
|
+
* Computed trend from recent progress measurements.
|
|
58
|
+
* 'accelerating' | 'steady' | 'stalling' | undefined.
|
|
59
|
+
*/
|
|
60
|
+
progressTrend?: 'accelerating' | 'steady' | 'stalling' | undefined;
|
|
35
61
|
/** When the goal was first set or last replaced. */
|
|
36
62
|
setAt: string;
|
|
37
63
|
/** Updated on every iteration completion. */
|
|
@@ -41,23 +67,11 @@ interface GoalFile {
|
|
|
41
67
|
/** Engine lifecycle state — 'running' means another process owns this goal. */
|
|
42
68
|
engineState: 'idle' | 'running' | 'stopped';
|
|
43
69
|
/**
|
|
44
|
-
* Mission-level lifecycle.
|
|
45
|
-
* when the engine detects `[GOAL_COMPLETE]` in a successful iteration's
|
|
46
|
-
* final text AND a verification pass agrees; `abandoned` is set by the
|
|
47
|
-
* user (e.g. `/goal abandon`) or when the engine exceeds a configured
|
|
48
|
-
* failure ceiling. Once not `active`, the engine refuses to run further
|
|
49
|
-
* iterations against this goal — protects against accidental restarts
|
|
50
|
-
* burning through API quota after the work is done.
|
|
51
|
-
*
|
|
52
|
-
* Optional for backward compatibility — pre-existing `goal.json` files
|
|
53
|
-
* without this field load as `active`.
|
|
70
|
+
* Mission-level lifecycle.
|
|
54
71
|
*/
|
|
55
72
|
goalState?: 'active' | 'paused' | 'completed' | 'abandoned' | undefined;
|
|
56
73
|
/**
|
|
57
|
-
* Per-todo attempt counter.
|
|
58
|
-
* to skip a todo that has failed N times rather than spinning on it
|
|
59
|
-
* forever. Persisted so attempt counts survive restarts (`/autonomy
|
|
60
|
-
* stop` + resume should not reset progress against a stuck task).
|
|
74
|
+
* Per-todo attempt counter.
|
|
61
75
|
*/
|
|
62
76
|
todoAttempts?: Record<string, number>;
|
|
63
77
|
/** Bounded ring buffer of recent iterations (newest last). */
|
|
@@ -67,22 +81,23 @@ interface GoalFile {
|
|
|
67
81
|
declare const MAX_JOURNAL_ENTRIES = 500;
|
|
68
82
|
/**
|
|
69
83
|
* Resolve the goal file path for a given project root.
|
|
70
|
-
* Exposed so the engine and CLI use one canonical path.
|
|
71
|
-
* Uses `~/.wrongstack/projects/<hash>/goal.json` .<hash>/`.
|
|
72
84
|
*/
|
|
73
85
|
declare function goalFilePath(projectRoot: string): string;
|
|
74
86
|
declare function loadGoal(filePath: string): Promise<GoalFile | null>;
|
|
75
87
|
declare function saveGoal(filePath: string, goal: GoalFile): Promise<void>;
|
|
76
88
|
declare function emptyGoal(goal: string): GoalFile;
|
|
89
|
+
/**
|
|
90
|
+
* Set progress estimate on a goal. Returns a new GoalFile.
|
|
91
|
+
* Clamps progress to 0-100.
|
|
92
|
+
*/
|
|
93
|
+
declare function setProgress(goal: GoalFile, progress: number, note?: string): GoalFile;
|
|
77
94
|
/**
|
|
78
95
|
* Append a journal entry, bumping iteration counters and trimming the
|
|
79
96
|
* ring buffer. Returns a new GoalFile — does not mutate the argument.
|
|
80
97
|
*/
|
|
81
98
|
declare function appendJournal(goal: GoalFile, entry: Omit<JournalEntry, 'iteration' | 'at'>): GoalFile;
|
|
82
99
|
/**
|
|
83
|
-
* Aggregate cumulative cost + tokens across all journal entries.
|
|
84
|
-
* without telemetry are skipped (legacy entries from before the field
|
|
85
|
-
* was added still load cleanly).
|
|
100
|
+
* Aggregate cumulative cost + tokens across all journal entries.
|
|
86
101
|
*/
|
|
87
102
|
declare function summarizeUsage(goal: GoalFile): {
|
|
88
103
|
totalCostUsd: number;
|
|
@@ -92,5 +107,32 @@ declare function summarizeUsage(goal: GoalFile): {
|
|
|
92
107
|
};
|
|
93
108
|
/** Format the goal + recent journal as a human-readable status block. */
|
|
94
109
|
declare function formatGoal(goal: GoalFile, journalLimit?: number): string;
|
|
110
|
+
/** A single progress measurement at a point in time. */
|
|
111
|
+
interface ProgressSnapshot {
|
|
112
|
+
at: string;
|
|
113
|
+
progress: number;
|
|
114
|
+
note?: string | undefined;
|
|
115
|
+
}
|
|
116
|
+
/**
|
|
117
|
+
* Parse [PROGRESS: N%] from agent final text.
|
|
118
|
+
* Supports formats:
|
|
119
|
+
* [PROGRESS: 45%]
|
|
120
|
+
* [PROGRESS: 45%] — 3/5 deliverables done
|
|
121
|
+
* [progress: 100%]
|
|
122
|
+
* Returns null if no match.
|
|
123
|
+
*/
|
|
124
|
+
declare function parseProgressFromText(text: string): {
|
|
125
|
+
progress: number;
|
|
126
|
+
note?: string;
|
|
127
|
+
} | null;
|
|
128
|
+
/**
|
|
129
|
+
* Record a progress measurement. Returns a new GoalFile with:
|
|
130
|
+
* - progress + progressNote updated
|
|
131
|
+
* - progressHistory appended (last 200 entries kept)
|
|
132
|
+
* - progress trend computed (accelerating/steady/stalling)
|
|
133
|
+
*/
|
|
134
|
+
declare function recordProgress(goal: GoalFile, progress: number, note?: string): GoalFile;
|
|
135
|
+
/** Max progress history entries to retain. */
|
|
136
|
+
declare const MAX_PROGRESS_HISTORY = 200;
|
|
95
137
|
|
|
96
|
-
export { type GoalFile as G, type JournalEntry as J, MAX_JOURNAL_ENTRIES as M,
|
|
138
|
+
export { type GoalFile as G, type JournalEntry as J, MAX_JOURNAL_ENTRIES as M, type ProgressSnapshot as P, MAX_PROGRESS_HISTORY as a, appendJournal as b, setProgress as c, summarizeUsage as d, emptyGoal as e, formatGoal as f, goalFilePath as g, loadGoal as l, parseProgressFromText as p, recordProgress as r, saveGoal as s };
|
|
@@ -1,19 +1,17 @@
|
|
|
1
|
-
import { T as Token,
|
|
2
|
-
import { E as EventBus,
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { E as ErrorHandler,
|
|
1
|
+
import { T as Token, a as Renderer, S as SystemPromptBuilder, H as HookRegistry } from './pipeline-BqiA_UMr.js';
|
|
2
|
+
import { E as EventBus, l as MemoryStore, b as BrainArbiter } from './brain-Dfv4Y82E.js';
|
|
3
|
+
import { C as Compactor } from './compactor-DXLxLcmU.js';
|
|
4
|
+
import { f as ConfigLoader, e as ConfigStore } from './config-BSU-6vah.js';
|
|
5
|
+
import { E as ErrorHandler, R as RetryPolicy } from './retry-policy-BcmuT_V0.js';
|
|
6
6
|
import { I as InputReader } from './input-reader-E-ffP2ee.js';
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import { b as ModelsRegistry } from './models-registry-Be3osGt5.js';
|
|
7
|
+
import { L as Logger } from './logger-B63L5bTg.js';
|
|
8
|
+
import { M as ModeStore } from './mode-ARA3HrkY.js';
|
|
9
|
+
import { M as ModelsRegistry } from './models-registry-B6_KfS65.js';
|
|
11
10
|
import { P as PathResolver } from './path-resolver-CPRj4bFY.js';
|
|
12
|
-
import {
|
|
13
|
-
import { P as ProviderRunner } from './provider-runner-
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { a as SkillLoader } from './skill-BJeF2DwY.js';
|
|
11
|
+
import { P as PermissionPolicy, S as SecretScrubber } from './permission-BDv7z0mk.js';
|
|
12
|
+
import { P as ProviderRunner } from './provider-runner-BUunikwY.js';
|
|
13
|
+
import { c as TokenCounter, i as SessionStore } from './context-CNRYfhUv.js';
|
|
14
|
+
import { S as SkillLoader } from './skill-Bj6Ezqb8.js';
|
|
17
15
|
|
|
18
16
|
/**
|
|
19
17
|
* Lifecycle of a single worktree handle.
|
|
@@ -241,4 +239,4 @@ declare class RunController {
|
|
|
241
239
|
private runHooks;
|
|
242
240
|
}
|
|
243
241
|
|
|
244
|
-
export { type AllocateOpts as A, type MergeOpts as M, RunController as R, TOKENS as T,
|
|
242
|
+
export { type AllocateOpts as A, type MergeOpts as M, RunController as R, TOKENS as T, WorktreeManager as W, type MergeResult as a, type RunControllerOptions as b, type WorktreeHandle as c, type WorktreeManagerOptions as d, type RunResult as e, type WorktreeStatus as f, assertSafePath as g };
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { T as Tracer } from './observability-
|
|
6
|
-
import { E as EventBus } from './
|
|
7
|
-
import { S as SecretScrubber } from './
|
|
8
|
-
import {
|
|
9
|
-
import { W as WireFamily } from './models-registry-Be3osGt5.js';
|
|
1
|
+
import { l as TextBlock, T as Tool, m as ToolUseBlock, C as Context, n as ToolResultBlock, R as Request, b as Response, P as Provider, g as ContentBlock, a0 as WrongStackError } from './context-CNRYfhUv.js';
|
|
2
|
+
import { L as Logger } from './logger-B63L5bTg.js';
|
|
3
|
+
import { B as BuildContext, H as HookRegistry, a as Renderer, P as Pipeline, C as Container } from './pipeline-BqiA_UMr.js';
|
|
4
|
+
import { H as HookEvent, u as ProviderConfig } from './config-BSU-6vah.js';
|
|
5
|
+
import { T as Tracer } from './observability-D-HZN_mF.js';
|
|
6
|
+
import { E as EventBus } from './brain-Dfv4Y82E.js';
|
|
7
|
+
import { P as PermissionPolicy, S as SecretScrubber } from './permission-BDv7z0mk.js';
|
|
8
|
+
import { W as WireFamily } from './models-registry-B6_KfS65.js';
|
|
10
9
|
|
|
11
10
|
/**
|
|
12
11
|
* A contributor that injects additional TextBlocks into the system prompt.
|
|
@@ -559,4 +558,4 @@ interface ToolCallPipelinePayload {
|
|
|
559
558
|
}
|
|
560
559
|
declare function createDefaultPipelines(): AgentPipelines;
|
|
561
560
|
|
|
562
|
-
export { type
|
|
561
|
+
export { type AgentPipelines as A, type BeforeIterationHook as B, DEFAULT_MAX_ITERATIONS as D, ExtensionRegistry as E, type HookRunEnv as H, type OnErrorHook as O, ProviderRegistry as P, type RunResult as R, type SystemPromptContributor as S, type ToolExecutorOptions as T, type UserInputPayload as U, type ToolExecutorStrategy as a, type ToolBatchResult as b, type ToolCallPipelinePayload as c, type ToolWrapper as d, ToolRegistry as e, type ToolExecutorLike as f, type AgentInit as g, type AgentInput as h, type AfterIterationHook as i, type AfterRunHook as j, type AfterToolExecutionHook as k, type AgentExtension as l, type BeforeRunHook as m, type BeforeToolExecutionHook as n, HookRunner as o, type HookRunnerOptions as p, type PreToolUseResult as q, type PromptResult as r, type ProviderFactory as s, type ProviderRunnerWrapper as t, createDefaultPipelines as u, type ProviderRunnerFn as v };
|