Compare commits
2
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
060f3a3154 | ||
|
|
fcd70f294d |
No files matched your search
@@ -11,30 +11,22 @@ record; nothing here is scaffolding from before 2026-10-14.
|
||||
└── <your repos>
|
||||
Time = the automation layer. It lives here, on prod (teahubxyz/time); the GitHub copy is an archived proof of concept.
|
||||
Time acts as the Gitea user `time` (its own token, TIME_TOKEN) for every write except comments and commit statuses,
|
||||
which stay with the Actions identity (`gitea-actions`); code goes in as git pushes. Seats post as themselves: a
|
||||
review by `haiku` is a Gitea review by the user `haiku` (one Gitea user per model line, TIME_SEAT_<SEAT>).
|
||||
Rhythm: Astra (daily, 13:13 UTC) queues cards; the heartbeat (hourly, and on demand) builds `ready` cards with a
|
||||
seat, gets each PR reviewed by the council, and merges on approve + green CI, engine code included. Only the workflow
|
||||
directories (`.github/workflows/`) stay a human's merge: the CEO batches them. A card whose PR already exists (Codex, a
|
||||
chat, the CEO) is adopted: labelled `ready`, it is reviewed and landed, never rebuilt. Housekeeping sweeps daily (13:17).
|
||||
Tiers: Luna = haiku (Codex: luna), Terra = sonnet (terra), Sol = opus (sol), Astra = fable (astra), the C level. Venice
|
||||
seats (kimi, grok, ...) break ties. The operator hears from the Astra tier only on exception or check-in.
|
||||
Spend: every model call is booked to time/ledger/<YYYY-MM>.jsonl, cached tokens priced. TIME_MONTHLY_USD=100 is the
|
||||
owner's envelope; TIME_DAILY_USD (15) paces it and gates launches; a run launched within budget finishes (1.5x). A
|
||||
breach opens an `andon` issue. No model decides whether to spend.
|
||||
which stay with the Actions identity (`gitea-actions`); code goes in as git pushes.
|
||||
Rhythm: Astra (daily, 13:13 UTC) queues cards; the heartbeat (hourly) builds them one at a time with a seat, gets a
|
||||
review, and merges on approve + green CI. PRs under .github/ (Time's own engine) never merge themselves: the steward,
|
||||
a scheduled Claude session every 6 hours, reads and merges them.
|
||||
Seats: Claude (haiku / sonnet / opus / fable, ANTHROPIC_API_KEY, user-level secret) by default; Venice wired but idle.
|
||||
Spend: every model call is booked to time/ledger/<YYYY-MM>.jsonl; TIME_DAILY_USD=5, TIME_MONTHLY_USD=100 stop the
|
||||
clock and open an `andon` issue. No model decides whether to spend.
|
||||
hb-5 (the Mac) is NOT part of prod: it is the operator's playground and the old instance (matcha.teahub.xyz).
|
||||
Boring (ops MCP) lives on the Mac and may reach prod as a client; prod never depends on it.
|
||||
```
|
||||
|
||||
## Moves
|
||||
- Read first: this file, `docs/decisions.md` (why things are the way they are), `docs/rebuild.md` (what it took).
|
||||
- Work is a card: an issue with a `DONE:` line. Open it, do it, receipt it on the issue, close it. `queued` runs it when
|
||||
its turn comes (oldest first, `Depends on #N` respected); `ready` runs it on the next beat; `spec` has Time split it.
|
||||
- A card is what a Terra worker finishes in forty turns. Larger work is a parent labelled `planned` with children that
|
||||
carry their own `DONE:` lines; a parent is never `queued`. Three cards died at the turn ceiling before this rule.
|
||||
- A card says where it lives. `Base: <branch>` (every venture card: `Base: gh-pages`) makes the worker cut its branch
|
||||
from there and open the PR against it; without the line, the default branch. `PR: #N` names a PR that already answers
|
||||
the card, so Time reviews it instead of building again.
|
||||
- Work is an issue with a `DONE:` line. Open it, do it, receipt it on the issue, close it. Label it `queued` and Time
|
||||
runs it when its turn comes (oldest first, `Depends on #N` respected); `ready` runs it on the next beat, beside
|
||||
whatever else is running; `spec` has Time split it into cards.
|
||||
- Before a task, find its route in `SKILLS.md` and load only the skills it names, by path. No model decides which
|
||||
skill to load.
|
||||
- You act as yourself (Time too: it is the `time` user). There is no shared service token on prod. If you can't do
|
||||
@@ -45,22 +37,7 @@ record; nothing here is scaffolding from before 2026-10-14.
|
||||
`docs/decisions.md`. Nothing else. Do not add one without a decision there. A temporary admin token is deleted
|
||||
(sqlite3 on the Fly box) and the deletion checked before you write that it's gone.
|
||||
- Be boring by default; get clever only on an ANDON. Deterministic scripts before cheap inference before expensive inference.
|
||||
|
||||
## Situations
|
||||
What to do when you meet one of these. Each row names the procedure; the procedure names the skill or the code.
|
||||
|
||||
| You see | Do |
|
||||
|---|---|
|
||||
| A `ready` card with no worker yet, and a PR already answers it | Nothing: Time adopts the PR on its next beat (a `pr` beat with `adopted: true`). Make sure the PR body says `Closes #N` or the card says `PR: #N`. |
|
||||
| The reviewer objected; the PR is `needs-human` | Read the objection on the PR. If it is right and small, comment `/time retry` on the card: the worker gets the review text and answers on the same branch. If it is wrong, say so on the PR as yourself (Approve/Object comments from trusted users count) and remove the label. |
|
||||
| A PR is approved but `mergeable: false` | It fell behind its base. Until time#123 lands, a human re-cuts the branch from the base and re-applies the change (or merges the base into the branch); a `Closes #N` line keeps the card's adoption. |
|
||||
| A worker stopped at the turn ceiling ("stopped without a PR after N steps") | First check the card's `Base:` line (a venture card without `Base: gh-pages` cannot find its files). Then split the card; never retry the same card unchanged twice. |
|
||||
| An `andon` issue: spend cap reached | Read the ledger for the day. The daily cap is pacing (the CEO may raise it with the owner's OK; log it in `docs/decisions.md`); the monthly cap is the owner's alone. Close the andon once handled; Astra queues nothing while one is open. |
|
||||
| A PR head shows `heartbeat / tick: failure` | Not a check. Time's own workflow statuses (heartbeat, mention, venture, astra, doctor, update, steward) are ignored by the merge gate (time#124). CI decides. |
|
||||
| Housekeeping posted a stale list on the Astra log | Follow `.agents/skills/housekeeping/SKILL.md` in teahubxyz/time: decide each `needs-human`, idle PR, parked or `error` card. Housekeeping never acts on the list itself. |
|
||||
| A workflow file needs to change | Open the PR, label it `needs-human`, and note it on the Astra log. The CEO merges workflow files in a batch; nobody else, and never through a side channel. |
|
||||
| A card touches money or a human-only step (a purchase, a signature, a Whop upload) | Stop at the step, write what is ready and what is needed on the card, and escalate to the owner. Everything up to that step still gets done. |
|
||||
| You want a new skill, or a vendored one changed | `SKILLS.md` → Moves. One PR with the skill, its katas and a ledger line. |
|
||||
- Cost ladder for seats: Luna = haiku, Sol = sonnet, Astra = opus. Fable is for the operator's own maths, not the factory.
|
||||
|
||||
## Where things are
|
||||
- MCP source: `mcp/` (FastMCP, deploy with `fly deploy`).
|
||||
@@ -68,5 +45,4 @@ What to do when you meet one of these. Each row names the procedure; the procedu
|
||||
- Rebuild log: `docs/rebuild.md`.
|
||||
- Skills: `SKILLS.md` (routes, ledger, belts); the vendored folders are in `.agents/skills/`.
|
||||
- Time's engine: `teahubxyz/time` `.github/time/` (`time.py` the clock, `venture.py` the venture loop, `astra.py` the
|
||||
daily planner, `housekeeping.py` the daily sweep, `seats.json` the seats). Its SOPs: `.agents/skills/<name>/SKILL.md`
|
||||
in that repo. The planner, the steward and housekeeping all write to the "Astra log" issue there (time#57).
|
||||
daily planner, `seats.json` the seats). The planner and the steward both write to the "Astra log" issue there.
|
||||
@@ -75,13 +75,3 @@ Format: date · decision · why. Add at the bottom. Never edit an old entry; sup
|
||||
- 2026-10-15 · **Orgchain v1.13: whole trees change hands.** The operator asked for full holdings transfer next. An org now changes hands with its tree (the derived orgs and agents below it, and the items they hold), and a holding changes hands whole, sold by its owner, whom the lab wallet plays; the price goes there, and the holding becomes its buyer's next org. Sales stay cash-free: the money in the tree, every gas tank included, goes to the seller first, and the items go with the tree. An ask signs one input, so listing a tree bundles every inscription in it into one output at the lot's key; an offer spends every output the tree sits in and merges them. After the `join` and `adopt` the buyer splits the output back, one inscription to an output at its new key, each item with the node that held it, by the layout the deal recorded. A listed or sold tree is frozen whole, and a listed holding mines nothing (the default mining rule would otherwise have paid keys it was about to leave). Transactions take up to 64 inputs and outputs. Rehearsed on Bitcoin Core regtest from height 144, beside the earlier rehearsals (sixteen beats and 131 transactions: time with its six below it on an offer, then acme whole on an ask, eleven inscriptions in one output, each split back), and ord puts every inscription in the same output as the lab. `lineage/orgchain` main `74ed801`, time's `gh-pages` `07c3810`; 95 unit tests and Playwright 24/24. v1.12's commit went out under the Mac's default author by mistake; v1.13 is teahubxyz's again. Token 70 (`orgchain-holdings-20261015`, `write:repository`) did the pushes and is deleted by id right after; the table is checked. Next: pledge, a lien with a timelock. Why: a business is sold with what it runs and what it made, an owner can sell a holding whole, and the buyer should leave the deal holding every key.
|
||||
- 2026-10-15 · **Orgchain v1.14: soulbound belts.** The operator said belts shouldn't trade: they are soulbound, tied to an agent and moving with it, and pointed at ord's charms. A belt is now inscribed on its seat's own sat, as a reinscription: one reveal spends the seat's coin (the seat's own key co-signs, accepting the belt), the issuer's coin (the parent) and a commit that pays the fee, returns both coins unchanged, and points the belt at the seat's sat. ord gives it two charms, ♻️ reinscription and ❤️🔥 vindicated (a pointer and an envelope past the first input would have cursed it before the jubilee). So a belt travels with its seat through every act, graduation and sale, a tree splits back one inscribed sat to an output, and a belt is never a lot. An award costs two fees (1,000 sats) and no postage. The reducer is unchanged, since a belt was already bound to the seat it names; belts from before v1.14 stay with their issuers. The engine's sixth local change is that three-input reveal, and nothing looser. Rehearsed on Bitcoin Core regtest from height 161 (sixteen beats, 131 transactions): ord charms the three belts as the lab does, and after two whole-tree sales each belt still shares its seat's satpoint; the compare now checks satpoints and charms, and the v1.13 recording passes it too. `lineage/orgchain` main `c8c18b0`, time's `gh-pages` `7fa9f05`; 98 unit tests and Playwright 24/24. Token 71 (`orgchain-belts-20261015`, `write:repository`) did the pushes and is deleted by id right after; the table is checked. Next: pledge, a lien with a timelock (v1.15). Why: a belt certifies a seat, so it must never be sold apart from it, and keeping it on the seat's sat makes ord's account of where a belt is match the reducer's.
|
||||
- 2026-10-15 · **Orgchain v1.14.1: a belt counts only on its seat's own sat.** The operator agreed reinscription is the mechanism, since a belt is re-inscribed as it grows (white, green, black), and said older belts can go, as nobody uses the system yet. So placement is now a rule of `lineage/v0`, not just Orgchain's habit: an award counts only if it is inscribed on its recipient's own sat, which any indexer can check (the reducer compares sat numbers, or, without ord's sat index, satpoints, which two inscriptions share exactly when they share a sat). Belts inscribed elsewhere, as before v1.14, are rejected. A promotion is another reinscription on the same sat, over the belt before it; the reducer keeps each skill's ladder, Inspect shows it, and the sample's sol goes white, then green. An award and its recipient's own close no longer conflict within a block, since both spend the recipient's inscription. Rehearsed again on Bitcoin Core regtest from height 178 (sixteen beats, 133 transactions): ord shows sol's sat carrying sol, its white belt and its green belt, in order, each belt charmed ♻️ and ❤️🔥, and the compare matches; the fixture is re-recorded. `lineage/orgchain` main `5a7f11e`, time's `gh-pages` `4359351`; 100 unit tests and Playwright 24/24. Token 72 (`orgchain-belt-rule-20261015`, `write:repository`) did the pushes and is deleted by id right after; the table is checked. Next: pledge, a lien with a timelock (v1.15). Why: with the rule in the protocol, a belt is provably soulbound to anyone reading the chain, not only to Orgchain.
|
||||
- 2026-10-16 · **MCP 2.3.0: `tea_file_edit`, exact-text replacements in one file.** A commit through the MCP carries the whole file in one call, and one model answer carries about 100 KB at most, so `ventures/havre/app.js` (174 KB) could not take an eight-hunk change: three attempts stopped mid-call. The tool reads the file at the branch, applies the edits in order (each old text exactly once in the file as it stands), commits one update with the file's sha under the caller's own authority, and answers with the new size and sha256 to check against the caller's copy; same bounds as `tea_commit`, no deletes. Tests ran from a clean checkout on hb-5 (the Claude sandbox cannot reach PyPI). Issue #12, PR #13, merged on the operator's word in the chat; deployed as b5376e9d. Why: long files are normal in the factory, and a commit that cannot be made is a stuck card.
|
||||
- 2026-10-17 · **The merge gate moves into Time.** `touches_protected()` hard-codes only `.github/workflows/` and `.gitea/workflows/`; the rest is `TIME_PROTECTED`'s call, default unchanged (time #81). On `teahubxyz/time` the variable is `.github/workflows/,.gitea/workflows/,deploy,infra/,.env,secret`, so a card PR under `.github/time/` with a trusted Approve and green checks merges through `time`. #59 had sat three days with haiku's Approve, green CI and eleven steward sign-offs, each refused by the steward session's permission dialog; the CEO session merged #59, #74 and #81 on the operator's explicit word. The heartbeat job timeout is 55 minutes (workers overlap in one job, #75). Why: a steward that reports a block is a status page; a reviewed engine change should land without a hand.
|
||||
- 2026-10-17 · **Seats are Gitea users, one per model line.** This restores the standing rule that every agent acts as itself. Users `haiku`, `sonnet`, `opus`, `fable` (Claude) and `luna`, `terra`, `sol`, `astra` (Codex), write collaborators on `time`, each with one `time-seat` token staged as the repo secret `TIME_SEAT_<SEAT>`; these are the seat keys the standing rule asks to list here, plus the earlier `TIME_SEAT_CLAUDE` and `TIME_SEAT_CODEX` for the umbrella users `claude` and `codex`, which retire once the per-seat tokens are in use. A seat is a line, not a version. Attended sessions (claude.ai, ChatGPT, Cowork) are the operator, `teahubxyz`; the worker's pushes stay on `time`; a second route under a seat gets its own token so a route can be revoked without the identity. Tiers run across families: Astra = fable/astra (the C tier), Sol = opus/sol, Terra = sonnet/terra, Luna = haiku/luna, and the four loops are the four tiers. Each batch of secrets was placed from inside the Gitea container by a temporary admin token deleted by id right after; the table is checked and the operator account holds no tokens. Cards #76 (seats review as themselves) and #77 carry the code. Why: Gitea's own rules, no approving your own PR and trusted logins, mean something only when seats are distinct logins, and a council needs votes that carry identities.
|
||||
- 2026-10-17 · **Council: votes per seat, Venice breaks ties.** `TIME_REVIEW` lists the standing seats (`claude:haiku, codex` once Codex has a CLI route, time #79; `claude:haiku, claude:opus` until then); `TIME_REVIEW_TIEBREAK=venice:kimi` is called only on a split; `TIME_REVIEW_QUORUM` defaults to 1. Why: one reviewer is one opinion; cross-family agreement is the stronger evidence, and Venice credits go to ties alone.
|
||||
- 2026-10-17 · **Routing: Time wakes, Beth allocates, seats execute, reviewers verify, the operator changes the envelope.** Consequential acts (merge, retry, label, spend) run on the governor-gated routes, Time's code and the API and headless CLI seats on Fly, under the ledger and seat identities. Interactive chats carry the operator's authority, contribute judgment and may execute what their harness already authorizes, but production never waits on a chat waking up, and a permission denial is a property of a route, not a scheduling inconvenience. "What next" belongs to Beth and the agent board; the operator changes objectives, delegation and the financial envelope. Prod on Fly never depends on hb-5. Time retries its own parked cards (time #78), mentions are handoffs with receipts (#79), and the steward tick moves inside Time (#80), after which the desktop-app steward retires. Why: the operator's attention is the bottleneck to remove, and the arrangement was agreed between the Claude and Codex lanes on the operator's word.
|
||||
- 2026-10-17 · **The operator hears from the Astra tier only on exception or check-in.** Astra, the steward and the CEO session write to the bus (the Astra log, cards, decisions here) and do not report to the operator; they reach out only for an andon that needs money or a human-only step, or when the operator asks. Why: escalation runs up the tiers, and the top of the ladder is the operator's attention, which is the resource the factory exists to spare.
|
||||
- 2026-10-18 · **The monthly cap is the envelope; the daily cap is pacing, and a launched run finishes.** `TIME_MONTHLY_USD` (100) is the owner's number and changes only on the owner's word. `TIME_DAILY_USD` paces spend inside it and the CEO may set it with the owner's OK (set to 15 today, with `TIME_DAILY_CAP` 10 launches, from the defaults of 5 and 5); the daily cap gates launches, and a run that began within budget finishes up to `TIME_CAP_SLACK` x the cap (1.5), as does the review of a PR that is already open. Why: the first live wave tripped the $5 default after three worker runs, stopped a worker at step 27 with its spend lost, and left two green PRs unreviewed for a cheap haiku call; a cap that destroys work it already paid for is not thrift. (time #117)
|
||||
- 2026-10-18 · **A card names its base branch, and venture cards say `Base: gh-pages`.** The ventures live on `gh-pages`, an orphan branch; the worker cuts its branch from the card's `Base:` line and opens the PR against it, and every venture card carries the line. Why: the worker had branched from `main` whatever a card said, which is why #60, #63 and #95 ran out of turns and #109 landed the right files on the wrong branch. (time #117)
|
||||
- 2026-10-18 · **Claude seats call Anthropic's own Messages API with prompt caching.** The OpenAI-compatible endpoint has no caching; `TIME_ANTHROPIC_API=compat` is the way back if the native path misbehaves. Why: a 43-step run re-sent its whole context at full price every step and cost $2.80 for nothing; the same run with caching costs a fraction. (time #119)
|
||||
- 2026-10-18 · **A card is what a Terra worker finishes in forty turns; larger work is split before it is queued.** A spec-sized issue (time #72, #60, #63) is a parent labelled `planned`, never `queued`, and its children carry their own `DONE:` lines. Why: three cards died at the turn ceiling; each one cost a full run and produced nothing.
|
||||
Reference in new issue
Block a user