.agents/docs/seam-design.md
Date: 2026-06-18 Status: approved direction, updated 2026-06-21
The pr-batch family and related agent workflows are useful across ShakaCode
repos, but repo-local copies can mix reusable process with repo-specific
commands, labels, release policy, paths, and domain examples. We want agents to
carry these workflows across repos without copying a stale .agents/ tree into
every repository or making each repo responsible for shared workflow updates.
Make shared skills portable by installing them in the user or agent environment,
then make each repo expose a small, validated AGENTS.md seam that supplies the
repo-specific values the portable skills need.
shakacode/agent-workflows
skills/... and workflows/... portable process, installed per user/agent
bin/... install, status, upgrade, and validation helpers
consumer repo
AGENTS.md canonical policy plus Agent Workflow Configuration seam
.agents/bin/agent-workflow-seam-doctor
optional local checker copy for the seam contract
.agents/skills/... repo-specific skills or explicit overrides
.agents/workflows/... repo-local workflow files only when the repo needs them
The default distribution path is this repository plus the user's normal skill
installation mechanism. For example, an agent may install the shared
pr-batch, verify, address-review, and changelog skills once into Codex or
Claude and use them in any repo. The skill then reads the target repo's
AGENTS.md seam to resolve concrete commands and policy.
Repository-pinned shared skill copies remain an optional escape hatch for environments that need exact workflow text in the checkout, such as cloud agents that cannot use a user skill install. They are not the default design; in this repo, keeping shared copies would duplicate installed Codex picker entries and should be justified by a specific reproducibility or execution-environment need.
Each adopting repo owns a section named ## Agent Workflow Configuration in
AGENTS.md. Shared skills may refer to these values by name:
/simplify to pin oneThe seam is deliberately human-readable because AGENTS.md is already the
repo's canonical agent policy. Add a structured config file only when a
non-LLM script needs to consume the values mechanically.
agent-workflow-seam-doctor checks the boundary between portable skills and the
repo:
AGENTS.md has the required seam keys<follow-up prefix>It does not reject ordinary command parameters such as <PR> or <sha>. Those
are task inputs, not repo-seam values.
git subtree solves "every repo has a pinned copy of the shared files," but
that is not the primary problem. The primary problem is whether a portable skill
can safely resolve repo-specific behavior. A subtree also makes the .agents/
prefix all-or-nothing, which is awkward when a repo has real local skills such
as destructive framework stress tests or product-specific release helpers.
Use a repository-pinned copy only when the execution environment cannot depend
on user-installed shared skills or when the repo intentionally wants to review
shared workflow updates like source code. Otherwise, install
shakacode/agent-workflows once for the user/agent and validate each repo's
seam.
Shared skills should contain portable procedure and safety rules:
Shared skill installation must include each skill's bin/ helpers with its
SKILL.md, and workflow text should call helpers relative to the installed
skill directory or through a repo-local helper copy. A repo that can load
installed skill Markdown but cannot execute installed helper scripts should pin
the helper scripts locally without adding duplicate shared SKILL.md files.
Repo-local content should contain concrete policy and domain knowledge:
AGENTS.mdagent-workflow-seam-doctor, and point adoption docs at this repository.shakacode/agent-workflows, install it in the agent
surfaces ShakaCode uses, and run bin/validate before updates. Use
agent-workflows-status and upgrade-agent-workflows for ongoing installed
pack maintenance.Run from the shakacode/agent-workflows shared pack root:
bin/validateruby bin/agent-workflow-seam-doctor-test.rbbash bin/install-agent-workflows-test.bashRun from a consumer repository:
bin/agent-workflow-seam-doctor --root <consumer-repo> --shared <this-repo>