granite.build: Command for Claude Code

.claude/commands/start-issue.md

start-issue is a command for Claude Code from ibm-granite/granite.build. It costs 19 tokens per session (1,343 once invoked), scanned B, original, Apache-2.0.

A GitHub-issue starting workflow that checks the repository, creates an isolated Git worktree, loads architecture documents, and plans the implementation.

In plain words
What is it for?
Use it when beginning a numbered GitHub issue to verify the branch and working tree, read the issue and project design notes, assess existing work, and prepare a plan.
Why use it?
It gives issue work a repeatable starting point and keeps changes separate from the main working directory. A worktree is another checkout of the same repository for independent work.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter. Also seen: reads .claude/ paths.

This is ibm-granite/granite.build's own configuration. It tells Claude Code how to work on granite.build itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything granite.build configures →

Needs its repository: it reads a path above its own folder, which exists only inside the repository. The line is WORKTREE_BASE=../granite.build-worktrees.

Reuse

Borrowing it

Nothing to install: this file belongs to ibm-granite/granite.build. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/ibm-granite/granite.build/main/.claude/commands/start-issue.md
Clone the repo
git clone --depth 1 https://github.com/ibm-granite/granite.build

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for start-issue

README.md
[![agentmods](https://agentmods.dev/badge/commands/ibm-granite/granite.build/start-issue.svg)](https://agentmods.dev/commands/ibm-granite/granite.build/start-issue)
Your own site
<a href="https://agentmods.dev/commands/ibm-granite/granite.build/start-issue"><img src="https://agentmods.dev/badge/commands/ibm-granite/granite.build/start-issue.svg" alt="Measured on agentmods" height="20"></a>
Per session 19 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,343 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00019 $0.01343
Opus 5 $0.00010 $0.00672
Sonnet 5 $0.00004 $0.00269
Haiku 4.5 $0.00002 $0.00134

Measured 2d ago against content hash 15fa591b8d20, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade B, and why

start-issue scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Reads agent configuration directoriesmediumAgent snooping

.claude/, .codex/, .gemini/ hold keys, settings and other credentials a mod has no legitimate need for.

cp -r .claude/settings.json $WORKTREE_BASE/<branch-name>/.claude/settings.json 2>/dev/null || true
.claude/commands/start-issue.md · 130 lines

How it starts

The opening of the file, as written. The whole thing — 130 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Start Work on a GitHub Issue

You are helping a developer start work on a GitHub issue. You will verify pre-conditions, create an isolated git worktree, load the issue and architecture documentation, assess what's already been implemented, and plan the work. Follow these steps in order, stopping if any step fails.

Issue number: $ARGUMENTS

Defaults

These values can be overridden by the user but apply by default:

ARCH_DOC_1=docs/plans/2026-02-23-architecture.md
ARCH_DOC_2=docs/plans/2026-02-18-standalone-deployment-design.md
WORKTREE_BASE=../granite.build-worktrees

Derive the fork owner and repo:

FORK_OWNER=$(git remote get-url origin | sed -E 's|.*[:/]([^/]+)/.*|\1|')
FORK_REPO=$(git remote get-url origin | sed -E 's|.*[:/][^/]+/(.*)$|\1|' | sed 's/\.git$//')

Step 0: Pre-flight checks

  1. If $ARGUMENTS is empty or not a number, show usage and stop:
    Usage: /start-issue <issue-number>
    Example: /start-issue 42
    
  2. Confirm we are on the main branch:
    git branch --show-current
    
    If not on main, warn the user and ask whether to switch (git checkout main) or abort.
  3. Check for uncommitted changes:
    git status --porcelain
    
    If there are uncommitted changes, ask the user what to do:
    • Commit them before proceeding (always use git commit -s — the upstream repo enforces the DCO check)
    • Stash them (git stash push -m "stash before issue-$ARGUMENTS")
    • Abort and let the user handle it manually
  4. Fetch the latest upstream:
    git fetch upstream
    

Step 1: Create branch and worktree

  1. Fetch the issue title to verify the issue exists and to derive the branch name:

    gh issue view $ARGUMENTS --repo "$FORK_OWNER/$FORK_REPO" --json title --template '{{.title}}'
    

    If the command fails (issue doesn't exist), report the error and stop.

  2. Slugify the title: lowercase, replace non-alphanumeric characters with hyphens, collapse consecutive hyphens, strip leading/trailing hyphens, truncate the slug so the total branch name (issue-$ARGUMENTS-<slug>) stays under 50 characters. Branch name: issue-$ARGUMENTS-<slug>

Read the full file on GitHub · 130 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 130 lines · 19 tokens per session scan B 15fa591b8d20

Subscribe to this mod's changes

start-issue is a command published in the GitHub repository ibm-granite/granite.build (44 stars, last pushed 2d ago), licensed Apache-2.0. It adds 19 tokens to every session and 1,343 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (reads agent configuration directories). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.