@robmclarty/volley 0.5.1 → 0.5.2
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 +19 -0
- package/README.md +1 -1
- package/dist/cli.js +607 -533
- package/dist/cli.js.map +1 -1
- package/dist/index.d.ts +25 -11
- package/dist/index.js +793 -719
- package/dist/index.js.map +1 -1
- package/package.json +27 -26
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { UsageTotals, FinishReason, StreamChunk, Engine } from 'fascicle';
|
|
1
|
+
import { UsageTotals, FinishReason, Throughput, StreamChunk, Engine } from 'fascicle';
|
|
2
2
|
import { z } from 'zod';
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -176,6 +176,12 @@ type PhaseRecord = {
|
|
|
176
176
|
provider: string;
|
|
177
177
|
model: string;
|
|
178
178
|
session_id: string | null;
|
|
179
|
+
/** Wall-clock of the phase's model work, the same measure for every provider
|
|
180
|
+
* so an all-local run and an all-Claude run compare directly. The builder's is
|
|
181
|
+
* fascicle's `GenerateResult.timing`: the whole call, every turn and the tools
|
|
182
|
+
* between them. The critic's spans its whole degradation ladder, failed
|
|
183
|
+
* attempts included, since no one result's timing covers the attempts before
|
|
184
|
+
* it. Neither counts the Ollama prewarm. */
|
|
179
185
|
duration_ms: number;
|
|
180
186
|
usage: UsageTotals;
|
|
181
187
|
cost_usd: number | null;
|
|
@@ -205,6 +211,13 @@ type PhaseRecord = {
|
|
|
205
211
|
* critique and on the builder. Additive, and a degraded verdict is *always*
|
|
206
212
|
* marked so it never passes silently as a full one. */
|
|
207
213
|
critic_degraded?: boolean;
|
|
214
|
+
/** Output tokens per second over the model's own turns (tool execution and
|
|
215
|
+
* retry backoff excluded), from fascicle's per-step timing. `basis` is
|
|
216
|
+
* `decode` when every turn streamed, `blended` when any round trip counted
|
|
217
|
+
* prefill and network too — always the case for `claude_cli`, whose rate
|
|
218
|
+
* fascicle derives from the CLI's reported API time. Absent when no turn
|
|
219
|
+
* carried timing. Additive. */
|
|
220
|
+
throughput?: Throughput;
|
|
208
221
|
};
|
|
209
222
|
type HaltReason = 'cost_cap' | 'gate_edit' | null;
|
|
210
223
|
/** Carry-state threaded through the fascicle loop. */
|
|
@@ -297,6 +310,14 @@ type Renderer = {
|
|
|
297
310
|
};
|
|
298
311
|
declare function create_renderer(options: RendererOptions): Renderer;
|
|
299
312
|
|
|
313
|
+
type OrchestratorDeps = {
|
|
314
|
+
renderer: Renderer;
|
|
315
|
+
engine?: Engine;
|
|
316
|
+
abort?: AbortSignal;
|
|
317
|
+
install_signal_handlers?: boolean;
|
|
318
|
+
};
|
|
319
|
+
declare function run_volley(config: ResolvedConfig, deps: OrchestratorDeps, resume_from?: LoopState | null): Promise<RunResult>;
|
|
320
|
+
|
|
300
321
|
declare function initial_state(): LoopState;
|
|
301
322
|
/** All stopping conditions live here: acceptance, cost cap, the gate
|
|
302
323
|
* edit refusal, and — implicitly via `max_rounds` — the iteration budget.
|
|
@@ -311,18 +332,11 @@ declare function gate(config: ResolvedConfig, state: LoopState): {
|
|
|
311
332
|
state: LoopState;
|
|
312
333
|
};
|
|
313
334
|
declare function status_of(value: LoopState, converged: boolean): RunStatus;
|
|
314
|
-
type OrchestratorDeps = {
|
|
315
|
-
renderer: Renderer;
|
|
316
|
-
engine?: Engine;
|
|
317
|
-
abort?: AbortSignal;
|
|
318
|
-
install_signal_handlers?: boolean;
|
|
319
|
-
};
|
|
320
|
-
declare function run_volley(config: ResolvedConfig, deps: OrchestratorDeps, resume_from?: LoopState | null): Promise<RunResult>;
|
|
321
335
|
|
|
322
336
|
/**
|
|
323
|
-
* Critic invocation: a read-only `claude_cli
|
|
324
|
-
* schema-validated structured verdict. The
|
|
325
|
-
* `.volley/feedback.md` and `.volley/verdict`.
|
|
337
|
+
* Critic invocation: a read-only session (`claude_cli`, or a local model with
|
|
338
|
+
* volley's read tools) returning a schema-validated structured verdict. The
|
|
339
|
+
* harness — not the critic — writes `.volley/feedback.md` and `.volley/verdict`.
|
|
326
340
|
*/
|
|
327
341
|
|
|
328
342
|
declare const verdict_schema: z.ZodObject<{
|