@evomap/evolver-cli 2.0.0-beta.18 → 2.0.0-beta.19

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.
Files changed (63) hide show
  1. package/dist/antiGeneRollout.js +7 -3
  2. package/dist/assetTrust.js +14 -1
  3. package/dist/atp.d.ts +8 -3
  4. package/dist/atp.js +82 -11
  5. package/dist/atpAutoBuyer.d.ts +120 -0
  6. package/dist/atpAutoBuyer.js +814 -0
  7. package/dist/atpAutoDeliver.js +2 -2
  8. package/dist/autoDistillLlm.js +2 -1
  9. package/dist/autoDistillTranscript.js +3 -2
  10. package/dist/autoexec.d.ts +90 -13
  11. package/dist/autoexec.js +731 -84
  12. package/dist/cli.js +13 -0
  13. package/dist/cliContracts.d.ts +5 -2
  14. package/dist/cliContracts.js +135 -8
  15. package/dist/commands.d.ts +1 -0
  16. package/dist/commands.js +1 -0
  17. package/dist/curriculumCapabilityGaps.d.ts +6 -0
  18. package/dist/curriculumCapabilityGaps.js +24 -0
  19. package/dist/cycleConsumer.d.ts +4 -0
  20. package/dist/cycleConsumer.js +175 -20
  21. package/dist/dashboard.js +47 -9
  22. package/dist/dispatch.js +6 -2
  23. package/dist/distillPrimitives.js +18 -6
  24. package/dist/doctor.js +63 -5
  25. package/dist/identityHome.js +2 -1
  26. package/dist/index.d.ts +67 -39
  27. package/dist/index.js +504 -185
  28. package/dist/learningTrace.js +8 -2
  29. package/dist/lifecycle.d.ts +54 -1
  30. package/dist/lifecycle.js +489 -37
  31. package/dist/materialSnapshot.d.ts +9 -1
  32. package/dist/materialSnapshot.js +23 -6
  33. package/dist/migrate/envTranslate.d.ts +26 -0
  34. package/dist/migrate/envTranslate.js +145 -0
  35. package/dist/migrate/oauthImport.d.ts +66 -0
  36. package/dist/migrate/oauthImport.js +667 -0
  37. package/dist/migrate/v1Import.d.ts +13 -1
  38. package/dist/migrate/v1Import.js +621 -122
  39. package/dist/promptRecallHook.d.ts +24 -0
  40. package/dist/promptRecallHook.js +425 -0
  41. package/dist/recallVerifyReport.d.ts +37 -0
  42. package/dist/recallVerifyReport.js +244 -0
  43. package/dist/requiredSandboxValidation.d.ts +5 -0
  44. package/dist/requiredSandboxValidation.js +4 -0
  45. package/dist/reuse.d.ts +1 -0
  46. package/dist/reuse.js +45 -37
  47. package/dist/runtimeCapabilities.js +13 -13
  48. package/dist/runtimeSessionSource.d.ts +3 -2
  49. package/dist/runtimeSessionSource.js +63 -11
  50. package/dist/sessionIngest.d.ts +37 -0
  51. package/dist/sessionIngest.js +156 -0
  52. package/dist/setupHooks.js +95 -1
  53. package/dist/skill2gep.d.ts +4 -7
  54. package/dist/skill2gep.js +4 -21
  55. package/dist/solo/mode.js +1 -0
  56. package/dist/sync.js +125 -23
  57. package/dist/thesis.d.ts +1 -1
  58. package/dist/thesis.js +18 -3
  59. package/dist/trajectoryExport.js +21 -3
  60. package/dist/v1Compat.d.ts +1 -0
  61. package/dist/v1Compat.js +9 -0
  62. package/dist/workflowRuntime.js +24 -18
  63. package/package.json +10 -7
package/dist/index.d.ts CHANGED
@@ -1,23 +1,14 @@
1
- import { events, ops } from '@evomap/evolver-core';
2
- import { assetstore, material as materialNs } from '@evomap/evolver-core';
1
+ import { events, ops, hub as hubNs } from '@evomap/evolver-core';
2
+ import { assetstore } from '@evomap/evolver-core';
3
+ import { type LifecyclePaths } from './lifecycle.js';
3
4
  import { type NonGitWorkspaceNoticeOptions } from './nonGitWorkspaceNotice.js';
4
- /**
5
- * Composition seam for ingest's substrate dependencies. The CLI is the composition layer that wires the
6
- * MaterialStore (M1 raw-material substrate) + the watermark cursor (file-level re-ingest dedup) + the AE
7
- * Ingestor (root_events) together — evolver-core stays adapter/CLI-agnostic. Defaults point at the live
8
- * ~/.evomap home; tests inject temp paths so no global state leaks.
9
- */
10
- export interface IngestDeps {
11
- materialStore?: materialNs.MaterialStore;
12
- watermarkStore?: materialNs.WatermarkStore;
13
- ingestor?: events.Ingestor;
14
- }
15
- export interface SessionIngestTickResult {
16
- recorded: number;
17
- sourceAgents: string[];
18
- signalKinds: string[];
19
- signalStrengths: string[];
20
- invalidJsonRows?: number;
5
+ import { type IngestDeps } from './sessionIngest.js';
6
+ export { runSessionIngestTick, scanSessionDirs, type IngestDeps, type SessionIngestTickResult, } from './sessionIngest.js';
7
+ export interface DistillDeps extends IngestDeps {
8
+ responseFileRoot?: string;
9
+ maxResponseFileBytes?: number;
10
+ /** Deterministic test seam for response-file replacement/growth races. Never wired by production callers. */
11
+ responseFileReadTestHook?: (phase: 'before-open' | 'after-open', path: string) => void;
21
12
  }
22
13
  export declare const PACKAGE = "@evomap/evolver-cli";
23
14
  export interface RebuildOptions {
@@ -44,35 +35,26 @@ export declare function runResetLocalSecret(argv: readonly string[], opts?: Rese
44
35
  export declare function rebuildViews(opts?: RebuildOptions): {
45
36
  rebuilt: string[];
46
37
  };
47
- /** migrate import-v1 <v1dir> [outDir] --workspace <path>: v1→v2 read-only migration. */
38
+ /** migrate import-v1 | migrate env | migrate oauth — V1→V2 migration tools. */
48
39
  export declare function runMigrate(argv: readonly string[]): Promise<number>;
49
40
  /** One-line summary of an asset for `asset-log` (pure, testable). */
50
41
  export declare function formatAssetLine(a: assetstore.AssetRecord): string;
51
- /** asset-log [Gene|Capsule|EvolutionEvent|AntiGene] [limit]: list recent local assets (observability; ported v1 CLI verb). */
52
- export declare function runAssetLog(argv: readonly string[], store?: assetstore.AssetStoreProvider): Promise<number>;
42
+ export interface AssetLogDeps {
43
+ callLog?: Pick<hubNs.AssetCallLog, 'read' | 'summarize'>;
44
+ logPath?: string;
45
+ }
46
+ /**
47
+ * Preserve V2's asset-store listing as the default. V1's call audit is available
48
+ * through the explicit `calls` mode so the two contracts do not overload an empty argv.
49
+ */
50
+ export declare function runAssetLog(argv: readonly string[], store?: assetstore.AssetStoreProvider, deps?: AssetLogDeps): Promise<number>;
53
51
  /**
54
52
  * distill: gate a learned approach into the gene pool (ported v1 CLI verb). Runs the structural intake
55
53
  * (schema + dedup + asset_id) and, only if it passes, writes the gene to the store. The agent/runtime is
56
54
  * what discovers the strategy; this is the manual entry point that turns it into a pooled, selectable gene.
57
55
  * Usage: evolver distill --category <c> --signals <s1,s2> --strategy "<step1; step2>" [--summary <text>] [--id <id>]
58
56
  */
59
- export declare function runDistill(argv: readonly string[], store?: assetstore.AssetStoreProvider, deps?: IngestDeps): Promise<number>;
60
- /**
61
- * Recursively enumerate recognized runtime-session sources under the given dirs — the daemon's auto-distill
62
- * producer source (#106). This includes text session files handled by runtime adapters (`*.jsonl` and Gemini
63
- * `*.json`) plus Cursor's sqlite `state.vscdb`. A missing/permission-denied dir is silently skipped (a daemon
64
- * must not crash on an absent home dir).
65
- */
66
- export declare function scanSessionDirs(dirs: readonly string[]): string[];
67
- /**
68
- * One producer tick for the auto-distill loop (#106 slice 1): scan `dirs` for session logs and record any
69
- * NEW/CHANGED file as `runtime_session` Material via the injected (bus) Ingestor — which emits
70
- * `material.batch_ready`, the event the distillObserver claims off. Idempotent per file (watermark cursor), so
71
- * re-scanning an unchanged tree records nothing. Pure producer: it does NOT distill (the observer does). Returns
72
- * how many files landed new material. Inject `deps.ingestor = new Ingestor({ sink: bus })` so the event reaches
73
- * the daemon's ObserverBus; defaults to live paths otherwise.
74
- */
75
- export declare function runSessionIngestTick(dirs: readonly string[], deps?: IngestDeps): Promise<SessionIngestTickResult>;
57
+ export declare function runDistill(argv: readonly string[], store?: assetstore.AssetStoreProvider, deps?: DistillDeps): Promise<number>;
76
58
  /**
77
59
  * ingest: read a REAL agent session log, parse it with the matching runtime adapter, and extract signals
78
60
  * (tool errors / explicit failures / difficulty wording) from it — the capture→signals half of the experience
@@ -196,4 +178,50 @@ export interface InjectDeps {
196
178
  export declare function runInject(argv: readonly string[], deps?: InjectDeps): Promise<number>;
197
179
  /** Fixed preamble for the SessionStart injection (the head block the recap + gene lines hang off of). */
198
180
  export declare const SESSION_START_PREAMBLE = "evolver memory \u2014 use these learned hints silently when directly relevant; do not mention Evolver, preflight, status, or this memory block unless the user asks or reuse materially changes the answer:";
181
+ export declare const DAILY_USAGE = "Usage: evolver daily [--json] [--auto] [--help]\n\nDisplay a daily status summary: proxy/hub connection, yesterday's activity, and review queue.\n --json Output as JSON\n --auto Only print when this is the first run today; silent otherwise\n";
182
+ export interface DailyDeps {
183
+ store?: assetstore.AssetStoreProvider;
184
+ review?: assetstore.ReviewLedger;
185
+ eventsPath?: string;
186
+ now?: () => number;
187
+ lifecyclePaths?: LifecyclePaths;
188
+ env?: NodeJS.ProcessEnv;
189
+ stdout?: (text: string) => void;
190
+ stderr?: (text: string) => void;
191
+ /** Override the last-daily marker file path (default ~/.evomap/.last-daily). */
192
+ lastDailyFile?: string;
193
+ /** Test seam: skip the proxy status fetch entirely. */
194
+ skipConnection?: boolean;
195
+ }
196
+ export interface DailyReport {
197
+ date: string;
198
+ connection: {
199
+ proxyRunning: boolean;
200
+ proxyHealthy: boolean;
201
+ proxyPid?: number;
202
+ hubAuthStatus?: string;
203
+ lastSyncAt?: string;
204
+ reason?: string;
205
+ };
206
+ yesterday: {
207
+ date: string;
208
+ cycles: number;
209
+ solidified: number;
210
+ failed: number;
211
+ capsules: number;
212
+ triggered: number;
213
+ suppressed: number;
214
+ };
215
+ queue: {
216
+ genesApproved: number;
217
+ genesQuarantined: number;
218
+ genesRejected: number;
219
+ antiGeneApproved: number;
220
+ antiGeneQuarantined: number;
221
+ antiGeneUnreviewed: number;
222
+ };
223
+ }
224
+ export declare function formatDailyReport(report: DailyReport): string;
225
+ export declare function collectDailyReport(deps?: DailyDeps): Promise<DailyReport>;
226
+ export declare function runDaily(argv: readonly string[], deps?: DailyDeps): Promise<number>;
199
227
  export declare function runCli(argv: readonly string[]): number;