opencode-swarm 7.168.0 → 7.169.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/.opencode/skills/swarm-pr-feedback/SKILL.md +11 -11
- package/binaries/win32-arm64/swarm-sandbox-runner.exe +0 -0
- package/binaries/win32-x64/swarm-sandbox-runner.exe +0 -0
- package/dist/cli/{coder-settlement-a35acvj1.js → coder-settlement-fd6ba876.js} +12 -12
- package/dist/cli/{config-doctor-9csx775x.js → config-doctor-zeppqwwx.js} +2 -2
- package/dist/cli/{core-agk5s7dm.js → core-fj1afc31.js} +5 -2
- package/dist/cli/{curation-policy-mgwv8h2k.js → curation-policy-k74qz9ms.js} +5 -5
- package/dist/cli/{curator-drift-k0zrnm09.js → curator-drift-3ssjr0nx.js} +5 -5
- package/dist/cli/{curator-2fcagjyk.js → curator-emftndv0.js} +39 -38
- package/dist/cli/curator-llm-factory-4t773tmz.js +72 -0
- package/dist/cli/{dispatch-8ks9dyk5.js → dispatch-hwwj3qrb.js} +2 -2
- package/dist/cli/{evidence-summary-service-4s6cje60.js → evidence-summary-service-51b69jc3.js} +16 -16
- package/dist/cli/{gate-evidence-saja4dan.js → gate-evidence-53s161wb.js} +7 -7
- package/dist/cli/guardrail-explain-mhx8gt8q.js +73 -0
- package/dist/cli/{guardrail-log-0h24spq0.js → guardrail-log-xg6hrdsq.js} +8 -8
- package/dist/cli/{guardrail-reset-cwbe47k5.js → guardrail-reset-fgv5kt5x.js} +39 -38
- package/dist/cli/{hive-promoter-esxtcvr1.js → hive-promoter-41zygtgx.js} +39 -38
- package/dist/cli/index-0hgmsyfp.js +92 -0
- package/dist/cli/{index-nsyxj57e.js → index-0vgs5r39.js} +8 -8
- package/dist/cli/{index-54w1564x.js → index-1cbjemgh.js} +2 -2
- package/dist/cli/{index-p612v1mv.js → index-2s7dvzff.js} +200 -51
- package/dist/cli/{index-3dywbkyr.js → index-2znfa537.js} +4 -4
- package/dist/cli/{index-seetnhpx.js → index-3bfzpzsb.js} +1 -1
- package/dist/cli/{index-yevn4jpe.js → index-3zcds757.js} +3101 -1918
- package/dist/cli/{index-d5qf7hvh.js → index-5400m33a.js} +1 -1
- package/dist/cli/{index-mr0wn36f.js → index-55fkkjec.js} +5 -5
- package/dist/cli/{index-qwsh0h2g.js → index-5qt9yf5w.js} +4 -4
- package/dist/cli/{index-30h1pk05.js → index-5reh1bjz.js} +3 -3
- package/dist/cli/{index-j950hqmq.js → index-76ng6vmq.js} +7 -7
- package/dist/cli/{index-qhey6vc3.js → index-7h01bkm6.js} +2 -2
- package/dist/cli/{index-yv76j77m.js → index-83m0y4cj.js} +6 -6
- package/dist/cli/{index-ddr97ram.js → index-8x9keek6.js} +41 -40
- package/dist/cli/{index-8ybjqg51.js → index-9ttqbhvw.js} +1 -1
- package/dist/cli/{index-kear8gb7.js → index-b3pmzbh1.js} +2 -2
- package/dist/cli/{index-h439y187.js → index-bernkwgf.js} +1 -1
- package/dist/cli/{index-m35hybf0.js → index-bm5xrfnx.js} +1 -1
- package/dist/cli/{index-pyf517sz.js → index-br3mvbsa.js} +2 -2
- package/dist/cli/{index-4r5pmtvk.js → index-bx1wgn3a.js} +4 -4
- package/dist/cli/{index-64phnth4.js → index-c7kr7tnk.js} +4 -4
- package/dist/cli/{index-nwwk3dej.js → index-cgpwjctj.js} +1 -1
- package/dist/cli/{index-s0d5xter.js → index-dd48vt27.js} +3 -3
- package/dist/cli/{index-wst6n478.js → index-dvbf6fpn.js} +1 -1
- package/dist/cli/{index-rxcgrgkc.js → index-e4dxf5cr.js} +39 -38
- package/dist/cli/{index-cyenn3pf.js → index-egkc2bpv.js} +36 -1
- package/dist/cli/{index-h0e2e3h1.js → index-exf0j569.js} +1 -1
- package/dist/cli/{index-a8xbvsse.js → index-fgp96k3r.js} +2 -2
- package/dist/cli/{index-5zqakgp4.js → index-fhh02gwx.js} +3 -3
- package/dist/cli/{index-dfyv3xkd.js → index-gfbggp8k.js} +9 -9
- package/dist/cli/{index-nprngf8p.js → index-ksybszed.js} +7 -7
- package/dist/cli/{index-v3xc4sde.js → index-nbdmdyke.js} +2 -1
- package/dist/cli/{index-z6qreakh.js → index-nprdr0sm.js} +6 -4
- package/dist/cli/{index-wnzxcr0z.js → index-nwv3e3kc.js} +2 -2
- package/dist/cli/{index-bvqqwx84.js → index-nyn01yrz.js} +2 -2
- package/dist/cli/{index-an8b5gda.js → index-p6xsgk4r.js} +7 -7
- package/dist/cli/{index-x7k3dps5.js → index-s96dpjsk.js} +2 -2
- package/dist/cli/{index-ze520xw1.js → index-sb1s03y9.js} +8 -8
- package/dist/cli/{index-00zx94vn.js → index-sxcfszbe.js} +5 -5
- package/dist/cli/{index-8f0kscpg.js → index-wwr67xc0.js} +197 -35
- package/dist/cli/{index-gp9yzr1v.js → index-xnpjwc4h.js} +1 -1
- package/dist/cli/{index-exatbqwj.js → index-yj24ny5k.js} +26 -4
- package/dist/cli/{index-21ree67h.js → index-zapc8vj4.js} +14 -14
- package/dist/cli/index.js +39 -38
- package/dist/cli/{knowledge-escalator-b2tf3sd1.js → knowledge-escalator-07s44av0.js} +13 -13
- package/dist/cli/{knowledge-events-bgs2kxe0.js → knowledge-events-j2n1569p.js} +11 -11
- package/dist/cli/{knowledge-link-dr3xnwyd.js → knowledge-link-rkxfrmhm.js} +4 -4
- package/dist/cli/{knowledge-store-stbmb1b9.js → knowledge-store-85metj89.js} +5 -5
- package/dist/cli/{knowledge-validator-zykgnsag.js → knowledge-validator-63k1xzcc.js} +7 -7
- package/dist/cli/{pending-delegations-n5qavj20.js → pending-delegations-dckmjymn.js} +12 -12
- package/dist/cli/{pr-subscriptions-gnvmyrng.js → pr-subscriptions-pyh73me6.js} +12 -12
- package/dist/cli/{pr-workflow-gate-cf3ybrws.js → pr-workflow-gate-k1r4rjw4.js} +39 -38
- package/dist/cli/{runner-k0ycgv8x.js → runner-1dwrgyyr.js} +6 -6
- package/dist/cli/{scan-cursor-b3mcrx23.js → scan-cursor-k6egg4n0.js} +6 -6
- package/dist/cli/{schema-08049cjb.js → schema-vdrtpggt.js} +5 -1
- package/dist/cli/{scope-persistence-a493gv51.js → scope-persistence-h1mmww19.js} +14 -14
- package/dist/cli/{skill-generator-2qqzkdpv.js → skill-generator-pmn6gmvk.js} +15 -15
- package/dist/cli/{snapshot-coordination-init-8yt8p7q0.js → snapshot-coordination-init-rspykgd0.js} +39 -38
- package/dist/cli/{telemetry-2wzapf11.js → telemetry-fdtaemnv.js} +1 -1
- package/dist/cli/{workspace-snapshot-rkgxhj9b.js → workspace-snapshot-hkz2wt1c.js} +4 -4
- package/dist/cli/{worktree-collision-ownership-xttafc4h.js → worktree-collision-ownership-x84dzzzc.js} +18 -104
- package/dist/cli/{worktree-isolation-e5q5rewk.js → worktree-isolation-nw9pakkx.js} +39 -38
- package/dist/commands/destructive-purge.d.ts +85 -0
- package/dist/commands/registry.d.ts +2 -2
- package/dist/commands/reset-session.d.ts +5 -1
- package/dist/config/constants.d.ts +4 -1
- package/dist/config/lane-context.d.ts +19 -0
- package/dist/config/schema.d.ts +77 -0
- package/dist/evaluation/index.d.ts +1 -0
- package/dist/evaluation/retrieval-quality.d.ts +116 -0
- package/dist/failures/invocation-failure.d.ts +23 -4
- package/dist/hooks/init-orphan-recovery.d.ts +7 -0
- package/dist/hooks/pr-workflow-gate.d.ts +8 -2
- package/dist/index.js +596 -590
- package/dist/memory/embeddings/reranker.d.ts +13 -2
- package/dist/memory/evaluation.d.ts +99 -0
- package/dist/memory/heldout-evaluation-corpus.d.ts +51 -0
- package/dist/memory/index.d.ts +5 -2
- package/dist/memory/sqlite-provider.d.ts +35 -1
- package/dist/memory/types.d.ts +14 -0
- package/dist/observability/otel-mapping.d.ts +5 -5
- package/dist/observability/otlp-exporter.d.ts +80 -0
- package/dist/parallel/lane-owners.d.ts +76 -0
- package/dist/tools/repo-graph/query.d.ts +6 -1
- package/dist/tools/repo-graph/types.d.ts +13 -4
- package/dist/utils/bun-compat.d.ts +20 -0
- package/dist/utils/gitignore-warning.d.ts +5 -2
- package/dist/worktree/base-migration.d.ts +55 -0
- package/dist/worktree/core.d.ts +15 -6
- package/dist/worktree/ownership.d.ts +66 -0
- package/opencode-swarm.schema.json +97 -0
- package/package.json +4 -2
- package/tests/fixtures/memory-recall-heldout/manifest.json +311 -0
- package/tests/fixtures/memory-recall-heldout/sources/bash.sh +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/c.c +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/cpp.cpp +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/csharp.cs +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/css.css +3 -0
- package/tests/fixtures/memory-recall-heldout/sources/dart.dart +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/go.go +3 -0
- package/tests/fixtures/memory-recall-heldout/sources/ini.ini +2 -0
- package/tests/fixtures/memory-recall-heldout/sources/java.java +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/javascript.js +3 -0
- package/tests/fixtures/memory-recall-heldout/sources/kotlin.kt +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/php.php +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/powershell.ps1 +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/python.py +2 -0
- package/tests/fixtures/memory-recall-heldout/sources/regex.regex +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/ruby.rb +3 -0
- package/tests/fixtures/memory-recall-heldout/sources/rust.rs +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/swift.swift +1 -0
- package/tests/fixtures/memory-recall-heldout/sources/tsx.tsx +3 -0
- package/tests/fixtures/memory-recall-heldout/sources/typescript.ts +3 -0
- package/dist/cli/curator-llm-factory-qaxmyy46.js +0 -71
- package/dist/cli/guardrail-explain-z41q6sf0.js +0 -72
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import { buildWorkspaceGraphAsync } from '../tools/repo-graph/builder';
|
|
2
|
+
export declare const _internals: {
|
|
3
|
+
buildWorkspaceGraphAsync: typeof buildWorkspaceGraphAsync;
|
|
4
|
+
};
|
|
5
|
+
export interface RetrievalQualityResourceCaps {
|
|
6
|
+
max_files: number;
|
|
7
|
+
walk_budget_ms: number;
|
|
8
|
+
max_tokens: number;
|
|
9
|
+
top_n: number;
|
|
10
|
+
}
|
|
11
|
+
export interface RetrievalQualityOptions {
|
|
12
|
+
corpusDirectory: string;
|
|
13
|
+
resourceCaps?: Partial<RetrievalQualityResourceCaps>;
|
|
14
|
+
/** Test-only diagnostic escape hatch. Production callers must clean up. */
|
|
15
|
+
keepTempRoot?: boolean;
|
|
16
|
+
}
|
|
17
|
+
export type RetrievalQualityStatus = 'complete' | 'degraded' | 'skipped';
|
|
18
|
+
export interface ExactMeasurement {
|
|
19
|
+
expected: string[];
|
|
20
|
+
observed: string[];
|
|
21
|
+
true_positive_count: number;
|
|
22
|
+
false_negative: string[];
|
|
23
|
+
false_positive: string[];
|
|
24
|
+
precision: number;
|
|
25
|
+
recall: number;
|
|
26
|
+
}
|
|
27
|
+
export interface RetrievalRouteMeasurement {
|
|
28
|
+
status: RetrievalQualityStatus;
|
|
29
|
+
provenance: 'direct-source-fallback' | 'fresh-indexed-subgraph' | 'unavailable';
|
|
30
|
+
degradation_reason?: string;
|
|
31
|
+
graph_hit: boolean;
|
|
32
|
+
positive_hit: boolean;
|
|
33
|
+
fallback_reason: string | null;
|
|
34
|
+
actions: string[];
|
|
35
|
+
matched_resource_count: number;
|
|
36
|
+
}
|
|
37
|
+
export interface HeldoutGraphQualityCase {
|
|
38
|
+
id: string;
|
|
39
|
+
language: string;
|
|
40
|
+
analyzer: {
|
|
41
|
+
declared_id: string | null;
|
|
42
|
+
implementation: 'extractFileSymbols';
|
|
43
|
+
};
|
|
44
|
+
source: {
|
|
45
|
+
hash: string;
|
|
46
|
+
provenance: 'direct-source';
|
|
47
|
+
};
|
|
48
|
+
status: RetrievalQualityStatus;
|
|
49
|
+
degradation_reason?: string;
|
|
50
|
+
symbols: ExactMeasurement;
|
|
51
|
+
edges: ExactMeasurement;
|
|
52
|
+
known_misses: {
|
|
53
|
+
declared: string[];
|
|
54
|
+
matching_measured_false_negatives: string[];
|
|
55
|
+
};
|
|
56
|
+
spurious_edges: {
|
|
57
|
+
declared: string[];
|
|
58
|
+
matching_measured_false_positives: string[];
|
|
59
|
+
};
|
|
60
|
+
paraphrase: {
|
|
61
|
+
query: string;
|
|
62
|
+
direct_source: RetrievalRouteMeasurement;
|
|
63
|
+
indexed_control: RetrievalRouteMeasurement;
|
|
64
|
+
};
|
|
65
|
+
latency_ms: number;
|
|
66
|
+
}
|
|
67
|
+
export interface HeldoutGraphQualityReport {
|
|
68
|
+
schema_version: 1;
|
|
69
|
+
corpus: {
|
|
70
|
+
id: string;
|
|
71
|
+
version: string | null;
|
|
72
|
+
hash: string;
|
|
73
|
+
split: 'heldout';
|
|
74
|
+
};
|
|
75
|
+
generated_at: string;
|
|
76
|
+
status: RetrievalQualityStatus;
|
|
77
|
+
degradation_reasons: string[];
|
|
78
|
+
resource_caps: RetrievalQualityResourceCaps;
|
|
79
|
+
resource_usage: {
|
|
80
|
+
case_count: number;
|
|
81
|
+
graph_node_count: number;
|
|
82
|
+
graph_edge_count: number;
|
|
83
|
+
indexed_storage_available: boolean;
|
|
84
|
+
};
|
|
85
|
+
summary: {
|
|
86
|
+
symbols: AggregateExactMeasurement;
|
|
87
|
+
edges: AggregateExactMeasurement;
|
|
88
|
+
complete_case_count: number;
|
|
89
|
+
direct_source_fallback_complete_count: number;
|
|
90
|
+
direct_source_fallback_positive_hit_count: number;
|
|
91
|
+
fresh_indexed_control_complete_count: number;
|
|
92
|
+
};
|
|
93
|
+
thresholds: Record<string, number>;
|
|
94
|
+
uncertainty: {
|
|
95
|
+
method: 'deterministic-heldout-corpus';
|
|
96
|
+
confidence: 0.95;
|
|
97
|
+
sample_count: number;
|
|
98
|
+
};
|
|
99
|
+
cases: HeldoutGraphQualityCase[];
|
|
100
|
+
}
|
|
101
|
+
export interface AggregateExactMeasurement {
|
|
102
|
+
expected_count: number;
|
|
103
|
+
observed_count: number;
|
|
104
|
+
true_positive_count: number;
|
|
105
|
+
false_negative_count: number;
|
|
106
|
+
false_positive_count: number;
|
|
107
|
+
precision: number;
|
|
108
|
+
recall: number;
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* Measure the repository graph and retrieval router against the immutable
|
|
112
|
+
* multilingual held-out corpus. This intentionally owns a disposable project
|
|
113
|
+
* root: graph persistence remains under that root's `.swarm/`, never beside a
|
|
114
|
+
* source fixture or a caller workspace.
|
|
115
|
+
*/
|
|
116
|
+
export declare function evaluateHeldoutGraphRetrievalQuality(options: RetrievalQualityOptions): Promise<HeldoutGraphQualityReport>;
|
|
@@ -32,10 +32,29 @@ export interface ToolFailureClassificationInput {
|
|
|
32
32
|
}
|
|
33
33
|
/**
|
|
34
34
|
* Redacts secrets/URLs and strips control chars for terminal/display safety.
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
35
|
+
* Order of operations (each step exists to keep a prior fix closed):
|
|
36
|
+
* 1. slice to MAX_SANITIZE_INPUT_CHARS (regex-work bound)
|
|
37
|
+
* 2. neutralize ANSI CSI sequences to a single space (#2369 Gap 2 — an SGR
|
|
38
|
+
* final byte `m` is a word character and defeated `\b`; substituting a
|
|
39
|
+
* separator can only create boundaries, never remove one, so the #2363
|
|
40
|
+
* split/join fixes stay closed)
|
|
41
|
+
* 3. redact URLs (against the CSI-neutralized view)
|
|
42
|
+
* 4. redact credential KV pairs — keyword match is UNANCHORED and tolerant
|
|
43
|
+
* of glued key names and identifier suffixes (#2369 Gap 1), and the
|
|
44
|
+
* value matcher tolerates a fill-tolerant auth scheme word (Basic,
|
|
45
|
+
* Digest, …) between separator and credential so `Authorization: Basic
|
|
46
|
+
* <base64>` redacts the credential, not just the scheme
|
|
47
|
+
* 5. redact SCREAMING_CASE KV pairs (unchanged shape)
|
|
48
|
+
* 6. strip residual control/format/DI runs to spaces
|
|
49
|
+
* 7. sweep residual over-long bare `[<params>m` SGR bodies (the >32-char
|
|
50
|
+
* CSI tail the bounded pre-pass cannot match)
|
|
51
|
+
* 8. trim + 512-byte UTF-8 bound
|
|
52
|
+
*
|
|
53
|
+
* Best-effort defense-in-depth for a log-display string, NOT a security
|
|
54
|
+
* boundary: combining marks (U+0300 class) still defeat keyword matching and
|
|
55
|
+
* are deliberately not fixed (#2369 Gap 3 — sweeping `\p{Mn}` would over-redact
|
|
56
|
+
* every legitimate combining accent in non-Latin diagnostics). Glued-key
|
|
57
|
+
* matching (Gap 1) and the CSI pre-pass (Gap 2) were added by #2485.
|
|
39
58
|
*/
|
|
40
59
|
export declare function sanitizeFailureEvidenceDisplay(value: string): string;
|
|
41
60
|
declare function isNeutralExitOne(command: string): boolean;
|
|
@@ -72,6 +72,13 @@ export interface InitOrphanRecoveryResult {
|
|
|
72
72
|
reason: string;
|
|
73
73
|
};
|
|
74
74
|
}
|
|
75
|
+
/**
|
|
76
|
+
* Issue #2527: resolves the worktree bases this project enumerates for
|
|
77
|
+
* reclamation — the project-internal default base plus every configured
|
|
78
|
+
* `worktree_dir` override. The LEGACY parent-level shared base is never
|
|
79
|
+
* enumerated for deletion (it is only read by the migration pass).
|
|
80
|
+
*/
|
|
81
|
+
export declare function resolveWorktreeEnumerationBases(directory: string): string[];
|
|
75
82
|
/**
|
|
76
83
|
* Runs bounded orphan cleanup at plugin init time.
|
|
77
84
|
*
|
|
@@ -914,6 +914,8 @@ export declare function abortPrWorkflow(directory: string, sessionID: string, op
|
|
|
914
914
|
}): Promise<{
|
|
915
915
|
mode: PrWorkflowMode;
|
|
916
916
|
prHeadSha?: string;
|
|
917
|
+
/** Remote branch head observed while cancelling a publication generation. */
|
|
918
|
+
observedRemoteHead?: string | null;
|
|
917
919
|
openLanes: number;
|
|
918
920
|
presumedStaleLanes?: string[];
|
|
919
921
|
presumedStaleDisclosure?: string;
|
|
@@ -1280,9 +1282,13 @@ export declare function recordPrFeedbackPushAttemptResult(directory: string, inp
|
|
|
1280
1282
|
* appends the audit event, and NEVER manufactures push authority. Used only
|
|
1281
1283
|
* by `abortPrWorkflow`'s explicit `cancelPublication` arm. Returns the NEW
|
|
1282
1284
|
* state revision when a state write landed (the abort clear must CAS against
|
|
1283
|
-
* it),
|
|
1285
|
+
* it), and the exact remote-head observation (including null when it could not
|
|
1286
|
+
* be resolved).
|
|
1284
1287
|
*/
|
|
1285
|
-
declare function cancelPrFeedbackPublication(directory: string, sessionID: string, reason: string): Promise<
|
|
1288
|
+
declare function cancelPrFeedbackPublication(directory: string, sessionID: string, reason: string): Promise<{
|
|
1289
|
+
revision: number | null;
|
|
1290
|
+
observedRemoteHead: string | null;
|
|
1291
|
+
}>;
|
|
1286
1292
|
export declare function resolvePrReviewWriterRunId(directory: string, sessionID: string, requestedRunId?: string): Promise<string>;
|
|
1287
1293
|
export declare function markPrReviewTriggerEvaluationComplete(directory: string, sessionID: string, runId: string, artifactPath: string): Promise<PrWorkflowGateState>;
|
|
1288
1294
|
/** Freeze one exact inline trigger ledger across every micro dispatch. */
|