Mirion Medical Claude Code Standard Operating Procedure — Version 1.0
| Document Title | A3C Claude Code Usage for Requirements, Development, and QA |
| Document Type | Standard Operating Procedure (SOP) |
| Business Area | Mirion Medical |
| Owner | AI Adoption and Acceleration Committee (A3C) |
| Version | 1.0 (03/28/2026 Dave Olund) |
| Status | Published |
This SOP defines how Claude Code is to be used to support requirements authoring, software development, documentation, and QA test creation in a controlled, reviewable, and maintainable way. It establishes standard practices for TPMs, developers, and QA staff so that AI-assisted work improves delivery without reducing engineering rigor, traceability, or accountability.
This SOP applies to approved Claude Code usage for product requirements, design exploration, code generation, documentation updates, review preparation, manual test case generation, and automation test scaffolding within approved organizational environments. It covers collaborative use across TPM, development, and QA roles where work is performed in shared repositories and supported by common Claude context files and project plans.
Each active repository should maintain a concise CLAUDE.md file that serves as the master index of project context. It should contain only the information that Claude needs regularly, such as project overview, tech stack, key directories, build/test commands, and references to deeper documentation.
Detailed documentation should be stored in smaller topic-specific markdown files under .claude/docs/. Examples include architecture notes, patterns, standards, domain rules, dependencies, testing guidance, and edge-case references. Technical docs will also include domain-specific context files like patient_context.md and domain_glossary.md for domain terminology.
Features, migrations, larger bug fixes, and major QA efforts should use phased project plans stored in a defined markdown location such as .claude/project/plans/ or an equivalent as work progresses.
A lessons.md file should be maintained to capture repeat issues, debugging lessons, anti-patterns, clarifications, and team learnings that should influence future Claude-assisted work across sessions.
When AI-assisted work moves from one role to another, the minimum persisted artifacts should include any shared CLAUDE.md updates, relevant .claude/docs updates, active project plans, and lessons learned that materially affect handoff and continuity.
Any pull request containing AI-generated or AI-assisted changes must be reviewed with the same or greater rigor as a manually authored pull request.
Larger, structural, risky, or architecture-significant changes should receive review from senior technical leads or architects in addition to standard peer review.
New features or materially changed behaviors should include unit tests or other suitable verification coverage so the code remains maintainable and reviewable over time.
The individual who submits or commits AI-assisted work remains accountable for the quality, correctness, and maintainability of that work. AI assistance does not reduce ownership, review expectations, or defect accountability. All AI-assisted changes must maintain requirement traceability from ticket to commits and pull request.
Repositories and project workspaces should retain committed Claude-related artifacts in accordance with normal engineering repository practices and any applicable organizational retention standards. Teams should avoid committing low-value or redundant generated files, but should preserve the markdown artifacts needed for continuity, auditability, and reuse.
This appendix captures commands, workflows, and prompt patterns. It is intended as a practical reference, not as a replacement for the main SOP instructions.
Custom slash commands will be stored in .claude/commands and will be added to the below list in the future.
These notes explain why certain standards appear in the SOP. They are included as background context rather than as direct work instructions.
Agent-Driven Development Lifecycle — The complete developer hand-guide from session start to merged PR
az login.
| # | Step | Driver | AI | Gate / Loop |
|---|---|---|---|---|
| 01 | Start a named session | Developer | — | — |
| 02 | Pull requirements from JIRA | Developer | ● | — |
| 03 | Implementation Plan | Developer | ● | — |
| 04 | Implementation Plan Review | Developer | — | ● GATE |
| 05 | Update JIRA | Developer | ● | — |
| 06 | Implementation & refinement cycle | Developer | ● | — |
| 07 | Code cleanup | Developer | ● | — |
| 08 | Update comments & documentation | Developer | ● | — |
| 09 | Security review | Developer | ● | ↻ 6 |
| 10 | SonarQube quality dashboard | Developer | ● | ↻ 6 |
| 11 | Create PR / Commit | Developer | ● | — |
| 12 | PR Review — GitHub Copilot | Developer | ● | ↻ 6 |
| 13 | Peer Review PR | Senior Developer | ● | ● GATE ↻ 6 |
| 14 | Merge PR, handoff & close | Developer | ● | — |
az login.
(3) Verify with claude /doctor.
| Transport | When to use | Add-command shape |
|---|---|---|
| http | Official remote MCP (GitHub, etc.) | claude mcp add --transport http [flags] <name> <url> |
| sse | Remote MCP where HTTP isn't available. Deprecation path. | claude mcp add --transport sse [flags] <name> <url> |
| stdio | Local process — community servers, dev tools. | claude mcp add [flags] <name> -- <command> [args...] |
| Scope | Stored in | Shared with |
|---|---|---|
| local (default) | ~/.claude.json | Just you, current project |
| project | .mcp.json at repo root | Your whole team |
| user | ~/.claude.json (global) | Just you, across every project |
| Command | Alt. | Description | When to use |
|---|---|---|---|
| /rename | — | Name the current session | Session start |
| /resume | — | Jump back into a named session | Resume work |
| /status | — | Confirm API usage, environment, default model | Before work |
| /doctor | — | Environment diagnostics | Troubleshoot |
| /config | — | Open interactive settings editor | Configure |
| /plan | Shift+Tab ×2 | Enter plan mode | Task start |
| /clear | — | Reset context window | Between tasks |
| /compact | — | Compress context preserving key info | >70% context |
| /context CC-2026 | — | Show what is loaded into context | Orient yourself |
| /branch CC-2026 | /fork | Branch conversation into new session | Explore forks |
| /memory | — | View and edit CLAUDE.md and auto-memory | Session end |
| /export | — | Export full conversation as text | Documentation |
| /copy CC-2026 | — | Copy Claude's output to clipboard | Share output |
| /add-dir | — | Add another directory to session scope | Extend scope |
| /effort | — | Set thinking depth: low/med/high/max (xhigh on 4.7) | Tune reasoning |
| /model | — | Switch models mid-session | Change model |
| Command | Alt. | Description | When to use |
|---|---|---|---|
| /security-review CC-2026 | — | Analyze pending changes for security issues | Before commit |
| /review | — | Built-in code review against base branch | Step 13 |
| /simplify | — | Refactor to reduce complexity | After impl. |
| /debug | — | Enable debug logging | Build failures |
| /diff CC-2026 | — | Diff viewer for uncommitted changes | Before commit |
| /insights CC-2026 | — | Session analytics | Retrospective |
| /cost | — | Token usage and cost for session | Budget check |
| /usage CC-2026 | — | Plan-level usage limits | Capacity check |
| Command | Alt. | Description | When to use |
|---|---|---|---|
| /permissions | — | Manage allow/ask/deny rules | Harden setup |
| /sandbox | — | Open sandbox configuration | Regulated runs |
| /agents | — | Manage subagent configurations | Multi-agent |
| /hooks | — | Browse configured hooks | Audit hooks |
| /mcp | — | MCP server status + OAuth | MCP ops |
| Command / Key | Alt. | Description | When to use |
|---|---|---|---|
| claude -w | --worktree | Launch in isolated git worktree | Parallel tasks |
| claude -c | --continue | Continue most recent conversation | Resume work |
| claude -r | --resume | Resume a specific named session | Named sessions |
| claude -p | Non-interactive print mode | Scripting | |
| Esc+Esc | /rewind | Browse checkpoints — restore code or conversation | Undo mistakes |
| Shift+Tab | — | Cycle permission modes | Mode switch |
| Alt+V | — | Paste screenshots/images | UI work |
| Ctrl+G | Ctrl+X Ctrl+E | Open prompt in $EDITOR | Edit prompt |
| Mode | Behavior | Use for |
|---|---|---|
| default | Asks before every file change and command | Sensitive work, starting out |
| acceptEdits | Auto-approves file edits; still asks for commands | Iterating on reviewed code |
| plan | Read-only; generates a plan, makes no changes | Step 3 — always |
| auto | Sonnet 4.6 classifier auto-approves safe calls. Admin-enabled. | Long-running trusted tasks |
| dontAsk | Auto-denies anything not on allowlist | CI pipelines, locked-down |
| bypassPermissions | All prompts off. No prompt-injection protection. | Isolated containers only |
./CLAUDE.md → ~/.claude/CLAUDE.md → ./CLAUDE.local.md.claude/rules/*.md with paths: frontmatter. Target: under 100 lines. Move architecture, doc indexes, and pattern references to .claude/docs/.
.claude/skills/<name>/SKILL.md. Descriptions always loaded; bodies load only when invoked. Build a skill for any workflow you repeat more than once a week.
~/.claude/projects/<project>/memory/MEMORY.md). First 200 lines or 25KB auto-load each session. End sessions with: "Update what we did to the project knowledge base."
| Ticket Type | Load These Files | Skip These Files |
|---|---|---|
| Backend feature / bug | backend.md | frontend.md, module_map.md |
| Frontend / UI | frontend.md | backend.md, module_map.md |
| Database / schema change | databases.md, backend.md | frontend.md, module_map.md |
| Cross-cutting refactor | module_map.md, backend.md | frontend.md |
| Domain-specific (dose, auth, audit) | glossary.md, frs.md + relevant module file | module_map.md unless cross-cutting |
| Test coverage only | Relevant module file only | glossary.md, frs.md, module_map.md |
| Doc / config only | None beyond CLAUDE.md | All .claude/docs/ files |
| Skill Name | Trigger | Loads |
|---|---|---|
| domain-glossary | When Claude needs RT QA terminology or domain term clarification | glossary.md |
| requirements-lookup | When checking acceptance criteria against FRS or verifying a business rule | frs.md |
| lessons-review | At session start on tickets in a previously-worked area | lessons.md (filtered by relevant domain) |
.claude/docs/ or convert it to a Skill..claude/docs/architecture.md | Service boundaries → same file | 9-file doc index → replace with 3-line summary| Event | Cadence | Common use |
|---|---|---|
| SessionStart | Per session | Inject branch/ticket context; audit-log |
| UserPromptSubmit | Per turn | Validate prompts; enforce context |
| PreToolUse | Per tool call | Security gate — exit 2 blocks the call |
| PostToolUse | Per tool call | Auto-lint, format, emit audit event |
| Stop | Per turn | Run tests, emit session-end events |
| SessionEnd | Per session | Archive artifacts; flush audit buffer |
.tool_name, .tool_input, .tool_response, .session_id, .cwd| Practice | Description | Source |
|---|---|---|
| You Own the Commit | The person who submits AI-assisted work remains accountable. Review every line. | SOP §12 |
| Maintain Requirement Traceability | JIRA ticket → commits → PR. Use JIRA ID in branch name. | SOP §12 |
| Persist the Handoff | Commit CLAUDE.md, .claude/docs/, plans, lessons.md when they affect future work. | SOP §6.5, §13 |
| One Task = One Session | Keep sessions focused. At 90% context, performance degrades. Use /clear between tasks. | Anthropic Docs |
| Story-Level Work Items | Assign complete stories that exercise all fourteen steps. | Pilot Retrospective |
| Hooks Over Instructions | Hooks are deterministic; CLAUDE.md is advisory. Use hooks for enforcement. | Anthropic Docs |
| Checkpoints Are Free Undo | Esc+Esc opens rewind. Try risky approaches knowing you can roll back. | Anthropic Docs |
| Subagents for Investigation | Delegate research to subagents — they keep your main session clean. | Anthropic Docs |
| Worktrees for Parallelism | claude --worktree for multiple features simultaneously. | Anthropic Docs |
| Skills Over Repeated Prompts | If you do something more than once a week, make it a skill. | Anthropic Docs |
| Verify, Verify, Verify | Give Claude a way to verify its own work. Include test commands. | Anthropic Docs |
| Co-Author Attribution | Tag PRs as co-authored for AI contribution tracking. | Pilot Retrospective |
| Progressive Disclosure | Explore first, then plan, then implement. | Anthropic Docs |
| Tiered Context Loading | Load only the context files relevant to your ticket type — not all files on every session. See Context Strategy table. | v2.0 Optimization |
| Track Every Session | Log time saved per ticket. Use /insights for analytics. | SOP §15 + Pilot |
| Symptom | Likely cause | Fix |
|---|---|---|
| claude command not found | Installer not on PATH | Check which claude. Re-run installer. |
| "Authentication failed" | Foundry Entra token expired | Run az login again |
| /doctor reports MCP failures | Server config or network | Run claude mcp list, remove and re-add |
| Hook not firing | Not registered or wrong event | Run /hooks to see registered hooks |
| /effort xhigh returns error | Opus 4.7 not available | Use /effort high or /effort max |
| Plan file not auto-loading | Outside memory hierarchy | CLAUDE.md auto-loads; plans load when referenced |
| Mode | Behavior | Approved for |
|---|---|---|
| default | Asks before every file change | All SunCHECK work (safe default) |
| acceptEdits | Auto-approves edits; asks for commands | Iterating on reviewed plan (Step 6) |
| plan | Read-only; generates plan | Step 3 — always |
| auto | Sonnet 4.6 classifier. Admin-enabled. | Long-running investigation in sandbox |
| dontAsk | Auto-denies anything not on allowlist | CI/headless/locked-down |
| bypassPermissions | All prompts off. No injection protection. | Isolated containers/VMs only |
| Tier | Location |
|---|---|
| Managed policy | /etc/claude/managed-settings.json (Win: %ProgramData%\Claude\) |
| Project | .claude/settings.json (commit this) |
| User | ~/.claude/settings.json |
| Local | .claude/settings.local.json (not committed) |
| Feature | Available on Foundry | Notes |
|---|---|---|
| Haiku 4.5, Sonnet 4.6, Opus 4.6 | ✓ | — |
| Opus 4.7 | Depends on deployment | Check Foundry admin |
| /effort xhigh | With Opus 4.7 only | — |
| /ultrareview, /ultraplan | ✗ | Requires Claude.ai auth |
| Routines (/schedule) | ✗ | Requires Claude.ai auth |
| /review, /security-review, /plan | ✓ | — |
| /insights, /loop, /doctor, /sandbox | ✓ | — |
| Subagents, Skills, Hooks | ✓ | — |
| MCP servers, Git worktrees | ✓ | — |
| Plan mode, Checkpoints | ✓ | — |
claude /doctor to confirm installation, login, Node 22+, MCP healthclaude /config to confirm settings.json merged correctlyclaude/rename <JIRA-ID>-short-desc to name the session/context
feature/JIRA-XXXX-short-desc
.claude/docs/project_plans/JIRA-XXXX-plan.md
# Reviewed: [JIRA-ID] [date] [initials]
/simplify on changed files/security-review in session/review on branch/memory to persist session learnings
/plan ·
/effort ·
/review ·
/security-review ·
/simplify ·
/doctor ·
/clear ·
/compact
Shift+Tab ·
Esc+Esc ·
Ctrl+G ·
Alt+V ·
Cmd+Esc ·
claude -c ·
claude -w ·
claude -r
Phases 0–13 | Manual + Automation | SunCHECK QA Agent System | suncheck-qa-agents/
Each module: _index.md (routing table) → sub-files (topic-specific). Agent loads _index first, then follows routing table.
Agent-Driven Testing Lifecycle — from Jira story to deployed automation code
node phase-cost.js snapshot — saves current token count before any work begins/analyze-story | Cost START snapshot taken./write-tests/review-tests/export-tests/upload-tests/generate-alignment/generate-spec/automation-review/automation-deploynode output/cost_snapshot.js <KEY> end <TC-KEY> — captures full cost from Phase 2 intake through Phase 12 delivery. Query: report <KEY>node output/cost_snapshot.js report — if any story shows STARTED (no END), take END snapshot now before closing.context/lessons.md (format: Date, Context, Lesson, Action, Tags). Only what actually happened this session./cost → writes session summary to session-log.md (date, stories, phases, cost, TODOs).| 0 | Session Start | CLAUDE.md auto-loads with 10 guardrails, output contract, and skill map. (Governance first) |
| 2–4 | Intake + Context + Plan | Phase 2: Read story (ACs, Validation, Notes, Comments, Bugs, Attachments). Phase 3: Load navigations, glossary, lessons.md, corrections-log.md, module/_index.md. Phase 4: Map ACs → R1…Rn, 6 scenario categories, evidence gate, gaps → [TBD]. Confirm plan at Gate 1. Cost START snapshot. Skill: /analyze-story |
| 5 | Write TCs | ONE TC per story, all scenarios as steps. Each step = numbered sub-actions + expected results. Conversation output only — no files yet. (Execute the plan) |
| 6 | AI Self-Review | 3-part quality gate: completeness, quality, traceability. Must-fix findings block Gate 2. (AI self-check) |
| G2 | Human Review | QA Engineer reviews, corrects, approves. No files generated until user approves. Reject → Phase 5. (Mandatory human gate) |
| 7 | Export .csv | Generate .csv (Zephyr format, importable). (Generate the file) |
| 8 | Upload to Zephyr | Push TCs to Zephyr Scale via API or manual import. Post-upload verification. Cost END snapshot taken here. (Deliver to Zephyr) |
| G3 | RA Review | RA reviews uploaded TC in Zephyr and approves or requests changes. Mandatory gate — no automation proceeds without approval. Reject → loop back to Phase 5 or 7. (Mandatory gate) |
| 9 | Alignment | TC steps → Playwright alignment table (Step # → Action → Code → Expected Result → Ready/PORT NEEDED/TBD). Reads Puppeteer + Playwright repos. Skill: /generate-alignment |
| G4 | Approve Alignment | Approve → Phase 10. Fix <row#> → re-display. Cancel → STOP. (Mandatory gate) |
| 10 | Automation Code | Alignment rows → .spec.ts. One test() block per alignment row. 10 dependency files read. 9 automation rules applied. Skill: /generate-spec |
| 11 | AI Code Review | 21-point checklist (Structure, Selectors, Interactions, Screenshots, Data) + Silent Pass Audit. Blocker / Warning / Suggestion. Skill: /automation-review |
| G5 | Approve Code | Approve → Phase 12. Fix <what> → re-generate. Cancel → STOP. (Mandatory gate) |
| 12 | Final Code Delivery | Apply review fixes, deploy .spec.ts to sc-playwright-automation repo. Automation code deploy. Cost END snapshot taken here. Skill: /automation-deploy (Ship the code) |
| CLOSE | Session Close | Cost safety-net check → append lessons.md → run /cost → session-log.md written. Always runs regardless of last phase. |
| 13 | Execute & Merge | Run .spec.ts locally, debug failures, raise PR. Manual — no AI skill. |
| G6 | Code Review & Merge | Team reviews PR. Approve → merge to main. Reject → fix + re-submit. Manual gate. (Final merge) |