sneakoscope 4.8.7 → 5.1.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/README.md +51 -726
- package/bench/tasks/t01-off-by-one/repo/package.json +9 -0
- package/bench/tasks/t01-off-by-one/repo/src/pagination.js +5 -0
- package/bench/tasks/t01-off-by-one/repo/test.js +5 -0
- package/bench/tasks/t01-off-by-one/task.json +13 -0
- package/bench/tasks/t02-signature-cochange/repo/package.json +9 -0
- package/bench/tasks/t02-signature-cochange/repo/src/admin.js +5 -0
- package/bench/tasks/t02-signature-cochange/repo/src/audit.js +5 -0
- package/bench/tasks/t02-signature-cochange/repo/src/labels.js +3 -0
- package/bench/tasks/t02-signature-cochange/repo/src/profile.js +5 -0
- package/bench/tasks/t02-signature-cochange/repo/test.js +9 -0
- package/bench/tasks/t02-signature-cochange/task.json +12 -0
- package/bench/tasks/t03-type-puzzle/repo/package.json +9 -0
- package/bench/tasks/t03-type-puzzle/repo/src/config.js +4 -0
- package/bench/tasks/t03-type-puzzle/repo/test.js +6 -0
- package/bench/tasks/t03-type-puzzle/task.json +13 -0
- package/bench/tasks/t04-refactor-preserve/repo/package.json +9 -0
- package/bench/tasks/t04-refactor-preserve/repo/src/cart.js +8 -0
- package/bench/tasks/t04-refactor-preserve/repo/test.js +4 -0
- package/bench/tasks/t04-refactor-preserve/task.json +12 -0
- package/bench/tasks/t05-performance/repo/package.json +9 -0
- package/bench/tasks/t05-performance/repo/src/pairs.js +9 -0
- package/bench/tasks/t05-performance/repo/test.js +11 -0
- package/bench/tasks/t05-performance/task.json +12 -0
- package/bench/tasks/t06-mistake-rule/repo/package.json +9 -0
- package/bench/tasks/t06-mistake-rule/repo/src/loader.js +6 -0
- package/bench/tasks/t06-mistake-rule/repo/test.js +7 -0
- package/bench/tasks/t06-mistake-rule/task.json +12 -0
- package/config/bench-baseline.json +7 -0
- package/crates/sks-core/Cargo.lock +1 -1
- package/crates/sks-core/Cargo.toml +1 -1
- package/crates/sks-core/src/main.rs +1 -1
- package/dist/bin/install.js +35 -0
- package/dist/bin/sks.js +1 -1
- package/dist/cli/cli-theme.js +51 -0
- package/dist/cli/command-registry.js +15 -4
- package/dist/cli/help-fast.js +18 -8
- package/dist/cli/insane-search-command.js +36 -8
- package/dist/cli/install-helpers.js +32 -0
- package/dist/commands/codex-lb.js +2 -0
- package/dist/commands/doctor.js +62 -6
- package/dist/commands/proof.js +6 -3
- package/dist/config/skills-manifest.json +82 -54
- package/dist/core/agents/agent-conflict-graph.js +5 -0
- package/dist/core/agents/agent-lease.js +5 -0
- package/dist/core/agents/agent-ledger-schemas.js +1 -0
- package/dist/core/agents/agent-orchestrator.js +268 -62
- package/dist/core/agents/agent-output-validator.js +14 -3
- package/dist/core/agents/agent-patch-queue-store.js +95 -2
- package/dist/core/agents/agent-patch-queue.js +6 -3
- package/dist/core/agents/agent-patch-schema.js +13 -0
- package/dist/core/agents/agent-proof-evidence.js +6 -1
- package/dist/core/agents/agent-runner-fake.js +40 -0
- package/dist/core/agents/agent-worker-pipeline.js +36 -2
- package/dist/core/agents/codex-exec-worker-adapter.js +2 -0
- package/dist/core/agents/native-worker-backend-router.js +58 -1
- package/dist/core/codex-app/sks-menubar.js +18 -5
- package/dist/core/codex-app.js +1 -0
- package/dist/core/codex-control/codex-sdk-config-policy.js +2 -1
- package/dist/core/codex-control/codex-sdk-env-policy.js +1 -1
- package/dist/core/codex-control/schemas/agent-worker-result.schema.js +12 -3
- package/dist/core/codex-hooks/codex-hook-managed-install.js +5 -0
- package/dist/core/codex-hooks/codex-hook-state-writer.js +70 -11
- package/dist/core/codex-hooks/codex-hook-trust-doctor.js +2 -2
- package/dist/core/codex-lb/codex-lb-env.js +20 -1
- package/dist/core/commands/basic-cli.js +21 -2
- package/dist/core/commands/check-command.js +37 -5
- package/dist/core/commands/computer-use-command.js +62 -7
- package/dist/core/commands/db-command.js +31 -5
- package/dist/core/commands/fast-mode-command.js +3 -0
- package/dist/core/commands/gate-result-contract.js +43 -0
- package/dist/core/commands/gates-command.js +6 -1
- package/dist/core/commands/gc-command.js +29 -2
- package/dist/core/commands/goal-command.js +9 -2
- package/dist/core/commands/gx-command.js +79 -7
- package/dist/core/commands/image-ux-review-command.js +188 -13
- package/dist/core/commands/mad-db-command.js +85 -176
- package/dist/core/commands/mad-sks-command.js +230 -29
- package/dist/core/commands/menubar-command.js +22 -1
- package/dist/core/commands/naruto-command.js +64 -10
- package/dist/core/commands/plan-command.js +76 -0
- package/dist/core/commands/ppt-command.js +159 -24
- package/dist/core/commands/qa-loop-command.js +6 -2
- package/dist/core/commands/release-command.js +55 -2
- package/dist/core/commands/research-command.js +1 -1
- package/dist/core/commands/review-command.js +217 -0
- package/dist/core/commands/route-success-helpers.js +59 -0
- package/dist/core/commands/run-command.js +19 -7
- package/dist/core/commands/seo-command.js +49 -1
- package/dist/core/commands/ui-command.js +161 -0
- package/dist/core/commands/uninstall-command.js +15 -1
- package/dist/core/db-safety.js +2 -2
- package/dist/core/doctor/doctor-transaction.js +8 -0
- package/dist/core/doctor/doctor-zellij-repair.js +1 -0
- package/dist/core/doctor/imagegen-repair.js +161 -0
- package/dist/core/feature-fixture-runner.js +2 -2
- package/dist/core/feature-fixtures.js +58 -37
- package/dist/core/feature-registry.js +102 -2
- package/dist/core/fsx.js +39 -6
- package/dist/core/image-ux-review/imagegen-adapter.js +48 -11
- package/dist/core/image-ux-review.js +16 -0
- package/dist/core/imagegen/imagegen-capability.js +11 -5
- package/dist/core/imagegen/require-imagegen.js +57 -0
- package/dist/core/init/skills.js +10 -5
- package/dist/core/mad-db/mad-db-coordinator.js +94 -18
- package/dist/core/mad-db/mad-db-policy.js +12 -10
- package/dist/core/mad-sks/executors/executor-base.js +8 -2
- package/dist/core/mad-sks/executors/index.js +4 -0
- package/dist/core/mad-sks/executors/sql-plane-executor.js +194 -0
- package/dist/core/naruto/naruto-active-pool.js +15 -4
- package/dist/core/naruto/naruto-real-worker-child.js +10 -0
- package/dist/core/naruto/naruto-role-policy.js +3 -0
- package/dist/core/naruto/naruto-task-hints.js +10 -0
- package/dist/core/naruto/naruto-work-graph.js +8 -2
- package/dist/core/naruto/naruto-work-item.js +6 -0
- package/dist/core/naruto/solution-tournament.js +101 -0
- package/dist/core/permission-gates.js +30 -0
- package/dist/core/pipeline-internals/runtime-core.js +11 -3
- package/dist/core/pipeline-internals/runtime-gates.js +27 -0
- package/dist/core/ppt-review/index.js +6 -1
- package/dist/core/ppt-review/slide-imagegen-review.js +75 -10
- package/dist/core/ppt.js +70 -2
- package/dist/core/proof/auto-finalize.js +70 -11
- package/dist/core/proof/proof-schema.js +2 -0
- package/dist/core/proof/route-adapter.js +5 -1
- package/dist/core/proof/route-finalizer.js +8 -5
- package/dist/core/proof/selftest-proof-fixtures.js +18 -5
- package/dist/core/proof/validation.js +2 -0
- package/dist/core/provider/model-router.js +53 -0
- package/dist/core/release/release-gate-node.js +3 -0
- package/dist/core/release/release-gate-resource-governor.js +1 -0
- package/dist/core/routes/constants.js +1 -1
- package/dist/core/routes.js +65 -18
- package/dist/core/safety/mutation-guard.js +5 -1
- package/dist/core/stop-gate/gate-evaluator.js +102 -0
- package/dist/core/stop-gate/stop-gate-check.js +16 -1
- package/dist/core/stop-gate/stop-gate-writer.js +4 -0
- package/dist/core/triwiki/agents-md-projector.js +184 -0
- package/dist/core/triwiki-wrongness/wrongness-schema.js +3 -1
- package/dist/core/trust-kernel/trust-kernel-schema.js +1 -0
- package/dist/core/trust-kernel/trust-report.js +1 -1
- package/dist/core/trust-kernel/trust-status.js +2 -0
- package/dist/core/ui/dashboard-html.js +111 -0
- package/dist/core/update/update-migration-state.js +366 -15
- package/dist/core/update-check.js +178 -81
- package/dist/core/verification/diff-quality.js +100 -0
- package/dist/core/verification/impact-scan.js +164 -0
- package/dist/core/verification/machine-feedback.js +146 -0
- package/dist/core/verification/mistake-rule-compiler.js +195 -0
- package/dist/core/version.js +1 -1
- package/dist/core/zellij/zellij-self-heal.js +9 -6
- package/dist/scripts/check-feature-quality.js +2 -2
- package/dist/scripts/cli-output-consistency-check.js +57 -0
- package/dist/scripts/coding-bench-check.js +136 -0
- package/dist/scripts/doctor-imagegen-repair-check.js +62 -0
- package/dist/scripts/ensure-bin-executable.js +11 -3
- package/dist/scripts/harness-benchmark-check.js +104 -0
- package/dist/scripts/legacy-update-e2e-check.js +228 -0
- package/dist/scripts/mad-db-command-check.js +11 -8
- package/dist/scripts/mad-db-route-identity-check.js +8 -6
- package/dist/scripts/mad-db-safety-conflict-matrix-check.js +31 -8
- package/dist/scripts/mad-db-skill-policy-snapshot-check.js +4 -5
- package/dist/scripts/ppt-real-imagegen-wiring-check.js +5 -1
- package/dist/scripts/proof-root-cause-policy-check.js +2 -0
- package/dist/scripts/release-dag-full-coverage-check.js +13 -4
- package/dist/scripts/release-gate-dag-runner.js +14 -0
- package/dist/scripts/release-gate-existence-audit.js +2 -1
- package/dist/scripts/release-gate-planner.js +2 -1
- package/dist/scripts/release-gate-script-parity-check.js +1 -1
- package/dist/scripts/release-metadata-1-19-check.js +2 -1
- package/dist/scripts/seo-geo-feature-fixture-quality-check.js +1 -1
- package/dist/scripts/sks-1-11-gate-lib.js +8 -6
- package/dist/scripts/ux-review-real-loop-fixture-check.js +9 -4
- package/dist/scripts/ux-review-run-wires-imagegen-check.js +4 -0
- package/docs/assets/sneakoscope-architecture-pipeline.jpg +0 -0
- package/docs/demo.tape +28 -0
- package/package.json +67 -3
- package/schemas/codex/completion-proof.schema.json +3 -2
- package/schemas/release/release-gate-node.schema.json +2 -1
- package/dist/scripts/agent-backfill-route-blackbox.js +0 -5
- package/dist/scripts/agent-dynamic-pool-route-blackbox.js +0 -5
- package/dist/scripts/agent-parallel-write-blackbox.js +0 -56
- package/dist/scripts/agent-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/agent-route-blackbox-lib.js +0 -132
- package/dist/scripts/blackbox-command-import-smoke.js +0 -143
- package/dist/scripts/blackbox-global-shim.js +0 -77
- package/dist/scripts/blackbox-matrix.js +0 -70
- package/dist/scripts/blackbox-npx-one-shot.js +0 -69
- package/dist/scripts/blackbox-pack-install.js +0 -174
- package/dist/scripts/brand-neutrality-zero-leakage-blackbox.js +0 -4
- package/dist/scripts/build-once-runner-blackbox.js +0 -34
- package/dist/scripts/codex-0140-integration-blackbox.js +0 -13
- package/dist/scripts/codex-agent-type-blackbox.js +0 -4
- package/dist/scripts/codex-app-harness-blackbox.js +0 -4
- package/dist/scripts/codex-app-skill-agent-blackbox.js +0 -4
- package/dist/scripts/codex-hook-approval-blackbox.js +0 -4
- package/dist/scripts/codex-init-deep-directory-local-blackbox.js +0 -4
- package/dist/scripts/codex-native-feature-broker-blackbox.js +0 -4
- package/dist/scripts/codex-native-pattern-analysis-blackbox.js +0 -4
- package/dist/scripts/codex-native-read-repair-split-blackbox.js +0 -55
- package/dist/scripts/codex-native-reference-cache-blackbox.js +0 -41
- package/dist/scripts/core-skill-integrity-blackbox.js +0 -32
- package/dist/scripts/dfix-fast-blackbox-check.js +0 -37
- package/dist/scripts/dfix-parallel-write-blackbox.js +0 -48
- package/dist/scripts/dfix-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/doctor-context7-mcp-repair-blackbox.js +0 -16
- package/dist/scripts/doctor-dirty-repair-blackbox.js +0 -22
- package/dist/scripts/doctor-dirty-semantic-blackbox.js +0 -8
- package/dist/scripts/doctor-fix-production-blackbox.js +0 -26
- package/dist/scripts/doctor-native-capability-repair-blackbox.js +0 -39
- package/dist/scripts/doctor-startup-config-repair-blackbox.js +0 -13
- package/dist/scripts/doctor-supabase-mcp-repair-blackbox.js +0 -14
- package/dist/scripts/doctor-transaction-engine-blackbox.js +0 -28
- package/dist/scripts/doctor-zellij-fix-blackbox.js +0 -4
- package/dist/scripts/doctor-zellij-no-homebrew-blackbox.js +0 -4
- package/dist/scripts/doctor-zellij-upgrade-blackbox.js +0 -4
- package/dist/scripts/gate-pack-runner-blackbox.js +0 -27
- package/dist/scripts/gate-pack-v2-blackbox.js +0 -18
- package/dist/scripts/geo-cli-blackbox-check.js +0 -18
- package/dist/scripts/loop-collision-blackbox.js +0 -3
- package/dist/scripts/loop-concurrency-oversubscription-blackbox.js +0 -3
- package/dist/scripts/loop-fixture-production-misuse-blackbox.js +0 -3
- package/dist/scripts/loop-kill-interrupt-real-blackbox.js +0 -3
- package/dist/scripts/loop-merge-strategy-blackbox.js +0 -3
- package/dist/scripts/loop-mesh-production-e2e-blackbox.js +0 -3
- package/dist/scripts/loop-side-effect-blackbox.js +0 -3
- package/dist/scripts/mad-db-operation-lifecycle-blackbox.js +0 -29
- package/dist/scripts/mad-sks-actual-executor-blackbox.js +0 -5
- package/dist/scripts/mad-zellij-headless-fallback-blackbox.js +0 -4
- package/dist/scripts/mad-zellij-self-heal-blackbox.js +0 -4
- package/dist/scripts/naruto-loop-mesh-blackbox.js +0 -3
- package/dist/scripts/naruto-real-parallelism-blackbox.js +0 -307
- package/dist/scripts/naruto-worktree-coding-blackbox.js +0 -29
- package/dist/scripts/parallel-runtime-real-blackbox.js +0 -44
- package/dist/scripts/pipeline-codex-native-doctor-mad-routing-real-blackbox.js +0 -77
- package/dist/scripts/pipeline-codex-native-e2e-blackbox.js +0 -13
- package/dist/scripts/pipeline-codex-native-image-routing-real-blackbox.js +0 -50
- package/dist/scripts/pipeline-codex-native-loop-routing-real-blackbox.js +0 -74
- package/dist/scripts/pipeline-codex-native-qa-routing-real-blackbox.js +0 -51
- package/dist/scripts/pipeline-codex-native-research-routing-real-blackbox.js +0 -45
- package/dist/scripts/pipeline-execution-profile-routing-blackbox.js +0 -4
- package/dist/scripts/postinstall-global-doctor-blackbox.js +0 -12
- package/dist/scripts/ppt-full-e2e-blackbox-check.js +0 -109
- package/dist/scripts/ppt-imagegen-blackbox-check.js +0 -46
- package/dist/scripts/project-skill-dedupe-blackbox.js +0 -36
- package/dist/scripts/qa-backfill-route-blackbox.js +0 -5
- package/dist/scripts/qa-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/release-full-parallelism-blackbox.js +0 -41
- package/dist/scripts/release-triwiki-first-runner-blackbox.js +0 -48
- package/dist/scripts/release-wiring-3110-blackbox.js +0 -27
- package/dist/scripts/release-wiring-3112-blackbox.js +0 -17
- package/dist/scripts/release-wiring-3113-blackbox.js +0 -17
- package/dist/scripts/research-backfill-route-blackbox.js +0 -5
- package/dist/scripts/research-final-reviewer-blackbox.js +0 -70
- package/dist/scripts/research-stage-cycle-runtime-blackbox.js +0 -40
- package/dist/scripts/research-synthesis-writer-blackbox.js +0 -24
- package/dist/scripts/route-blackbox-realism-check.js +0 -21
- package/dist/scripts/scheduler-resource-claim-blackbox.js +0 -24
- package/dist/scripts/seo-cli-blackbox-check.js +0 -18
- package/dist/scripts/sks-3110-all-feature-regression-blackbox.js +0 -116
- package/dist/scripts/sks-3112-all-feature-regression-blackbox.js +0 -29
- package/dist/scripts/sks-3113-all-feature-regression-blackbox.js +0 -17
- package/dist/scripts/sks-400-all-feature-regression-blackbox.js +0 -21
- package/dist/scripts/sks-400-extreme-parallel-blackbox.js +0 -8
- package/dist/scripts/sks-400-five-minute-blackbox.js +0 -9
- package/dist/scripts/sks-400-legacy-purge-blackbox.js +0 -8
- package/dist/scripts/sks-401-all-feature-regression-blackbox.js +0 -46
- package/dist/scripts/sks-401-five-minute-actual-blackbox.js +0 -23
- package/dist/scripts/sks-402-all-feature-regression-blackbox.js +0 -9
- package/dist/scripts/sks-402-five-minute-real-blackbox.js +0 -22
- package/dist/scripts/sksd-warm-cache-blackbox.js +0 -12
- package/dist/scripts/supabase-secret-preservation-blackbox.js +0 -29
- package/dist/scripts/team-backfill-route-blackbox.js +0 -5
- package/dist/scripts/team-parallel-write-blackbox.js +0 -55
- package/dist/scripts/team-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/triwiki-affected-graph-blackbox.js +0 -28
- package/dist/scripts/triwiki-proof-bank-blackbox.js +0 -30
- package/dist/scripts/triwiki-proof-bank-lock-blackbox.js +0 -7
- package/dist/scripts/update-preserves-supabase-keys-blackbox.js +0 -27
- package/dist/scripts/ux-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/ux-review-imagegen-blackbox-check.js +0 -67
- package/dist/scripts/zellij-initial-main-only-blackbox.js +0 -28
- package/dist/scripts/zellij-pane-lock-concurrency-blackbox.js +0 -80
- package/dist/scripts/zellij-pane-lock-open-worker-integration-blackbox.js +0 -137
- package/dist/scripts/zellij-self-heal-typed-blackbox.js +0 -4
- package/dist/scripts/zellij-slot-telemetry-real-blackbox.js +0 -20
- package/dist/scripts/zellij-stacked-fallback-integration-blackbox.js +0 -81
- package/dist/scripts/zellij-worker-pane-real-ui-blackbox.js +0 -202
|
@@ -43,6 +43,20 @@ console.log(`SKS Release DAG
|
|
|
43
43
|
critical_path: ${(result.critical_path_ms / 1000).toFixed(1)}s
|
|
44
44
|
certificate: ${result.completion_certificate.confidence} sla=${(result.completion_certificate.sla_ms / 1000).toFixed(0)}s met=${result.completion_certificate.sla_met}
|
|
45
45
|
report: ${result.report_dir}`);
|
|
46
|
+
const gateResult = {
|
|
47
|
+
schema: 'sks.gate-result.v1',
|
|
48
|
+
ok: result.ok === true,
|
|
49
|
+
blockers: result.ok ? [] : result.failures.map((failure) => `release_gate_failed:${failure.id}`),
|
|
50
|
+
summary: {
|
|
51
|
+
total_gates: result.total_gates,
|
|
52
|
+
selected_gates: result.selected_gates,
|
|
53
|
+
cached: result.cached,
|
|
54
|
+
completed: result.completed,
|
|
55
|
+
failed: result.failed,
|
|
56
|
+
report_dir: result.report_dir
|
|
57
|
+
}
|
|
58
|
+
};
|
|
59
|
+
console.log(JSON.stringify(gateResult));
|
|
46
60
|
if (!result.ok) {
|
|
47
61
|
for (const failure of result.failures) {
|
|
48
62
|
console.error(`[fail] ${failure.id} exit=${failure.exit_code}\n${failure.stderr_tail}`);
|
|
@@ -43,7 +43,8 @@ const releaseCheckTarget = releaseCheck.includes('release:check:affected')
|
|
|
43
43
|
: releaseCheck;
|
|
44
44
|
assertGate(releaseCheckTarget.includes('release-gate-dag-runner') && /--preset\s+(?:release|affected)/.test(releaseCheckTarget), 'release:check must use the v2 DAG release/affected preset', { release_check: scripts['release:check'], resolved_release_check: releaseCheckTarget });
|
|
45
45
|
assertGate(releaseGates.length > 0 && releaseGates.length <= 200, 'release v2 manifest must include 1..200 release gates', { gate_count: releaseGates.length });
|
|
46
|
-
|
|
46
|
+
const PACKAGE_SCRIPT_BUDGET = 150;
|
|
47
|
+
assertGate(Object.keys(scripts).length <= PACKAGE_SCRIPT_BUDGET, 'package script budget exceeded', { script_count: Object.keys(scripts).length, limit: PACKAGE_SCRIPT_BUDGET });
|
|
47
48
|
for (const id of requiredRelease)
|
|
48
49
|
assertGate(releaseIds.has(id), `critical release gate missing from release v2 manifest: ${id}`, { id });
|
|
49
50
|
for (const id of requiredHarness)
|
|
@@ -9,6 +9,7 @@ import { assertGate, emitGate, importDist, root } from './sks-1-18-gate-lib.js';
|
|
|
9
9
|
const { validateReleaseGateManifest } = await importDist('core/release/release-gate-node.js');
|
|
10
10
|
const pkg = JSON.parse(fs.readFileSync(path.join(root, 'package.json'), 'utf8'));
|
|
11
11
|
const scripts = pkg.scripts || {};
|
|
12
|
+
const PACKAGE_SCRIPT_BUDGET = 150;
|
|
12
13
|
const release = readManifest('release-gates.v2.json');
|
|
13
14
|
const harness = readManifest('infra-harness-gates.json');
|
|
14
15
|
assertGate(!fs.existsSync(path.join(root, 'release-gates.json')), 'release-gates.json v1 must not be present');
|
|
@@ -27,7 +28,7 @@ const releasePresetLeaks = release.gates.filter((gate) => !Array.isArray(gate.pr
|
|
|
27
28
|
const harnessPresetLeaks = harness.gates.filter((gate) => !Array.isArray(gate.preset) || !gate.preset.includes('harness') || gate.preset.includes('release')).map((gate) => gate.id);
|
|
28
29
|
const npmRunGates = release.gates.concat(harness.gates).filter((gate) => /\bnpm\s+run\b/.test(String(gate.command))).map((gate) => gate.id);
|
|
29
30
|
assertGate(release.gates.length <= 200, 'release preset gate budget exceeded', { release_gates: release.gates.length, limit: 200 });
|
|
30
|
-
assertGate(Object.keys(scripts).length <=
|
|
31
|
+
assertGate(Object.keys(scripts).length <= PACKAGE_SCRIPT_BUDGET, 'package.json script budget exceeded', { scripts: Object.keys(scripts).length, limit: PACKAGE_SCRIPT_BUDGET });
|
|
31
32
|
assertGate(duplicateAcrossManifests.length === 0, 'gate appears in both release and harness manifests', { duplicateAcrossManifests });
|
|
32
33
|
assertGate(releaseZellij.length === 0, 'zellij gates must live in infra-harness-gates.json, not release-gates.v2.json', { releaseZellij });
|
|
33
34
|
assertGate(harnessNonZellij.length === 0, 'infra harness manifest must contain only zellij gates', { harnessNonZellij });
|
|
@@ -38,7 +38,7 @@ export const REQUIRED_3110_RELEASE_IDS = [
|
|
|
38
38
|
'config:managed-merge-callsite-coverage',
|
|
39
39
|
'release:gate-script-parity',
|
|
40
40
|
'release:wiring-3110-blackbox',
|
|
41
|
-
'sks:
|
|
41
|
+
'sks:3112-all-feature-regression'
|
|
42
42
|
];
|
|
43
43
|
if (isMain()) {
|
|
44
44
|
main().catch((err) => {
|
|
@@ -372,7 +372,8 @@ assertGate(releaseManifest?.schema === 'sks.release-gates.v2', 'release gate man
|
|
|
372
372
|
assertGate(harnessManifest?.schema === 'sks.infra-harness-gates.v1', 'infra harness manifest schema mismatch', { schema: harnessManifest?.schema || null });
|
|
373
373
|
assertGate(releaseGates.length > 0 && releaseGates.length <= 200, 'release v2 manifest must include 1..200 release gates', { release_gates: releaseGates.length });
|
|
374
374
|
assertGate(harnessGates.length > 0, 'infra harness manifest must include harness gates', { harness_gates: harnessGates.length });
|
|
375
|
-
|
|
375
|
+
const PACKAGE_SCRIPT_BUDGET = 150;
|
|
376
|
+
assertGate(Object.keys(pkg.scripts || {}).length <= PACKAGE_SCRIPT_BUDGET, 'package script budget exceeded', { script_count: Object.keys(pkg.scripts || {}).length, limit: PACKAGE_SCRIPT_BUDGET });
|
|
376
377
|
for (const script of requiredPackageScripts)
|
|
377
378
|
assertGate(Boolean(pkg.scripts?.[script]), `missing package script: ${script}`);
|
|
378
379
|
for (const id of requiredReleaseGates)
|
|
@@ -9,7 +9,7 @@ for (const id of ['cli-seo-geo-optimizer', 'route-seo-geo-optimizer']) {
|
|
|
9
9
|
assertGate(feature, `feature missing: ${id}`);
|
|
10
10
|
assertGate(feature.fixture?.status === 'pass', `feature fixture must pass: ${id}`, feature);
|
|
11
11
|
assertGate(feature.fixture?.quality !== 'static_contract', `SEO/GEO feature must not rely on static contract: ${id}`, feature.fixture);
|
|
12
|
-
assertGate(
|
|
12
|
+
assertGate(feature.fixture?.quality === 'runtime_verified', `SEO/GEO fixture quality must be runtime-backed by execution: ${id}`, feature.fixture);
|
|
13
13
|
}
|
|
14
14
|
const selftest = registryMod.buildAllFeaturesSelftest(registry, {});
|
|
15
15
|
const runtimeCheck = selftest.checks.find((check) => check.id === 'runtime_routes_not_static_contract');
|
|
@@ -23,15 +23,17 @@ export function runSksJson(args) {
|
|
|
23
23
|
timeout: Number(process.env.SKS_GATE_TIMEOUT_MS || 120_000),
|
|
24
24
|
env: { ...process.env, SKS_SKIP_NPM_FRESHNESS_CHECK: '1', CI: 'true' }
|
|
25
25
|
});
|
|
26
|
-
|
|
27
|
-
assertGate(false, 'sks command failed', { args, status: result.status, stdout: result.stdout, stderr: result.stderr });
|
|
28
|
-
}
|
|
26
|
+
let parsed = null;
|
|
29
27
|
try {
|
|
30
|
-
|
|
28
|
+
parsed = JSON.parse(result.stdout);
|
|
31
29
|
}
|
|
32
30
|
catch (err) {
|
|
33
31
|
assertGate(false, 'sks command did not emit parseable JSON', { args, stdout: result.stdout, error: err.message });
|
|
34
32
|
}
|
|
33
|
+
if (result.status !== 0 && !parsed?.mission_id) {
|
|
34
|
+
assertGate(false, 'sks command failed', { args, status: result.status, stdout: result.stdout, stderr: result.stderr });
|
|
35
|
+
}
|
|
36
|
+
return { ...parsed, _process_status: result.status, _stderr_tail: String(result.stderr || '').slice(-600) };
|
|
35
37
|
}
|
|
36
38
|
export function runPptReview(action = 'review') {
|
|
37
39
|
const json = runSksJson(['ppt', 'fixture', '--mock', '--json']);
|
|
@@ -46,7 +48,7 @@ export function runPptReview(action = 'review') {
|
|
|
46
48
|
},
|
|
47
49
|
slideIssues: review.slide_issue_ledger || {}
|
|
48
50
|
};
|
|
49
|
-
assertGate(json.
|
|
51
|
+
assertGate(Boolean(json.mission_id), 'ppt imagegen review fixture did not create a mission', json);
|
|
50
52
|
assertGate(json.proof_evidence?.generated_slide_callout_images_count > 0, 'ppt callout image evidence missing', json.proof_evidence);
|
|
51
53
|
assertGate(json.proof_evidence?.slide_issue_extraction_status === 'valid', 'ppt issue extraction missing', json.proof_evidence);
|
|
52
54
|
return json;
|
|
@@ -60,7 +62,7 @@ export function runDfixFixture() {
|
|
|
60
62
|
}
|
|
61
63
|
export function runUxFixture() {
|
|
62
64
|
const json = runSksJson(['image-ux-review', 'fixture', '--mock', '--json']);
|
|
63
|
-
assertGate(json.
|
|
65
|
+
assertGate(Boolean(json.mission_id), 'image UX review fixture did not create a mission', json);
|
|
64
66
|
return json;
|
|
65
67
|
}
|
|
66
68
|
export function missionFile(missionId, file) {
|
|
@@ -1,24 +1,29 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
// @ts-nocheck
|
|
3
3
|
import assert from 'node:assert/strict';
|
|
4
|
+
import fs from 'node:fs';
|
|
5
|
+
import os from 'node:os';
|
|
4
6
|
import { spawnSync } from 'node:child_process';
|
|
5
7
|
import path from 'node:path';
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
+
const repoRoot = process.cwd();
|
|
9
|
+
const root = fs.mkdtempSync(path.join(os.tmpdir(), 'sks-ux-review-real-loop-fixture-'));
|
|
10
|
+
const result = spawnSync(process.execPath, [path.join(repoRoot, 'dist/bin/sks.js'), 'image-ux-review', 'fixture', '--mock', '--json'], {
|
|
8
11
|
cwd: root,
|
|
9
12
|
encoding: 'utf8',
|
|
10
|
-
env: { ...process.env, SKS_SKIP_NPM_FRESHNESS_CHECK: '1', CI: 'true' },
|
|
13
|
+
env: { ...process.env, SKS_SKIP_NPM_FRESHNESS_CHECK: '1', SKS_UPDATE_MIGRATION_GATE_DISABLED: '1', CI: 'true' },
|
|
11
14
|
timeout: Number(process.env.SKS_UX_REVIEW_REAL_LOOP_FIXTURE_TIMEOUT_MS || 180_000)
|
|
12
15
|
});
|
|
13
|
-
assert.
|
|
16
|
+
assert.ok([0, 1].includes(result.status), JSON.stringify({
|
|
14
17
|
stderr: result.stderr,
|
|
15
18
|
stdout: result.stdout,
|
|
16
19
|
signal: result.signal,
|
|
17
20
|
error: result.error?.message || null
|
|
18
21
|
}, null, 2));
|
|
19
22
|
const json = JSON.parse(result.stdout);
|
|
23
|
+
assert.equal(json.ok, false);
|
|
20
24
|
assert.equal(json.artifacts.gate.mock_fixture_cannot_claim_real, true);
|
|
21
25
|
assert.equal(json.artifacts.generated_review_ledger.real_generated_count, 0);
|
|
22
26
|
assert.equal(json.artifacts.generated_review_ledger.generated_count, 1);
|
|
27
|
+
assert.equal(json.proof.status, 'mock_only');
|
|
23
28
|
console.log(JSON.stringify({ schema: 'sks.ux-review-real-loop-fixture.v1', ok: true, mission_id: json.mission_id }, null, 2));
|
|
24
29
|
//# sourceMappingURL=ux-review-real-loop-fixture-check.js.map
|
|
@@ -3,7 +3,11 @@
|
|
|
3
3
|
import { emitGate, requireContains } from './sks-1-12-real-execution-check-lib.js';
|
|
4
4
|
requireContains('ux-review:run-wires-imagegen', 'src/core/commands/image-ux-review-command.ts', [
|
|
5
5
|
'const shouldGenerateCallouts = flag(args, \'--generate-callouts\') || flag(args, \'--fix\')',
|
|
6
|
+
'requireCodexImagegen',
|
|
6
7
|
'generateGptImage2CalloutReview',
|
|
8
|
+
'evidence_class',
|
|
9
|
+
'output_sha256',
|
|
10
|
+
'imagegen_response_non_codex_api_fallback_not_full_evidence',
|
|
7
11
|
'extractRealCallouts',
|
|
8
12
|
'buildImageUxCalloutExtractionReport'
|
|
9
13
|
]);
|
|
Binary file
|
package/docs/demo.tape
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
Output docs/assets/sks-v5-demo.gif
|
|
2
|
+
Set Shell "zsh"
|
|
3
|
+
Set FontSize 16
|
|
4
|
+
Set Width 1280
|
|
5
|
+
Set Height 720
|
|
6
|
+
Set TypingSpeed 20ms
|
|
7
|
+
|
|
8
|
+
Type "npx sneakoscope install --yes"
|
|
9
|
+
Sleep 500ms
|
|
10
|
+
Enter
|
|
11
|
+
Sleep 1s
|
|
12
|
+
Ctrl+C
|
|
13
|
+
|
|
14
|
+
Type "sks plan \"ship a proof-first review flow\""
|
|
15
|
+
Enter
|
|
16
|
+
Sleep 1s
|
|
17
|
+
|
|
18
|
+
Type "sks review --staged"
|
|
19
|
+
Enter
|
|
20
|
+
Sleep 1s
|
|
21
|
+
|
|
22
|
+
Type "sks ui --once"
|
|
23
|
+
Enter
|
|
24
|
+
Sleep 1s
|
|
25
|
+
|
|
26
|
+
Type "sks naruto run \"demo no-op swarm\" --backend fake --clones 4 --work-items 4 --no-open-zellij --json"
|
|
27
|
+
Enter
|
|
28
|
+
Sleep 2s
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sneakoscope",
|
|
3
3
|
"displayName": "ㅅㅋㅅ",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "5.1.2",
|
|
5
5
|
"description": "Sneakoscope Codex: fast proof-first Codex trust layer with image-based Voxel TriWiki.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"homepage": "https://github.com/mandarange/Sneakoscope-Codex#readme",
|
|
@@ -14,7 +14,8 @@
|
|
|
14
14
|
},
|
|
15
15
|
"bin": {
|
|
16
16
|
"sks": "dist/bin/sks.js",
|
|
17
|
-
"sneakoscope": "dist/bin/sks.js"
|
|
17
|
+
"sneakoscope": "dist/bin/sks.js",
|
|
18
|
+
"sneakoscope-install": "dist/bin/install.js"
|
|
18
19
|
},
|
|
19
20
|
"publishConfig": {
|
|
20
21
|
"access": "public",
|
|
@@ -32,8 +33,11 @@
|
|
|
32
33
|
"!dist/**/*.tsbuildinfo",
|
|
33
34
|
"!dist/**/__tests__",
|
|
34
35
|
"!dist/**/*.test.js",
|
|
36
|
+
"!dist/scripts/*blackbox*.js",
|
|
35
37
|
"!dist/vendor/openai-codex/rust-v0.131.0",
|
|
36
38
|
"config/codex-releases/rust-v0.142.0.json",
|
|
39
|
+
"config/bench-baseline.json",
|
|
40
|
+
"bench/tasks",
|
|
37
41
|
"schemas",
|
|
38
42
|
"!schemas/codex/app-server-0.142/**",
|
|
39
43
|
"schemas/codex/app-server-0.142/codex_app_server_protocol.v2.schemas.json",
|
|
@@ -41,6 +45,8 @@
|
|
|
41
45
|
"crates/sks-core/Cargo.lock",
|
|
42
46
|
"crates/sks-core/Cargo.toml",
|
|
43
47
|
"crates/sks-core/src",
|
|
48
|
+
"docs/demo.tape",
|
|
49
|
+
"docs/assets/sneakoscope-architecture-pipeline.jpg",
|
|
44
50
|
"README.md",
|
|
45
51
|
"LICENSE"
|
|
46
52
|
],
|
|
@@ -60,17 +66,31 @@
|
|
|
60
66
|
"runtime:dist-parity": "node ./dist/scripts/runtime-dist-parity-check.js",
|
|
61
67
|
"release:check": "npm run release:check:affected --silent",
|
|
62
68
|
"release:metadata": "node ./dist/scripts/release-metadata-check.js",
|
|
69
|
+
"release:gate-script-parity": "node ./dist/scripts/release-gate-script-parity-check.js",
|
|
63
70
|
"release:check:parallel": "npm run build --silent && node ./dist/scripts/release-parallel-check.js && node ./dist/scripts/release-check-stamp.js write",
|
|
64
71
|
"release:check:legacy": "npm run release:check:parallel --silent",
|
|
72
|
+
"release:dag-full-coverage": "node ./dist/scripts/release-dag-full-coverage-check.js",
|
|
65
73
|
"core-skill:route-runtime-integration": "node ./dist/scripts/core-skill-route-runtime-integration-check.js",
|
|
74
|
+
"core-skill:no-drift": "node ./dist/scripts/core-skill-no-drift-check.js",
|
|
66
75
|
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
67
76
|
"schema:check": "node ./dist/scripts/check-runtime-schemas.js",
|
|
68
77
|
"repo-audit": "node ./dist/scripts/repo-audit.js",
|
|
78
|
+
"native-capability:postcheck": "node ./dist/scripts/native-capability-postcheck-check.js",
|
|
79
|
+
"secret:preservation-guard": "node ./dist/scripts/secret-preservation-guard-check.js",
|
|
80
|
+
"secret:supabase-preservation-blackbox": "node ./dist/scripts/supabase-secret-preservation-blackbox.js",
|
|
81
|
+
"update:preserves-supabase-keys": "node ./dist/scripts/update-preserves-supabase-keys-blackbox.js",
|
|
82
|
+
"skill:dedupe-blackbox": "node ./dist/scripts/project-skill-dedupe-blackbox.js",
|
|
69
83
|
"postinstall": "node ./dist/bin/sks.js postinstall",
|
|
70
84
|
"selftest": "node ./dist/bin/sks.js selftest --mock",
|
|
71
85
|
"doctor": "node ./dist/bin/sks.js doctor",
|
|
86
|
+
"doctor:fix-production-blackbox": "node ./dist/scripts/doctor-fix-production-blackbox.js",
|
|
87
|
+
"doctor:startup-config-repair-blackbox": "node ./dist/scripts/doctor-startup-config-repair-blackbox.js",
|
|
88
|
+
"doctor:context7-mcp-repair-blackbox": "node ./dist/scripts/doctor-context7-mcp-repair-blackbox.js",
|
|
89
|
+
"doctor:supabase-mcp-repair-blackbox": "node ./dist/scripts/doctor-supabase-mcp-repair-blackbox.js",
|
|
72
90
|
"codex:config-load-probe": "node ./dist/scripts/codex-config-load-probe.js --json",
|
|
73
91
|
"codex:actual-config-load-probe": "node ./dist/scripts/codex-config-load-probe.js --actual-codex --json",
|
|
92
|
+
"codex:0140-capability": "node ./dist/scripts/codex-0140-capability-check.js",
|
|
93
|
+
"codex:0140-feature-probes": "node ./dist/scripts/codex-0140-feature-probes-check.js",
|
|
74
94
|
"runtime:ts-rust-boundary": "node ./dist/scripts/runtime-ts-rust-boundary-check.js",
|
|
75
95
|
"release:check:dynamic": "node ./dist/scripts/release-check-dynamic.js",
|
|
76
96
|
"release:check:dynamic:execute": "node ./dist/scripts/release-check-dynamic-execute.js",
|
|
@@ -96,6 +116,48 @@
|
|
|
96
116
|
"feature:check": "node ./dist/bin/sks.js features check --json",
|
|
97
117
|
"feature-quality:check": "node ./dist/scripts/check-feature-quality.js --release",
|
|
98
118
|
"all-features:selftest": "node ./dist/bin/sks.js all-features selftest --mock --json",
|
|
119
|
+
"doctor:imagegen-repair": "node ./dist/scripts/doctor-imagegen-repair-check.js",
|
|
120
|
+
"image-fidelity:check": "node ./dist/scripts/image-fidelity-fixture-check.js",
|
|
121
|
+
"imagegen:capability": "node ./dist/scripts/imagegen-capability-check.js",
|
|
122
|
+
"imagegen:gpt-image-2-request-validator": "node ./dist/scripts/gpt-image-2-request-validator-check.js",
|
|
123
|
+
"ux-review:run-wires-imagegen": "node ./dist/scripts/ux-review-run-wires-imagegen-check.js",
|
|
124
|
+
"ux-review:extract-wires-real-extractor": "node ./dist/scripts/ux-review-extract-wires-real-extractor-check.js",
|
|
125
|
+
"ux-review:patch-diff-recheck": "node ./dist/scripts/ux-review-patch-diff-recheck-check.js",
|
|
126
|
+
"ux-review:imagegen-blackbox": "node ./dist/scripts/ux-review-imagegen-blackbox-check.js",
|
|
127
|
+
"ux-review:real-loop-fixture": "node ./dist/scripts/ux-review-real-loop-fixture-check.js",
|
|
128
|
+
"ppt:real-export-adapter": "node ./dist/scripts/ppt-real-export-adapter-check.js",
|
|
129
|
+
"ppt:real-imagegen-wiring": "node ./dist/scripts/ppt-real-imagegen-wiring-check.js",
|
|
130
|
+
"ppt:reexport-rereview": "node ./dist/scripts/ppt-reexport-rereview-check.js",
|
|
131
|
+
"ppt:full-e2e-blackbox": "node ./dist/scripts/ppt-full-e2e-blackbox-check.js",
|
|
132
|
+
"ppt:full-e2e-artifact-graph": "node ./dist/scripts/ppt-full-e2e-artifact-graph-check.js",
|
|
133
|
+
"ppt:imagegen-blackbox": "node ./dist/scripts/ppt-imagegen-blackbox-check.js",
|
|
134
|
+
"ux-ppt:structured-extraction": "node ./dist/scripts/ux-ppt-structured-extraction-check.js",
|
|
135
|
+
"dfix:patch-handoff": "node ./dist/scripts/dfix-patch-handoff-check.js",
|
|
136
|
+
"dfix:verification-recommendation": "node ./dist/scripts/dfix-verification-recommendation-check.js",
|
|
137
|
+
"dfix:fast-kernel": "node ./dist/scripts/dfix-fast-kernel-check.js",
|
|
138
|
+
"dfix:blackbox-fast": "node ./dist/scripts/dfix-fast-blackbox-check.js",
|
|
139
|
+
"dfix:performance": "node ./dist/scripts/dfix-performance-check.js",
|
|
140
|
+
"dfix:parallel-write-blackbox": "node ./dist/scripts/dfix-parallel-write-blackbox.js",
|
|
141
|
+
"all-features:deep-completion": "node ./dist/scripts/all-feature-deep-completion-check.js",
|
|
142
|
+
"evidence:flagship-coverage": "node ./dist/scripts/evidence-flagship-coverage-check.js",
|
|
143
|
+
"ux-review:generate-callouts-fixture": "node ./dist/scripts/ux-review-generate-callouts-fixture-check.js",
|
|
144
|
+
"ux-review:extract-real-callouts-fixture": "node ./dist/scripts/ux-review-extract-real-callouts-fixture-check.js",
|
|
145
|
+
"ux-review:patch-handoff-fixture": "node ./dist/scripts/ux-review-patch-handoff-fixture-check.js",
|
|
146
|
+
"ux-review:recapture-recheck-fixture": "node ./dist/scripts/ux-review-recapture-recheck-fixture-check.js",
|
|
147
|
+
"ux-review:no-text-fallback": "node ./dist/scripts/ux-review-no-text-fallback-check.js",
|
|
148
|
+
"ux-review:no-fake-callouts": "node ./dist/scripts/ux-review-no-fake-callouts-check.js",
|
|
149
|
+
"ux-review:image-voxel-relations": "node ./dist/scripts/ux-review-image-voxel-relations-check.js",
|
|
150
|
+
"ppt:imagegen-review-fixture": "node ./dist/scripts/ppt-imagegen-review-fixture-check.js",
|
|
151
|
+
"ppt:slide-export-fixture": "node ./dist/scripts/ppt-slide-export-fixture-check.js",
|
|
152
|
+
"ppt:no-text-fallback": "node ./dist/scripts/ppt-no-text-fallback-check.js",
|
|
153
|
+
"ppt:no-mock-as-real": "node ./dist/scripts/ppt-no-mock-as-real-check.js",
|
|
154
|
+
"ppt:issue-extraction-fixture": "node ./dist/scripts/ppt-issue-extraction-fixture-check.js",
|
|
155
|
+
"ppt:image-voxel-relations": "node ./dist/scripts/ppt-image-voxel-relations-check.js",
|
|
156
|
+
"ppt:proof-trust-fixture": "node ./dist/scripts/ppt-proof-trust-fixture-check.js",
|
|
157
|
+
"dfix:fixture": "node ./dist/scripts/dfix-fixture-check.js",
|
|
158
|
+
"dfix:verification": "node ./dist/scripts/dfix-verification-check.js",
|
|
159
|
+
"all-features:completion": "node ./dist/bin/sks.js all-features complete --json",
|
|
160
|
+
"json-schema:recursive-check": "node ./dist/scripts/json-schema-recursive-check.js",
|
|
99
161
|
"trust:check": "node ./dist/bin/sks.js trust validate latest --json || node ./dist/scripts/trust-fixture-check.js",
|
|
100
162
|
"wrongness:check": "node ./dist/bin/sks.js wrongness validate project --json && node ./dist/scripts/wrongness-fixture-check.js",
|
|
101
163
|
"git-hygiene:check": "node ./dist/bin/sks.js git doctor --json",
|
|
@@ -109,10 +171,12 @@
|
|
|
109
171
|
"qa-loop:effort-escalation": "node ./dist/scripts/qa-loop-effort-escalation-check.js",
|
|
110
172
|
"qa-loop:budget-policy": "node ./dist/scripts/qa-loop-budget-policy-check.js",
|
|
111
173
|
"naruto:real-active-pool-runtime": "node ./dist/scripts/naruto-real-active-pool-runtime-check.js",
|
|
174
|
+
"bench": "node ./dist/scripts/coding-bench-check.js",
|
|
175
|
+
"release:check:bench": "npm run build:incremental --silent && npm run bench --silent",
|
|
112
176
|
"release:check:affected": "npm run build:incremental --silent && node ./dist/scripts/release-gate-dag-runner.js --preset affected --changed-since auto --sla 5m && node ./dist/scripts/release-check-stamp.js write",
|
|
113
177
|
"release:check:fast": "npm run build:incremental --silent && node ./dist/scripts/release-gate-dag-runner.js --preset fast --changed-since auto --sla 5m && node ./dist/scripts/release-check-stamp.js write",
|
|
114
178
|
"release:check:confidence": "npm run build:incremental --silent && node ./dist/scripts/release-gate-dag-runner.js --preset confidence --changed-since auto --sla 5m && node ./dist/scripts/release-check-stamp.js write",
|
|
115
|
-
"release:check:full": "npm run build:clean --silent && node ./dist/scripts/release-gate-dag-runner.js --preset release --full && node ./dist/scripts/release-check-stamp.js write",
|
|
179
|
+
"release:check:full": "npm run build:clean --silent && node ./dist/scripts/release-gate-dag-runner.js --preset release --full && node ./dist/scripts/release-gate-dag-runner.js --preset bench --full && node ./dist/scripts/release-check-stamp.js write",
|
|
116
180
|
"publish:prep-ignore-scripts": "npm run prepublishOnly",
|
|
117
181
|
"publish:ignore-scripts": "npm run publish:prep-ignore-scripts && npm publish --ignore-scripts",
|
|
118
182
|
"naruto:ssot-gate-aliases": "node ./dist/scripts/naruto-ssot-gate-aliases-check.js",
|
|
@@ -3,12 +3,13 @@
|
|
|
3
3
|
"$id": "https://sneakoscope.local/schemas/codex/completion-proof.schema.json",
|
|
4
4
|
"title": "SKS Completion Proof",
|
|
5
5
|
"type": "object",
|
|
6
|
-
"required": ["schema", "mission_id", "route", "status", "evidence", "claims", "unverified", "blockers"],
|
|
6
|
+
"required": ["schema", "execution_class", "mission_id", "route", "status", "evidence", "claims", "unverified", "blockers"],
|
|
7
7
|
"properties": {
|
|
8
8
|
"schema": { "const": "sks.completion-proof.v1" },
|
|
9
|
+
"execution_class": { "enum": ["real", "mock_fixture"] },
|
|
9
10
|
"mission_id": { "type": ["string", "null"] },
|
|
10
11
|
"route": { "type": ["string", "null"] },
|
|
11
|
-
"status": { "enum": ["verified", "verified_partial", "blocked", "failed", "not_verified"] },
|
|
12
|
+
"status": { "enum": ["verified", "verified_partial", "mock_only", "blocked", "failed", "not_verified"] },
|
|
12
13
|
"evidence": { "type": "object" },
|
|
13
14
|
"claims": { "type": "array" },
|
|
14
15
|
"unverified": { "type": "array" },
|
|
@@ -18,11 +18,12 @@
|
|
|
18
18
|
"type": "array",
|
|
19
19
|
"minItems": 1,
|
|
20
20
|
"items": {
|
|
21
|
-
"enum": ["cpu-light", "cpu-heavy", "io-light", "io-heavy", "git", "git-worktree", "zellij-real", "local-llm-real", "remote-model-real", "python", "network", "global-config", "publish", "fs-read"]
|
|
21
|
+
"enum": ["cpu-light", "cpu-heavy", "io-light", "io-heavy", "git", "git-worktree", "zellij-real", "browser-real", "secret-sensitive", "local-llm-real", "remote-model-real", "python", "network", "global-config", "publish", "fs-read", "fs-write", "timing-sensitive"]
|
|
22
22
|
}
|
|
23
23
|
},
|
|
24
24
|
"side_effect": { "enum": ["hermetic", "real-env"] },
|
|
25
25
|
"timeout_ms": { "type": "integer", "minimum": 1 },
|
|
26
|
+
"output_contract": { "const": "sks.gate-result.v1" },
|
|
26
27
|
"cache": {
|
|
27
28
|
"type": "object",
|
|
28
29
|
"required": ["enabled", "inputs"],
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import fs from 'node:fs';
|
|
4
|
-
import os from 'node:os';
|
|
5
|
-
import path from 'node:path';
|
|
6
|
-
import { spawnSync } from 'node:child_process';
|
|
7
|
-
import { assertGate, emitGate, importDist, root } from './sks-1-18-gate-lib.js';
|
|
8
|
-
const schemaMod = await importDist('core/agents/agent-patch-schema.js');
|
|
9
|
-
const applyMod = await importDist('core/agents/agent-patch-apply-worker.js');
|
|
10
|
-
const tmp = fs.mkdtempSync(path.join(os.tmpdir(), 'sks-agent-blackbox-'));
|
|
11
|
-
fs.writeFileSync(path.join(tmp, 'fixture.txt'), 'before\n');
|
|
12
|
-
const envelope = schemaMod.normalizeAgentPatchEnvelope({
|
|
13
|
-
agent_id: 'blackbox-agent',
|
|
14
|
-
session_id: 'blackbox-session',
|
|
15
|
-
slot_id: 'blackbox-slot',
|
|
16
|
-
generation_index: 1,
|
|
17
|
-
lease_id: 'lease:blackbox-agent:fixture.txt',
|
|
18
|
-
operations: [{ op: 'replace', path: 'fixture.txt', search: 'before', replace: 'after' }]
|
|
19
|
-
});
|
|
20
|
-
const dry = await applyMod.applyAgentPatchEnvelope(tmp, envelope, { dryRun: true });
|
|
21
|
-
const applied = await applyMod.applyAgentPatchEnvelope(tmp, envelope);
|
|
22
|
-
const agentRun = spawnSync(process.execPath, [
|
|
23
|
-
'dist/bin/sks.js',
|
|
24
|
-
'agent',
|
|
25
|
-
'run',
|
|
26
|
-
'agent parallel write blackbox route fixture',
|
|
27
|
-
'--mock',
|
|
28
|
-
'--write-mode',
|
|
29
|
-
'parallel',
|
|
30
|
-
'--apply-patches',
|
|
31
|
-
'--dry-run-patches',
|
|
32
|
-
'--max-write-agents',
|
|
33
|
-
'1',
|
|
34
|
-
'--json'
|
|
35
|
-
], { cwd: root, encoding: 'utf8', maxBuffer: 2 * 1024 * 1024 });
|
|
36
|
-
const agentJson = parseJson(agentRun.stdout);
|
|
37
|
-
const routePolicy = agentJson?.parallel_write_policy || null;
|
|
38
|
-
const report = { schema: 'sks.agent-parallel-write-blackbox.v1', ok: dry.ok && applied.ok && agentRun.status === 0 && routePolicy?.route_level_flags_wired === true, dry, applied, route_command: { status: agentRun.status, mission_id: agentJson?.mission_id || null, route_policy: routePolicy, stderr_tail: agentRun.stderr.slice(-2000) } };
|
|
39
|
-
const out = path.join(root, '.sneakoscope', 'reports', 'agent-parallel-write-blackbox.json');
|
|
40
|
-
fs.mkdirSync(path.dirname(out), { recursive: true });
|
|
41
|
-
fs.writeFileSync(out, `${JSON.stringify(report, null, 2)}\n`);
|
|
42
|
-
assertGate(dry.status === 'dry_run', 'agent parallel write blackbox dry-run status mismatch', report);
|
|
43
|
-
assertGate(applied.ok === true, 'agent parallel write blackbox apply failed', report);
|
|
44
|
-
assertGate(fs.readFileSync(path.join(tmp, 'fixture.txt'), 'utf8') === 'after\n', 'agent parallel write blackbox content mismatch', report);
|
|
45
|
-
assertGate(routePolicy?.write_mode === 'parallel', 'Agent route must carry --write-mode parallel into native agent policy', report);
|
|
46
|
-
assertGate(routePolicy?.apply_patches === true, 'Agent route must carry --apply-patches into native agent policy', report);
|
|
47
|
-
emitGate('agent:parallel-write-blackbox', { changed_files: applied.changed_files.length });
|
|
48
|
-
function parseJson(text) {
|
|
49
|
-
try {
|
|
50
|
-
return JSON.parse(text);
|
|
51
|
-
}
|
|
52
|
-
catch {
|
|
53
|
-
return null;
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
//# sourceMappingURL=agent-parallel-write-blackbox.js.map
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { runPatchSwarmRouteBlackbox } from './agent-patch-swarm-gate-lib.js';
|
|
4
|
-
await runPatchSwarmRouteBlackbox({
|
|
5
|
-
gate: 'agent:patch-swarm-route-blackbox',
|
|
6
|
-
route: '$Agent',
|
|
7
|
-
routeCommand: 'sks agent run',
|
|
8
|
-
reportName: 'agent-patch-swarm-route-blackbox'
|
|
9
|
-
});
|
|
10
|
-
//# sourceMappingURL=agent-patch-swarm-route-blackbox.js.map
|
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
// @ts-nocheck
|
|
2
|
-
import fs from 'node:fs';
|
|
3
|
-
import path from 'node:path';
|
|
4
|
-
import { spawnSync } from 'node:child_process';
|
|
5
|
-
import { assertGate, emitGate, root } from './sks-1-18-gate-lib.js';
|
|
6
|
-
const PROMPT = 'route truth dynamic scheduler fixture';
|
|
7
|
-
const ROUTE_ARGS = ['--agents', '5', '--work-items', '8', '--target-active-slots', '5', '--minimum-work-items', '5', '--max-queue-expansion', '10', '--mock', '--json'];
|
|
8
|
-
export function runRouteBackfillBlackbox(route, gate) {
|
|
9
|
-
if (String(route).toLowerCase().includes('team'))
|
|
10
|
-
return runActualTeamBackfillBlackbox(gate);
|
|
11
|
-
if (String(route).toLowerCase().includes('research'))
|
|
12
|
-
return runActualResearchBackfillBlackbox(gate);
|
|
13
|
-
if (String(route).toLowerCase().includes('qa'))
|
|
14
|
-
return runActualQaBackfillBlackbox(gate);
|
|
15
|
-
return runActualAgentBackfillBlackbox(gate);
|
|
16
|
-
}
|
|
17
|
-
export function runActualAgentBackfillBlackbox(gate = 'agent:backfill-route-blackbox') {
|
|
18
|
-
const json = runSks(['agent', 'run', PROMPT, '--route', '$Agent', ...ROUTE_ARGS], gate);
|
|
19
|
-
validateNativeRun(json, gate, { route: '$Agent', command: 'sks agent run', kind: 'actual_agent_command' });
|
|
20
|
-
return json;
|
|
21
|
-
}
|
|
22
|
-
export function runActualTeamBackfillBlackbox(gate = 'team:backfill-route-blackbox') {
|
|
23
|
-
const json = runSks(['team', PROMPT, ...ROUTE_ARGS, '--no-open-zellij'], gate);
|
|
24
|
-
validateNativeRun(json.native_agent_run, gate, { route: '$Team', command: 'sks team', kind: 'actual_team_command' });
|
|
25
|
-
return json;
|
|
26
|
-
}
|
|
27
|
-
export function runActualResearchBackfillBlackbox(gate = 'research:backfill-route-blackbox') {
|
|
28
|
-
const prepared = runSks(['research', 'prepare', PROMPT, '--json'], `${gate}:prepare`);
|
|
29
|
-
const missionId = prepared.mission_id;
|
|
30
|
-
assertGate(Boolean(missionId), `${gate} research prepare must return mission_id`, prepared);
|
|
31
|
-
const json = runSks(['research', 'run', missionId, ...ROUTE_ARGS], gate);
|
|
32
|
-
const native = json.native_agent_run || readMissionJson(missionId, 'research-native-agent-run.json');
|
|
33
|
-
validateNativeRun(native, gate, { route: '$Research', command: 'sks research run', kind: 'actual_research_command' });
|
|
34
|
-
return json;
|
|
35
|
-
}
|
|
36
|
-
export function runActualQaBackfillBlackbox(gate = 'qa:backfill-route-blackbox') {
|
|
37
|
-
const prepared = runSks(['qa-loop', 'prepare', PROMPT, '--json'], `${gate}:prepare`);
|
|
38
|
-
const missionId = prepared.mission_id;
|
|
39
|
-
assertGate(Boolean(missionId), `${gate} qa prepare must return mission_id`, prepared);
|
|
40
|
-
const json = runSks(['qa-loop', 'run', missionId, ...ROUTE_ARGS], gate);
|
|
41
|
-
const native = json.native_agent_run || readMissionJson(missionId, 'qa-native-agent-run.json');
|
|
42
|
-
validateNativeRun(native, gate, { route: '$QA-LOOP', command: 'sks qa-loop run', kind: 'actual_qa_command' });
|
|
43
|
-
return json;
|
|
44
|
-
}
|
|
45
|
-
export function validateNativeRun(json, gate, expected = {}) {
|
|
46
|
-
assertGate(Boolean(json), `${gate} native agent run JSON missing`, {});
|
|
47
|
-
const state = json.scheduler?.state || {};
|
|
48
|
-
const proof = json.proof || {};
|
|
49
|
-
const ledgerRoot = path.join(root, json.ledger_root || '');
|
|
50
|
-
assertGate(fs.existsSync(ledgerRoot), `${gate} ledger root missing`, { ledger_root: json.ledger_root });
|
|
51
|
-
const events = readJsonl(path.join(ledgerRoot, 'agent-scheduler-events.jsonl'));
|
|
52
|
-
const backfills = events.filter((event) => event.event_type === 'backfill_event');
|
|
53
|
-
const graph = readJson(path.join(ledgerRoot, 'agent-task-graph.json'));
|
|
54
|
-
const queue = readJson(path.join(ledgerRoot, 'agent-work-queue.json'));
|
|
55
|
-
const supervisor = readJson(path.join(ledgerRoot, 'agent-zellij-lane-supervisor.json'));
|
|
56
|
-
assertGate(json.ok === true, `${gate} proof must pass`, proof);
|
|
57
|
-
assertGate(graph.schema === 'sks.agent-task-graph.v1', `${gate} task graph schema missing`, graph);
|
|
58
|
-
assertGate(graph.target_active_slots === 5 && graph.total_work_items === 8, `${gate} task graph must split active slots and work items`, graph.route_work_count_summary);
|
|
59
|
-
assertGate(queue.total_work_items === graph.total_work_items, `${gate} work queue must match task graph`, { queue: queue.total_work_items, graph: graph.total_work_items });
|
|
60
|
-
assertGate(state.target_active_slots === 5, `${gate} target active slots must be 5`, state);
|
|
61
|
-
assertGate(state.total_work_items === queue.total_work_items, `${gate} scheduler must match work queue`, { scheduler: state.total_work_items, queue: queue.total_work_items });
|
|
62
|
-
assertGate(state.max_observed_active_slots === 5, `${gate} must observe 5 active slots`, state);
|
|
63
|
-
assertGate(state.expected_backfill_count >= 2, `${gate} expected backfill count must be at least 2`, state);
|
|
64
|
-
assertGate(state.backfill_count >= state.expected_backfill_count, `${gate} backfills must satisfy expectation`, state);
|
|
65
|
-
assertGate(backfills.length >= 2, `${gate} must emit at least two backfill events`, { backfills });
|
|
66
|
-
assertGate(events.some((event) => event.event_type === 'scheduler_draining'), `${gate} must emit scheduler_draining`, {});
|
|
67
|
-
assertGate(state.pending_queue_drained === true, `${gate} queue must drain`, state);
|
|
68
|
-
assertGate(state.all_generations_closed === true, `${gate} generations must close`, state);
|
|
69
|
-
assertGate(proof.requested_work_items === 8, `${gate} proof must record requested work items`, proof);
|
|
70
|
-
assertGate(proof.actual_total_work_items === 8, `${gate} proof must record actual total work items`, proof);
|
|
71
|
-
assertGate(proof.task_graph_total_work_items === 8, `${gate} proof task graph total must be 8`, proof);
|
|
72
|
-
assertGate(proof.work_queue_total_work_items === 8, `${gate} proof work queue total must be 8`, proof);
|
|
73
|
-
assertGate(proof.scheduler_total_work_items === 8, `${gate} proof scheduler total must be 8`, proof);
|
|
74
|
-
assertGate(proof.task_graph_matches_cli_options === true, `${gate} proof must bind task graph to CLI options`, proof);
|
|
75
|
-
assertGate(proof.work_queue_matches_task_graph === true, `${gate} proof must bind work queue to task graph`, proof);
|
|
76
|
-
assertGate(proof.scheduler_matches_work_queue === true, `${gate} proof must bind scheduler to work queue`, proof);
|
|
77
|
-
assertGate(proof.generation_count >= state.total_work_items, `${gate} proof generation count must cover work items`, proof);
|
|
78
|
-
assertGate(proof.terminal_close_report_count >= proof.generation_count, `${gate} close reports must cover generations`, proof);
|
|
79
|
-
assertGate(proof.terminal_reports_match_generations === true, `${gate} proof must bind terminal reports to generations`, proof);
|
|
80
|
-
assertGate(proof.source_intelligence_generation_refs_ok === true && proof.task_graph_source_refs_ok === true && proof.work_queue_source_refs_ok === true, `${gate} source refs must propagate`, proof);
|
|
81
|
-
assertGate(proof.goal_mode_generation_refs_ok === true && proof.task_graph_goal_refs_ok === true && proof.work_queue_goal_refs_ok === true, `${gate} goal refs must propagate`, proof);
|
|
82
|
-
assertGate(proof.lane_supervisor_integrated === true && supervisor.schema === 'sks.zellij-lane-supervisor.v1', `${gate} Zellij supervisor must be integrated`, { proof, supervisor });
|
|
83
|
-
assertGate(proof.zellij_lane_no_flicker_verified === true, `${gate} Zellij no-flicker proof must pass`, proof);
|
|
84
|
-
assertGate(proof.real_route_command_used === true, `${gate} must use real route command`, proof);
|
|
85
|
-
assertGate(String(proof.route_command || '').includes(expected.command), `${gate} proof route command mismatch`, proof);
|
|
86
|
-
assertGate(proof.route_blackbox_kind === expected.kind, `${gate} proof route blackbox kind mismatch`, proof);
|
|
87
|
-
if (expected.route !== '$Agent') {
|
|
88
|
-
assertGate(!/\bagent\s+run\b/i.test(String(proof.route_command || '')), `${gate} must not use agent run stand-in`, proof);
|
|
89
|
-
}
|
|
90
|
-
emitGate(gate, {
|
|
91
|
-
route: expected.route,
|
|
92
|
-
command: proof.route_command,
|
|
93
|
-
mission_id: json.mission_id,
|
|
94
|
-
target_active_slots: state.target_active_slots,
|
|
95
|
-
total_work_items: state.total_work_items,
|
|
96
|
-
expected_backfill_count: state.expected_backfill_count,
|
|
97
|
-
backfill_count: state.backfill_count,
|
|
98
|
-
generation_count: proof.generation_count
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
function runSks(args, gate) {
|
|
102
|
-
const result = spawnSync(process.execPath, ['dist/bin/sks.js', ...args], {
|
|
103
|
-
cwd: root,
|
|
104
|
-
encoding: 'utf8',
|
|
105
|
-
env: { ...process.env, SKS_AGENT_DYNAMIC_BACKFILL_FIXTURE: '1' },
|
|
106
|
-
maxBuffer: 1024 * 1024 * 16
|
|
107
|
-
});
|
|
108
|
-
assertGate(result.status === 0, `${gate} route command failed`, { args, stdout: result.stdout.slice(-4000), stderr: result.stderr.slice(-4000) });
|
|
109
|
-
return parseJson(result.stdout, gate);
|
|
110
|
-
}
|
|
111
|
-
function parseJson(stdout, gate) {
|
|
112
|
-
try {
|
|
113
|
-
return JSON.parse(stdout);
|
|
114
|
-
}
|
|
115
|
-
catch (err) {
|
|
116
|
-
const start = stdout.indexOf('{');
|
|
117
|
-
const end = stdout.lastIndexOf('}');
|
|
118
|
-
if (start >= 0 && end > start)
|
|
119
|
-
return JSON.parse(stdout.slice(start, end + 1));
|
|
120
|
-
assertGate(false, `${gate} did not emit JSON`, { stdout: stdout.slice(-4000), error: String(err) });
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
function readMissionJson(missionId, rel) {
|
|
124
|
-
return readJson(path.join(root, '.sneakoscope', 'missions', missionId, rel));
|
|
125
|
-
}
|
|
126
|
-
function readJson(file) {
|
|
127
|
-
return JSON.parse(fs.readFileSync(file, 'utf8'));
|
|
128
|
-
}
|
|
129
|
-
function readJsonl(file) {
|
|
130
|
-
return fs.readFileSync(file, 'utf8').trim().split(/\n+/).filter(Boolean).map((line) => JSON.parse(line));
|
|
131
|
-
}
|
|
132
|
-
//# sourceMappingURL=agent-route-blackbox-lib.js.map
|