Skip to Content
turbo-12f
Architecture

Delivery, operations, and Observer

How DevOps manages bootstraps and dry-run promotions, Release gates and bisects staging, SRE watches live URLs, and Observer resolves waiting items.

Explanation

Four components handle repository onboarding, staging-to-main releases, post-release monitoring, and optional unattended operator decisions (devops, release, sre, and internal/observer).

Onboard

DevOps

Bootstrap or adopt repos, run Project Gate, and build dry-run artifacts.

Gate

Release

Verify whole-tree staging checks, bisect failures, and merge to main.

Monitor

SRE

Probe live URLs, group errors by fingerprint, and triage or roll back.

Automate

Observer

Resolve waiting items every 10s via read-only UI sessions when enabled.

DevOps (internal/roles/devops)

internal/roles/devops runs pure Go automation (zero LLM calls) with defaultCommandTimeout = 10m. In the team flow DevOps is the team member who owns each lane's merge-policy, merge and deploy-dry-run steps (scripts, no agent session); the classic flow runs the same three steps. Standalone Install (deploy.go) retries timed-out installs up to InstallTimeoutRetries (2), while Gate and DeployDryRun run the install once (DeployDryRun only when the tree has no node_modules).

CapabilityFilesWhat Go does
Bootstrap, Init & Adoptbootstrap.go, connect.go, adopt.goBootstrap scaffolds the starter template, .t12/ config, and CI workflow into a new repository. A clone with no commits (what GitHub hands out for a repository the factory just created under the person's own account) counts as empty and keeps its origin. A non-empty repo that is not already bootstrapped (no .t12/config.json) is refused. InitLocalProject does the same for t12 repo init, and treats the cloud's registration of the same repository under the same name as its own; another repository under that name is refused. Adopt takes an existing repo via project.Detect (Node.js, Go, Python, Rust, Effect-TS) onto staging or t12-staging.
Project Gategate.go, depscache.goVerifies the .t12/ config files, that every role's skills resolve to their pinned hashes (skills.Check()), both branches, and the toolchain; installs dependencies through the deps-cache; then runs build, lint, typecheck and unit in the cage on the staging base. A command that is a no-op is recorded as such, so a ["true"] placeholder never reads as a green check.
Dry-run & Promotedeploy.go, promote.go, account.goBuilds staging in cage and keeps the artifact as an artifact document (key <project>/<tree>); nothing is uploaded at this step. The built dist/ is a rebuildable cache under <home>/artifacts/. Promotions go to the promotions:<project> log stream. With no hosting account connected the deployer is DryRunOnly{} (H10): production stays a dry run, and the release gate says to connect an account. With a Cloudflare (token and account id) or Vercel connection of the person's own, AccountDeployer deploys the artifact (Cloudflare Workers through wrangler, or static files to Vercel; a project that needs its Worker needs Cloudflare), checks that the site answers, and redeploys the previous tree if it does not. RollBack works within 24h.

Release (internal/roles/release)

internal/roles/release is a pure Go gatekeeper triggered on the release lane, t12 release gate, and t12 release merge.

It reads the project's release ledger from the database, bisects failing trees (Bisect / AddFixLane), and promotes clean trees to main. The ledger is a release-checks document per <project>/<tree> plus the release:<project>:signoffs and release:<project>:holds log streams. The release checks run qc, ui-check, a red-team session on twice a single lane's budget, the deploy dry-run, and explorer when qc.explorer is on. On Adopted repos, release.Open pushes only the staging branch and opens the PR without creating a repo or pushing main. RenderPRBody (summary.go) formats PRs outcome-first with deslop.CheckProse warnings and ends with a Closes #N line for each GitHub issue the conversations' records name, so the merge closes them.

See Release and SRE for the 4-part gate, --no-ff merge sequence, and bisection rules.

SRE (internal/roles/sre)

internal/roles/sre pairs deterministic HTTP probing (t12-adapter sre probe --url) with a 10m NoCommands: true triage session (triage.go). The t12 sre watch and triage commands are the same in both flows; the per-lane sre step is the last step of a classic lane only, and the team flow has no such step.

It keeps the normalized fingerprints of each project in the sre-fingerprints document (key: the project), files follow-up requests on project defects, or triggers devops.RollBack. See SRE watch, triage, and rollback.

Observer (internal/observer)

internal/observer runs inside t12-ui every 10s once an Operator switches it on for chosen projects or conversations (the observer-setting document; POST /api/observer needs an Operator). The cloud build does not start the loop. Each cycle recovers any interrupted item, picks the top waiting item in scope, and acts for the request's opener, or for the Operator who enabled it when no person opened it. It injects that person's UserProfile and any roles.observer override, then runs a 5m NoCommands observer.md session that reads only the evidence staged for the item.

Waiting item priority order (kinds.go)

PriorityKindAllowed actionsRequired rightBlocked by active job
1commandallow, denyacceptorNone (never)
2approve-partapprove, send-backacceptoraction job
3stuckretry, waitrunaction or build
4answeranswer, decide-for-meeditoraction job
5confirmconfirm, answer, waitacceptoraction job
6buildbuild, waitacceptoraction or build
7signoffsignoff, hold, waitacceptoraction job
8holdhold, waitacceptoraction job
9releaserelease, waitacceptoraction or build

The rights come from the acting person's access to the request. On a team project, acceptor, editor and run belong to its owners, members and Operators; a client who opened the request has only acceptor, so only acceptor kinds. On a request with no project, the opener has all three. A confirm item needs a project name when the request has none, and release only appears for a person who made the latest sign-off.

Key takeaway

Delivery and operations stay deterministic by default: DevOps, Release, and SRE use scripts for every gate, and even optional Observer automation runs toolless and writes an auditable decision per action.

Next steps

On this page