ClaudeMods
☰
KO
● 0 명 접속 중 · 조회 0 회
후원프로젝트 제출
GitHub 저장소 · 작성자 dsj1984

mandrel-status

베타, 읽기 전용: 프롬프트 위에 현재 /mandrel-deliver Story 표시

dsj1984@dsj1984

dsj1984/mandrel/tree/main/.agents/mods/mandrel-status

번역 완료

이 mod 소개

Mandrel

CI / CD

Story 중심 GitHub 오케스트레이션을 기반으로 한 AI 코딩 어시스턴트용 워크플로 프레임워크입니다. 계획, 실행과 상태가 모두 GitHub Issues, Labels, Projects V2 안에 존재합니다.

Prerequisites

Mandrel은 mandrel npm 패키지로 배포되며 프로젝트 GitHub 저장소에 오케스트레이션을 연결합니다. 미리 저장소나 원격을 만들 필요 없이 bootstrap.js가 콜드 스타트 중 git init → gh repo create --push → gh project create를 준비합니다. Node.js >= 22.22.1(< 25)、PATH의 git、인증된 GitHub CLI gh >= 2.40이 필요합니다. gh auth login 토큰에 project scope가 없으면 warn-and-skip-board가 되고, gh auth refresh -s project로 보드 생성을 켤 수 있습니다.

Quickstart

npx mandrel init        # install mandrel → sync → prompt → bootstrap → onboarding tail → /mandrel-plan handoff
# then, inside Claude Code (commands load from .claude/commands/):
/mandrel-plan --seed "…"   # interrogate → author one Story (default) → persist
/mandrel-deliver <id>      # story-<id> → PR → main

./.agents/가 없으면 npx mandrel init은 mandrel을 설치하고 mandrel sync로 구체화한 뒤 지금 구성할지 파일만 만들지 묻습니다. 옵션 1은 bootstrap.js, 스택 감지, 문서 스캐폴딩 제안, mandrel doctor 준비 게이트와 /mandrel-plan 인계를 실행하고, 옵션 2는 나중에 mandrel init을 다시 실행하게 합니다. --assume-yes를 전달하면 비대화형 구성으로 진행합니다. 이미 ./.agents/가 있으면 설치와 동기화를 건너뛰고, /mandrel-plan --seed "<idea>"로 첫 Story를 작성한 뒤 /mandrel-deliver <storyId>로 전달합니다(story-<id> → PR → main)。

Manual equivalent

npm install mandrel   # pin an exact, provenance-signed version
npx mandrel sync                # materialize ./.agents/ from the package
node .agents/scripts/bootstrap.js

npm install mandrel은 잠금 파일에 정확하고 출처가 서명된 버전을 고정합니다. postinstall 훅은 best-effort로 mandrel sync를 실행해 ./.agents/를 보통 자동 생성합니다. --ignore-scripts 또는 샌드박스 CI에서는 명시적 npx mandrel sync가 안전장치이며 npx mandrel doctor로 설치를 확인할 수 있습니다.

pnpm의 격리 레이아웃에서는 의존성이 .pnpm에 남아 최상위 node_modules에서 보이지 않습니다. .agents/scripts/*.js가 ajv、js-yaml、…를 찾도록 설치 전에 .npmrc에 다음을 추가하세요.

# Lift mandrel's runtime deps to the top-level node_modules so the
# materialized .agents/scripts can resolve them.
shamefully-hoist=true

더 제한적인 대안은 .agents/runtime-deps.json의 각 패키지에 public-hoist-pattern[]=를 지정하는 것입니다. complexity kernel의 폐쇄를 위해 목록을 복사하지 말고 파일을 읽으세요. mandrel doctor가 runtime-deps missing: …를 보고하면 이 설정이 해결책입니다.

bootstrap.js는 TTY에서 대화형으로 실행되며 git remote와 git config user.name에서 owner、repo、base branch、operator handle을 추론합니다. 추론할 수 없는 항목(보통 선택적인 Projects V2 number)만 묻습니다. 폴더나 GitHub 저장소가 없으면 git init과 첫 커밋, gh repo create --source=. --push, gh project create를 실행합니다. --visibility private|public|internal、--owner、--repo、--base-branch、--operator-handle、--assume-yes로 값을 덮어쓸 수 있으며 스크립트는 멱등적입니다.

참조 문서는 .agents/README.md、docs/SDLC.md、.agents/docs/configuration.md、.agents/docs/workflows.md에 있습니다.

Update

npx mandrel update

mandrel update는 npm view mandrel version으로 최신 버전을 확인하고 No-op이면 끝냅니다. 잠금 파일에서 패키지 관리자를 골라 Install하고 ./.agents/를 Sync, Migrate, Doctor한 뒤 changelog의 대상 섹션을 Surface합니다. 변경은 디스크에 staged로 남으며 git add나 git commit은 실행하지 않습니다.

Flags

--dry-run은 버전과 순서를 출력하고 종료합니다. --install-cmd "<cmd>"는 설치 명령을 덮어쓰고 {target}을 최신 버전으로 치환합니다. pnpm-lock.yaml은 pnpm add -D …, yarn.lock은 yarn add -D …, 그 외에는 npm install …를 사용합니다. 예: --install-cmd "pnpm add -D mandrel@{target} -w".

Manual equivalent

npm install mandrel@latest   # or pnpm add / yarn up
npx mandrel sync                        # re-materialize ./.agents/
npx mandrel doctor                      # verify the install

Benchmarking

효과는 독립 저장소 mandrel-bench 가 측정합니다. 게시된 mandrel 패키지의 consumer로서 특정 버전을 고정하고 mandrel sync로 전개한 뒤 /mandrel-plan→/mandrel-deliver 파이프라인을 시나리오에 적용합니다(bare-model 대조 포함)。Quality、Planning fidelity、Autonomy、Efficiency、Overhead ratio의 다섯 차원을 평가하고 잡음 구간이 있는 분포로 보고하여 bare-model 기준선 대비 부가 가치를 추적합니다.

하네스를 고정하고 mandrel 버전만 바꾸므로 harness-version과 framework-version을 분리할 수 있습니다. 게시 패키지 경로는 실제 소비자 계약을 검증합니다. 의존성은 단방향으로 mandrel-bench가 mandrel에 의존하며 역방향은 아닙니다. 자세한 내용은 mandrel-bench README를 참고하세요.

Contributors

게시된 mandrel 패키지는 .agents/、bin/、lib/와 docs/CHANGELOG.md를 포함하고 .agents/ 및 lib/ 아래 tests 하위 트리는 제외합니다. .agents/는 소비자의 ./.agents/에 구체화되고 bin/mandrel.js와 lib/ 구현은 node_modules/mandrel/에 남아 npx mandrel … CLI를 지원합니다. docs/、tests/、.github/와 루트 도구 설정은 내부 개발용입니다.

npm run lint           # biome + markdownlint + repo ratchets + generated-doc drift
npm run format         # biome format — JavaScript/JSON only, not markdown
npm test               # framework tests
npm run test:coverage  # tests with coverage gate

docs/architecture.md는 모듈 맵, 저장소 레이아웃, 상태 머신과 기술 스택을 설명합니다. .agents/docs/configuration.md는 .agentrc.json 키를, .agents/docs/workflows.md는 슬래시 명령 인덱스를, docs/CHANGELOG.md는 릴리스 기록을 설명합니다. AGENTS.md는 docs/onboarding.md로 연결되고 docs/release-operations.md는 Release Checklist、Install Matrix 릴리스 게이트、단일 패키지 릴리스 토폴로지、PAT / npm-token 설정과 메이저 버전 정책을 다룹니다. release-please는 main의 Conventional Commits에서 chore: release main PR을 만들고 CI 후 squash-merge、태그、npm 게시를 수행합니다.

.npmrc의 ignore-scripts=true로 npm install / npm ci 라이프사이클 훅은 기본 비활성화됩니다. 이는 CWE-1357에 대한 심층 방어이며 CI는 --ignore-scripts를 명시합니다. 필요할 때만 npm install --ignore-scripts=false를 사용하세요.

CRAP와 Maintainability 게이트는 .husky/pre-commit、.husky/pre-push、close-validation、ci.yml에서 .agentrc.json의 delivery.quality.*와 같은 임계값을 사용하는 차단 게이트입니다. pre-commit은 위반 시 커밋을 거부하며 npm run lint / npm test / check-baselines.js가 초록이어도 결과를 예측할 수 없습니다.

License

MIT

https://www.npmjs.com/package/mandrel

설치

먼저 작성자의 README에서 marketplace와 플러그인 이름을 확인하세요. 저장소 구조에 따라 명령어가 달라질 수 있습니다.

claude plugin marketplace add dsj1984/mandrel
claude plugin install mandrel-status
원문 / README

Mandrel

CI / CD

An opinionated workflow framework for AI coding assistants built on Story-centric GitHub orchestration. Planning, execution, and state all live natively in GitHub Issues, Labels, and Projects V2.

Prerequisites

Mandrel is distributed as the mandrel npm package and wires its orchestration into your project's GitHub repository. You do not need a pre-created Git repo or GitHub remote — bootstrap.js provisions both as part of a cold start (git init → gh repo create --push → gh project create). You need:

  • Node.js >= 22.22.1 (< 25).
  • git on your PATH.
  • GitHub CLI gh >= 2.40, authenticated — run gh auth login once so orchestration scripts pick up your token from the OS keychain. A vanilla gh auth login token does not carry the project scope needed to provision the GitHub Projects V2 board; bootstrap degrades to warn-and-skip-board in that case (no hard failure). To enable board provisioning, grant the scope with gh auth refresh -s project (re-auth in the browser when prompted) before running bootstrap.js.

Quickstart

The canonical cold-start path is one command, then one slash command:

npx mandrel init        # install mandrel → sync → prompt → bootstrap → onboarding tail → /mandrel-plan handoff
# then, inside Claude Code (commands load from .claude/commands/):
/mandrel-plan --seed "…"   # interrogate → author one Story (default) → persist
/mandrel-deliver <id>      # story-<id> → PR → main

npx mandrel init installs mandrel (when ./.agents/ is absent), materializes it via mandrel sync, then asks whether to configure now (option 1 → runs bootstrap.js, then the onboarding tail: stack detection, docs scaffolding offer, mandrel doctor readiness gate, and a /mandrel-plan handoff) or stop at just the files (option 2 → re-run mandrel init any time to configure). Pass --assume-yes for a non-interactive run that proceeds straight to configure (and forwards the flag to bootstrap). When ./.agents/ is already present (you ran npm install mandrel first), init skips the install/sync and goes straight to the prompt. Once mandrel init completes, you land at the /mandrel-plan handoff — run /mandrel-plan --seed "<idea>" to author your first Story, then deliver it with /mandrel-deliver <storyId> (story-<id> → PR → main).

Manual equivalent

If you prefer to drive the steps mandrel init wraps by hand, run them from your project root:

npm install mandrel   # pin an exact, provenance-signed version
npx mandrel sync                # materialize ./.agents/ from the package
node .agents/scripts/bootstrap.js

npm install mandrel pins an exact, provenance-signed version in your lockfile. The package's postinstall hook runs mandrel sync best-effort, so ./.agents/ is usually materialized automatically; the explicit npx mandrel sync above is the belt-and-suspenders step for --ignore-scripts or sandboxed-CI installs. Run npx mandrel doctor any time to confirm the install is healthy.

pnpm users — hoist mandrel's runtime deps. The materialized ./.agents/scripts/*.js run from your project root and resolve their third-party deps (ajv, js-yaml, …) from your top-level node_modules. npm and yarn hoist transitive deps there automatically; pnpm's default isolated layout does not — it keeps them in the .pnpm virtual store, so the framework scripts (and mandrel doctor's runtime-deps check) cannot see them. Add the following to your .npmrc before installing:

# Lift mandrel's runtime deps to the top-level node_modules so the
# materialized .agents/scripts can resolve them.
shamefully-hoist=true

Prefer a surgical alternative? Replace shamefully-hoist with a scoped public-hoist-pattern[]= line per package listed in .agents/runtime-deps.json — read the file rather than copying a list from here, since the complexity kernel's closure is several packages. If mandrel doctor reports runtime-deps missing: …, this is the fix.

bootstrap.js is interactive on a TTY and auto-accepts the owner/repo/base branch/operator handle it can infer from your local git remote and git config user.name — you only get prompted for fields it can't infer (typically the optional Projects V2 number). When the folder is not yet a git repo, or the GitHub repo doesn't exist, it provisions them: git init plus a first commit, then gh repo create --source=. --push (use --visibility private|public|internal, default private, to set the new repo's visibility), then gh project create for the Projects V2 board. Override anything inferred with --owner, --repo, --base-branch, or --operator-handle. For CI / scripted installs pass --assume-yes plus whichever overrides you need. The script is idempotent — safe to re-run anytime.

For the consumer reference and the end-to-end workflow narrative, see .agents/README.md and docs/SDLC.md. Every .agentrc.json key is documented in .agents/docs/configuration.md, and the slash-command index lives in .agents/docs/workflows.md.

Update

Advance mandrel to the newest published version and re-materialize ./.agents/ in one command:

npx mandrel update

mandrel update runs an ordered cycle:

  1. Resolve the newest published version (a npm view mandrel version registry probe) and the currently installed version.
  2. No-op short-circuit — already on the newest version ⇒ nothing to do.
  3. Install the target version with the project's package manager — auto-detected from the lockfile (pnpm-lock.yaml ⇒ pnpm, yarn.lock ⇒ yarn, otherwise npm) so the bump lands in your real lockfile. The dependency bump is left staged on disk — mandrel update performs no git add / git commit, so you review and commit the lockfile change yourself.
  4. Sync — re-materialize ./.agents/ from the freshly installed payload.
  5. Migrate — apply version-keyed migration steps for the crossed range.
  6. Doctor — run the check registry to verify the resulting install.
  7. Surface the target changelog section.

Flags

  • --dry-run — print the resolved target version and the ordered step plan, then exit. No dependency is bumped, no file is written, no seam runs.
  • --install-cmd "<cmd>" — override the auto-detected install command. The package manager is normally detected from your lockfile (pnpm-lock.yaml ⇒ pnpm add -D …, yarn.lock ⇒ yarn add -D …, otherwise npm install …), so an override is rarely needed. When you do pass one, a {target} placeholder is substituted with the resolved newest version — e.g. --install-cmd "pnpm add -D mandrel@{target} -w" — so the override can still consume the auto-probed version. The registry probe always stays on npm view (it is a PM-agnostic registry query).

Manual equivalent

If you prefer to drive the steps by hand:

npm install mandrel@latest   # or pnpm add / yarn up
npx mandrel sync                        # re-materialize ./.agents/
npx mandrel doctor                      # verify the install

Benchmarking

Mandrel's effectiveness is measured by a separate companion repo, mandrel-bench — a consumer of the published mandrel package. It pins a specific framework version, materializes it via mandrel sync, and drives Mandrel's own /mandrel-plan→/mandrel-deliver pipeline (plus a bare-model control) over a scenario corpus. Each run is scored across five dimensions — Quality, Planning fidelity, and Autonomy (what the scaffolding buys) versus Efficiency and Overhead ratio (what it costs) — reported as distributions with a noise-band, tracking the framework's value-add over the bare-model baseline across versions and models.

The benchmark lives in its own repo on purpose: holding the harness fixed while varying the pinned mandrel version cleanly decouples harness-version from framework-version, and running through the published-package + mandrel sync path exercises the real consumer contract. The dependency is one-directional — mandrel-bench depends on mandrel, never the reverse. See the mandrel-bench README for the dimensions, run model, and how to benchmark a new version.

Contributors

The published mandrel package ships three directories — .agents/, bin/, and lib/ — plus the single file docs/CHANGELOG.md, and excludes the __tests__ subtrees under .agents/ and lib/ (see the files array in package.json). .agents/ is the payload mandrel sync materializes into a consumer's ./.agents/ directory; bin/mandrel.js and its lib/ implementation stay inside node_modules/mandrel/ and back the npx mandrel … CLI used throughout this README. Everything else in this repository — docs/, tests/, .github/, the root tooling configs — is internal development tooling and is not published.

Common commands while developing the framework itself:

npm run lint           # biome + markdownlint + repo ratchets + generated-doc drift
npm run format         # biome format — JavaScript/JSON only, not markdown
npm test               # framework tests
npm run test:coverage  # tests with coverage gate

Deeper reference material lives in docs/ rather than inline here:

  • docs/architecture.md — module map, repo layout, state machine, and tech stack.
  • .agents/docs/configuration.md — every .agentrc.json key explained.
  • .agents/docs/workflows.md — slash-command index (auto-generated from the workflow set).
  • docs/CHANGELOG.md — release history.
  • AGENTS.md — the repository-level orientation pointer; it links on to docs/onboarding.md for the layout, commands, and development standards.
  • docs/release-operations.md — the Release Checklist, the Install Matrix release gate, the single-package release topology, PAT / npm-token setup, and the major-version policy. Releases are automated by release-please: land Conventional Commits on main and it opens a combined chore: release main PR that squash-merges itself once CI is green, tags main, and publishes mandrel to npm.

Install scripts are disabled by default: the committed .npmrc sets ignore-scripts=true, so npm install / npm ci will not execute dependency lifecycle hooks — a defense-in-depth measure against malicious lifecycle scripts in compromised transitive packages (CWE-1357). CI passes --ignore-scripts explicitly. If you knowingly need install scripts for a specific install, run npm install --ignore-scripts=false for that invocation only.

CRAP and Maintainability gates fire at four sites — .husky/pre-commit (quality-preview.js --staged, scored on the staged index), .husky/pre-push (diff-scoped against origin/main), close-validation (story close), and CI (ci.yml, push + PR) — against the same thresholds from delivery.quality.* in .agentrc.json. All four are blocking: the pre-commit hook fires earliest and refuses the commit on a threshold violation, and a green npm run lint / npm test / check-baselines.js run does not predict it.

License

MIT

비슷한 프로젝트