Skip to content

workspace: commit trailers for leases, runs, records and applies, replacing studio's Studio-* and Factory-* trailers #3149

Closed

Description

@lex00

Part of #3145. Related: #3033, #3035, #3036, #3037.

Problem

Studio joins commits to work, contracts and leases through its own trailers, and publishing a build adds more:

trailer meaning location
Studio-Author: factory / studio-init / studio-migrate / design-app who authored the commit record.mjs:40, setup-app.mjs:14, upgrade-app.mjs:44
Studio-Unit, Studio-Contract, Studio-Driver, Studio-Evidence joins to records record.mjs:109,125-131, decision.kind.mjs:132
Factory-Lease, Factory-Note joins to the lease record.mjs:161
Applied-By, Applied-At, Applied-Commit (always --no-ff) a person applying a built branch apply.mjs:220-225

chant has the Chant-Agent trailer (ws-067) and the commit-join hook (#2663), but no vocabulary for leases, runs, records or applies.

Proposal

This issue (#3149) owns all commit trailer names, including the run trailer.

Activity

  1. added
    enhancement
    area:workspace
    provenance
    boundaries
    on Oct 1, 2026
  2. lex00 commented on Oct 3, 2026

    @lex00
    ContributorAuthor

    Design as built in #3295, recorded as ws-075.

    The trailers are Chant-Agent (unchanged from ws-067), Chant-Lease: <fencing token>, Chant-Run: <run id>, Chant-Record: <kind>:<id> (repeatable, kind is the record kind's name) and, on the commit that applies a leased branch, Chant-Applied-By, Chant-Applied-At and Chant-Applied-Commit. The names live in packages/core/src/workspace/trailers.ts with formatChantTrailers and readChantTrailers. chant still never makes a commit; the writer adds the lines. chant workspace runs start (#3033) prints the Chant-Run line for the run it opens.

    graph --intent gives every commit node a joins object: agent, lease as { token, item }, run, records as { kind, id, node } and applied as { by, at, commit }. The lease's item comes from the lease histories on the local chant/lifecycle branch (a git grep over **/_leases/*.jsonl, any member's ledger, never fetched). A Chant-Record of a kind the walk reads, or a lease's work item, gets a new carries edge, and the commit is then the own work of the decision it names or that the work item implements: decided instead of decided-by-window, and not intent-commit-bare. graph --intent --record reports the same joins and buckets such a commit own. Both are additions within read contract 1.

    Studio's mapping, one to one: Studio-Unit: W-1 becomes Chant-Record: work:W-1; Studio-Contract, Studio-Driver and Studio-Evidence become Chant-Record: contract:C-1, driver:D-1, evidence:<sha256>; Factory-Lease becomes Chant-Lease; Studio-Author: factory becomes Chant-Agent: factory (the factory declared as an agent session); Applied-By/At/Commit become Chant-Applied-By/At/Commit. Factory-Note stays text in the message body. Contract, driver and evidence refs resolve to graph nodes once those kinds exist (#3148); until then they are reported with node: null, so studio can switch trailers before #3148 lands and keep its commitJoins plugin for those kinds in the meantime.

    Two parts re-scoped. The apply stays a commit with trailers and does not also get a ledger line: the merge commit already holds who, when and which tip, and ws-068 keeps ledgers for facts made off the working branch (ws-075 option e, rejected with that reason). Author classes beyond Chant-Agent (studio-init, studio-migrate and plugin-defined classes) are #3080: a commit with no session is judged by its author and signature as before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:workspaceboundariesenhancementprovenance

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions