sneakoscope 2.0.13 → 2.0.15
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 +6 -3
- 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/.sks-build-stamp.json +4 -4
- package/dist/bin/sks.js +1 -1
- package/dist/cli/command-registry.js +1 -0
- package/dist/commands/mad-db.js +5 -0
- package/dist/commands/zellij-slot-pane.js +3 -1
- package/dist/core/agents/agent-orchestrator.js +11 -4
- package/dist/core/agents/agent-output-validator.js +1 -1
- package/dist/core/agents/agent-plan.js +3 -2
- package/dist/core/agents/native-cli-session-swarm.js +118 -0
- package/dist/core/agents/native-cli-worker.js +85 -0
- package/dist/core/codex-control/codex-fake-sdk-adapter.js +3 -3
- package/dist/core/codex-control/gpt-final-review-schema.js +61 -14
- package/dist/core/commands/basic-cli.js +1 -1
- package/dist/core/commands/command-suggestions.js +1 -1
- package/dist/core/commands/mad-db-command.js +106 -0
- package/dist/core/commands/mad-sks-command.js +50 -13
- package/dist/core/commands/naruto-command.js +82 -1
- package/dist/core/commands/research-command.js +83 -17
- package/dist/core/commands/team-command.js +25 -1
- package/dist/core/db-safety.js +26 -0
- package/dist/core/fsx.js +1 -1
- package/dist/core/mad-db/mad-db-capability.js +84 -0
- package/dist/core/mad-db/mad-db-ledger.js +17 -0
- package/dist/core/mad-db/mad-db-policy-resolver.js +46 -0
- package/dist/core/naruto/naruto-real-worker-child.js +11 -3
- package/dist/core/naruto/naruto-real-worker-runtime.js +4 -0
- package/dist/core/pipeline/final-gpt-patch-stage.js +20 -3
- package/dist/core/pipeline-internals/runtime-core.js +74 -8
- package/dist/core/pipeline-internals/runtime-gates.js +44 -0
- package/dist/core/proof/route-proof-gate.js +5 -3
- package/dist/core/proof/route-proof-policy.js +9 -1
- package/dist/core/release/release-gate-affected-selector.js +113 -0
- package/dist/core/release/release-gate-batch-runner.js +67 -0
- package/dist/core/release/release-gate-dag.js +22 -3
- package/dist/core/release/release-gate-resource-governor.js +23 -11
- package/dist/core/research/implementation-blueprint-densifier.js +124 -0
- package/dist/core/research/implementation-blueprint-markdown.js +1 -1
- package/dist/core/research/implementation-blueprint.js +68 -7
- package/dist/core/research/research-claim-builder.js +114 -0
- package/dist/core/research/research-cycle-runner.js +115 -11
- package/dist/core/research/research-final-reviewer.js +181 -1
- package/dist/core/research/research-handoff.js +69 -5
- package/dist/core/research/research-realistic-report.js +162 -0
- package/dist/core/research/research-repetition-detector.js +75 -0
- package/dist/core/research/research-report-quality.js +27 -5
- package/dist/core/research/research-source-ledger-merge.js +186 -0
- package/dist/core/research/research-source-shards.js +176 -0
- package/dist/core/research/research-stage-runner.js +537 -11
- package/dist/core/research/research-synthesis-prompt.js +52 -0
- package/dist/core/research/research-synthesis-writer.js +208 -0
- package/dist/core/research/research-work-graph.js +114 -23
- package/dist/core/research.js +72 -48
- package/dist/core/routes.js +23 -19
- package/dist/core/update/update-notice.js +120 -0
- package/dist/core/version.js +1 -1
- package/dist/core/zellij/zellij-dashboard-renderer.js +2 -0
- package/dist/core/zellij/zellij-slot-column-anchor.js +35 -1
- package/dist/core/zellij/zellij-slot-pane-renderer.js +57 -0
- package/dist/core/zellij/zellij-slot-telemetry.js +182 -0
- package/dist/scripts/release-gate-dag-runner.js +5 -0
- package/dist/scripts/release-speed-summary.js +25 -0
- package/package.json +67 -5
- package/schemas/codex/agent-result.schema.json +1 -1
- package/schemas/mad-db/mad-db-capability.schema.json +31 -0
- package/schemas/mad-db/mad-db-ledger.schema.json +14 -0
- package/schemas/research/implementation-blueprint.schema.json +6 -1
- package/schemas/research/research-final-review.schema.json +10 -0
- package/schemas/research/research-source-shard.schema.json +46 -0
- package/schemas/research/research-synthesis-output.schema.json +62 -0
- package/schemas/update/update-notice.schema.json +19 -0
- package/schemas/zellij/zellij-slot-telemetry.schema.json +89 -0
- package/dist/build-manifest.json +0 -1184
- package/dist/scripts/agent-ast-aware-work-graph-check.js +0 -25
- package/dist/scripts/agent-backfill-replenishment-check.js +0 -13
- package/dist/scripts/agent-backfill-route-blackbox.js +0 -5
- package/dist/scripts/agent-background-terminals-check.js +0 -16
- package/dist/scripts/agent-cleanup-command-ux-check.js +0 -12
- package/dist/scripts/agent-cleanup-executor-check.js +0 -53
- package/dist/scripts/agent-cleanup-executor-v2-check.js +0 -39
- package/dist/scripts/agent-cli-options-to-task-graph-check.js +0 -5
- package/dist/scripts/agent-codex-app-cockpit-check.js +0 -91
- package/dist/scripts/agent-codex-child-overlap-check.js +0 -21
- package/dist/scripts/agent-dynamic-cockpit-check.js +0 -10
- package/dist/scripts/agent-dynamic-pool-check.js +0 -13
- package/dist/scripts/agent-dynamic-pool-route-blackbox.js +0 -5
- package/dist/scripts/agent-fast-mode-default-check.js +0 -62
- package/dist/scripts/agent-fast-mode-worker-propagation-check.js +0 -7
- package/dist/scripts/agent-follow-up-work-schema-check.js +0 -80
- package/dist/scripts/agent-goal-mode-propagation-check.js +0 -9
- package/dist/scripts/agent-intelligent-work-graph-check.js +0 -25
- package/dist/scripts/agent-janitor-check.js +0 -76
- package/dist/scripts/agent-main-no-scout-check.js +0 -11
- package/dist/scripts/agent-model-authored-patch-envelope-check.js +0 -15
- package/dist/scripts/agent-multi-project-isolation-check.js +0 -86
- package/dist/scripts/agent-native-cli-session-proof-check.js +0 -7
- package/dist/scripts/agent-native-cli-session-swarm-10-check.js +0 -7
- package/dist/scripts/agent-native-cli-session-swarm-20-check.js +0 -7
- package/dist/scripts/agent-native-cli-session-swarm-check.js +0 -7
- package/dist/scripts/agent-no-subagent-scaling-check.js +0 -7
- package/dist/scripts/agent-parallel-write-blackbox.js +0 -56
- package/dist/scripts/agent-parallel-write-kernel-check.js +0 -103
- package/dist/scripts/agent-patch-conflict-rebase-check.js +0 -198
- package/dist/scripts/agent-patch-envelope-extraction-check.js +0 -17
- package/dist/scripts/agent-patch-proof-check.js +0 -41
- package/dist/scripts/agent-patch-proof-runtime-check.js +0 -63
- package/dist/scripts/agent-patch-queue-runtime-check.js +0 -36
- package/dist/scripts/agent-patch-rollback-check.js +0 -38
- package/dist/scripts/agent-patch-rollback-dag-check.js +0 -14
- package/dist/scripts/agent-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/agent-patch-swarm-runtime-check.js +0 -10
- package/dist/scripts/agent-patch-swarm-runtime-truth-check.js +0 -76
- package/dist/scripts/agent-patch-transaction-journal-check.js +0 -57
- package/dist/scripts/agent-patch-verification-dag-check.js +0 -14
- package/dist/scripts/agent-proof-contract-reconciled-check.js +0 -5
- package/dist/scripts/agent-real-codex-dynamic-smoke-check.js +0 -166
- package/dist/scripts/agent-real-codex-dynamic-smoke-v2-check.js +0 -14
- package/dist/scripts/agent-real-codex-in-zellij-worker-pane-check.js +0 -229
- package/dist/scripts/agent-real-codex-parallel-workers-10-check.js +0 -5
- package/dist/scripts/agent-real-codex-parallel-workers-20-check.js +0 -5
- package/dist/scripts/agent-real-codex-parallel-workers-5-check.js +0 -5
- package/dist/scripts/agent-real-codex-parallel-workers-check.js +0 -5
- package/dist/scripts/agent-role-config-repair-check.js +0 -33
- package/dist/scripts/agent-rollback-command-check.js +0 -86
- package/dist/scripts/agent-route-truth-backfill-check.js +0 -5
- package/dist/scripts/agent-scheduler-proof-check.js +0 -13
- package/dist/scripts/agent-scheduler-proof-hardening-check.js +0 -22
- package/dist/scripts/agent-session-generation-check.js +0 -21
- package/dist/scripts/agent-slot-pane-binding-proof-check.js +0 -64
- package/dist/scripts/agent-source-intelligence-propagation-check.js +0 -9
- package/dist/scripts/agent-strategy-to-lease-wiring-check.js +0 -32
- package/dist/scripts/agent-strategy-to-patch-strict-check.js +0 -54
- package/dist/scripts/agent-task-graph-expansion-check.js +0 -14
- package/dist/scripts/agent-terminal-generations-check.js +0 -23
- package/dist/scripts/agent-visual-consistency-check.js +0 -9
- package/dist/scripts/agent-wiki-context-proof-check.js +0 -62
- package/dist/scripts/agent-worker-backend-router-check.js +0 -63
- package/dist/scripts/agent-worker-scout-limited-check.js +0 -17
- package/dist/scripts/agent-zellij-dynamic-backfill-panes-check.js +0 -34
- package/dist/scripts/agent-zellij-runtime-check.js +0 -84
- package/dist/scripts/all-feature-deep-completion-check.js +0 -31
- package/dist/scripts/appshots-capability-check.js +0 -18
- package/dist/scripts/appshots-evidence-check.js +0 -48
- package/dist/scripts/appshots-operator-policy-check.js +0 -25
- package/dist/scripts/appshots-privacy-safety-check.js +0 -48
- package/dist/scripts/appshots-source-intelligence-check.js +0 -53
- package/dist/scripts/appshots-thread-attachment-discovery-check.js +0 -87
- package/dist/scripts/appshots-triwiki-voxel-check.js +0 -46
- package/dist/scripts/architecture-guard-check.js +0 -55
- package/dist/scripts/changelog-check.js +0 -47
- package/dist/scripts/codex-0-133-official-compat-report.js +0 -53
- package/dist/scripts/codex-0-134-official-compat-report.js +0 -110
- package/dist/scripts/codex-0-134-runner-truth-check.js +0 -66
- package/dist/scripts/codex-0-135-compat-check.js +0 -57
- package/dist/scripts/codex-0-136-compat-check.js +0 -30
- package/dist/scripts/codex-0-137-compat-check.js +0 -27
- package/dist/scripts/codex-app-fast-ui-preservation-check.js +0 -32
- package/dist/scripts/codex-app-provider-badge-check.js +0 -37
- package/dist/scripts/codex-app-ui-clobber-guard-check.js +0 -22
- package/dist/scripts/codex-app-ui-preservation-check.js +0 -96
- package/dist/scripts/codex-control-all-pipelines-check.js +0 -36
- package/dist/scripts/codex-control-capability-check.js +0 -10
- package/dist/scripts/codex-control-empty-result-retry-check.js +0 -43
- package/dist/scripts/codex-control-event-stream-ledger-check.js +0 -10
- package/dist/scripts/codex-control-keepalive-no-cot-leak-check.js +0 -14
- package/dist/scripts/codex-control-no-legacy-fallback-check.js +0 -31
- package/dist/scripts/codex-control-side-effect-scope-check.js +0 -26
- package/dist/scripts/codex-control-stream-idle-watchdog-check.js +0 -18
- package/dist/scripts/codex-control-structured-output-check.js +0 -11
- package/dist/scripts/codex-control-thread-registry-check.js +0 -11
- package/dist/scripts/codex-control-tool-call-sequence-repair-check.js +0 -14
- package/dist/scripts/codex-environment-scoped-approvals-check.js +0 -10
- package/dist/scripts/codex-exec-output-schema-actual-syntax-check.js +0 -33
- package/dist/scripts/codex-fast-mode-profile-propagation-check.js +0 -12
- package/dist/scripts/codex-history-search-check.js +0 -19
- package/dist/scripts/codex-hook-semantic-check.js +0 -15
- package/dist/scripts/codex-hook-strict-subset-check.js +0 -61
- package/dist/scripts/codex-lb-config-toml-safety-check.js +0 -85
- package/dist/scripts/codex-lb-persistence-truth-check.js +0 -96
- package/dist/scripts/codex-lb-setup-fixture-check.js +0 -91
- package/dist/scripts/codex-lb-setup-truthfulness-check.js +0 -84
- package/dist/scripts/codex-legacy-profile-consumers-removed-check.js +0 -24
- package/dist/scripts/codex-managed-proxy-env-check.js +0 -17
- package/dist/scripts/codex-output-schema-fixture-check.js +0 -25
- package/dist/scripts/codex-permission-profiles-check.js +0 -36
- package/dist/scripts/codex-plugin-list-json-check.js +0 -8
- package/dist/scripts/codex-profile-primary-check.js +0 -13
- package/dist/scripts/codex-project-config-policy-splitter-check.js +0 -51
- package/dist/scripts/codex-resume-cwd-truth-check.js +0 -17
- package/dist/scripts/codex-sdk-all-pipelines-check.js +0 -32
- package/dist/scripts/codex-sdk-backend-router-check.js +0 -65
- package/dist/scripts/codex-sdk-capability-check.js +0 -11
- package/dist/scripts/codex-sdk-core-skill-pipeline-check.js +0 -9
- package/dist/scripts/codex-sdk-dfix-pipeline-check.js +0 -9
- package/dist/scripts/codex-sdk-event-stream-ledger-check.js +0 -9
- package/dist/scripts/codex-sdk-no-legacy-fallback-check.js +0 -33
- package/dist/scripts/codex-sdk-qa-pipeline-check.js +0 -8
- package/dist/scripts/codex-sdk-real-smoke-check.js +0 -39
- package/dist/scripts/codex-sdk-release-review-pipeline-check.js +0 -13
- package/dist/scripts/codex-sdk-research-pipeline-check.js +0 -15
- package/dist/scripts/codex-sdk-sandbox-policy-check.js +0 -21
- package/dist/scripts/codex-sdk-structured-output-check.js +0 -10
- package/dist/scripts/codex-sdk-team-naruto-agent-pipeline-check.js +0 -12
- package/dist/scripts/codex-sdk-thread-registry-check.js +0 -11
- package/dist/scripts/codex-sdk-ux-ppt-review-pipeline-check.js +0 -9
- package/dist/scripts/codex-sdk-zellij-pane-binding-check.js +0 -13
- package/dist/scripts/codex-thread-runtime-choice-check.js +0 -10
- package/dist/scripts/codex-web-adapter-check.js +0 -12
- package/dist/scripts/computer-use-live-evidence-check.js +0 -55
- package/dist/scripts/computer-use-live-optional-check.js +0 -32
- package/dist/scripts/computer-use-policy-check.js +0 -69
- package/dist/scripts/computer-use-visual-route-fixture-check.js +0 -37
- package/dist/scripts/core-skill-card-schema-check.js +0 -61
- package/dist/scripts/core-skill-deployment-snapshot-check.js +0 -54
- package/dist/scripts/core-skill-heldout-validation-check.js +0 -49
- package/dist/scripts/core-skill-no-inference-optimizer-check.js +0 -75
- package/dist/scripts/core-skill-patch-check.js +0 -79
- package/dist/scripts/core-skill-promotion-side-effect-ledger-check.js +0 -64
- package/dist/scripts/core-skill-rollout-scoring-check.js +0 -72
- package/dist/scripts/core-skill-route-runtime-integration-check.js +0 -49
- package/dist/scripts/dfix-fast-blackbox-check.js +0 -37
- package/dist/scripts/dfix-fast-kernel-check.js +0 -26
- package/dist/scripts/dfix-fixture-check.js +0 -6
- package/dist/scripts/dfix-parallel-write-blackbox.js +0 -48
- package/dist/scripts/dfix-patch-handoff-check.js +0 -13
- package/dist/scripts/dfix-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/dfix-performance-check.js +0 -15
- package/dist/scripts/dfix-verification-check.js +0 -9
- package/dist/scripts/dfix-verification-recommendation-check.js +0 -15
- package/dist/scripts/docs-truthfulness-check.js +0 -61
- package/dist/scripts/doctor-codex-doctor-parity-check.js +0 -17
- package/dist/scripts/doctor-fix-proves-codex-read-check.js +0 -64
- package/dist/scripts/doctor-fix-recovers-corrupted-config-check.js +0 -122
- package/dist/scripts/doctor-fixes-codex-app-fast-ui-check.js +0 -39
- package/dist/scripts/evidence-fixture-check.js +0 -26
- package/dist/scripts/evidence-flagship-coverage-check.js +0 -55
- package/dist/scripts/fake-real-proof-policy-v2-check.js +0 -27
- package/dist/scripts/fake-vs-real-proof-policy-check.js +0 -14
- package/dist/scripts/fast-codex-service-tier-proof-check.js +0 -42
- package/dist/scripts/flagship-proof-graph-v2-check.js +0 -48
- package/dist/scripts/flagship-proof-graph-v3-check.js +0 -67
- package/dist/scripts/flagship-proof-graph-v4-check.js +0 -61
- package/dist/scripts/git-precommit-fixture-check.js +0 -41
- package/dist/scripts/git-worktree-cache-performance-check.js +0 -25
- package/dist/scripts/git-worktree-capability-check.js +0 -27
- package/dist/scripts/git-worktree-checkpoint-check.js +0 -20
- package/dist/scripts/git-worktree-cleanup-check.js +0 -27
- package/dist/scripts/git-worktree-cross-rebase-check.js +0 -39
- package/dist/scripts/git-worktree-diff-envelope-check.js +0 -17
- package/dist/scripts/git-worktree-diff-export-check.js +0 -43
- package/dist/scripts/git-worktree-dirty-lock-check.js +0 -17
- package/dist/scripts/git-worktree-dirty-main-detection-check.js +0 -14
- package/dist/scripts/git-worktree-integration-primary-check.js +0 -24
- package/dist/scripts/git-worktree-integration-primary-runtime-check.js +0 -20
- package/dist/scripts/git-worktree-manager-check.js +0 -37
- package/dist/scripts/git-worktree-manifest-append-check.js +0 -18
- package/dist/scripts/git-worktree-merge-queue-check.js +0 -31
- package/dist/scripts/git-worktree-pool-performance-check.js +0 -20
- package/dist/scripts/git-worktree-untracked-diff-check.js +0 -18
- package/dist/scripts/goal-mode-official-default-check.js +0 -12
- package/dist/scripts/gpt-final-arbiter-check.js +0 -63
- package/dist/scripts/gpt-final-arbiter-performance-check.js +0 -36
- package/dist/scripts/gpt-image-2-request-validator-check.js +0 -35
- package/dist/scripts/hooks-0.134-context-parity-check.js +0 -20
- package/dist/scripts/hooks-actual-parity-check.js +0 -17
- package/dist/scripts/hooks-actual-parity-v2-check.js +0 -21
- package/dist/scripts/hooks-latest-schema-check.js +0 -20
- package/dist/scripts/hooks-managed-install-fixture-check.js +0 -21
- package/dist/scripts/hooks-official-hash-oracle-check.js +0 -35
- package/dist/scripts/hooks-official-hash-parity-check.js +0 -17
- package/dist/scripts/hooks-subagent-events-check.js +0 -17
- package/dist/scripts/hooks-trust-state-check.js +0 -14
- package/dist/scripts/image-fidelity-fixture-check.js +0 -24
- package/dist/scripts/imagegen-capability-check.js +0 -30
- package/dist/scripts/imagegen-real-smoke-check.js +0 -155
- package/dist/scripts/install-update-preserves-config-check.js +0 -87
- package/dist/scripts/json-schema-recursive-check.js +0 -78
- package/dist/scripts/legacy-multiagent-removal-check.js +0 -85
- package/dist/scripts/legacy-upgrade-matrix-check.js +0 -300
- package/dist/scripts/local-collab-all-pipelines-final-gpt-check.js +0 -21
- package/dist/scripts/local-collab-gpt-final-availability-check.js +0 -58
- package/dist/scripts/local-collab-no-local-only-final-check.js +0 -27
- package/dist/scripts/local-collab-policy-check.js +0 -17
- package/dist/scripts/local-collab-worktree-gpt-final-apply-policy-check.js +0 -63
- package/dist/scripts/local-llm-all-pipelines-check.js +0 -11
- package/dist/scripts/local-llm-cache-performance-check.js +0 -10
- package/dist/scripts/local-llm-capability-check.js +0 -14
- package/dist/scripts/local-llm-smoke-check.js +0 -23
- package/dist/scripts/local-llm-structured-output-check.js +0 -11
- package/dist/scripts/local-llm-throughput-check.js +0 -10
- package/dist/scripts/local-llm-tool-call-repair-check.js +0 -10
- package/dist/scripts/local-llm-warmup-check.js +0 -11
- package/dist/scripts/loop-blocker-check.js +0 -15
- package/dist/scripts/mad-preflight-blocks-unreadable-config-check.js +0 -35
- package/dist/scripts/mad-sks-actual-executor-blackbox.js +0 -5
- package/dist/scripts/mad-sks-app-ui-no-mutation-check.js +0 -92
- package/dist/scripts/mad-sks-audit-proof-check.js +0 -34
- package/dist/scripts/mad-sks-db-executor-check.js +0 -5
- package/dist/scripts/mad-sks-executor-proof-graph-check.js +0 -5
- package/dist/scripts/mad-sks-fast-mode-propagation-check.js +0 -24
- package/dist/scripts/mad-sks-file-write-executor-check.js +0 -5
- package/dist/scripts/mad-sks-immutable-harness-check.js +0 -36
- package/dist/scripts/mad-sks-no-harness-modification-check.js +0 -25
- package/dist/scripts/mad-sks-package-executor-check.js +0 -5
- package/dist/scripts/mad-sks-permission-model-check.js +0 -22
- package/dist/scripts/mad-sks-rollback-apply-check.js +0 -5
- package/dist/scripts/mad-sks-service-executor-check.js +0 -5
- package/dist/scripts/mad-sks-shell-executor-check.js +0 -5
- package/dist/scripts/mad-sks-write-guard-check.js +0 -28
- package/dist/scripts/mad-sks-zellij-default-pane-worker-check.js +0 -37
- package/dist/scripts/mad-sks-zellij-launch-check.js +0 -102
- package/dist/scripts/mcp-0-134-modernization-check.js +0 -55
- package/dist/scripts/mcp-readonly-concurrency-check.js +0 -17
- package/dist/scripts/mcp-readonly-runtime-scheduler-check.js +0 -20
- package/dist/scripts/mcp-tool-naming-parity-check.js +0 -16
- package/dist/scripts/memory-summary-rebuild-check.js +0 -22
- package/dist/scripts/mutation-callsite-coverage-check.js +0 -180
- package/dist/scripts/naruto-active-pool-check.js +0 -39
- package/dist/scripts/naruto-actual-worker-control-plane-check.js +0 -56
- package/dist/scripts/naruto-allocation-policy-check.js +0 -33
- package/dist/scripts/naruto-allocation-runtime-wiring-check.js +0 -92
- package/dist/scripts/naruto-concurrency-governor-check.js +0 -53
- package/dist/scripts/naruto-extreme-parallelism-check.js +0 -22
- package/dist/scripts/naruto-extreme-parallelism-real-check.js +0 -43
- package/dist/scripts/naruto-gpt-final-pack-check.js +0 -34
- package/dist/scripts/naruto-orchestrator-runtime-source-check.js +0 -70
- package/dist/scripts/naruto-parallel-patch-apply-check.js +0 -41
- package/dist/scripts/naruto-readonly-routing-check.js +0 -116
- package/dist/scripts/naruto-real-active-pool-check.js +0 -39
- package/dist/scripts/naruto-real-active-pool-runtime-check.js +0 -55
- package/dist/scripts/naruto-rebalance-policy-check.js +0 -41
- package/dist/scripts/naruto-role-distribution-check.js +0 -23
- package/dist/scripts/naruto-shadow-clone-swarm-check.js +0 -153
- package/dist/scripts/naruto-verification-pool-check.js +0 -36
- package/dist/scripts/naruto-work-graph-check.js +0 -24
- package/dist/scripts/naruto-worktree-coding-blackbox.js +0 -29
- package/dist/scripts/naruto-worktree-coding-check.js +0 -44
- package/dist/scripts/naruto-worktree-gpt-final-check.js +0 -45
- package/dist/scripts/naruto-worktree-zellij-ui-check.js +0 -28
- package/dist/scripts/naruto-zellij-dynamic-right-column-check.js +0 -48
- package/dist/scripts/naruto-zellij-massive-ui-check.js +0 -23
- package/dist/scripts/non-recursive-pipeline-check.js +0 -68
- package/dist/scripts/npm-publish-performance-check.js +0 -65
- package/dist/scripts/official-docs-compat-report.js +0 -304
- package/dist/scripts/packlist-performance-check.js +0 -83
- package/dist/scripts/parallel-verification-engine-check.js +0 -85
- package/dist/scripts/postinstall-safe-side-effects-check.js +0 -65
- package/dist/scripts/ppt-full-e2e-artifact-graph-check.js +0 -40
- package/dist/scripts/ppt-full-e2e-blackbox-check.js +0 -109
- package/dist/scripts/ppt-image-voxel-relations-check.js +0 -9
- package/dist/scripts/ppt-imagegen-blackbox-check.js +0 -46
- package/dist/scripts/ppt-imagegen-review-fixture-check.js +0 -6
- package/dist/scripts/ppt-issue-extraction-fixture-check.js +0 -7
- package/dist/scripts/ppt-no-mock-as-real-check.js +0 -8
- package/dist/scripts/ppt-no-text-fallback-check.js +0 -7
- package/dist/scripts/ppt-proof-trust-fixture-check.js +0 -10
- package/dist/scripts/ppt-real-export-adapter-check.js +0 -13
- package/dist/scripts/ppt-real-imagegen-smoke-check.js +0 -42
- package/dist/scripts/ppt-real-imagegen-wiring-check.js +0 -16
- package/dist/scripts/ppt-reexport-rereview-check.js +0 -19
- package/dist/scripts/ppt-slide-export-fixture-check.js +0 -7
- package/dist/scripts/prepublish-fast-check.js +0 -128
- package/dist/scripts/priority-full-closure-check.js +0 -12
- package/dist/scripts/product-design-auto-install-check.js +0 -119
- package/dist/scripts/product-design-plugin-routing-check.js +0 -101
- package/dist/scripts/prompt-placeholder-guard-check.js +0 -33
- package/dist/scripts/provider-badge-context-check.js +0 -26
- package/dist/scripts/provider-context-config-toml-check.js +0 -63
- package/dist/scripts/python-codex-sdk-all-pipelines-check.js +0 -47
- package/dist/scripts/python-codex-sdk-capability-check.js +0 -75
- package/dist/scripts/python-codex-sdk-sandbox-policy-check.js +0 -10
- package/dist/scripts/python-codex-sdk-stream-bridge-check.js +0 -12
- package/dist/scripts/python-tools-smoke-check.js +0 -71
- package/dist/scripts/qa-actual-route-backfill-check.js +0 -5
- package/dist/scripts/qa-backfill-route-blackbox.js +0 -5
- package/dist/scripts/qa-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/readme-architecture-imagegen-official-check.js +0 -448
- package/dist/scripts/release-cache-glob-hashing-check.js +0 -42
- package/dist/scripts/release-dag-full-coverage-check.js +0 -53
- package/dist/scripts/release-dist-freshness-check.js +0 -8
- package/dist/scripts/release-dynamic-performance-check.js +0 -103
- package/dist/scripts/release-gate-budget-check.js +0 -36
- package/dist/scripts/release-gate-dag-runner-check.js +0 -17
- package/dist/scripts/release-metadata-1-11-check.js +0 -37
- package/dist/scripts/release-metadata-1-12-check.js +0 -48
- package/dist/scripts/release-metadata-1-13-check.js +0 -53
- package/dist/scripts/release-metadata-1-14-check.js +0 -63
- package/dist/scripts/release-metadata-1-16-check.js +0 -81
- package/dist/scripts/release-metadata-1-17-check.js +0 -51
- package/dist/scripts/release-metadata-1-19-check.js +0 -371
- package/dist/scripts/release-metadata-check.js +0 -7
- package/dist/scripts/release-native-agent-fixture-check.js +0 -41
- package/dist/scripts/release-parallel-check.js +0 -374
- package/dist/scripts/release-parallel-full-coverage-check.js +0 -13
- package/dist/scripts/release-parallel-speed-budget-check.js +0 -79
- package/dist/scripts/release-provenance-check.js +0 -150
- package/dist/scripts/release-readiness-report.js +0 -1146
- package/dist/scripts/release-real-check.js +0 -330
- package/dist/scripts/release-registry-check.js +0 -344
- package/dist/scripts/release-runtime-truth-matrix-check.js +0 -47
- package/dist/scripts/release-stability-report-check.js +0 -99
- package/dist/scripts/release-version-truth-check.js +0 -134
- package/dist/scripts/research-actual-route-backfill-check.js +0 -5
- package/dist/scripts/research-backfill-route-blackbox.js +0 -5
- package/dist/scripts/research-quality-gate-check.js +0 -86
- package/dist/scripts/responses-retry-policy-centralized-check.js +0 -19
- package/dist/scripts/retention-cleanup-safety-check.js +0 -155
- package/dist/scripts/route-blackbox-realism-check.js +0 -21
- package/dist/scripts/route-proof-artifact-structure-check.js +0 -145
- package/dist/scripts/runtime-dist-parity-check.js +0 -78
- package/dist/scripts/runtime-no-mjs-scripts-check.js +0 -45
- package/dist/scripts/runtime-no-src-mjs-check.js +0 -32
- package/dist/scripts/runtime-no-tmux-check.js +0 -113
- package/dist/scripts/runtime-ts-python-boundary-check.js +0 -59
- package/dist/scripts/runtime-ts-rust-boundary-check.js +0 -74
- package/dist/scripts/runtime-ts-source-of-truth-check.js +0 -55
- package/dist/scripts/safety-check.js +0 -23
- package/dist/scripts/shared-memory-fixture-check.js +0 -27
- package/dist/scripts/side-effect-runtime-report-check.js +0 -19
- package/dist/scripts/side-effect-zero-gate-check.js +0 -226
- package/dist/scripts/sks-1-11-fixture-check.js +0 -130
- package/dist/scripts/source-intelligence-all-modes-check.js +0 -32
- package/dist/scripts/source-intelligence-policy-check.js +0 -13
- package/dist/scripts/strategy-adhd-orchestrating-gate-check.js +0 -22
- package/dist/scripts/strategy-file-ownership-plan-check.js +0 -18
- package/dist/scripts/strategy-parallel-modification-plan-check.js +0 -19
- package/dist/scripts/strategy-verification-rollback-dag-check.js +0 -19
- package/dist/scripts/team-actual-route-backfill-check.js +0 -5
- 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/terminal-keyboard-enhancement-safety-check.js +0 -12
- package/dist/scripts/terminal-tui-output-stability-check.js +0 -35
- package/dist/scripts/test-no-orphan-dist-imports-check.js +0 -73
- package/dist/scripts/trust-fixture-check.js +0 -33
- package/dist/scripts/typescript-migration-report.js +0 -78
- package/dist/scripts/ultra-router-auto-router-check.js +0 -33
- package/dist/scripts/ultra-router-classification-check.js +0 -28
- package/dist/scripts/ux-patch-swarm-route-blackbox.js +0 -10
- package/dist/scripts/ux-ppt-structured-extraction-check.js +0 -21
- package/dist/scripts/ux-review-extract-real-callouts-fixture-check.js +0 -8
- package/dist/scripts/ux-review-extract-wires-real-extractor-check.js +0 -15
- package/dist/scripts/ux-review-generate-callouts-fixture-check.js +0 -9
- package/dist/scripts/ux-review-image-voxel-relations-check.js +0 -31
- package/dist/scripts/ux-review-imagegen-blackbox-check.js +0 -67
- package/dist/scripts/ux-review-no-fake-callouts-check.js +0 -8
- package/dist/scripts/ux-review-no-text-fallback-check.js +0 -25
- package/dist/scripts/ux-review-patch-diff-recheck-check.js +0 -20
- package/dist/scripts/ux-review-patch-handoff-fixture-check.js +0 -8
- package/dist/scripts/ux-review-real-imagegen-smoke-check.js +0 -31
- package/dist/scripts/ux-review-real-loop-fixture-check.js +0 -24
- package/dist/scripts/ux-review-recapture-recheck-fixture-check.js +0 -8
- package/dist/scripts/ux-review-run-wires-imagegen-check.js +0 -11
- package/dist/scripts/worker-pane-communication-contract-check.js +0 -54
- package/dist/scripts/wrongness-fixture-check.js +0 -65
- package/dist/scripts/xai-mcp-capability-check.js +0 -14
- package/dist/scripts/zellij-capability-check.js +0 -15
- package/dist/scripts/zellij-dashboard-pane-check.js +0 -70
- package/dist/scripts/zellij-developer-controls-check.js +0 -20
- package/dist/scripts/zellij-doctor-readiness-check.js +0 -63
- package/dist/scripts/zellij-dynamic-pane-lifecycle-check.js +0 -21
- package/dist/scripts/zellij-first-slot-down-stack-check.js +0 -20
- package/dist/scripts/zellij-first-slot-down-stack-real-check.js +0 -356
- package/dist/scripts/zellij-initial-main-only-blackbox.js +0 -28
- package/dist/scripts/zellij-lane-renderer-check.js +0 -65
- package/dist/scripts/zellij-launch-command-truth-check.js +0 -75
- package/dist/scripts/zellij-layout-valid-check.js +0 -90
- package/dist/scripts/zellij-pane-proof-check.js +0 -59
- package/dist/scripts/zellij-real-session-cleanup-check.js +0 -21
- package/dist/scripts/zellij-real-session-heartbeat-check.js +0 -49
- package/dist/scripts/zellij-real-session-launch-check.js +0 -57
- package/dist/scripts/zellij-right-column-headless-overflow-check.js +0 -22
- package/dist/scripts/zellij-right-column-manager-check.js +0 -27
- package/dist/scripts/zellij-screen-proof-check.js +0 -45
- package/dist/scripts/zellij-slot-column-anchor-check.js +0 -66
- package/dist/scripts/zellij-slot-only-ui-check.js +0 -26
- package/dist/scripts/zellij-slot-pane-renderer-check.js +0 -106
- package/dist/scripts/zellij-slot-renderer-proof-semantics-check.js +0 -59
- package/dist/scripts/zellij-spawn-on-demand-layout-check.js +0 -40
- package/dist/scripts/zellij-ui-design-check.js +0 -105
- package/dist/scripts/zellij-worker-pane-manager-check.js +0 -109
- package/dist/scripts/zellij-worker-pane-manager-single-owner-check.js +0 -47
- package/dist/scripts/zellij-worker-pane-real-ui-blackbox.js +0 -202
- package/dist/scripts/zellij-worker-pane-spawn-order-check.js +0 -35
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/permission-request.command.input.schema.json +0 -61
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/permission-request.command.output.schema.json +0 -103
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/post-compact.command.input.schema.json +0 -52
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/post-compact.command.output.schema.json +0 -24
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/post-tool-use.command.input.schema.json +0 -67
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/post-tool-use.command.output.schema.json +0 -84
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/pre-compact.command.input.schema.json +0 -52
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/pre-compact.command.output.schema.json +0 -24
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/pre-tool-use.command.input.schema.json +0 -65
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/pre-tool-use.command.output.schema.json +0 -105
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/session-start.command.input.schema.json +0 -59
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/session-start.command.output.schema.json +0 -63
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/snapshot-metadata.json +0 -31
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/stop.command.input.schema.json +0 -63
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/stop.command.output.schema.json +0 -45
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/user-prompt-submit.command.input.schema.json +0 -59
- package/dist/vendor/openai-codex/rust-v0.131.0/hooks/user-prompt-submit.command.output.schema.json +0 -81
|
@@ -1,86 +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 { fileURLToPath, pathToFileURL } from 'node:url';
|
|
7
|
-
const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), '..', '..');
|
|
8
|
-
const issues = [];
|
|
9
|
-
for (const rel of ['src/core/session/project-namespace.ts', 'src/core/agents/agent-orchestrator.ts']) {
|
|
10
|
-
if (!fs.existsSync(path.join(root, rel)))
|
|
11
|
-
issues.push(`missing:${rel}`);
|
|
12
|
-
}
|
|
13
|
-
const orchestrator = read('src/core/agents/agent-orchestrator.ts');
|
|
14
|
-
for (const token of ['buildProjectNamespace', 'namespacedAgentSessionId', 'writeProjectNamespaceArtifact']) {
|
|
15
|
-
if (!orchestrator.includes(token))
|
|
16
|
-
issues.push(`orchestrator_namespace_missing:${token}`);
|
|
17
|
-
}
|
|
18
|
-
await runFixture();
|
|
19
|
-
const result = { schema: 'sks.agent-multi-project-isolation-check.v1', ok: issues.length === 0, issues };
|
|
20
|
-
console.log(JSON.stringify(result, null, 2));
|
|
21
|
-
if (!result.ok)
|
|
22
|
-
process.exitCode = 1;
|
|
23
|
-
function read(rel) {
|
|
24
|
-
try {
|
|
25
|
-
return fs.readFileSync(path.join(root, rel), 'utf8');
|
|
26
|
-
}
|
|
27
|
-
catch {
|
|
28
|
-
return '';
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
async function runFixture() {
|
|
32
|
-
const built = path.join(root, 'dist', 'core', 'session', 'project-namespace.js');
|
|
33
|
-
const orchestratorBuilt = path.join(root, 'dist', 'core', 'agents', 'agent-orchestrator.js');
|
|
34
|
-
const janitorBuilt = path.join(root, 'dist', 'core', 'agents', 'agent-janitor.js');
|
|
35
|
-
if (!fs.existsSync(built) || !fs.existsSync(orchestratorBuilt) || !fs.existsSync(janitorBuilt)) {
|
|
36
|
-
issues.push('fixture_dist_namespace_or_orchestrator_missing_run_build_first');
|
|
37
|
-
return;
|
|
38
|
-
}
|
|
39
|
-
const mod = await import(pathToFileURL(built).href);
|
|
40
|
-
const orchestrator = await import(pathToFileURL(orchestratorBuilt).href);
|
|
41
|
-
const janitor = await import(pathToFileURL(janitorBuilt).href);
|
|
42
|
-
const a = fs.mkdtempSync(path.join(os.tmpdir(), 'sks-proj-a-'));
|
|
43
|
-
const b = fs.mkdtempSync(path.join(os.tmpdir(), 'sks-proj-b-'));
|
|
44
|
-
const nsA = await mod.buildProjectNamespace({ root: a, missionId: 'M-same' });
|
|
45
|
-
const nsB = await mod.buildProjectNamespace({ root: b, missionId: 'M-same' });
|
|
46
|
-
if (nsA.root_hash === nsB.root_hash)
|
|
47
|
-
issues.push('fixture_root_hash_collision');
|
|
48
|
-
if (nsA.mission_namespace_id === nsB.mission_namespace_id)
|
|
49
|
-
issues.push('fixture_mission_namespace_collision');
|
|
50
|
-
if (!nsA.temp_dir.includes(nsA.root_hash) || !nsB.temp_dir.includes(nsB.root_hash))
|
|
51
|
-
issues.push('fixture_temp_dir_missing_hash');
|
|
52
|
-
if (mod.namespacedZellijSessionName(nsA, 'team') === mod.namespacedZellijSessionName(nsB, 'team'))
|
|
53
|
-
issues.push('fixture_zellij_session_collision');
|
|
54
|
-
const sessionA = mod.namespacedAgentSessionId({ agentId: 'agent_1', missionId: 'M-same', rootHash: nsA.root_hash, index: 1 });
|
|
55
|
-
const sessionB = mod.namespacedAgentSessionId({ agentId: 'agent_1', missionId: 'M-same', rootHash: nsB.root_hash, index: 1 });
|
|
56
|
-
if (sessionA === sessionB)
|
|
57
|
-
issues.push('fixture_agent_session_collision');
|
|
58
|
-
const [runA, runB] = await Promise.all([
|
|
59
|
-
orchestrator.runNativeAgentOrchestrator({ root: a, missionId: 'M-same', prompt: 'fixture A', backend: 'fake', agents: 5, concurrency: 2, readonly: true }),
|
|
60
|
-
orchestrator.runNativeAgentOrchestrator({ root: b, missionId: 'M-same', prompt: 'fixture B', backend: 'fake', agents: 5, concurrency: 2, readonly: true })
|
|
61
|
-
]);
|
|
62
|
-
if (!runA.ok || !runB.ok)
|
|
63
|
-
issues.push('fixture_concurrent_fake_agent_failed');
|
|
64
|
-
const proofA = JSON.parse(fs.readFileSync(path.join(a, '.sneakoscope', 'missions', 'M-same', 'agents', 'agent-proof-evidence.json'), 'utf8'));
|
|
65
|
-
const proofB = JSON.parse(fs.readFileSync(path.join(b, '.sneakoscope', 'missions', 'M-same', 'agents', 'agent-proof-evidence.json'), 'utf8'));
|
|
66
|
-
const liveNsA = JSON.parse(fs.readFileSync(path.join(a, '.sneakoscope', 'missions', 'M-same', 'project-session-namespace.json'), 'utf8'));
|
|
67
|
-
const liveNsB = JSON.parse(fs.readFileSync(path.join(b, '.sneakoscope', 'missions', 'M-same', 'project-session-namespace.json'), 'utf8'));
|
|
68
|
-
if (liveNsA.root_hash === liveNsB.root_hash)
|
|
69
|
-
issues.push('fixture_runtime_root_hash_collision');
|
|
70
|
-
if (proofA.mission_id !== 'M-same' || proofB.mission_id !== 'M-same')
|
|
71
|
-
issues.push('fixture_proof_mission_id_drift');
|
|
72
|
-
if (JSON.stringify(proofA).includes(liveNsB.root_hash) || JSON.stringify(proofB).includes(liveNsA.root_hash))
|
|
73
|
-
issues.push('fixture_proof_cross_project_reference');
|
|
74
|
-
const currentA = JSON.parse(fs.readFileSync(path.join(a, '.sneakoscope', 'state', 'current.json'), 'utf8'));
|
|
75
|
-
const currentB = JSON.parse(fs.readFileSync(path.join(b, '.sneakoscope', 'state', 'current.json'), 'utf8'));
|
|
76
|
-
if (currentA.mission_id !== 'M-same' || currentB.mission_id !== 'M-same')
|
|
77
|
-
issues.push('fixture_current_state_not_project_local');
|
|
78
|
-
fs.mkdirSync(liveNsA.temp_dir, { recursive: true });
|
|
79
|
-
fs.mkdirSync(liveNsB.temp_dir, { recursive: true });
|
|
80
|
-
await janitor.runAgentJanitor({ missionDir: path.join(a, '.sneakoscope', 'missions', 'M-same'), missionId: 'M-same', projectHash: liveNsA.root_hash, cleanup: true });
|
|
81
|
-
if (!fs.existsSync(liveNsA.temp_dir))
|
|
82
|
-
issues.push('fixture_janitor_deleted_active_project_temp');
|
|
83
|
-
if (!fs.existsSync(liveNsB.temp_dir))
|
|
84
|
-
issues.push('fixture_janitor_cross_project_deleted_temp');
|
|
85
|
-
}
|
|
86
|
-
//# sourceMappingURL=agent-multi-project-isolation-check.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { emitGate } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { runNativeCliSwarmCheck } from './lib/native-cli-session-swarm-check-lib.js';
|
|
5
|
-
const report = runNativeCliSwarmCheck({ agents: 5, workItems: 5, reportName: 'agent-native-cli-session-proof.json' });
|
|
6
|
-
emitGate('agent:native-cli-session-proof', { spawned: report.native_cli_session_proof.spawned_worker_process_count });
|
|
7
|
-
//# sourceMappingURL=agent-native-cli-session-proof-check.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { emitGate } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { runNativeCliSwarmCheck } from './lib/native-cli-session-swarm-check-lib.js';
|
|
5
|
-
const report = runNativeCliSwarmCheck({ agents: 10, workItems: 10, reportName: 'agent-native-cli-session-swarm-10.json' });
|
|
6
|
-
emitGate('agent:native-cli-session-swarm-10', { agents: report.agents, max_observed: report.native_cli_session_proof.max_observed_worker_process_count });
|
|
7
|
-
//# sourceMappingURL=agent-native-cli-session-swarm-10-check.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { emitGate } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { runNativeCliSwarmCheck } from './lib/native-cli-session-swarm-check-lib.js';
|
|
5
|
-
const report = runNativeCliSwarmCheck({ agents: 20, workItems: 20, reportName: 'agent-native-cli-session-swarm-20.json' });
|
|
6
|
-
emitGate('agent:native-cli-session-swarm-20', { agents: report.agents, max_observed: report.native_cli_session_proof.max_observed_worker_process_count });
|
|
7
|
-
//# sourceMappingURL=agent-native-cli-session-swarm-20-check.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { emitGate } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { runNativeCliSwarmCheck } from './lib/native-cli-session-swarm-check-lib.js';
|
|
5
|
-
const report = runNativeCliSwarmCheck({ agents: 5, workItems: 5, reportName: 'agent-native-cli-session-swarm.json' });
|
|
6
|
-
emitGate('agent:native-cli-session-swarm', { agents: report.agents, max_observed: report.native_cli_session_proof.max_observed_worker_process_count });
|
|
7
|
-
//# sourceMappingURL=agent-native-cli-session-swarm-check.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { emitGate } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { runNativeCliSwarmCheck } from './lib/native-cli-session-swarm-check-lib.js';
|
|
5
|
-
const report = runNativeCliSwarmCheck({ agents: 5, workItems: 5, reportName: 'agent-no-subagent-scaling.json' });
|
|
6
|
-
emitGate('agent:no-subagent-scaling', { native_worker_process_count: report.no_subagent_scaling_policy.native_worker_process_count });
|
|
7
|
-
//# sourceMappingURL=agent-no-subagent-scaling-check.js.map
|
|
@@ -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,103 +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 { assertGate, emitGate, importDist, root } from './sks-1-18-gate-lib.js';
|
|
7
|
-
const queueMod = await importDist('core/agents/agent-patch-queue.js');
|
|
8
|
-
const applyMod = await importDist('core/agents/agent-patch-apply-worker.js');
|
|
9
|
-
const mergeMod = await importDist('core/agents/agent-merge-coordinator.js');
|
|
10
|
-
const proofMod = await importDist('core/agents/agent-patch-proof.js');
|
|
11
|
-
const tmp = fs.mkdtempSync(path.join(os.tmpdir(), 'sks-agent-patch-'));
|
|
12
|
-
fs.writeFileSync(path.join(tmp, 'a.txt'), 'alpha\n');
|
|
13
|
-
fs.writeFileSync(path.join(tmp, 'b.txt'), 'bravo\n');
|
|
14
|
-
const queue = new queueMod.InMemoryAgentPatchQueue();
|
|
15
|
-
const envelope = (agent, file, operation) => ({
|
|
16
|
-
schema: 'sks.agent-patch-envelope.v1',
|
|
17
|
-
agent_id: agent,
|
|
18
|
-
session_id: `${agent}-session`,
|
|
19
|
-
slot_id: `${agent}-slot`,
|
|
20
|
-
generation_index: 1,
|
|
21
|
-
lease_id: `lease:${agent}:${file}`,
|
|
22
|
-
task_slice_id: `task:${agent}:${file}`,
|
|
23
|
-
verification_hint: { node_id: `verify:${agent}` },
|
|
24
|
-
rollback_hint: { node_id: `rollback:${agent}` },
|
|
25
|
-
lease_proof: {
|
|
26
|
-
lease_id: `lease:${agent}:${file}`,
|
|
27
|
-
owner_agent: agent,
|
|
28
|
-
strategy_task_id: `strategy:${agent}`,
|
|
29
|
-
micro_win_id: `micro:${agent}:${file}`,
|
|
30
|
-
verification_node_id: `verify:${agent}`,
|
|
31
|
-
rollback_node_id: `rollback:${agent}`,
|
|
32
|
-
allowed_paths: [file],
|
|
33
|
-
protected_path_check: 'passed'
|
|
34
|
-
},
|
|
35
|
-
operations: [operation]
|
|
36
|
-
});
|
|
37
|
-
const first = queue.enqueue(envelope('agent-a', 'a.txt', { op: 'replace', path: 'a.txt', search: 'alpha', replace: 'alpha-1' }));
|
|
38
|
-
const second = queue.enqueue(envelope('agent-b', 'b.txt', { op: 'replace', path: 'b.txt', search: 'bravo', replace: 'bravo-1' }));
|
|
39
|
-
const merge = mergeMod.coordinateAgentPatchMerge(queue.queued());
|
|
40
|
-
const applyResults = [];
|
|
41
|
-
for (const entry of queue.queued()) {
|
|
42
|
-
const applyResult = await applyMod.applyAgentPatchEnvelope(tmp, entry.envelope);
|
|
43
|
-
applyResults.push({ ...applyResult, entry_id: entry.id });
|
|
44
|
-
if (applyResult.ok)
|
|
45
|
-
queue.markApplied(entry.id);
|
|
46
|
-
}
|
|
47
|
-
const proof = proofMod.buildAgentPatchProof({
|
|
48
|
-
queue: queue.toJSON(),
|
|
49
|
-
merge,
|
|
50
|
-
applyResults,
|
|
51
|
-
verification: ['fixture-files-mutated'],
|
|
52
|
-
transactionJournal: {
|
|
53
|
-
schema: 'sks.agent-patch-transaction-journal-summary.v1',
|
|
54
|
-
ok: true,
|
|
55
|
-
event_count: 8,
|
|
56
|
-
blockers: []
|
|
57
|
-
},
|
|
58
|
-
verificationRollbackDag: {
|
|
59
|
-
nodes: [
|
|
60
|
-
{ id: 'verify:agent-a', kind: 'verification' },
|
|
61
|
-
{ id: 'rollback:agent-a', kind: 'rollback' },
|
|
62
|
-
{ id: 'verify:agent-b', kind: 'verification' },
|
|
63
|
-
{ id: 'rollback:agent-b', kind: 'rollback' }
|
|
64
|
-
]
|
|
65
|
-
}
|
|
66
|
-
});
|
|
67
|
-
const atomicProbeFile = path.join(tmp, 'atomic.txt');
|
|
68
|
-
fs.writeFileSync(atomicProbeFile, 'before\n');
|
|
69
|
-
const atomicBlocked = await applyMod.applyAgentPatchEnvelope(tmp, {
|
|
70
|
-
schema: 'sks.agent-patch-envelope.v1',
|
|
71
|
-
agent_id: 'atomic-probe',
|
|
72
|
-
session_id: 'atomic-session',
|
|
73
|
-
slot_id: 'atomic-slot',
|
|
74
|
-
generation_index: 1,
|
|
75
|
-
lease_id: 'lease:atomic-probe:atomic.txt',
|
|
76
|
-
rollback_hint: { node_id: 'rollback:atomic' },
|
|
77
|
-
operations: [
|
|
78
|
-
{ op: 'replace', path: 'atomic.txt', search: 'before', replace: 'after' },
|
|
79
|
-
{ op: 'write', path: '.codex/blocked.txt', content: 'blocked' }
|
|
80
|
-
]
|
|
81
|
-
});
|
|
82
|
-
const normalizedConflict = mergeMod.coordinateAgentPatchMerge([
|
|
83
|
-
envelope('agent-a', 'same.txt', { op: 'write', path: 'same.txt', content: 'a' }),
|
|
84
|
-
envelope('agent-b', 'same.txt', { op: 'write', path: './same.txt', content: 'b' })
|
|
85
|
-
]);
|
|
86
|
-
const parentChildConflict = mergeMod.coordinateAgentPatchMerge([
|
|
87
|
-
envelope('agent-a', 'dir', { op: 'write', path: 'dir', content: 'a' }),
|
|
88
|
-
envelope('agent-b', 'dir/file.txt', { op: 'write', path: 'dir/file.txt', content: 'b' })
|
|
89
|
-
]);
|
|
90
|
-
const report = { schema: 'sks.agent-parallel-write-kernel-check.v1', ok: proof.ok, first, second, merge, applyResults, proof, atomicBlocked, normalizedConflict, parentChildConflict };
|
|
91
|
-
const out = path.join(root, '.sneakoscope', 'reports', 'agent-parallel-write-kernel.json');
|
|
92
|
-
fs.mkdirSync(path.dirname(out), { recursive: true });
|
|
93
|
-
fs.writeFileSync(out, `${JSON.stringify(report, null, 2)}\n`);
|
|
94
|
-
assertGate(merge.ok === true, 'parallel write merge should not report conflicts for disjoint files', report);
|
|
95
|
-
assertGate(applyResults.every((result) => result.ok), 'parallel write apply results must all pass', report);
|
|
96
|
-
assertGate(proof.ok === true, 'parallel write proof must pass', report);
|
|
97
|
-
assertGate(fs.readFileSync(path.join(tmp, 'a.txt'), 'utf8').includes('alpha-1'), 'first patch did not apply', report);
|
|
98
|
-
assertGate(fs.readFileSync(path.join(tmp, 'b.txt'), 'utf8').includes('bravo-1'), 'second patch did not apply', report);
|
|
99
|
-
assertGate(atomicBlocked.ok === false && fs.readFileSync(atomicProbeFile, 'utf8') === 'before\n', 'blocked patch must not partially mutate files', report);
|
|
100
|
-
assertGate(normalizedConflict.ok === false, 'merge coordinator must catch normalized path collisions', report);
|
|
101
|
-
assertGate(parentChildConflict.ok === false, 'merge coordinator must catch parent/child path overlaps', report);
|
|
102
|
-
emitGate('agent:parallel-write-kernel', { changed_files: proof.changed_files.length });
|
|
103
|
-
//# sourceMappingURL=agent-parallel-write-kernel-check.js.map
|
|
@@ -1,198 +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 { assertGate, emitGate, importDist } from './sks-1-18-gate-lib.js';
|
|
7
|
-
import { writeReport } from './agent-patch-swarm-gate-lib.js';
|
|
8
|
-
const queueMod = await importDist('core/agents/agent-patch-queue-store.js');
|
|
9
|
-
const mergeMod = await importDist('core/agents/agent-merge-coordinator.js');
|
|
10
|
-
const rebaseMod = await importDist('core/agents/agent-patch-conflict-rebase.js');
|
|
11
|
-
const proofMod = await importDist('core/agents/agent-patch-proof.js');
|
|
12
|
-
const journalMod = await importDist('core/agents/agent-patch-transaction-journal.js');
|
|
13
|
-
const sameFileSuccess = await runFixture('same-file-success', {
|
|
14
|
-
files: { 'same.txt': 'base\n' },
|
|
15
|
-
envelopes: [
|
|
16
|
-
makeEnvelope('agent-a', [replaceOp('same.txt', 'base', 'agent-a')]),
|
|
17
|
-
makeEnvelope('agent-b', [replaceOp('same.txt', 'agent-a', 'agent-b')])
|
|
18
|
-
]
|
|
19
|
-
});
|
|
20
|
-
const proof = await buildProofForSuccessfulRebase(sameFileSuccess);
|
|
21
|
-
const unreconcilable = await runFixture('same-file-unreconcilable', {
|
|
22
|
-
files: { 'miss.txt': 'base\n' },
|
|
23
|
-
envelopes: [
|
|
24
|
-
makeEnvelope('agent-c', [replaceOp('miss.txt', 'base', 'agent-c')]),
|
|
25
|
-
makeEnvelope('agent-d', [replaceOp('miss.txt', 'never-present', 'agent-d')])
|
|
26
|
-
]
|
|
27
|
-
});
|
|
28
|
-
const subtree = await runFixture('subtree-conflict', {
|
|
29
|
-
envelopes: [
|
|
30
|
-
makeEnvelope('agent-e', [writeOp('tree/child.txt', 'child\n')]),
|
|
31
|
-
makeEnvelope('agent-f', [writeOp('tree', 'parent-as-file\n')])
|
|
32
|
-
]
|
|
33
|
-
});
|
|
34
|
-
const domainBlocked = await runFixture('domain-conflict-blocked', {
|
|
35
|
-
envelopes: [
|
|
36
|
-
makeEnvelope('agent-g', [writeOp('domain-a.txt', 'a\n')], { conflict_prediction_id: 'shared-domain' }),
|
|
37
|
-
makeEnvelope('agent-h', [writeOp('domain-b.txt', 'b\n')], { conflict_prediction_id: 'shared-domain' })
|
|
38
|
-
]
|
|
39
|
-
});
|
|
40
|
-
const domainRetry = await runFixture('domain-conflict-retry', {
|
|
41
|
-
envelopes: [
|
|
42
|
-
makeEnvelope('agent-i', [writeOp('domain-c.txt', 'c\n')], { conflict_prediction_id: 'retry-domain' }),
|
|
43
|
-
makeEnvelope('agent-j', [writeOp('domain-d.txt', 'd\n')], { conflict_prediction_id: 'retry-domain' })
|
|
44
|
-
],
|
|
45
|
-
rebaseOptions: { allowDomainRetry: true }
|
|
46
|
-
});
|
|
47
|
-
const protectedPath = await runFixture('protected-path-conflict', {
|
|
48
|
-
envelopes: [
|
|
49
|
-
makeEnvelope('agent-k', [writeOp('.codex/protected.txt', 'blocked\n')], { allowed_paths: ['.codex/protected.txt'] })
|
|
50
|
-
]
|
|
51
|
-
});
|
|
52
|
-
const unleased = await runFixture('unleased-path-conflict', {
|
|
53
|
-
envelopes: [
|
|
54
|
-
makeEnvelope('agent-l', [writeOp('outside.txt', 'blocked\n')], { allowed_paths: ['allowed.txt'] })
|
|
55
|
-
]
|
|
56
|
-
});
|
|
57
|
-
const dirty = await runFixture('dirty-unrelated-change', {
|
|
58
|
-
files: { 'dirty.txt': 'changed by somebody else\n' },
|
|
59
|
-
envelopes: [makeEnvelope('agent-m', [writeOp('dirty.txt', 'agent write\n')])],
|
|
60
|
-
mergeFactory: (entries) => manualMerge(entries, 'dirty_unrelated_change:dirty.txt', 'dirty.txt')
|
|
61
|
-
});
|
|
62
|
-
const stale = await runFixture('stale-context-rebase', {
|
|
63
|
-
files: { 'stale.txt': 'current\n' },
|
|
64
|
-
envelopes: [makeEnvelope('agent-n', [replaceOp('stale.txt', 'current', 'rebased')])],
|
|
65
|
-
mergeFactory: (entries) => manualMerge(entries, 'stale_context:stale.txt', 'stale.txt')
|
|
66
|
-
});
|
|
67
|
-
const checks = {
|
|
68
|
-
same_file_group_created: sameFileSuccess.merge.serial_merge_groups.length === 1,
|
|
69
|
-
same_file_rebase_succeeds: sameFileSuccess.rebase.ok === true && sameFileSuccess.rebase.rebase_attempt_count === 2 && sameFileSuccess.rebase.succeeded_entry_ids.length === 2,
|
|
70
|
-
same_file_rollback_dry_run_recorded: sameFileSuccess.rebase.apply_results.every((row) => row.rollback_dry_run?.ok === true),
|
|
71
|
-
proof_accepts_successful_rebase: proof.conflict_rebase_ok === true && proof.ok === true,
|
|
72
|
-
unreconcilable_blocks: unreconcilable.rebase.ok === false && textOf(unreconcilable.rebase).includes('search_not_found'),
|
|
73
|
-
subtree_blocks_without_throwing: subtree.rebase.ok === false && textOf(subtree.rebase).includes('serial_rebase_exception'),
|
|
74
|
-
domain_blocks_by_default: domainBlocked.rebase.ok === false && domainBlocked.rebase.blocked_entry_ids.length === 2,
|
|
75
|
-
domain_retry_can_succeed_when_allowed: domainRetry.rebase.ok === true && domainRetry.rebase.succeeded_entry_ids.length === 2,
|
|
76
|
-
protected_path_blocks: protectedPath.rebase.ok === false && textOf(protectedPath.rebase).includes('protected_path'),
|
|
77
|
-
unleased_path_blocks: unleased.rebase.ok === false && textOf(unleased.rebase).includes('lease_path_not_allowed'),
|
|
78
|
-
dirty_unrelated_change_blocks: dirty.rebase.ok === false && textOf(dirty.rebase).includes('dirty_unrelated_change'),
|
|
79
|
-
stale_context_rebases: stale.rebase.ok === true && stale.rebase.succeeded_entry_ids.length === 1,
|
|
80
|
-
fixtures_produce_conflict_graphs: [sameFileSuccess, unreconcilable, subtree, domainBlocked, domainRetry, protectedPath, unleased].every((fixture) => fixture.merge.conflict_graph?.edges?.length >= 1),
|
|
81
|
-
fixtures_produce_serial_groups: [sameFileSuccess, unreconcilable, subtree, domainBlocked, domainRetry, protectedPath, unleased, dirty, stale].every((fixture) => fixture.merge.serial_merge_groups?.length >= 1),
|
|
82
|
-
fixtures_produce_rebase_artifacts: [sameFileSuccess, unreconcilable, subtree, domainBlocked, domainRetry, protectedPath, unleased, dirty, stale].every((fixture) => fs.existsSync(path.join(fixture.dir, 'agent-patch-conflict-rebase-results.json')))
|
|
83
|
-
};
|
|
84
|
-
const report = {
|
|
85
|
-
schema: 'sks.agent-patch-conflict-rebase-check.v1',
|
|
86
|
-
ok: Object.values(checks).every(Boolean),
|
|
87
|
-
checks,
|
|
88
|
-
proof,
|
|
89
|
-
fixtures: {
|
|
90
|
-
sameFileSuccess,
|
|
91
|
-
unreconcilable,
|
|
92
|
-
subtree,
|
|
93
|
-
domainBlocked,
|
|
94
|
-
domainRetry,
|
|
95
|
-
protectedPath,
|
|
96
|
-
unleased,
|
|
97
|
-
dirty,
|
|
98
|
-
stale
|
|
99
|
-
}
|
|
100
|
-
};
|
|
101
|
-
writeReport('agent-patch-conflict-rebase', report);
|
|
102
|
-
for (const [name, ok] of Object.entries(checks)) {
|
|
103
|
-
assertGate(ok === true, `conflict rebase fixture failed: ${name}`, report);
|
|
104
|
-
}
|
|
105
|
-
emitGate('agent:patch-conflict-rebase', { rebase_attempt_count: sameFileSuccess.rebase.rebase_attempt_count, fixture_count: Object.keys(report.fixtures).length });
|
|
106
|
-
async function buildProofForSuccessfulRebase(fixture) {
|
|
107
|
-
const journal = new journalMod.AgentPatchTransactionJournal(fixture.dir);
|
|
108
|
-
for (const id of fixture.rebase.succeeded_entry_ids) {
|
|
109
|
-
const applyResult = fixture.rebase.apply_results.find((row) => row.entry_id === id);
|
|
110
|
-
await fixture.store.markApplying(id);
|
|
111
|
-
await fixture.store.markApplied(id);
|
|
112
|
-
await journal.append({ event_type: 'verification_started', entry_id: id, agent_id: applyResult?.agent_id || null, lease_id: applyResult?.lease_id || null, status: 'started', changed_files: applyResult?.changed_files || [], rollback_digest: applyResult?.rollback_digest || null });
|
|
113
|
-
await journal.append({ event_type: 'verification_finished', entry_id: id, agent_id: applyResult?.agent_id || null, lease_id: applyResult?.lease_id || null, status: 'verified', verification_status: applyResult?.verification?.status || 'verified', changed_files: applyResult?.changed_files || [], rollback_digest: applyResult?.rollback_digest || null });
|
|
114
|
-
await fixture.store.markVerified(id);
|
|
115
|
-
}
|
|
116
|
-
const journalSummary = await journal.writeSummary();
|
|
117
|
-
return proofMod.buildAgentPatchProof({
|
|
118
|
-
queue: fixture.store.queue.toJSON(),
|
|
119
|
-
merge: { ...fixture.merge, ok: true, blockers: [], unresolved_conflict_entry_ids: [] },
|
|
120
|
-
applyResults: fixture.rebase.apply_results,
|
|
121
|
-
verification: ['verified'],
|
|
122
|
-
parallelWritePolicy: { write_mode: 'serial' },
|
|
123
|
-
transactionJournal: journalSummary,
|
|
124
|
-
conflictRebase: fixture.rebase
|
|
125
|
-
});
|
|
126
|
-
}
|
|
127
|
-
async function runFixture(name, input) {
|
|
128
|
-
const dir = fs.mkdtempSync(path.join(os.tmpdir(), `sks-conflict-rebase-${name}-`));
|
|
129
|
-
writeFiles(dir, input.files || {});
|
|
130
|
-
const store = new queueMod.PersistentAgentPatchQueueStore(dir);
|
|
131
|
-
const entries = [];
|
|
132
|
-
for (const envelope of input.envelopes)
|
|
133
|
-
entries.push(await store.enqueue(envelope, { mission_id: `M-${name}`, route: '$Agent' }));
|
|
134
|
-
const merge = input.mergeFactory ? input.mergeFactory(entries) : mergeMod.coordinateAgentPatchMerge(entries);
|
|
135
|
-
const rebase = await rebaseMod.executeAgentPatchConflictRebase(dir, entries, merge, { artifactsDir: dir, ...(input.rebaseOptions || {}) });
|
|
136
|
-
return { name, dir, store, merge, rebase };
|
|
137
|
-
}
|
|
138
|
-
function makeEnvelope(agent, operations, extraLease = {}) {
|
|
139
|
-
const allowedPaths = extraLease.allowed_paths || operations.map((operation) => operation.path);
|
|
140
|
-
return {
|
|
141
|
-
schema: 'sks.agent-patch-envelope.v1',
|
|
142
|
-
agent_id: agent,
|
|
143
|
-
session_id: `session-${agent}`,
|
|
144
|
-
slot_id: `slot-${agent}`,
|
|
145
|
-
generation_index: 1,
|
|
146
|
-
lease_id: `lease-${agent}`,
|
|
147
|
-
lease_proof: {
|
|
148
|
-
lease_id: `lease-${agent}`,
|
|
149
|
-
owner_agent: agent,
|
|
150
|
-
owner_persona: 'fixture',
|
|
151
|
-
allowed_paths: allowedPaths,
|
|
152
|
-
strategy_task_id: `task-${agent}`,
|
|
153
|
-
micro_win_id: `win-${agent}`,
|
|
154
|
-
verification_node_id: `verify-${agent}`,
|
|
155
|
-
rollback_node_id: `rollback-${agent}`,
|
|
156
|
-
protected_path_check: 'passed',
|
|
157
|
-
...extraLease
|
|
158
|
-
},
|
|
159
|
-
verification_hint: { node_id: `verify-${agent}` },
|
|
160
|
-
rollback_hint: { node_id: `rollback-${agent}` },
|
|
161
|
-
operations
|
|
162
|
-
};
|
|
163
|
-
}
|
|
164
|
-
function writeOp(file, content) {
|
|
165
|
-
return { op: 'write', path: file, content };
|
|
166
|
-
}
|
|
167
|
-
function replaceOp(file, search, replace) {
|
|
168
|
-
return { op: 'replace', path: file, search, replace };
|
|
169
|
-
}
|
|
170
|
-
function manualMerge(entries, reason, file) {
|
|
171
|
-
return {
|
|
172
|
-
schema: 'sks.agent-merge-coordinator.v1',
|
|
173
|
-
ok: false,
|
|
174
|
-
merge_order: entries.map((entry) => entry.agent_id),
|
|
175
|
-
apply_order: ['serial-001'],
|
|
176
|
-
touched_files: [file],
|
|
177
|
-
conflicts: [{ type: 'manual-fixture', file, entries: entries.map((entry) => entry.id), agents: entries.map((entry) => entry.agent_id), reason }],
|
|
178
|
-
conflict_graph: {
|
|
179
|
-
nodes: entries.map((entry) => ({ entry_id: entry.id, agent_id: entry.agent_id, lease_id: entry.lease_id })),
|
|
180
|
-
edges: [{ file, entries: entries.map((entry) => entry.id), reason }]
|
|
181
|
-
},
|
|
182
|
-
parallel_apply_groups: [],
|
|
183
|
-
serial_merge_groups: [{ group_id: 'serial-001', entry_ids: entries.map((entry) => entry.id), agents: entries.map((entry) => entry.agent_id), reason, file }],
|
|
184
|
-
blocked_conflicts: [{ type: 'manual-fixture', file, entries: entries.map((entry) => entry.id), agents: entries.map((entry) => entry.agent_id), reason }],
|
|
185
|
-
blockers: [reason]
|
|
186
|
-
};
|
|
187
|
-
}
|
|
188
|
-
function writeFiles(root, files) {
|
|
189
|
-
for (const [rel, content] of Object.entries(files)) {
|
|
190
|
-
const file = path.join(root, rel);
|
|
191
|
-
fs.mkdirSync(path.dirname(file), { recursive: true });
|
|
192
|
-
fs.writeFileSync(file, content);
|
|
193
|
-
}
|
|
194
|
-
}
|
|
195
|
-
function textOf(value) {
|
|
196
|
-
return JSON.stringify(value);
|
|
197
|
-
}
|
|
198
|
-
//# sourceMappingURL=agent-patch-conflict-rebase-check.js.map
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import { assertGate, emitGate, importDist } from './sks-1-18-gate-lib.js';
|
|
4
|
-
import { writeReport } from './agent-patch-swarm-gate-lib.js';
|
|
5
|
-
const fake = await importDist('core/agents/agent-runner-fake.js');
|
|
6
|
-
const schema = await importDist('core/agents/agent-patch-schema.js');
|
|
7
|
-
const result = await fake.runFakeAgent({ id: 'agent-a', session_id: 'session-a', slot_id: 'slot-a', generation_index: 1, persona_id: 'implementer' }, { id: 'slice-a', write_paths: ['fixture-a.txt'], micro_win_id: 'micro-win-a' }, { missionId: 'mission-a', route: '$Agent' });
|
|
8
|
-
const envelope = result.patch_envelopes?.[0];
|
|
9
|
-
const validation = envelope ? schema.validateAgentPatchEnvelope(envelope) : { ok: false, violations: ['missing_envelope'] };
|
|
10
|
-
const report = { schema: 'sks.agent-patch-envelope-extraction-check.v1', ok: validation.ok, result, envelope, validation };
|
|
11
|
-
writeReport('agent-patch-envelope-extraction', report);
|
|
12
|
-
assertGate(Array.isArray(result.patch_envelopes) && result.patch_envelopes.length === 1, 'fake agent must emit one patch envelope for a write slice', report);
|
|
13
|
-
assertGate(validation.ok === true, 'emitted patch envelope must validate', report);
|
|
14
|
-
assertGate(envelope.session_id && envelope.slot_id && Number.isFinite(envelope.generation_index), 'patch envelope must include session/slot/generation metadata', report);
|
|
15
|
-
assertGate(envelope.lease_id || envelope.lease_proof?.lease_id, 'patch envelope must include a lease id', report);
|
|
16
|
-
emitGate('agent:patch-envelope-extraction', { envelope_count: result.patch_envelopes.length });
|
|
17
|
-
//# sourceMappingURL=agent-patch-envelope-extraction-check.js.map
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import fs from 'node:fs';
|
|
4
|
-
import path from 'node:path';
|
|
5
|
-
import { assertGate, emitGate, importDist, root } from './sks-1-18-gate-lib.js';
|
|
6
|
-
const proofMod = await importDist('core/agents/agent-patch-proof.js');
|
|
7
|
-
const proof = proofMod.buildAgentPatchProof({
|
|
8
|
-
queue: {
|
|
9
|
-
queued_count: 0,
|
|
10
|
-
entries: [
|
|
11
|
-
{ id: 'entry-a', status: 'applied', violations: [] },
|
|
12
|
-
{ id: 'entry-b', status: 'applied', violations: [] }
|
|
13
|
-
],
|
|
14
|
-
events: [
|
|
15
|
-
{ entry_id: 'entry-a', event_type: 'applied' },
|
|
16
|
-
{ entry_id: 'entry-b', event_type: 'applied' }
|
|
17
|
-
]
|
|
18
|
-
},
|
|
19
|
-
merge: { ok: true, blockers: [] },
|
|
20
|
-
applyResults: [
|
|
21
|
-
{ ok: true, changed_files: ['a.txt'], rollback_digest: 'digest-a', verification: { status: 'unit-fixture' } },
|
|
22
|
-
{ ok: true, changed_files: ['b.txt'], rollback_digest: 'digest-b', verification: { status: 'unit-fixture' } }
|
|
23
|
-
],
|
|
24
|
-
verification: ['unit-fixture'],
|
|
25
|
-
transactionJournal: { ok: true, blockers: [], event_count: 10 },
|
|
26
|
-
conflictRebase: { ok: true, blockers: [] }
|
|
27
|
-
});
|
|
28
|
-
const pendingProof = proofMod.buildAgentPatchProof({
|
|
29
|
-
queue: { queued_count: 1, entries: [{ id: 'entry-pending', status: 'pending', violations: [] }] },
|
|
30
|
-
merge: { ok: true, blockers: [] },
|
|
31
|
-
applyResults: []
|
|
32
|
-
});
|
|
33
|
-
const report = { schema: 'sks.agent-patch-proof-check.v1', ok: proof.ok, proof };
|
|
34
|
-
const out = path.join(root, '.sneakoscope', 'reports', 'agent-patch-proof.json');
|
|
35
|
-
fs.mkdirSync(path.dirname(out), { recursive: true });
|
|
36
|
-
fs.writeFileSync(out, `${JSON.stringify(report, null, 2)}\n`);
|
|
37
|
-
assertGate(proof.ok === true, 'agent patch proof should pass clean apply results', report);
|
|
38
|
-
assertGate(proof.rollback_digests.length === 2, 'agent patch proof must preserve rollback digests', report);
|
|
39
|
-
assertGate(pendingProof.ok === false, 'agent patch proof must block pending queue entries', { pendingProof });
|
|
40
|
-
emitGate('agent:patch-proof', { rollback_digests: proof.rollback_digests.length });
|
|
41
|
-
//# sourceMappingURL=agent-patch-proof-check.js.map
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
// @ts-nocheck
|
|
3
|
-
import fs from 'node:fs';
|
|
4
|
-
import path from 'node:path';
|
|
5
|
-
import { assertGate, emitGate, importDist } from './sks-1-18-gate-lib.js';
|
|
6
|
-
import { makeTempPatchProject, writeReport } from './agent-patch-swarm-gate-lib.js';
|
|
7
|
-
const queueMod = await importDist('core/agents/agent-patch-queue.js');
|
|
8
|
-
const mergeMod = await importDist('core/agents/agent-merge-coordinator.js');
|
|
9
|
-
const applyMod = await importDist('core/agents/agent-patch-apply-worker.js');
|
|
10
|
-
const proofMod = await importDist('core/agents/agent-patch-proof.js');
|
|
11
|
-
const tmp = makeTempPatchProject('sks-patch-proof-');
|
|
12
|
-
const queue = new queueMod.InMemoryAgentPatchQueue();
|
|
13
|
-
for (let index = 1; index <= 5; index += 1) {
|
|
14
|
-
queue.enqueue({
|
|
15
|
-
schema: 'sks.agent-patch-envelope.v1',
|
|
16
|
-
agent_id: `agent-${index}`,
|
|
17
|
-
session_id: `session-${index}`,
|
|
18
|
-
slot_id: `slot-${index}`,
|
|
19
|
-
generation_index: 1,
|
|
20
|
-
lease_id: `lease-${index}`,
|
|
21
|
-
lease_proof: { lease_id: `lease-${index}`, allowed_paths: [`file-${index}.txt`], strategy_task_id: `task-${index}`, owner_agent: `agent-${index}`, verification_node_id: `verify-${index}`, rollback_node_id: `rollback-${index}` },
|
|
22
|
-
rollback_hint: { node_id: `rollback-${index}` },
|
|
23
|
-
operations: [{ op: 'write', path: `file-${index}.txt`, content: `after-${index}\n` }]
|
|
24
|
-
});
|
|
25
|
-
}
|
|
26
|
-
const merge = mergeMod.coordinateAgentPatchMerge(queue.queued());
|
|
27
|
-
const applyResults = [];
|
|
28
|
-
for (const entry of queue.queued()) {
|
|
29
|
-
const applied = await applyMod.applyAgentPatchEnvelope(tmp, entry.envelope, { entryId: entry.id });
|
|
30
|
-
applyResults.push(applied);
|
|
31
|
-
if (applied.ok)
|
|
32
|
-
queue.markApplied(entry.id);
|
|
33
|
-
}
|
|
34
|
-
for (const entry of queue.entries)
|
|
35
|
-
queue.markVerified(entry.id);
|
|
36
|
-
const verificationRollbackDag = {
|
|
37
|
-
nodes: queue.entries.flatMap((entry, index) => [
|
|
38
|
-
{ id: `verify-${index + 1}`, kind: 'verification' },
|
|
39
|
-
{ id: `rollback-${index + 1}`, kind: 'rollback' }
|
|
40
|
-
])
|
|
41
|
-
};
|
|
42
|
-
const fileOwnershipPlan = {
|
|
43
|
-
owners: queue.entries.flatMap((entry, index) => (entry.write_paths || []).map((file) => ({ path: file, access: 'write', owner_agent: `agent-${index + 1}` })))
|
|
44
|
-
};
|
|
45
|
-
const proof = proofMod.buildAgentPatchProof({
|
|
46
|
-
queue: queue.toJSON(),
|
|
47
|
-
merge,
|
|
48
|
-
applyResults,
|
|
49
|
-
verification: applyResults.map((row) => row.verification.status),
|
|
50
|
-
parallelWritePolicy: { write_mode: 'parallel' },
|
|
51
|
-
verificationRollbackDag,
|
|
52
|
-
fileOwnershipPlan,
|
|
53
|
-
transactionJournal: { ok: true, blockers: [], event_count: 25 },
|
|
54
|
-
conflictRebase: { ok: true, blockers: [] }
|
|
55
|
-
});
|
|
56
|
-
const report = { schema: 'sks.agent-patch-proof-runtime-check.v1', ok: proof.ok, tmp, queue: queue.toJSON(), merge, applyResults, proof };
|
|
57
|
-
writeReport('agent-patch-proof-runtime', report);
|
|
58
|
-
assertGate(proof.ok === true, 'patch proof runtime must pass for verified disjoint patches', report);
|
|
59
|
-
assertGate(proof.patch_queue_ok === true && proof.patch_apply_ok === true && proof.patch_verification_ok === true && proof.patch_rollback_ok === true, 'patch proof booleans must all pass', report);
|
|
60
|
-
assertGate(proof.parallel_patch_apply_verified === true, 'patch proof must record parallel apply group evidence', report);
|
|
61
|
-
assertGate(fs.readFileSync(path.join(tmp, 'file-1.txt'), 'utf8') === 'after-1\n', 'patch must be applied to fixture file', report);
|
|
62
|
-
emitGate('agent:patch-proof-runtime', { changed_files: proof.changed_files.length });
|
|
63
|
-
//# sourceMappingURL=agent-patch-proof-runtime-check.js.map
|