Skip to content

@gemstack/agent-data out of skill-branches; the branches SKILL.md for every place an agent wakes up - #1752

Merged
suleimansh merged 30 commits into
mainfrom
agent-data-lib
Sep 2, 2026
Merged

@gemstack/agent-data out of skill-branches; the branches SKILL.md for every place an agent wakes up#1752
suleimansh merged 30 commits into
mainfrom
agent-data-lib

Conversation

@suleimansh

@suleimansh suleimansh commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Preparatory work for #1750 PR (a) — not PR (a) itself: no branch rename, no queue split, no publish.

1. packages/agent-data — the data-branch machinery leaves skill-branches into a library: file-branch.ts, git.ts, git-exclude.ts (with their tests and SPECs, moved as renames), plus names.ts with BRANCHES_DIR and DATA_BRANCH = 'agent-data'. No SKILL.md, no command. skill-branches, skill-tickets and the framework import from it; the old copies are gone, nothing is re-exported. No behavior change.

DECISIONS.md in the package is the design record: the non-obvious decisions, in plain words — that is the file to review. skill-branches and skill-tickets get theirs in the same shape (#1750 point 7); the tickets one changes again with the queue split in PR (a).

2. skill-branches/SKILL.md rewritten. The dogfood (use-npm-skills 0.1.0, fresh clones) found two flaws: it said branches … without saying how to install the command, and it opened with "you were started inside .branches/agent-<id>/", false on a plain clone. Now: install the repository's dependencies, run npx branches; read where you are off npx branches status — an agent-* branch means a checkout was made for you, anything else means a plain clone and you branch with git switch -c agent-<name>. Leftovers of the report-the-name design removed. skill-tickets/SKILL.md gets the same install line and npx tickets; the framework's presets still say bare tickets … (they run where it is on the PATH) and change in PR (a) §6.

Open point, to settle before PR (a): npx never consults PATH. When @gemstack/skill-branches is not in the nearest node_modules, npx branches fetches the registry's branches@1.0.4 — a stranger's file-tree printer. This repository's root has no .bin/branches (the dependency sits in packages/framework), so a daemon-started agent following the new text would hit it. Same for npx tickets: the registry's tickets@0.2.2 is a JIRA tool. Either the skills become root devDependencies (what use-npm-skills adoption needs anyway) or the text says npx -p @gemstack/skill-branches branches.

Second open point, for PR (a): .branches/agent-data matches the agent-* pattern skill-branches lists and reclaims (any path-safe id counts, and data is one). After the rename, branches list would show the data checkout as agent data, and prune could delete it once it is clean and pushed. PR (a) either keeps the data branch out of that listing by name, or the branch gets a name outside the agent- prefix.

Left as-is on purpose: TICKETS_BRANCH = 'tickets' (the rename is PR (a)), holder.ts still reading the agent id off the checkout (AGENT_ID is PR (a)), the branch_yourself.md prompt bridge, repoHasRemote in skill-branches. The three DECISIONS.md describe the branch as it is after PR (a): the branch and its checkout are still named tickets, DATA_BRANCH has no importer yet, and the tickets skill still imports skill-branches for the holder.

Tests: agent-data 53, skill-branches 77, skill-tickets 57, framework 1386 + dashboard 865 — all green on fresh builds.

🤖 curated · Fable 5.1, effort high — the agent moved the files and drafted the SKILL.md and DECISIONS.md; I read both and stand behind them.

🤖 Generated with Claude Code

https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA

suleimansh and others added 30 commits September 2, 2026 00:37
A library, not a skill: `file-branch.ts`, `git.ts`, `git-exclude.ts`,
`BRANCHES_DIR` and the new `DATA_BRANCH = 'agent-data'` move into
`packages/agent-data` with their SPECs. skill-branches, skill-tickets and
the framework import them from there; no re-exports, no behavior change.
Part of #1750 PR (a).

🤖 curated · Fable 5.1, effort high

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
… DECISIONS.md

The skill installs and runs its command as `npx branches`, reads where it
is off its branch (a checkout made for it, or a plain clone), and drops
the leftovers of the report-the-name design. The library's DECISIONS.md
records the human decisions behind the package, dated and attributed.

🤖 curated · Fable 5.1, effort high

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MwF8Navc7vvfDT65t7JZiA
…branches/

The agent-* paragraph no longer asserts the .branches/ layout: a plain clone on an
agent branch (a cloud session, a person continuing an agent's branch) reads it too.
The explaining sentence about the file existing twice goes; the frontmatter
description is one plain sentence; status is said to print JSON.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
…son named

`queue done` matched nothing when given the text passed to `queue add --ticket`:
the entry is the link the queue prints. meta.json says whose file it is. One
duplicate sentence gone.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
The archives are not on this branch; the sync failure is the caller's to report,
not a dashboard's; the import rule was already stated under the first bullet.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
…ckage links

The .branches/<name> link after a rename was a decision the file did not hold. The
sentence claiming npx finds the package the same way from a checkout goes: that is
the PR's open point. The skill folder is linked whole, not a SKILL.md shortcut;
'GitHub' is the remote; <id> says who names it.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
… the remote

A close is refused for a non-holder, so the claim rule says so; put never writes a
lock; the planning-claim rule without the library's batch; 'GitHub' is the remote.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
… births stated

A stranger could not place 'a long-running process', did not know what a write does
after two failed pushes, and was not told that a stranded commit is dropped when it no
longer applies. Two decisions the file did not hold: the branch is born parentless, and
.branches/ is hidden through git's exclude file, never a committed .gitignore. The
git-code bullet restated the first one and goes.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
…, who pushes

The rename link is .branches/agent-<name>, as the branch is named; the file said
.branches/<name>. The reclaim pushes the branch itself when allowed, which read as a
contradiction of 'the agent never pushes'. Naming goes through the command. 'instant
and free' was padding.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
… claims explained

'The data branch' and 'put' appeared from nowhere; the command's verbs are listed once.
What a planning claim skips, who reads a queue link, and who releases a dead agent's
claims are said.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
…rop said

'Carried by the next write' and 'dropped when it no longer applies' read as two rules;
they are one, and the drop tells nobody.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
Two agents naming the same thing at once race on the rename and the loser takes the next
suffix, which a rebuild would not do on its own. 'Committed into the repository' now says
which repository.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
… goes

meta.json is the importing program's bookkeeping, opaque to the skill. An entry with no
priority goes to the end of the file; a linked one takes the ticket's priority, 5 when
the ticket has none.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WDPvXJ7KN5Msffxmc3vYvi
@suleimansh
suleimansh merged commit 365e546 into main Sep 2, 2026
2 checks passed
@suleimansh
suleimansh deleted the agent-data-lib branch September 2, 2026 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant