Merge t3/enforce-orchestration-meter into spec-reconciliation: one before-tool path (worker exempt, contract guard, delegation guard, meter), routing decision read from the meter, retry-of on routing.retry_choice, ledger kind names. done: merge / next: tests on the merged tree, record parts

This commit is contained in:
swaits committed 2026-11-23 15:10:44 -07:00
commit c5df3068ce
36 files changed
+3567 -118

No files matched your search

+7 -3
View File
@@ -84,8 +84,11 @@ Give each task to the least expensive worker that is capable enough, counting re
and keep your own context for judgement. Use the host's own delegation first. Run independent
work in parallel when it shortens the critical path. Brief a worker with a contract
(`sisi delegate brief`), check what comes back in proportion to the risk, and record the
judgement (`sisi delegate judge`). `sisi route` recommends a worker from that record, and
`sisi delegate guide` is the playbook.
judgement (`sisi delegate judge`). Before delegating, ask `sisi route`, which recommends a worker
from that record and keeps your difficulty guess. When a worker is unavailable, give the same
brief to the next worker the router names, without asking the person and without reporting it:
worker availability is internal, and only a changed outcome or time is theirs to hear. `sisi delegate guide`
is the playbook.
Why: verified value per unit of time, cost and attention is the objective, and the strongest
model's attention is the scarcest resource.
@@ -95,7 +98,8 @@ model's attention is the scarcest resource.
When you finish, say what was delivered, the decisions that matter, what was verified and how,
what was not verified, and any risk or follow-up, in proportion to the change. Leave out the
story of how you got there. State assumptions and departures from what was asked. Never describe
unverified work as done.
unverified work as done. Say what you verified yourself and what you took on a worker's word. Leave
out which workers, tools or providers were used or unavailable, unless it changes the outcome.
Why: the person acts on your report. A false or padded one costs them more than a late one.
+7
View File
@@ -28,6 +28,13 @@
"tests",
"debug"
],
"other_kinds": [
"read",
"search",
"research",
"review",
"docs"
],
"build_words": [
"change",
"fix",
+104
View File
@@ -0,0 +1,104 @@
{
"_about": "Host tool names the orchestration meter needs (sisi/orchestration.py). Per host: `delegation` tools start a worker (where the call carries the model and the brief text, as dotted paths into the tool's input); `exempt` tools are never counted as direct work (the question dialog, planning and to-do tools, messaging tools). Any other tool, including one named nowhere here, counts. `refuse` says how the host's before-tool hook refuses a call: `json-deny` prints the host's permission-deny JSON, `exit-2` exits with status 2 and the reason on standard error, `none` means the meter only counts there. `evidence` says how sure this entry is.",
"claude-code": {
"refuse": "json-deny",
"evidence": "observed live (tools/live_orchestration_check.py)",
"delegation": {
"Task": {
"model": "model",
"brief": "prompt"
},
"Agent": {
"model": "model",
"brief": "prompt"
}
},
"exempt": {
"dialog": [
"AskUserQuestion"
],
"planning": [
"TodoWrite",
"EnterPlanMode",
"ExitPlanMode",
"TaskCreate",
"TaskUpdate",
"TaskList",
"TaskGet",
"TaskOutput",
"TaskStop"
],
"messaging": [
"SendMessage",
"SendUserMessage",
"PushNotification"
]
}
},
"codex": {
"refuse": "exit-2",
"evidence": "from the host's hook documentation; not run live here",
"delegation": {},
"exempt": {
"dialog": [
"request_user_input"
],
"planning": [
"update_plan"
],
"messaging": []
}
},
"gemini": {
"refuse": "exit-2",
"evidence": "from the host's hook documentation; not run live here",
"delegation": {},
"exempt": {
"dialog": [
"ask_user"
],
"planning": [
"write_todos"
],
"messaging": []
}
},
"copilot": {
"refuse": "none",
"evidence": "the host's before-tool refusal contract is not confirmed here; counts only",
"delegation": {
"task": {
"model": "model",
"brief": "prompt"
}
},
"exempt": {
"dialog": [
"ask_user"
],
"planning": [
"update_todo"
],
"messaging": []
}
},
"cursor": {
"refuse": "exit-2",
"evidence": "from the host's hook documentation; not run live here",
"delegation": {
"Task": {
"model": "model",
"brief": "prompt"
}
},
"exempt": {
"dialog": [
"AskQuestion"
],
"planning": [
"TodoWrite"
],
"messaging": []
}
}
}
+10
View File
@@ -80,6 +80,16 @@ present; nothing here names one. Read on demand: `sisi delegate guide`.
- Unavailability is temporary and is never a quality judgement: record it
with `sisi workers down`, use the next worker, and try again when due.
A rejected result never marks a worker down.
- When a worker is unavailable (a quota, limit, login or connection failure
that reaches you as a delegation result or as a later notice), do not ask
the person whether or when, and do not report it: worker availability,
quotas, retries and routing are internal. Give the same brief to the next
worker the router names and cancel the failed task so it cannot resume on a
stale branch. If every other provider is down, use the host's own
subagents. If nothing at all is usable, do the work yourself. The person
hears of it only when nothing usable is left or the fallback changes what
they receive, or when, in a way they must act on: one plain sentence about
that consequence, not about the workers.
## Keeping the picture current