@sema-agent/core 7.54.1 → 7.55.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +437 -0
- package/dist/agents/agent-transcript-tool.js +2 -1
- package/dist/agents/builtin-agents.d.ts +12 -14
- package/dist/agents/cc-peer-directory.d.ts +36 -0
- package/dist/agents/cc-peer-directory.js +138 -0
- package/dist/agents/cc-peer-wire.d.ts +105 -0
- package/dist/agents/cc-peer-wire.js +98 -0
- package/dist/agents/cc-uds-peer-channel.d.ts +40 -0
- package/dist/agents/cc-uds-peer-channel.js +457 -0
- package/dist/agents/cross-session-envelope.d.ts +4 -1
- package/dist/agents/cross-session-envelope.js +8 -1
- package/dist/agents/cross-session-judge.d.ts +2 -2
- package/dist/agents/list-agents-tool.js +2 -1
- package/dist/agents/observer.d.ts +4 -5
- package/dist/agents/observer.js +2 -1
- package/dist/agents/peer-admission.d.ts +6 -0
- package/dist/agents/peer-admission.js +4 -1
- package/dist/agents/peer-directory.d.ts +43 -9
- package/dist/agents/peer-directory.js +66 -23
- package/dist/agents/peer-notices.d.ts +1 -1
- package/dist/agents/peer-session-drain.d.ts +3 -1
- package/dist/agents/peer-session-drain.js +1 -0
- package/dist/agents/read-inbox-tool.js +2 -1
- package/dist/agents/retain-ledger.d.ts +1 -1
- package/dist/agents/roster-store.d.ts +1 -1
- package/dist/agents/send-message-tool.d.ts +10 -0
- package/dist/agents/send-message-tool.js +34 -5
- package/dist/agents/subagent.d.ts +34 -79
- package/dist/agents/subagent.js +45 -46
- package/dist/agents/tool-filter.d.ts +29 -46
- package/dist/agents/tool-filter.js +8 -31
- package/dist/agents/verify.d.ts +3 -3
- package/dist/brain/anthropic.js +14 -9
- package/dist/brain/errors.d.ts +15 -0
- package/dist/brain/errors.js +10 -0
- package/dist/brain/model-presets.d.ts +4 -4
- package/dist/brain/open-responses.js +15 -10
- package/dist/brain/openai.js +17 -12
- package/dist/brain/provider-dialect.d.ts +39 -3
- package/dist/brain/provider-dialect.js +28 -0
- package/dist/brain/reasoning.d.ts +1 -1
- package/dist/brain/request-params.d.ts +55 -5
- package/dist/brain/request-params.js +35 -3
- package/dist/brain/retry.d.ts +1 -1
- package/dist/brain/route-adjudicator.d.ts +15 -0
- package/dist/brain/route-adjudicator.js +15 -0
- package/dist/brain/stream-engine.js +6 -5
- package/dist/brain/stream-shared.d.ts +1 -1
- package/dist/core/advisor-verdict.d.ts +120 -0
- package/dist/core/advisor-verdict.js +92 -0
- package/dist/core/agent-definition.d.ts +7 -8
- package/dist/core/allow-entry.d.ts +49 -23
- package/dist/core/allow-entry.js +57 -32
- package/dist/core/allow-rule-shadow.d.ts +7 -0
- package/dist/core/approval-object.d.ts +2 -1
- package/dist/core/approval-object.js +6 -6
- package/dist/core/ask-origin.d.ts +63 -11
- package/dist/core/ask-origin.js +27 -5
- package/dist/core/ask-question.js +10 -4
- package/dist/core/auto-compaction.d.ts +11 -8
- package/dist/core/auto-compaction.js +4 -2
- package/dist/core/auto-mode-arming.d.ts +2 -2
- package/dist/core/auto-mode-defaults.d.ts +8 -8
- package/dist/core/auto-mode-prompt-assets.d.ts +3 -3
- package/dist/core/auto-mode-prompt.d.ts +1 -1
- package/dist/core/auto-mode.d.ts +17 -9
- package/dist/core/auto-mode.js +9 -6
- package/dist/core/background-agent-store.d.ts +3 -3
- package/dist/core/canonical-json.d.ts +1 -1
- package/dist/core/canonical-json.js +2 -2
- package/dist/core/checkpoint-requirements.d.ts +6 -3
- package/dist/core/checkpoint-requirements.js +4 -14
- package/dist/core/checkpoint-store.d.ts +80 -51
- package/dist/core/checkpoint-store.js +56 -74
- package/dist/core/child-clamp-seats.d.ts +6 -0
- package/dist/core/child-clamp-seats.js +3 -16
- package/dist/core/compliance.d.ts +2 -2
- package/dist/core/context-edit.d.ts +6 -7
- package/dist/core/cross-boundary-taint.d.ts +9 -3
- package/dist/core/cross-boundary-taint.js +5 -3
- package/dist/core/decision-receipt.js +2 -2
- package/dist/core/effective-path-target.d.ts +1 -1
- package/dist/core/engine-notice.d.ts +19 -5
- package/dist/core/exec-output-tail.d.ts +1 -1
- package/dist/core/file-history-retention.d.ts +1 -1
- package/dist/core/file-history-store.d.ts +59 -9
- package/dist/core/file-history-store.js +35 -17
- package/dist/core/gate-fold.js +3 -2
- package/dist/core/gate-lanes.js +12 -8
- package/dist/core/gate-outcome.d.ts +17 -4
- package/dist/core/gate-outcome.js +30 -0
- package/dist/core/governance-codes.d.ts +13 -3
- package/dist/core/governance-codes.js +10 -0
- package/dist/core/hands-band.d.ts +1 -1
- package/dist/core/hooks.d.ts +4 -4
- package/dist/core/host-target.d.ts +49 -0
- package/dist/core/host-target.js +59 -0
- package/dist/core/image-downsample.d.ts +1 -1
- package/dist/core/lsp-diagnostics.d.ts +4 -4
- package/dist/core/lsp.d.ts +3 -3
- package/dist/core/mailbox-store.d.ts +4 -0
- package/dist/core/mcp-connection-pool.d.ts +18 -2
- package/dist/core/mcp-connection-pool.js +53 -6
- package/dist/core/mcp-failure.d.ts +23 -4
- package/dist/core/mcp-failure.js +26 -11
- package/dist/core/mcp-listing-drift.d.ts +10 -0
- package/dist/core/mcp-listing-drift.js +6 -0
- package/dist/core/mcp-server-link.d.ts +173 -0
- package/dist/core/mcp-server-link.js +127 -0
- package/dist/core/mcp-server-spec.d.ts +4 -2
- package/dist/core/mcp-session-end.d.ts +26 -0
- package/dist/core/mcp-session-end.js +29 -0
- package/dist/core/mcp-startup-request.d.ts +17 -0
- package/dist/core/mcp-startup-request.js +17 -0
- package/dist/core/mcp.d.ts +13 -13
- package/dist/core/mcp.js +187 -162
- package/dist/core/media-byte-cap.d.ts +1 -1
- package/dist/core/memory-engine/engine.d.ts +9 -9
- package/dist/core/memory-engine/provenance-wording.d.ts +1 -1
- package/dist/core/memory-engine/tools.js +4 -1
- package/dist/core/mode-policy.d.ts +1 -1
- package/dist/core/namespaced-rule-name.d.ts +33 -7
- package/dist/core/namespaced-rule-name.js +39 -25
- package/dist/core/output-style.d.ts +1 -1
- package/dist/core/param-rule-reach.d.ts +15 -0
- package/dist/core/param-rule-reach.js +30 -0
- package/dist/core/parent-spec-seat.d.ts +8 -1
- package/dist/core/parent-spec-seat.js +4 -0
- package/dist/core/pause-registry.d.ts +16 -5
- package/dist/core/pause-registry.js +6 -2
- package/dist/core/peer-channel.d.ts +70 -0
- package/dist/core/peer-channel.js +1 -0
- package/dist/core/permission-rule-consent.d.ts +11 -5
- package/dist/core/permission-rule-consent.js +37 -30
- package/dist/core/permission-rule-model.d.ts +233 -64
- package/dist/core/permission-rule-model.js +384 -85
- package/dist/core/permission-rule-provider.d.ts +2 -1
- package/dist/core/permission-rule-store.d.ts +20 -25
- package/dist/core/permission-rule-store.js +1 -4
- package/dist/core/permission-rule-sync.d.ts +11 -2
- package/dist/core/permission-rule-sync.js +8 -1
- package/dist/core/permission-rules.d.ts +49 -11
- package/dist/core/permission-rules.js +123 -89
- package/dist/core/persisted-rule-arms.d.ts +4 -2
- package/dist/core/present-plan-tool.js +3 -1
- package/dist/core/protocol-naming.d.ts +2 -2
- package/dist/core/read-only-shell-table.d.ts +1 -1
- package/dist/core/read-only-shell.d.ts +1 -1
- package/dist/core/roles.d.ts +6 -2
- package/dist/core/roles.js +45 -44
- package/dist/core/rule-offer-read.d.ts +53 -0
- package/dist/core/rule-offer-read.js +146 -0
- package/dist/core/rule-owner.d.ts +46 -0
- package/dist/core/rule-owner.js +28 -0
- package/dist/core/runner/advisor-instructions.d.ts +70 -0
- package/dist/core/runner/advisor-instructions.js +61 -0
- package/dist/core/runner/advisor-tool.d.ts +33 -0
- package/dist/core/runner/advisor-tool.js +112 -0
- package/dist/core/runner/announce-once-ledger.d.ts +4 -26
- package/dist/core/runner/announce-once-ledger.js +14 -46
- package/dist/core/runner/approval-feedback.js +6 -3
- package/dist/core/runner/assemble-result.d.ts +1 -1
- package/dist/core/runner/caller-roster.d.ts +7 -0
- package/dist/core/runner/caller-roster.js +11 -0
- package/dist/core/runner/classifier-ladder.d.ts +27 -5
- package/dist/core/runner/classifier-ladder.js +12 -11
- package/dist/core/runner/compaction-restate.d.ts +10 -6
- package/dist/core/runner/compaction-restate.js +9 -3
- package/dist/core/runner/contracts.d.ts +13 -9
- package/dist/core/runner/conversation-segment.d.ts +28 -0
- package/dist/core/runner/conversation-segment.js +42 -0
- package/dist/core/runner/cross-boundary-lane.d.ts +6 -5
- package/dist/core/runner/cross-boundary-lane.js +26 -15
- package/dist/core/runner/decide-continuation.d.ts +7 -4
- package/dist/core/runner/decide-continuation.js +2 -2
- package/dist/core/runner/denial-limit-arms.d.ts +2 -2
- package/dist/core/runner/derived-route-fallback.d.ts +24 -24
- package/dist/core/runner/derived-route-fallback.js +9 -7
- package/dist/core/runner/gate-exit.d.ts +6 -0
- package/dist/core/runner/gate-exit.js +7 -2
- package/dist/core/runner/initial-run-state.js +1 -1
- package/dist/core/runner/permission-rule-lanes.d.ts +2 -2
- package/dist/core/runner/permission-rule-lanes.js +14 -7
- package/dist/core/runner/person-path-rows.js +1 -1
- package/dist/core/runner/prepare-advisor.d.ts +63 -0
- package/dist/core/runner/prepare-advisor.js +77 -0
- package/dist/core/runner/prepare-caps-and-workflow.js +1 -1
- package/dist/core/runner/prepare-config-doors.d.ts +6 -4
- package/dist/core/runner/prepare-config-doors.js +18 -12
- package/dist/core/runner/prepare-delegation-surface.d.ts +2 -2
- package/dist/core/runner/prepare-delegation-surface.js +1 -1
- package/dist/core/runner/prepare-file-history.js +39 -39
- package/dist/core/runner/prepare-gate-stations.d.ts +1 -4
- package/dist/core/runner/prepare-gate-stations.js +2 -7
- package/dist/core/runner/prepare-inherited-gate.d.ts +5 -4
- package/dist/core/runner/prepare-inherited-gate.js +3 -3
- package/dist/core/runner/prepare-park-ask.js +7 -7
- package/dist/core/runner/prepare-policy-chain.d.ts +1 -1
- package/dist/core/runner/prepare-policy-chain.js +4 -10
- package/dist/core/runner/prepare-project-context.d.ts +5 -2
- package/dist/core/runner/prepare-project-context.js +6 -3
- package/dist/core/runner/prepare-prompt-inputs.js +1 -1
- package/dist/core/runner/prepare-protocol-tools.d.ts +2 -2
- package/dist/core/runner/prepare-protocol-tools.js +3 -2
- package/dist/core/runner/prepare-safety-scan.d.ts +9 -12
- package/dist/core/runner/prepare-safety-scan.js +8 -6
- package/dist/core/runner/prepare-task.js +15 -18
- package/dist/core/runner/prepare-tool-disclosure-mount.js +6 -4
- package/dist/core/runner/prepare-wiring-manifest.d.ts +6 -3
- package/dist/core/runner/prepare-wiring-manifest.js +2 -2
- package/dist/core/runner/resume-policy-outcome.js +1 -1
- package/dist/core/runner/retired-runner-deps.js +1 -1
- package/dist/core/runner/run-attachment-seats.js +0 -1
- package/dist/core/runner/run-compaction-machinery.d.ts +1 -1
- package/dist/core/runner/run-compaction-machinery.js +2 -12
- package/dist/core/runner/run-git-lane.d.ts +1 -0
- package/dist/core/runner/run-harness-handlers.js +2 -3
- package/dist/core/runner/run-leg.js +13 -0
- package/dist/core/runner/run-settle-and-teardown.js +1 -1
- package/dist/core/runner/run-telemetry-and-budget-seats.js +1 -1
- package/dist/core/runner/run-turn-boundary.d.ts +1 -0
- package/dist/core/runner/run-turn-boundary.js +14 -12
- package/dist/core/runner/session-rule-policy.d.ts +22 -21
- package/dist/core/runner/session-rule-policy.js +13 -28
- package/dist/core/runner/side-call-account.d.ts +32 -8
- package/dist/core/runner/side-call-account.js +23 -1
- package/dist/core/runner/strict-output-schema.d.ts +1 -1
- package/dist/core/runner/sub-agent-deny-lists.js +4 -3
- package/dist/core/runner/synthetic-tools.d.ts +10 -13
- package/dist/core/runner/synthetic-tools.js +4 -2
- package/dist/core/runner/tool-disclosure.js +2 -1
- package/dist/core/runner/tool-face-overlay.d.ts +2 -1
- package/dist/core/runner/tool-face-overlay.js +17 -1
- package/dist/core/runner/tool-progress-lane.d.ts +2 -2
- package/dist/core/runner/tool-turn-repair-seat.d.ts +3 -2
- package/dist/core/runner/turn-attachments.d.ts +60 -67
- package/dist/core/runner-deps.d.ts +37 -37
- package/dist/core/runtime-caps.d.ts +4 -4
- package/dist/core/safety-merge-corpus.js +17 -1
- package/dist/core/same-plain-value.d.ts +40 -0
- package/dist/core/same-plain-value.js +49 -0
- package/dist/core/scheduler.d.ts +1 -1
- package/dist/core/sensitive-path-policy.d.ts +1 -1
- package/dist/core/sensitive-path-policy.js +1 -1
- package/dist/core/session-policy-store.d.ts +77 -22
- package/dist/core/session-policy-store.js +56 -14
- package/dist/core/session-reconcile.d.ts +2 -2
- package/dist/core/session-store.d.ts +80 -30
- package/dist/core/session-store.js +118 -76
- package/dist/core/session.d.ts +24 -46
- package/dist/core/shared-memory/tools.js +3 -1
- package/dist/core/shared-memory/types.d.ts +1 -1
- package/dist/core/side-query.d.ts +10 -0
- package/dist/core/side-query.js +5 -0
- package/dist/core/store-contracts/checkpoint-store-contract.js +29 -2
- package/dist/core/store-contracts/file-history-store-contract.js +43 -3
- package/dist/core/store-contracts/session-policy-store-contract.d.ts +7 -0
- package/dist/core/store-contracts/session-policy-store-contract.js +130 -0
- package/dist/core/store-contracts/session-repo-contract.js +125 -0
- package/dist/core/store-contracts/session-store-contract.d.ts +4 -7
- package/dist/core/store-contracts/session-store-contract.js +215 -41
- package/dist/core/store-contracts/workflow-journal-store-contract.js +26 -1
- package/dist/core/surrogate-safe-slice.d.ts +3 -3
- package/dist/core/task-event.d.ts +10 -4
- package/dist/core/task-notification.d.ts +3 -3
- package/dist/core/task-registry-agent.d.ts +4 -4
- package/dist/core/task-registry-shared.d.ts +4 -4
- package/dist/core/task-registry-shared.js +1 -0
- package/dist/core/task-registry.d.ts +4 -4
- package/dist/core/task-registry.js +3 -1
- package/dist/core/task-result.d.ts +3 -3
- package/dist/core/task-spec.d.ts +52 -52
- package/dist/core/task-stream.d.ts +6 -6
- package/dist/core/task-tool-shape.d.ts +4 -4
- package/dist/core/tighten-task-spec.d.ts +1 -1
- package/dist/core/tool-catalog-entries.d.ts +19 -2
- package/dist/core/tool-catalog-entries.js +57 -42
- package/dist/core/tool-conformance.js +1 -0
- package/dist/core/tool-errors.d.ts +2 -2
- package/dist/core/tool-face-reader.js +5 -3
- package/dist/core/tool-face.d.ts +21 -2
- package/dist/core/tool-face.js +1 -1
- package/dist/core/tool-model-gate.d.ts +3 -3
- package/dist/core/tool-name-aliases.d.ts +29 -8
- package/dist/core/tool-name-aliases.js +27 -3
- package/dist/core/tool-name-readings.d.ts +5 -8
- package/dist/core/tool-name-readings.js +1 -2
- package/dist/core/tool-policy.d.ts +24 -5
- package/dist/core/tool-policy.js +34 -10
- package/dist/core/tool-registry.d.ts +14 -7
- package/dist/core/tool-registry.js +17 -7
- package/dist/core/tool-result-store.js +2 -1
- package/dist/core/tool-roster.d.ts +47 -18
- package/dist/core/tool-roster.js +53 -32
- package/dist/core/tool-spec-members.js +1 -1
- package/dist/core/tool-spec.d.ts +35 -21
- package/dist/core/tools.js +3 -2
- package/dist/core/trace.d.ts +4 -0
- package/dist/core/untrusted-egress.d.ts +1 -1
- package/dist/core/untrusted-text.d.ts +1 -1
- package/dist/core/warm-resume.d.ts +1 -1
- package/dist/core/wiring-manifest.d.ts +49 -0
- package/dist/core/wiring-manifest.js +13 -5
- package/dist/core/workflow-journal-store.d.ts +62 -0
- package/dist/core/workflow-journal-store.js +77 -1
- package/dist/core/workflow-run-store.d.ts +6 -0
- package/dist/core/workflow-run-store.js +2 -0
- package/dist/engine/compaction/compaction.d.ts +9 -9
- package/dist/engine/execution-env/node-execution-env.d.ts +19 -5
- package/dist/engine/execution-env/node-execution-env.js +43 -22
- package/dist/engine/harness/agent-harness.d.ts +14 -8
- package/dist/engine/harness/agent-harness.js +33 -26
- package/dist/engine/harness/types.d.ts +29 -7
- package/dist/engine/harness/types.js +12 -1
- package/dist/engine/llm/types.d.ts +9 -9
- package/dist/engine/llm/validation.d.ts +4 -1
- package/dist/engine/llm/validation.js +13 -1
- package/dist/engine/loop/agent-loop.d.ts +1 -1
- package/dist/engine/loop/agent-loop.js +10 -8
- package/dist/engine/loop/types.d.ts +15 -13
- package/dist/engine/lsp/node-lsp-manager.d.ts +2 -2
- package/dist/engine/session/memory-repo.d.ts +10 -11
- package/dist/engine/session/memory-repo.js +13 -8
- package/dist/engine/session/parent-chain-guard.d.ts +3 -2
- package/dist/engine/session/parent-chain-guard.js +1 -1
- package/dist/engine/session/repo-utils.d.ts +31 -3
- package/dist/engine/session/repo-utils.js +42 -5
- package/dist/index.d.ts +27 -15
- package/dist/index.js +21 -11
- package/dist/internal/harness-types.d.ts +1 -1
- package/dist/internal/harness.d.ts +3 -3
- package/dist/internal/harness.js +2 -2
- package/dist/internal/llm.d.ts +1 -1
- package/dist/internal/llm.js +1 -1
- package/dist/orchestration/goal.js +2 -2
- package/dist/orchestration/run-workflow-tool.d.ts +2 -2
- package/dist/orchestration/run-workflow-tool.js +5 -3
- package/dist/orchestration/workflow-size-guideline.d.ts +4 -4
- package/dist/orchestration/workflow-types.d.ts +18 -0
- package/dist/orchestration/workflow-types.js +6 -0
- package/dist/orchestration/workflow.d.ts +2 -13
- package/dist/orchestration/workflow.js +21 -31
- package/dist/prompt-assembly/event-registry.js +1 -0
- package/dist/prompt-assembly/tool-catalog.d.ts +3 -0
- package/dist/prompt-assembly/tool-catalog.js +3 -0
- package/dist/prompts/default.d.ts +14 -14
- package/dist/scenarios/full-body.d.ts +4 -4
- package/dist/stores/file/adoption/adopt.d.ts +4 -3
- package/dist/stores/file/adoption/adopt.js +24 -31
- package/dist/stores/file/adoption/marker.d.ts +6 -13
- package/dist/stores/file/adoption/marker.js +6 -15
- package/dist/stores/file/checkpoint-store.d.ts +3 -0
- package/dist/stores/file/checkpoint-store.js +9 -3
- package/dist/stores/file/file-history-store.d.ts +20 -19
- package/dist/stores/file/file-history-store.js +152 -135
- package/dist/stores/file/fs-atomic.d.ts +15 -0
- package/dist/stores/file/fs-atomic.js +89 -14
- package/dist/stores/file/index.d.ts +1 -1
- package/dist/stores/file/mailbox-store.d.ts +3 -0
- package/dist/stores/file/mailbox-store.js +3 -1
- package/dist/stores/file/permission-rule-adopt.d.ts +1 -1
- package/dist/stores/file/permission-rule-adopt.js +15 -16
- package/dist/stores/file/permission-rule-store.d.ts +18 -2
- package/dist/stores/file/permission-rule-store.js +21 -14
- package/dist/stores/file/session-policy-store.d.ts +3 -3
- package/dist/stores/file/session-store.d.ts +26 -11
- package/dist/stores/file/session-store.js +77 -40
- package/dist/stores/file/workflow-journal-store.d.ts +10 -4
- package/dist/stores/file/workflow-journal-store.js +28 -13
- package/dist/tools/artifact/artifact-text.d.ts +1 -1
- package/dist/tools/artifact/artifact-tool.js +2 -1
- package/dist/tools/fs/bash-readonly-classifier.d.ts +3 -3
- package/dist/tools/fs/fs-bash.d.ts +2 -2
- package/dist/tools/fs/fs-bash.js +3 -1
- package/dist/tools/fs/fs-shared.d.ts +8 -8
- package/dist/tools/fs/gh-rate-limit.d.ts +1 -1
- package/dist/tools/fs/notebook.d.ts +2 -2
- package/dist/tools/fs/read-deny.d.ts +29 -7
- package/dist/tools/fs/read-deny.js +63 -22
- package/dist/tools/fs/removal-targets.d.ts +1 -1
- package/dist/tools/fs/safety.d.ts +9 -9
- package/dist/tools/fs/search.d.ts +6 -6
- package/dist/tools/fs/shell-read-check.js +6 -1
- package/dist/tools/fs/shell-read-judge.d.ts +4 -0
- package/dist/tools/fs/shell-read-judge.js +5 -2
- package/dist/tools/loop-tick.d.ts +2 -2
- package/dist/tools/scheduler-tools.js +5 -1
- package/dist/tools/task-list.d.ts +7 -7
- package/dist/tools/task-list.js +5 -1
- package/dist/tools/todo.js +2 -1
- package/dist/tools/web.d.ts +1 -1
- package/dist/tools/web.js +40 -37
- package/dist/tools/worktree.d.ts +3 -3
- package/dist/tools/worktree.js +3 -1
- package/package.json +1 -1
- package/test/export-surface.snapshot.json +5756 -5638
- package/wire-changes/core@7.55.0.json +3318 -0
- package/dist/core/store-contracts/session-store-incarnation-contract.d.ts +0 -39
- package/dist/core/store-contracts/session-store-incarnation-contract.js +0 -95
|
@@ -26,8 +26,9 @@ export type ToolTurnIncompleteItem = {
|
|
|
26
26
|
count: number;
|
|
27
27
|
toolCallIds: readonly string[];
|
|
28
28
|
};
|
|
29
|
-
/** Does a turn's content carry a tool call?
|
|
30
|
-
*
|
|
29
|
+
/** Does a turn's content carry a tool call? The dropped-call line's reading of "the turn goes on", taken at the message's
|
|
30
|
+
* end before its batch runs. The turn boundary does not read it: whether the turn owes the next request is the loop's
|
|
31
|
+
* own decision (a batch can end the run), handed to the boundary as `continues`. */
|
|
31
32
|
export declare function turnCarriesToolCall(content: unknown): boolean;
|
|
32
33
|
/** The person's line for one cause — once per run per cause, whichever observer saw it first. */
|
|
33
34
|
export interface ToolTurnIncompleteSeat {
|
|
@@ -14,22 +14,20 @@ import { type ResolvedSkillListingBudget } from "../skill-listing-budget.js";
|
|
|
14
14
|
* The steerer wraps each body exactly once at a single call site, so double-wrap/no-wrap can't drift
|
|
15
15
|
* per-producer.
|
|
16
16
|
*/
|
|
17
|
-
/**
|
|
17
|
+
/** Cadence constants for the todo reminder. */
|
|
18
18
|
export declare const TODO_REMINDER_CONFIG: {
|
|
19
19
|
readonly TURNS_SINCE_WRITE: 10;
|
|
20
20
|
readonly TURNS_BETWEEN_REMINDERS: 10;
|
|
21
21
|
};
|
|
22
|
-
/**
|
|
23
|
-
*
|
|
24
|
-
* `EVERY_N_TURNS` gates BOTH windows (since-last-ToolSearch and since-last-reminder, @608920);
|
|
22
|
+
/** Tool-search reminder cadence defaults.
|
|
23
|
+
* `EVERY_N_TURNS` gates BOTH windows (since-last-ToolSearch and since-last-reminder);
|
|
25
24
|
* `MAX_NAMES` bounds how many undiscovered names the body enumerates before the `(+N more)` tail. */
|
|
26
25
|
export declare const TOOL_SEARCH_REMINDER_CONFIG: {
|
|
27
26
|
readonly EVERY_N_TURNS: 15;
|
|
28
27
|
readonly MAX_NAMES: 10;
|
|
29
28
|
};
|
|
30
29
|
/**
|
|
31
|
-
* The `total_tokens_reminder` mode set
|
|
32
|
-
* (bundle `R9o`; the settings schema declares the same five for its `totalTokensReminder` key).
|
|
30
|
+
* The `total_tokens_reminder` mode set.
|
|
33
31
|
* Each arm names what the rendered number IS, per CC's own schema prose:
|
|
34
32
|
* - `off` — the lane is silent. Kept as a member rather than folded into the opt-in flag because it
|
|
35
33
|
* is the DEPLOYMENT-RESOLVED kill switch (CC resolves the mode from env
|
|
@@ -57,9 +55,9 @@ export declare const TOTAL_TOKENS_REMINDER_MODES: readonly ["off", "infinite", "
|
|
|
57
55
|
*/
|
|
58
56
|
type TaskSpecTotalTokensReminderMode = NonNullable<NonNullable<TaskSpec["attachments"]>["totalTokensReminderMode"]>;
|
|
59
57
|
export type TotalTokensReminderMode = [TaskSpecTotalTokensReminderMode] extends [(typeof TOTAL_TOKENS_REMINDER_MODES)[number]] ? (typeof TOTAL_TOKENS_REMINDER_MODES)[number] : never;
|
|
60
|
-
/**
|
|
61
|
-
*
|
|
62
|
-
*
|
|
58
|
+
/** The default mode. The 2026-07-30 registration of this lane rested on the premise that it is OFF by default;
|
|
59
|
+
* the reference flipped that default, which is the fact that reopened the ruling. Applies only ONCE the deployment has
|
|
60
|
+
* opted the lane in. */
|
|
63
61
|
export declare const TOTAL_TOKENS_REMINDER_DEFAULT_MODE: TotalTokensReminderMode;
|
|
64
62
|
/** CC's `fixed` arm constant (bundle `A9o`). A fixed anchor is the POINT of that arm (the
|
|
65
63
|
* number is meant not to move), so it is copied as the constant it is rather than re-pointed at a
|
|
@@ -215,7 +213,7 @@ export interface AttachmentState {
|
|
|
215
213
|
status: string;
|
|
216
214
|
}>;
|
|
217
215
|
/** Cadence-clock value AT the last task WRITE anchor block, INCLUSIVE (task #51 F1 block units — see
|
|
218
|
-
* {@link advanceCadenceClock}).
|
|
216
|
+
* {@link advanceCadenceClock}). 口径①: the reference's counter resets ONLY on a
|
|
219
217
|
* TaskCreate/TaskUpdate tool_use (`a.name === bD || a.name === hF`) — a TaskGet/TaskList READ is NOT
|
|
220
218
|
* engagement and leaves the 10-unit window running. F3: stamped on tool-call INITIATION (the tool_use
|
|
221
219
|
* block existing in the transcript IS CC's anchor — qFm never checks execution outcome, so a failed or
|
|
@@ -226,13 +224,13 @@ export interface AttachmentState {
|
|
|
226
224
|
todoLastWriteTurn?: number;
|
|
227
225
|
lastTodoReminderTurn: number;
|
|
228
226
|
lastTaskReminderTurn: number;
|
|
229
|
-
/** Cadence-clock value at the last `ToolSearch` tool_use block (
|
|
227
|
+
/** Cadence-clock value at the last `ToolSearch` tool_use block (the reference
|
|
230
228
|
* finds it by BACKWARD transcript scan: `turnsSinceLastToolSearch`). Same INITIATION-anchor semantics
|
|
231
229
|
* as {@link taskLastWriteTurn} — the block existing in the transcript is the anchor, no outcome check.
|
|
232
230
|
* `undefined` = never used this leg, which is the state the reminder exists for (220's scan returns the
|
|
233
231
|
* full transcript length there). */
|
|
234
232
|
toolSearchLastUseTurn?: number;
|
|
235
|
-
/** Cadence-clock value at the last tool_search_usage_reminder emitted (
|
|
233
|
+
/** Cadence-clock value at the last tool_search_usage_reminder emitted (the reference's
|
|
236
234
|
* `turnsSinceLastReminder`, found by scanning back for the attachment entry itself). */
|
|
237
235
|
lastToolSearchReminderTurn: number;
|
|
238
236
|
/** changed_files per-path dedup: the last mtime already surfaced for a path — the same (path, mtime)
|
|
@@ -357,7 +355,7 @@ export type WriteFamily = "todo" | "task" | "tool_search";
|
|
|
357
355
|
export declare function stampWriteAnchor(state: AttachmentState, family: WriteFamily, clock: number): void;
|
|
358
356
|
/**
|
|
359
357
|
* 口径④ cadence clock, task #51 F1 (verified against observed CC behavior) — CC's cadence unit is the
|
|
360
|
-
* per-content-block assistant TRANSCRIPT ENTRY, not the physical turn.
|
|
358
|
+
* per-content-block assistant TRANSCRIPT ENTRY, not the physical turn. The reference mints ONE
|
|
361
359
|
* `{type:"assistant"}` entry PER content block: the streaming layer at `content_block_stop`
|
|
362
360
|
* (pretty.js:593011-593038 — `content: pnn([Pr],…)` single-block array, `rn.push` per block) and the
|
|
363
361
|
* `tgf` normalizer (:597284 — `content.map` → one single-block entry each). The reminder counters
|
|
@@ -365,7 +363,7 @@ export declare function stampWriteAnchor(state: AttachmentState, family: WriteFa
|
|
|
365
363
|
* (:599513-599517) applied to a single-block entry degenerates to "is this block thinking/
|
|
366
364
|
* redacted_thinking" — so the 10/10 windows consume ONE unit per NON-THINKING CONTENT BLOCK. A
|
|
367
365
|
* `[text, tool_use]` turn costs 2 units, a parallel-k tool batch costs k(+lead) — live probe
|
|
368
|
-
* (bench/probes/task51-cadence-live, real
|
|
366
|
+
* (bench/probes/task51-cadence-live, real reference client + stub API): `[text, tool_use]×N` fires the
|
|
369
367
|
* task_reminder at request #7, block-exact, where a turn-level clock predicts #11-12.
|
|
370
368
|
*
|
|
371
369
|
* Applied by the run loop once per completed assistant MESSAGE; returns the advanced clock. CC edge
|
|
@@ -414,12 +412,11 @@ export interface AttachmentInputs {
|
|
|
414
412
|
/**
|
|
415
413
|
* The output-style frame's body, rendered once at prepare from `TaskSpec.outputStyle` (output-style.ts);
|
|
416
414
|
* present ⇒ the frame is due at this boundary. The reference implementation's producer has no window: it
|
|
417
|
-
* attaches at every attachment cycle while a non-default style is active, so the run loop passes it at every
|
|
418
|
-
*
|
|
415
|
+
* attaches at every attachment cycle while a non-default style is active, so the run loop passes it at every owed
|
|
416
|
+
* boundary whose request does not already carry it (a leg's head) and this producer holds no state for it.
|
|
419
417
|
*/
|
|
420
418
|
outputStyle?: string;
|
|
421
|
-
/** SR-3 budget_usd lane
|
|
422
|
-
* with the mount at @607474): the run's cost progress against its $ ceiling, in USD. Only passed
|
|
419
|
+
/** SR-3 budget_usd lane: the run's cost progress against its $ ceiling, in USD. Only passed
|
|
423
420
|
* when `config.budgetUsd` opted in AND the task actually carries a ceiling (CC gate
|
|
424
421
|
* `e === void 0 → []` — no `maxBudgetUsd`, no lane). CC computes `used = sy()` (session-cumulative
|
|
425
422
|
* totalCostUSD) and `remaining = total − used`, both raw JS numbers; sema feeds the SAME coordinate
|
|
@@ -457,16 +454,15 @@ export interface AttachmentInputs {
|
|
|
457
454
|
* value (or absence) = CC `"baseline"` (on). sema keeps env resolution at the deployment shell
|
|
458
455
|
* and carries only the resolved mode here — core reads no env. */
|
|
459
456
|
todoReminderMode?: "baseline" | "off";
|
|
460
|
-
/** Tool_search_usage_reminder lane (opt-in, default OFF
|
|
461
|
-
* `toolSearchReminder` config resolves non-null, @607450-607456 / `cXi` @185859). */
|
|
457
|
+
/** Tool_search_usage_reminder lane (opt-in, default OFF). */
|
|
462
458
|
toolSearchReminder?: boolean;
|
|
463
459
|
changedFiles: boolean;
|
|
464
460
|
/** SR-3: budget_usd progressive reminder lane (opt-in, default OFF like every 133 member). CC fires
|
|
465
461
|
* it on EVERY attachment cycle while `maxBudgetUsd` is set; there is NO threshold ladder and no
|
|
466
462
|
* throttle window (QFm/`_Fy` are unconditional) — the "progression" is the numbers advancing with
|
|
467
|
-
* spend. sema mirrors that: one line per collected clean boundary, no window state here; the
|
|
468
|
-
*
|
|
469
|
-
* finished run
|
|
463
|
+
* spend. sema mirrors that: one line per collected clean boundary, no window state here; the turn
|
|
464
|
+
* boundary collects the whole bundle only where the turn's own work owes the next request (a
|
|
465
|
+
* boundary steer must never EXTEND a finished run — the loop's continuation fact, `continues`).
|
|
470
466
|
*
|
|
471
467
|
* Attribution CORRECTED (the previous note claimed "gated `d = !t.agentId` :479177 —
|
|
472
468
|
* subagents never see it", which reads 220 wrong). In 220 the `!agentId` flag gates only the
|
|
@@ -483,9 +479,8 @@ export interface AttachmentInputs {
|
|
|
483
479
|
* snapshots `maxCostUsd` and every other governance field) reaches the lane. */
|
|
484
480
|
budgetUsd?: boolean;
|
|
485
481
|
/**
|
|
486
|
-
* `total_tokens_reminder
|
|
487
|
-
*
|
|
488
|
-
* ceiling sees it too — the attribution verbatim). DEFAULT ON, matching 2.1.245+'s own default;
|
|
482
|
+
* `total_tokens_reminder`: registered in the SHARED producer group beside `budget_usd`, so a subagent carrying its own
|
|
483
|
+
* ceiling sees it too. DEFAULT ON, matching the reference's own default;
|
|
489
484
|
* explicit `false` opts out. Before the
|
|
490
485
|
* flip an un-opted deployment rendered no reminder frame at all. The countdown arms still need a
|
|
491
486
|
* declared ceiling, so a task without one is silent either way. (Scoped deliberately to this lane:
|
|
@@ -537,10 +532,10 @@ export interface AttachmentInputs {
|
|
|
537
532
|
mcpInstructions?: boolean;
|
|
538
533
|
};
|
|
539
534
|
/** Deferred tools whose schemas the model has NOT loaded yet (declared but not
|
|
540
|
-
* activated), sorted, snapshotted by the run loop.
|
|
541
|
-
*
|
|
535
|
+
* activated), sorted, snapshotted by the run loop.
|
|
536
|
+
* Only passed
|
|
542
537
|
* when `config.toolSearchReminder` is opted in AND the task actually has deferred tools — an empty
|
|
543
|
-
* or absent list silences the lane permanently
|
|
538
|
+
* or absent list silences the lane permanently. */
|
|
544
539
|
undiscoveredTools?: readonly string[];
|
|
545
540
|
/** Is the direct-call lane mounted on this run's placeholders (`Prepared.deferDirectCall`,
|
|
546
541
|
* i.e. `TaskSpec.deferSelfResolve` not disabled)? Selects which closing sentence the
|
|
@@ -578,7 +573,7 @@ export interface AttachmentInputs {
|
|
|
578
573
|
* (prepare-time static in practice; the producer's delta path serves dynamic-registration
|
|
579
574
|
* deployments and tests). Only passed when `config.agentListing` opted in. */
|
|
580
575
|
agentListing?: ReadonlyArray<AgentListingEntry>;
|
|
581
|
-
/** The delegation tool's mounted name — interpolated into the
|
|
576
|
+
/** The delegation tool's mounted name — interpolated into the roster headers ("…for the
|
|
582
577
|
* Agent tool:"); byte-identical to CC under the default name "Agent". */
|
|
583
578
|
agentToolName?: string;
|
|
584
579
|
/** [c209-C] Q4 — model catalog names for the agent_listing INITIAL frame's trailing
|
|
@@ -625,7 +620,7 @@ export interface AttachmentInputs {
|
|
|
625
620
|
*/
|
|
626
621
|
export declare function collectDueAttachments(state: AttachmentState, inp: AttachmentInputs): readonly TurnAttachment[];
|
|
627
622
|
/**
|
|
628
|
-
*
|
|
623
|
+
* The `tool_search_usage_reminder` renderer text, with the two
|
|
629
624
|
* interpolations resolved: the name list (+ `(+N more)` tail when the census exceeds
|
|
630
625
|
* {@link TOOL_SEARCH_REMINDER_CONFIG}.MAX_NAMES) and the ToolSearch tool's mounted name — sema mounts
|
|
631
626
|
* the same name. The quoted `select:<name>[,<name>...]` form is also sema's real ToolSearch contract
|
|
@@ -643,14 +638,14 @@ export declare function collectDueAttachments(state: AttachmentState, inp: Attac
|
|
|
643
638
|
*/
|
|
644
639
|
export declare function renderToolSearchUsageReminder(undiscovered: readonly string[], directCallEnabled?: boolean): string;
|
|
645
640
|
/**
|
|
646
|
-
* SR-3 —
|
|
641
|
+
* SR-3 — the reference's `budget_usd` template (cli296.js:250449: "USD budget: $"):
|
|
647
642
|
* `USD budget: $${used}/$${total}; $${remaining} remaining`
|
|
648
643
|
* `remaining = total − used` is computed producer-side in CC (QFm :480427 `n = e - t`) and re-derived
|
|
649
644
|
* here from the two inputs — one fewer number to drift. CC interpolates RAW JS numbers (sy() is a
|
|
650
645
|
* float accumulator; no rounding anywhere in QFm or the renderer), kept verbatim: sema's inputs come
|
|
651
646
|
* from integer micro-USD ÷ 1e6, so they render with ≤6 decimals by construction.
|
|
652
647
|
*/
|
|
653
|
-
/** A1 —
|
|
648
|
+
/** A1 — the date-change reminder shape (cli296.js:139311: "The date has changed. Today's date is now") (de-branded is a no-op here: the text is neutral). */
|
|
654
649
|
export declare function renderDateChange(newDate: string): string;
|
|
655
650
|
/**
|
|
656
651
|
* A1-R — the date_change producer (CC attachments.ts:1400-1443 parity): the system-prefix
|
|
@@ -704,8 +699,8 @@ export declare function commitInstructionsChange(state: InstructionsChangeState,
|
|
|
704
699
|
}>): void;
|
|
705
700
|
export declare function renderBudgetUsd(used: number, total: number): string;
|
|
706
701
|
/**
|
|
707
|
-
*
|
|
708
|
-
*
|
|
702
|
+
* The whole body is the one-line envelope (cli296.js:188983): "<total_tokens>N tokens left</total_tokens>",
|
|
703
|
+
* where N is the arm's own substitution — the literal
|
|
709
704
|
* `Infinite`, the {@link TOTAL_TOKENS_FIXED_ARM_VALUE} constant, or the remaining count clamped at
|
|
710
705
|
* zero (CC's `Math.max(0, …)`: an over-spent run reads `0 tokens left`, never a negative number).
|
|
711
706
|
*
|
|
@@ -719,7 +714,7 @@ export declare function renderBudgetUsd(used: number, total: number): string;
|
|
|
719
714
|
*/
|
|
720
715
|
export declare function renderTotalTokensReminder(mode: TotalTokensReminderMode, remaining: number): string;
|
|
721
716
|
/**
|
|
722
|
-
* SR-7 —
|
|
717
|
+
* SR-7 — inner text (cli296.js:246247): "The container was restarted" — the aggregated
|
|
723
718
|
* orphaned-background-task notice a restarted/resumed leg injects ONCE (CC's own `<system-reminder>`
|
|
724
719
|
* wrapper is added by the caller — sema's single-wrap-point discipline, F3). Line shape CC-exact:
|
|
725
720
|
* `- ${description || "(no description)"} (task ${id})` — `||` kept (an EMPTY description also reads
|
|
@@ -732,7 +727,7 @@ export declare function renderOrphanedBackgroundTasks(tasks: ReadonlyArray<{
|
|
|
732
727
|
description?: string;
|
|
733
728
|
}>): string;
|
|
734
729
|
/**
|
|
735
|
-
*
|
|
730
|
+
* Per-frame list cap for the `deferred_tools_delta` arms.
|
|
736
731
|
* Lists longer than this collapse to a grouped one-liner + "…and N more".
|
|
737
732
|
*/
|
|
738
733
|
export declare const TOOLS_DELTA_LIST_MAX = 30;
|
|
@@ -741,21 +736,21 @@ export declare const TOOLS_DELTA_LIST_MAX = 30;
|
|
|
741
736
|
* are CALLER-drained on intact cap survival, exactly like {@link AttachmentInputs.newTools}. */
|
|
742
737
|
export interface McpToolsDeltaFacts {
|
|
743
738
|
/** Previously-announced deferred tools that LEFT the harness roster (their server withdrew them —
|
|
744
|
-
* reached through RefreshMcpTools's prefix re-splice).
|
|
739
|
+
* reached through RefreshMcpTools's prefix re-splice). */
|
|
745
740
|
removed?: readonly string[];
|
|
746
|
-
/** Previously-announced-then-withdrawn deferred tools that came BACK.
|
|
741
|
+
/** Previously-announced-then-withdrawn deferred tools that came BACK. */
|
|
747
742
|
readded?: readonly string[];
|
|
748
743
|
/** Declared MCP servers that failed to connect at materialize (`MaterializedMcp.statuses`, status
|
|
749
744
|
* `"failed"`). `error` is REMOTE/transport text — the producer neutralizes + bounds it at intake.
|
|
750
|
-
*
|
|
745
|
+
* */
|
|
751
746
|
failedServers?: ReadonlyArray<{
|
|
752
747
|
name: string;
|
|
753
748
|
error?: string;
|
|
754
749
|
}>;
|
|
755
750
|
}
|
|
756
751
|
/**
|
|
757
|
-
* G1 — deferred-tool materialization announce (boundary notice).
|
|
758
|
-
*
|
|
752
|
+
* G1 — deferred-tool materialization announce (boundary notice). The reference's template (cli296.js:128211): "The following deferred tools are now available via", in full:
|
|
753
|
+
* "The following deferred
|
|
759
754
|
* tools are now available via ${ToolSearch}. Their schemas are NOT loaded — calling them directly
|
|
760
755
|
* will fail with InputValidationError. Use ${ToolSearch} with query \"select:<name>[,...]\" to load
|
|
761
756
|
* tool schemas before calling them:" — but CC announces DISCOVERABLE tools (schemas still deferred),
|
|
@@ -766,12 +761,12 @@ export interface McpToolsDeltaFacts {
|
|
|
766
761
|
* CC 2.1.220 (`deferred_tools_delta`, cli250.js:45890-45918) carries SIX arms; sema
|
|
767
762
|
* shipped only the `added` one. The arms below are the ones whose STATE IS REACHABLE in this engine
|
|
768
763
|
* (data-side audit):
|
|
769
|
-
* - `readded`
|
|
764
|
+
* - `readded` / `removed`: reachable via RefreshMcpTools — the refresh splices a
|
|
770
765
|
* server's whole `mcp__<server>__` prefix domain out of the live tool array and pushes the fresh
|
|
771
766
|
* listing back, so a withdrawn tool genuinely leaves (and a re-advertised one genuinely returns)
|
|
772
767
|
* the roster mid-task. CC's trailing "Load via ToolSearch as before" / "Do not search for them —
|
|
773
768
|
* ToolSearch will return no match" clauses are kept, because sema mounts the SAME ToolSearch name.
|
|
774
|
-
* - `failed
|
|
769
|
+
* - `failed`: reachable from `MaterializedMcp.statuses` (`status: "failed"`, fail-open
|
|
775
770
|
* connect skip). CC additionally splits a MANAGED-POLICY sub-arm off this list (`jlr`/`Oy_` error
|
|
776
771
|
* codes @626575) — sema has no managed-policy error taxonomy, so only the connection-failure form
|
|
777
772
|
* is rendered.
|
|
@@ -780,7 +775,7 @@ export interface McpToolsDeltaFacts {
|
|
|
780
775
|
* (`McpServerSpec.transport.headers` / `principalHeader`) with no OAuth flow and no
|
|
781
776
|
* authorization-required status — an auth rejection surfaces as an ordinary connect failure and is
|
|
782
777
|
* covered by the `failed` arm above.
|
|
783
|
-
* - `pending
|
|
778
|
+
* - `pending`: `materializeMcpTools` is fully AWAITED inside prepareTask (one
|
|
784
779
|
* `Promise.allSettled` over every server) before the run loop's first turn, so "still connecting"
|
|
785
780
|
* does not exist at any turn boundary — `McpServerStatus.status` is `connected | failed` only.
|
|
786
781
|
* Returns `undefined` when every arm is empty (CC `i.length === 0 → []`).
|
|
@@ -801,17 +796,16 @@ export declare function renderToolsDelta(input: {
|
|
|
801
796
|
* assert compact placeholders the model can see are not there. */
|
|
802
797
|
readdedSwappedUnderStatic?: readonly string[];
|
|
803
798
|
} & McpToolsDeltaFacts): string | undefined;
|
|
804
|
-
/** The `(Tools: …)` value for an entry that precomputed none (
|
|
805
|
-
* @465662: no allowlist and no denylist ⇒ the literal "All tools"). */
|
|
799
|
+
/** The `(Tools: …)` value for an entry that precomputed none (no allowlist and no denylist ⇒ the literal "All tools"). */
|
|
806
800
|
export declare const AGENT_TOOLS_NOTE_DEFAULT = "All tools";
|
|
807
|
-
/**
|
|
801
|
+
/** The roster concurrency note (cli296.js:139690): "When you launch multiple agents for independent work". */
|
|
808
802
|
export declare const AGENT_CONCURRENCY_NOTE = "When you launch multiple agents for independent work, send them in a single message with multiple tool uses so they run concurrently.";
|
|
809
|
-
/**
|
|
810
|
-
* parity spot audit, PARITY-SPOT-AGENT-TYPES F5 / PARITY-SPOT-REMINDERS SR-V1).
|
|
811
|
-
* removal lists (agent types
|
|
803
|
+
/** The ambient-context tail (cli296.js:250618): "This is ambient context" — resolved by the 2026-07-10
|
|
804
|
+
* parity spot audit, PARITY-SPOT-AGENT-TYPES F5 / PARITY-SPOT-REMINDERS SR-V1). It is appended after BOTH
|
|
805
|
+
* removal lists (agent types, mcp instructions) so the model treats the drift notice as
|
|
812
806
|
* background, not something to announce. */
|
|
813
807
|
export declare const AMBIENT_CONTEXT_NOTE = "This is ambient context \u2014 do not narrate it to the user unless they ask or it is directly relevant to their request.";
|
|
814
|
-
/**
|
|
808
|
+
/** The initial-roster header (cli296.js:139688): "Available agent types for the Agent tool:" with the tool name interpolated here — single-sourced here for the renderer
|
|
815
809
|
* AND the run loop's resume transcript probe (MED-3②: "was the listing ever delivered?"). */
|
|
816
810
|
export declare function agentListingInitialHeader(toolName: string): string;
|
|
817
811
|
/**
|
|
@@ -829,18 +823,18 @@ export declare function replayAnnouncedListing(texts: readonly string[], headers
|
|
|
829
823
|
}): Set<string> | undefined;
|
|
830
824
|
/** Removal-frame header for the agent-type roster (single-sourced for renderer + replay parser). */
|
|
831
825
|
export declare const AGENT_LISTING_REMOVED_HEADER = "The following agent types are no longer available:";
|
|
832
|
-
/**
|
|
826
|
+
/** The roster-drift header (cli296.js:139689): "New agent types are now available for the" — same single-source rationale as {@link agentListingInitialHeader}.
|
|
833
827
|
* The interpolated tool name is neutralized on both headers: a caller renames the delegation tool, so
|
|
834
828
|
* the name is deployment text arriving on the marked-reminder lane like every other field here. */
|
|
835
829
|
export declare function agentListingDeltaHeader(toolName: string): string;
|
|
836
830
|
/**
|
|
837
|
-
* G1 续批 — agent-type roster announce (
|
|
838
|
-
* headers
|
|
831
|
+
* G1 续批 — agent-type roster announce (`agent_listing_delta`, cli296.js:250594),
|
|
832
|
+
* headers with the tool name interpolated — byte-identical to the reference under the default "Agent").
|
|
839
833
|
* First call (no announced map) = CC `isInitial`: full roster under "Available agent types…", plus the
|
|
840
834
|
* concurrency note when more than one type is offered. Later
|
|
841
835
|
* calls announce only drift: adds under "New agent types are now available…", removals under "The
|
|
842
|
-
* following agent types are no longer available:" + `- <name>` lines, followed by the
|
|
843
|
-
* {@link AMBIENT_CONTEXT_NOTE}
|
|
836
|
+
* following agent types are no longer available:" + `- <name>` lines, followed by the
|
|
837
|
+
* {@link AMBIENT_CONTEXT_NOTE}. Name-keyed like CC: a description
|
|
844
838
|
* change on an existing name is not re-announced. Every line carries a `(Tools: …)` tail (
|
|
845
839
|
* 220 `fvd`/`WW_` @465651-465668 — the model needs each type's tool boundary to pick a type;
|
|
846
840
|
* PARITY-SPOT-AGENT-TYPES F3), defaulted to {@link AGENT_TOOLS_NOTE_DEFAULT} when the entry precomputed none.
|
|
@@ -923,11 +917,11 @@ export interface SkillsListingFrameRender extends SkillsBlockRender {
|
|
|
923
917
|
* [c209-C] skills_listing producer — the skills counterpart of {@link renderAgentListingDelta}, with
|
|
924
918
|
* the degradation report the disclosure lane announces. First call (no announced map) = the full
|
|
925
919
|
* `<skills>` disclosure block VERBATIM (the exact bytes that used to sit in the stable system prompt
|
|
926
|
-
* now ride the reminder lane
|
|
920
|
+
* now ride the reminder lane, as a
|
|
927
921
|
* first-user-turn reminder ~5.9KB, report §5.1). Later calls announce only drift, name-keyed like the
|
|
928
922
|
* agent arm: adds under {@link SKILLS_LISTING_DELTA_HEADER} with the SAME `- name: description` line
|
|
929
923
|
* shape the block uses, removals under {@link SKILLS_LISTING_REMOVED_HEADER} + `- <name>` lines,
|
|
930
|
-
* followed by the
|
|
924
|
+
* followed by the {@link AMBIENT_CONTEXT_NOTE} (agent-removal-arm parity). A description
|
|
931
925
|
* change on an existing name is not re-announced (name-keyed, agent-arm parity).
|
|
932
926
|
*
|
|
933
927
|
* ONE RULER FOR EVERY FRAME: the drift frame is measured against the SAME resolved budget as the
|
|
@@ -995,18 +989,18 @@ export declare function fenceMcpServerInstructions(server: string, text: string)
|
|
|
995
989
|
*/
|
|
996
990
|
export declare function renderMcpInstructionsEntry(entry: McpInstructionsEntry): string;
|
|
997
991
|
/**
|
|
998
|
-
* G1 续批 — MCP server-instruction delta (
|
|
999
|
-
*
|
|
992
|
+
* G1 续批 — MCP server-instruction delta (the reference header, cli296.js:250602: "The following MCP servers have provided instructions").
|
|
993
|
+
* Deliberate deviations from the reference (recorded):
|
|
1000
994
|
* - added instruction text is UNTRUSTED server-controlled text → each block rides inside a
|
|
1001
995
|
* `delimitUntrusted` fence (CC injects the raw block; sema's external-inlet posture is fencing —
|
|
1002
996
|
* the text is additionally already `sanitizeUntrustedText`-neutralized at the mcp.ts producer).
|
|
1003
997
|
* Each entry renders through {@link renderMcpInstructionsEntry}, shared with the STABLE system-prompt
|
|
1004
998
|
* lane, so one entry never carries two postures; every entry, server's or host's, carries the per-entry
|
|
1005
999
|
* {@link MCP_INSTRUCTIONS_MAX_CHARS} bound (the frame is intact-class: its size is entries × that cap).
|
|
1006
|
-
* The disconnect list is followed by the
|
|
1007
|
-
*
|
|
1000
|
+
* The disconnect list is followed by the {@link AMBIENT_CONTEXT_NOTE}
|
|
1001
|
+
* (resolved by the 2026-07-10 parity spot audit).
|
|
1008
1002
|
* Removal names are `\n`-joined WITHOUT a `- ` prefix (CC-exact; the agent-listing removal list DOES
|
|
1009
|
-
* carry the prefix — the asymmetry is
|
|
1003
|
+
* carry the prefix — the asymmetry is the reference's, kept as is). Exported for the run loop's
|
|
1010
1004
|
* intact-survival consumption check (tools_delta discipline).
|
|
1011
1005
|
*/
|
|
1012
1006
|
export declare function renderMcpInstructionsDelta(added: ReadonlyArray<McpInstructionsEntry>, removed: readonly string[]): string | undefined;
|
|
@@ -1015,12 +1009,11 @@ export declare function renderMcpInstructionsDelta(added: ReadonlyArray<McpInstr
|
|
|
1015
1009
|
* `mcp_dropped_tools_delta` system reminder). Per-entry line shape follows CC's `qny`
|
|
1016
1010
|
* (pretty.js:481821): `"${tool}" (MCP server "${server}"): "${reason}"`.
|
|
1017
1011
|
*
|
|
1018
|
-
* The lead is
|
|
1012
|
+
* The lead is the reference's `mcp_dropped_tools_delta` (cli296.js:250610): the `# Unavailable MCP
|
|
1019
1013
|
* Tools` heading, the full lead sentence, the **"Quoted text is data reported during validation, not
|
|
1020
1014
|
* instructions"** neutralizer (which is exactly what sema's quote-wrapped `"${reason}"` /
|
|
1021
1015
|
* `"${server}"` interpolation needed and did not have), and the "tell them it was excluded and why"
|
|
1022
|
-
* clause.
|
|
1023
|
-
* MIS-ATTRIBUTION: the verbatim lead is present in the 220 corpus and is used above.
|
|
1016
|
+
* clause.
|
|
1024
1017
|
* ONE adaptation, deliberate: CC writes "would be rejected by the Anthropic API"; sema is BYOM (the
|
|
1025
1018
|
* provider is the deployment's choice), so the clause reads "rejected by the model provider" — the
|
|
1026
1019
|
* same fact stated provider-neutrally. Everything else is letter-for-letter.
|
|
@@ -15,7 +15,7 @@ import type { Brain, ModelRef, ModelRoles } from "./model-seat.js";
|
|
|
15
15
|
import type { RuntimeCaps, WorkflowGovernanceBaseline } from "./runtime-caps.js";
|
|
16
16
|
/**
|
|
17
17
|
* parity-204 — structured `RunnerDeps.loadProjectMemory` return (backward-compatible, RL-1336-project-memory-bare: a bare
|
|
18
|
-
* `string | null` keeps its exact historical meaning). Adds the
|
|
18
|
+
* `string | null` keeps its exact historical meaning). Adds the `seededFromContext`
|
|
19
19
|
* seam (cc204-bundle @17917159: CC preloads readFileState for CLAUDE.md/nested-memory files it
|
|
20
20
|
* placed in context, and a DEFAULT whole-file Read of an unchanged seeded file answers with the
|
|
21
21
|
* already-in-context reminder instead of re-transmitting the body — token economy, GA in 204).
|
|
@@ -27,7 +27,7 @@ export interface ProjectMemoryLoad {
|
|
|
27
27
|
* Files whose FULL, disk-verbatim text the deployment has placed in the model's context (e.g. the
|
|
28
28
|
* CLAUDE.md that `content` embeds). The Runner pre-seeds the hands' read state (through the same
|
|
29
29
|
* resolveKey containment as a real Read — an out-of-root path is silently skipped), so a default
|
|
30
|
-
* whole-file Read of an UNCHANGED seeded file returns the
|
|
30
|
+
* whole-file Read of an UNCHANGED seeded file returns the reminder
|
|
31
31
|
* (`This file is already in your context (see "Contents of <path>" above) and has not changed on
|
|
32
32
|
* disk…`) instead of the body. `content` here MUST be the file's exact disk text at load time —
|
|
33
33
|
* the unchanged check hashes it; never declare a truncated/annotated variant (CC's `isPartialView`
|
|
@@ -52,10 +52,8 @@ export interface ProjectMemoryLoad {
|
|
|
52
52
|
*/
|
|
53
53
|
instructionSources?: ReadonlyArray<{
|
|
54
54
|
path: string;
|
|
55
|
-
/**
|
|
56
|
-
*
|
|
57
|
-
* Runtime already handled null (collectInstructionsChange's from===null arm); this widening
|
|
58
|
-
* only aligns the declared type with the shipped behavior. */
|
|
55
|
+
/** `null` = the source is DECLARED but currently ABSENT from disk — the change probe then watches for
|
|
56
|
+
* its APPEARANCE (renders "absent → hash"). */
|
|
59
57
|
contentHash: string | null;
|
|
60
58
|
}>;
|
|
61
59
|
}
|
|
@@ -240,13 +238,13 @@ export interface RunnerDeps {
|
|
|
240
238
|
*/
|
|
241
239
|
agentConfigDir?: string;
|
|
242
240
|
/**
|
|
243
|
-
* backlog #286 (#279 —
|
|
241
|
+
* backlog #286 (#279 — `DANGEROUS_FILES`/`DANGEROUS_DIRECTORIES`/
|
|
244
242
|
* `DANGEROUS_DIRECTORY_PATHS` parity): the WRITE-protection table. DEFAULT-ON: a path-confinable
|
|
245
243
|
* write (Write/Edit/NotebookEdit) whose target lands on a table row has a surviving `allow`
|
|
246
244
|
* demoted to `ask` at the tool gate (`decisionReason: "safety"`; a deny/ask verdict is untouched;
|
|
247
245
|
* approval flows the ordinary ask-resolution chain — classifier, blanket `onAsk`, durable park —
|
|
248
246
|
* with no `requiresRealApproval` mandate). Absent =
|
|
249
|
-
* {@link import("./write-protect.js").WRITE_PROTECTED_DEFAULT_TABLE} (the
|
|
247
|
+
* {@link import("./write-protect.js").WRITE_PROTECTED_DEFAULT_TABLE} (the reference triple +
|
|
250
248
|
* the two argued sema rows). This key IS the whole-table escape hatch, deployment seat ONLY — the
|
|
251
249
|
* task layer's twin is add-only ({@link TaskSpec.writeProtectedAdditions}: its rows UNION this
|
|
252
250
|
* table and can remove none), and no governed-workflow channel reaches either: `[]` = no table (explicit and legal); a non-empty
|
|
@@ -545,6 +543,8 @@ export interface RunnerDeps {
|
|
|
545
543
|
fileHistoryStore?: import("./file-history-store.js").FileHistoryStore | "disabled";
|
|
546
544
|
/** The deployment's CAPTURE switch, apart from the store seat: `"off"` (the only word, and only beside a wired store; anything else refuses prepare, `config.invalid_file_history_capture`) ⇒ no run records — no first-touch record, no turn boundary, no fork carry, no liveness advisory, manifest `fileHistory: "disabled"` — while a wired {@link fileHistoryStore} still serves {@link TaskSpec.restoreFiles} / {@link TaskSpec.rewindFilesTo} from what it already holds. */
|
|
547
545
|
fileHistoryCapture?: "off";
|
|
546
|
+
/** The deployment's ADVISOR switch: `"disabled"` (the only word; anything else refuses prepare, `config.advisor_tool_invalid`) ⇒ no leg attaches the `advisor` tool and every {@link TaskSpec.advisorModel} is ignored unread — manifest `advisor: { state: "not_attached", reason: "disabled" }`, no notice. */
|
|
547
|
+
advisorTool?: "disabled";
|
|
548
548
|
/**
|
|
549
549
|
* design/381 DV-14 (终审落锤) — what an Edit/Write/NotebookEdit does when its FIRST-TOUCH history
|
|
550
550
|
* record cannot be persisted (`FileHistoryStore.trackEdit` answered `{ok:false}` = NO durable
|
|
@@ -563,13 +563,13 @@ export interface RunnerDeps {
|
|
|
563
563
|
*/
|
|
564
564
|
onTrackFailure?: "refuse" | "proceed-unprotected";
|
|
565
565
|
/**
|
|
566
|
-
* design/99 §E6 — DURABLE per-session permission rules (a deny-narrowing folded into the task-time tool
|
|
567
|
-
*
|
|
568
|
-
*
|
|
569
|
-
*
|
|
570
|
-
*
|
|
571
|
-
*
|
|
572
|
-
* honors the `operator` flag the
|
|
566
|
+
* design/99 §E6 — DURABLE per-session permission rules (a deny-narrowing folded into the task-time tool policy).
|
|
567
|
+
* Omitted ⇒ OFF (no rules read). A deployment's cross-replica backend matches the CAS-rev + tighten-only semantics of
|
|
568
|
+
* {@link import("./session-policy-store.js").InMemorySessionPolicyStore}. A task carrying its own `sessionId` has its
|
|
569
|
+
* rules re-read at every tool gate of its own AND of every delegated leg; a descendant reads the key from ITS runner's store,
|
|
570
|
+
* whichever that is — none ⇒ it keeps its spawn-time snapshot and announces `config.session_rules_unreadable`; a DIFFERENT
|
|
571
|
+
* store answers for the key itself, silently (no row there ⇒ nothing binds), so give delegation runners this same store.
|
|
572
|
+
* Composed BEFORE the caller policy, they only SUBTRACT capability. core does NOT verify owner/operator identity — the store honors the `operator` flag the caller freezes from a verified principal.
|
|
573
573
|
*/
|
|
574
574
|
sessionPolicyStore?: import("./session-policy-store.js").SessionPolicyStore;
|
|
575
575
|
/**
|
|
@@ -730,9 +730,9 @@ export interface RunnerDeps {
|
|
|
730
730
|
* engine-spawned child) AND this face is present AND the per-principal DENY bit is not set
|
|
731
731
|
* ({@link RuntimeCaps.autoMode}` !== false` — absent is not a denial).
|
|
732
732
|
*
|
|
733
|
-
* 🔐 Trust gate (the
|
|
733
|
+
* 🔐 Trust gate (the three-source invariant): classifier RULES enter EXCLUSIVELY
|
|
734
734
|
* here — a deployment-constructed object, never a `TaskSpec` field, never a repo-file plane. The
|
|
735
|
-
* prompt is assembled from the SHA-locked
|
|
735
|
+
* prompt is assembled from the SHA-locked reference assets (`buildAutoModePrompt`) with these
|
|
736
736
|
* rules merged CC-exactly (user rules replace a section; the `"$defaults"` sentinel splices the
|
|
737
737
|
* stock rules back in). The classify leg runs on the `classifier` role's model (fallback
|
|
738
738
|
* `summarize → default`; tier default `flash`) via the brain's simple-completion pipe — same
|
|
@@ -747,7 +747,7 @@ export interface RunnerDeps {
|
|
|
747
747
|
isolatePeers?: true;
|
|
748
748
|
};
|
|
749
749
|
autoMode?: {
|
|
750
|
-
/** Rule overrides for the four permissions sections (omitted section =
|
|
750
|
+
/** Rule overrides for the four permissions sections (omitted section = the defaults). */
|
|
751
751
|
rules?: import("./auto-mode-prompt.js").AutoModeRules;
|
|
752
752
|
/** Settings-plane deny rules rendered into the `<settings_deny_rules>` slot (circumvention catch). */
|
|
753
753
|
settingsDenyRules?: readonly string[];
|
|
@@ -784,7 +784,7 @@ export interface RunnerDeps {
|
|
|
784
784
|
*/
|
|
785
785
|
classifierFallback?: import("./auto-mode.js").AutoModeClassifierFallback;
|
|
786
786
|
/**
|
|
787
|
-
* The classifier DENIAL LIMIT
|
|
787
|
+
* The classifier DENIAL LIMIT: a run whose classifier keeps blocking falls
|
|
788
788
|
* back to a PERSON instead of being denied without end. Per run: a `block` first increments the
|
|
789
789
|
* consecutive and total counts and then judges `consecutive >= maxConsecutive || total >= maxTotal`
|
|
790
790
|
* — the block that reaches a bound is itself the one that becomes an `ask` (the 3rd consecutive
|
|
@@ -942,19 +942,19 @@ export interface RunnerDeps {
|
|
|
942
942
|
* `SendMessageToolOptions.lane` and into the session-box drain; read per call / per pass. */
|
|
943
943
|
peerLane?: Partial<import("../agents/peer-admission.js").PeerLaneConfig>;
|
|
944
944
|
/**
|
|
945
|
-
* design/385 §2.1 / §5.1 — the peer-session DIRECTORY: the discovery truth of the cross-session
|
|
946
|
-
*
|
|
947
|
-
*
|
|
948
|
-
*
|
|
949
|
-
*
|
|
950
|
-
*
|
|
951
|
-
*
|
|
952
|
-
*
|
|
953
|
-
*
|
|
954
|
-
* `crossProcessSafe: true`; otherwise the lane is REFUSED at prepare with a named
|
|
955
|
-
* `config.peer_lane_unmounted` notice (never mounted on luck), and the seat is inert for that run.
|
|
945
|
+
* design/385 §2.1 / §5.1 — the peer-session DIRECTORY: the discovery truth of the cross-session lane (other sessions
|
|
946
|
+
* of this engine for the same user). A HOST implements the contract (cli: the pid-keyed registration files; server: its
|
|
947
|
+
* session table) and writes the rows; the engine only reads them. Seat semantics = the mailbox seat's: NO seat, NO lane —
|
|
948
|
+
* every face stays byte-identical to a pre-385 build. With the seat wired the engine (a) mounts `ListAgents` (alias
|
|
949
|
+
* `ListPeers`), (b) opens SendMessage's `session.<id>` address arm and its last `name [ref]` rung, (c) drains this
|
|
950
|
+
* session's own `session.<sessionId>` box at every turn boundary (the mailbox contract's third consumption chain), and
|
|
951
|
+
* (d) splices the cross-session rule into the auto-mode classifier slot. HARD PRECONDITION (design/385 §1.2⑥):
|
|
952
|
+
* `mailboxStore` must be wired AND declare `crossProcessSafe: true`; otherwise the lane is REFUSED at prepare with a
|
|
953
|
+
* named `config.peer_lane_unmounted` notice (never mounted on luck), and the seat is inert for that run.
|
|
956
954
|
*/
|
|
957
955
|
peerDirectory?: import("../agents/peer-directory.js").PeerDirectory;
|
|
956
|
+
/** The cross-session SOCKET channel ({@link import("./peer-channel.js").PeerChannel}; bundled: `createCcUdsPeerChannel`, the reference agent's dialect). SendMessage reads each target row's lane once (`peerSessionLane`, against {@link mailboxStore}'s `identity`): a row whose capability bit names this store keeps its box append and its socket gets a content-free doorbell; any other row with a socket (a reference-agent session, a session of this engine on another store) gets the message over its socket, at-most-once (`via: "uds"`). Absent ⇒ such a row refuses `peer_send.not_reachable`, never an append into a box nobody drains; every other face is unchanged. The engine never listens (a host calls `listen`). Inert without {@link peerDirectory}. */
|
|
957
|
+
peerChannel?: import("./peer-channel.js").PeerChannel;
|
|
958
958
|
/**
|
|
959
959
|
* design/385 §4.4 — this deployment's `crossSessionInbound` setting LAYERS for the drain-point
|
|
960
960
|
* judgment (managed / user / repo, resolved by `resolveCrossSessionInboundSetting` — explicit value
|
|
@@ -977,7 +977,7 @@ export interface RunnerDeps {
|
|
|
977
977
|
assistant: string;
|
|
978
978
|
};
|
|
979
979
|
/**
|
|
980
|
-
* design/385 §4.4 (slice 4) — this deployment's `dialogExpiry` (
|
|
980
|
+
* design/385 §4.4 (slice 4) — this deployment's `dialogExpiry` (settings key, vocabulary
|
|
981
981
|
* `"60s" | "5m" | "10m" | "never"`, default `"5m"`): how long a HELD cross-session message whose cause
|
|
982
982
|
* a human review could resolve (mode-mismatch / no-mode-asserted / invalid attestation) waits in this
|
|
983
983
|
* session's held queue before it resolves to its safe no-action default — EXPIRED, dropped WITH a
|
|
@@ -1079,7 +1079,7 @@ export interface RunnerDeps {
|
|
|
1079
1079
|
/**
|
|
1080
1080
|
* design/138 S1 — the NEW-ARCHITECTURE memory seam (MemoryEngine over a {@link import("./memory-engine/types.js").MemoryBackend}).
|
|
1081
1081
|
* When set AND `spec.memory.enabled`, the task runs the INJECTION-FIRST file-based memory lifecycle
|
|
1082
|
-
* (materialize → session file ops → harvest with the full gate set), the
|
|
1082
|
+
* (materialize → session file ops → harvest with the full gate set), the `# Memory`
|
|
1083
1083
|
* instruction + fenced derived index replace the legacy `<user_memory>` block, and NO remember/recall
|
|
1084
1084
|
* tools are mounted (memory = the model's ordinary file skills). **S4: unset ⇒
|
|
1085
1085
|
* the task runs MEMORY-LESS** — the legacy `memoryStore` runtime path was retired (one deprecation
|
|
@@ -1326,9 +1326,9 @@ export interface RunnerDeps {
|
|
|
1326
1326
|
* simply carries no suggestions.
|
|
1327
1327
|
* - `"rewind"` — the file-history machinery backing rewind reported a best-effort failure: a
|
|
1328
1328
|
* turn-start boundary capture failed or timed out (that turn cannot be rewound to; the turn
|
|
1329
|
-
* itself proceeds),
|
|
1330
|
-
*
|
|
1331
|
-
* `
|
|
1329
|
+
* itself proceeds), a first-touch failure was tolerated under `onTrackFailure:"proceed-unprotected"`, a
|
|
1330
|
+
* first-touch record could not be retracted, or a fork's history carry failed. `err` is always a
|
|
1331
|
+
* `FileHistoryStoreError`: read its `code` / `permanence`, never the message text.
|
|
1332
1332
|
* - `"hook"` — a deployment hook misbehaved: a callback threw, or returned a verdict it was not
|
|
1333
1333
|
* allowed to (e.g. a declared-observational hook). The engine applies the hook's own documented
|
|
1334
1334
|
* fallback (swallow, or fail-closed deny, per its contract) and reports the fact here.
|
|
@@ -1415,7 +1415,7 @@ export interface RunnerDeps {
|
|
|
1415
1415
|
/**
|
|
1416
1416
|
* design/374 — the microCompact knobs. Both default ON (`machine: "cc"`, `clearOnRejection: true`).
|
|
1417
1417
|
*
|
|
1418
|
-
* - `machine`: `"cc"` (default: the
|
|
1418
|
+
* - `machine`: `"cc"` (default: the rejection-leg form — keep 5, ≥20k minimum-savings
|
|
1419
1419
|
* gate, one deep clear beyond the keep window, CC marker bytes) or `"off"` (no proactive
|
|
1420
1420
|
* frontier clearing at all — the D-2 off switch; the machine then gets its ONE shot at the
|
|
1421
1421
|
* blocking point instead, the slice-3 arm A, trace trigger `"blocking"`). The vocabulary is
|
|
@@ -1452,7 +1452,7 @@ export interface RunnerDeps {
|
|
|
1452
1452
|
cacheBreakDetection?: boolean;
|
|
1453
1453
|
/**
|
|
1454
1454
|
* Aggregate inline-MEDIA (image) byte budget for the request (batch-C/§17.2 sibling of the text budget;
|
|
1455
|
-
*
|
|
1455
|
+
* `tengu_media_byte_cap` in the reference). Image reads (`Read` → ImageContent) are per-image-capped but
|
|
1456
1456
|
* accumulate across turns; this bounds the SUM in the request by stripping the OLDEST images (replaced with a
|
|
1457
1457
|
* marker) — request-only, non-destructive (the durable session keeps the image; the model can re-Read it).
|
|
1458
1458
|
* The same budget bounds the media of one `tool_end.output` (spent there as base64 on the wire, x 4/3); both readers
|
|
@@ -86,7 +86,7 @@ export interface WorkflowGovernanceBaseline {
|
|
|
86
86
|
*/
|
|
87
87
|
/**
|
|
88
88
|
* #692 C-d — WHICH plane's ratchet denied auto mode, when the resolver knows: the three settings sources
|
|
89
|
-
*
|
|
89
|
+
* the reference's `permissions.disableAutoMode` can come from, as the resolver folds them into the one deny bit
|
|
90
90
|
* ({@link RuntimeCaps.autoMode} `=== false`). `org` = a managed / organization policy plane; `local` = the
|
|
91
91
|
* machine's local settings; `settings` = the user's / project's settings file. Read ONLY beside the deny bit
|
|
92
92
|
* (a source with no denial is a contradiction the value screen refuses as a resolver fault); projected onto
|
|
@@ -112,7 +112,7 @@ export interface RuntimeCaps {
|
|
|
112
112
|
* deployment, never GRANT beyond it. */
|
|
113
113
|
allowFork?: boolean;
|
|
114
114
|
/**
|
|
115
|
-
* Observer agents
|
|
115
|
+
* Observer agents: honor
|
|
116
116
|
* {@link AgentDefinition.observer} auto-spawn declarations. **POLARITY NOTE — unlike
|
|
117
117
|
* `allowWorkflows`/`allowFork` (`undefined` = unrestricted), this one is `=== true` EXPLICIT
|
|
118
118
|
* opt-in, default OFF**: CC's gate pair is a default-UNSET experimental env var
|
|
@@ -133,7 +133,7 @@ export interface RuntimeCaps {
|
|
|
133
133
|
* must not demote a reachable person into the model answering for them). */
|
|
134
134
|
forceDurableGate?: boolean;
|
|
135
135
|
/**
|
|
136
|
-
* The per-principal auto-mode DENY bit (
|
|
136
|
+
* The per-principal auto-mode DENY bit (the mirror of the settings-plane
|
|
137
137
|
* `permissions.disableAutoMode` ratchet: an organization may only take auto mode AWAY; it is the
|
|
138
138
|
* USER who turns it on, by requesting the mode at {@link TaskSpec.permissionMode}).
|
|
139
139
|
*
|
|
@@ -145,7 +145,7 @@ export interface RuntimeCaps {
|
|
|
145
145
|
* unset. The arming itself: intent ∧ {@link RunnerDeps.autoMode} present ∧ this bit not `false`
|
|
146
146
|
* (allow → run; block → deny `source:"classifier"`; classifier failure → FAIL-CLOSED back to the
|
|
147
147
|
* original ask chain). The trust gate is unchanged: classifier RULES enter only through the
|
|
148
|
-
* deployment assembly face, never a repo-controlled plane (the
|
|
148
|
+
* deployment assembly face, never a repo-controlled plane (the three-source invariant).
|
|
149
149
|
* A denial resolves to a no-op (asks flow the original chain; no warn — the gate, not a mistake).
|
|
150
150
|
*/
|
|
151
151
|
autoMode?: boolean;
|