

Also from Kynth Studios


Also from Kynth Studios


Also from Kynth Studios
1# SAFe Agent Team Quick Reference23> **Philosophy**: "Search First, Reuse Always, Create Only When Necessary"4>5> Pattern discovery is MANDATORY before implementation.6>7> **Team Culture**: "We work as a round table team that has 4 pillars of SAFe inscribed on that round table. It means something."89## Documentation1011**Workflow SOPs:**1213- [Agent Workflow SOP v1.4](./docs/sop/AGENT_WORKFLOW_SOP.md) - vNext contract, Exit States, Role Collapsing ({{TICKET_PREFIX}}-497/499)14- [Agent Configuration SOP](./docs/sop/AGENT_CONFIGURATION_SOP.md) - Tool restrictions, model selection15- [ARCHitect-in-CLI Role](./docs/workflow/ARCHITECT_IN_CLI_ROLE.md) - Primary orchestrator definition1617**CI/CD Documentation:**1819- [CI/CD Pipeline Guide](./docs/ci-cd/CI-CD-Pipeline-Guide.md) - Pipeline implementation guide2021**Database SOPs:**2223- [RLS Migration SOP](./docs/database/RLS_DATABASE_MIGRATION_SOP.md) - MANDATORY for Data Engineer2425**Project Standards:**2627- [Harness Whitepapers](./docs/whitepapers/) - Architecture, research alignment, and evidence28- [Agent Perspective](./docs/whitepapers/CLAUDE-CODE-HARNESS-AGENT-PERSPECTIVE.md) - Why the harness works29- [SAFe Methodology](https://github.com/{{GITHUB_ORG}}/{{PROJECT_REPO}}) - This repository3031## When to Use Which Agent3233| Agent Role | Use Case | Success Criteria | Primary Tools |34| ------------------------------------ | ------------------------------------------------------------------------------------------------- | ----------------------------------------------------------- | ----------------------------------- |35| **TDM** (Technical Delivery Manager) | Reactive blocker resolution, Linear updates, evidence tracking (NOT orchestration - see v1.3 SOP) | Blockers resolved, evidence attached, Linear updated | Linear, Confluence |36| **BSA** (Business Systems Analyst) | Requirements decomposition, acceptance criteria, testing strategy | Clear user stories, testable ACs, QA plan defined | Linear, Confluence, Markdown |37| **System Architect** | Pattern validation, Stage 1 PR review, migration approval, architectural decisions | ADR created, PR technical review complete, no conflicts | Read, Grep, ADR templates |38| **FE Developer** | UI components, client-side logic, user interactions | Lint and build passes | Read, Write, Edit, Bash |39| **BE Developer** | API routes, server logic, RLS enforcement | Integration tests pass | Read, Write, Edit, Bash |40| **DE** (Data Engineer) | Schema changes, migrations, database architecture | Migration applied, RLS maintained | Prisma, SQL, migration tools |41| **TW** (Technical Writer) | Documentation, guides, technical content | Markdown lint passes | Read, Write, Edit, Grep, Glob, Bash |42| **DPE** (Data Provisioning Engineer) | Test data, database access, data validation | Test data available, DB accessible | SQL, Prisma Studio, scripts |43| **QAS** (Quality Assurance) | **GATE OWNER**: Execute testing, validate ACs, iteration authority, evidence to Linear | All ACs verified, evidence posted, Exit: "Approved for RTE" | Playwright, Jest, Linear MCP |44| **SecEng** (Security Engineer) | Security validation, RLS checks, vulnerability assessment (Independence Gate - not collapsible) | Security audit passed, RLS enforced | RLS scripts, security tools |45| **RTE** (Release Train Engineer) | **PR SHEPHERD**: PR creation, CI/CD monitoring (NO code, NO merge) - Exit: "Ready for HITL" | PR created, CI green, Exit: "Ready for HITL Review" | Git, GitHub CLI, CI tools |4647## Auto-Loaded Skills4849Skills are loaded progressively—metadata at startup, full content when context triggers.5051| Skill | Trigger | Purpose |52| ------------------------ | ---------------------- | ------------------------------------------- |53| `safe-workflow` | Commits, branches, PRs | SAFe format, rebase-first workflow |54| `safe-ai-dlc` | Multi-issue programs | Bolts, Units of Work, HITL gate |55| `vault-sync` | Knowledge vault drift | Detect staleness, regenerate, record |56| `pattern-discovery` | Before writing code | Pattern-first development (MANDATORY) |57| `rls-patterns` | Database operations | RLS context helpers (withUserContext, etc.) |58| `frontend-patterns` | UI work | Clerk, shadcn, Next.js patterns |59| `api-patterns` | API route creation | Route structure, error handling |60| `testing-patterns` | Writing tests | Jest, Playwright patterns |61| `orchestration-patterns` | Multi-step work | Agent loop, evidence-based delivery |62| `agent-coordination` | Multi-agent work | Assignment matrix, escalation patterns |63| `team-coordination` | Agent Teams spawn | Multi-agent orchestration (experimental) |6465**Note**: `/skills` command has display bug (v2.0.73, GitHub #14733). Skills work but won't show in list. Ask Claude directly: "What skills are available?"6667## Success Validation Commands6869### Frontend Development7071```bash72npm run type-check && npm run lint && npm run build && echo "FE SUCCESS" || echo "FE FAILED"73```7475### Backend Development7677```bash78npm run test:integration && echo "BE SUCCESS" || echo "BE FAILED"79```8081### Documentation8283```bash84npm run lint:md && echo "DOCS SUCCESS" || echo "DOCS FAILED"85```8687### Pre-Push Validation8889```bash90npm run ci:validate && echo "CI SUCCESS" || echo "CI FAILED"91```9293### Database Migration9495```bash96npx prisma migrate dev --name migration_name && echo "MIGRATION SUCCESS" || echo "MIGRATION FAILED"97```9899## SAFe Specs-Driven Workflow100101### Planning Phase (BSA)102103```bash104# Large initiative → Use planning template105cp specs_templates/planning_template.md specs/{feature}-planning.md106# Fill with Epic → Features → Stories → Enablers107108# User story → Use spec template109cp specs_templates/spec_template.md specs/{{TICKET_PREFIX}}-XXX-{feature}-spec.md110# Fill with implementation details111```112113### Execution Phase (All Agents)114115```bash116# 1. Read spec for clear goal117cat specs/{{TICKET_PREFIX}}-XXX-{feature}-spec.md118119# 2. Extract:120# - User story (goal)121# - Acceptance criteria (success)122# - Low-level tasks (steps)123# - Demo script (validation)124125# 3. Implement using Simon's loop:126# - Clear goal from spec127# - Pattern discovery (codebase + specs)128# - Iterate until demo script passes129# - Escalate if blocked130```131132## Pattern Discovery Protocol (MANDATORY)133134### 0. Search Specs Directory (FIRST)135136```bash137# Find similar implementations in specs138ls specs/*-spec.md | grep "similar_feature"139140# Review SAFe user stories141grep -r "As a.*I want to" specs/142143# Check patterns from past specs144cat specs/XXX-similar-spec.md145```146147### 1. Search Codebase148149```bash150# Search for similar functionality151grep -r "feature_name|functionality" app/152153# Find existing helpers154ls lib/ && grep -r "helper_pattern" lib/155156# Check components157grep -r "component_pattern" components/158```159160### 2. Search Session History161162```bash163# Search agent session todos164grep -r "similar_feature|pattern" ~/.claude/todos/ 2>/dev/null165166# Find recent implementation patterns167ls -lt ~/.claude/todos/ | head -20168```169170### 3. Consult Documentation171172- `CONTRIBUTING.md` - Workflow and git process173- `docs/database/DATA_DICTIONARY.md` - Database schema (SINGLE SOURCE OF TRUTH)174- `docs/database/RLS_IMPLEMENTATION_GUIDE.md` - Row Level Security (MANDATORY for DB ops)175- `docs/security/SECURITY_FIRST_ARCHITECTURE.md` - Security patterns176177### 4. Architectural Validation178179- Propose pattern to System Architect180- Get approval before implementation181- Document decision in session notes182183## Agent Workflow184185### Standard Agent Loop (Per Simon Willison)1861871. **Clear Goal** - BSA defines with acceptance criteria1882. **Pattern Discovery** - Search codebase and sessions1893. **Iterative Problem Solving**:190 - Implement approach191 - Run validation command192 - If fails → analyze error, adjust, repeat193 - If blocked → escalate to TDM with context1944. **Evidence Attachment** - Session ID + validation results in Linear195196### No Over-Engineering197198- ❌ No file locks199- ❌ No circuit breakers200- ❌ No arbitrary retry limits201- ✅ Let agents iterate until success or blocked202- ✅ Agent decides when to escalate203204## Session Archaeology205206### Monitor Concurrent Sessions207208```bash209# See active sessions210ls -lt ~/.claude/todos/*.json | head -10211212# Check for concurrent work on same files213grep -l "file_path" ~/.claude/todos/*.json214```215216### Cross-Agent Coordination217218```bash219# Find related work by another agent220grep -r "linear_ticket_number" ~/.claude/todos/221222# Discover implementation patterns223grep -r "withUserContext|withAdminContext" ~/.claude/todos/224```225226## Exit States (vNext Contract)227228Each agent has explicit exit states that define handoff points:229230```231┌─────────────────┬───────────────────────────────────────────┐232│ Role │ Exit State │233├─────────────────┼───────────────────────────────────────────┤234│ BE-Developer │ "Ready for QAS" │235│ FE-Developer │ "Ready for QAS" │236│ Data-Engineer │ "Ready for QAS" │237│ QAS │ "Approved for RTE" │238│ RTE │ "Ready for HITL Review" │239│ System Architect│ "Stage 1 Approved - Ready for ARCHitect" │240│ HITL │ MERGED │241└─────────────────┴───────────────────────────────────────────┘242```243244### Gate Quick Reference245246```247┌─────────────────┬─────────────────┬─────────────────────────┐248│ Gate │ Owner │ Blocking? │249├─────────────────┼─────────────────┼─────────────────────────┤250│ Stop-the-Line │ Implementer │ YES - no AC = no work │251│ QAS Gate │ QAS │ YES - no approval = stop│252│ Stage 1 Review │ System Architect│ YES - pattern check │253│ Stage 2 Review │ ARCHitect-CLI │ YES - architecture check│254│ HITL Merge │ {{AUTHOR_NAME}} │ YES - final authority │255└─────────────────┴─────────────────┴─────────────────────────┘256```257258### Role Collapsing ({{TICKET_PREFIX}}-499)259260- **RTE**: Collapsible (PR creation, CI shepherding can be done by implementer)261- **QAS**: NOT collapsible (independence gate - spawn subagent for verification)262- **SecEng**: NOT collapsible (security audit requires independence)263264See [Agent Workflow SOP v1.4](./docs/sop/AGENT_WORKFLOW_SOP.md) for details.265266### Agent Teams (Experimental)267268Agent Teams enable real-time multi-agent orchestration using Claude Code's experimental Agent Teams feature. When enabled, agents are spawned as teammates with shared task lists and SAFe quality gates enforced via task dependencies.269270- **Enable**: Set `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` in `.claude/settings.json`271- **Skill**: `/team-coordination` — patterns for TeamCreate, SendMessage, shared TaskList272- **Guide**: See [Agent Teams Guide](docs/onboarding/AGENT-TEAMS-GUIDE.md) and [Optional Features](docs/guides/OPTIONAL-FEATURES.md)273274---275276## Quick Reference277278### Key Documentation279280- `CONTRIBUTING.md` - Complete workflow guide (MANDATORY READ)281- `docs/database/DATA_DICTIONARY.md` - Database schema (SINGLE SOURCE OF TRUTH)282- `docs/database/RLS_DATABASE_MIGRATION_SOP.md` - Schema changes (ARCHitect approval required)283- `docs/security/SECURITY_FIRST_ARCHITECTURE.md` - Security patterns284285### Agent Files286287- `.claude/agents/bsa.md` - Business Systems Analyst288- `.claude/agents/system-architect.md` - System Architect289- `.claude/agents/tdm.md` - Technical Delivery Manager290- `.claude/agents/fe-developer.md` - Frontend Developer291- `.claude/agents/be-developer.md` - Backend Developer292- `.claude/agents/data-engineer.md` - Data Engineer293- `.claude/agents/data-provisioning-eng.md` - Data Provisioning Engineer294- `.claude/agents/tech-writer.md` - Technical Writer295- `.claude/agents/qas.md` - Quality Assurance Specialist296- `.claude/agents/security-engineer.md` - Security Engineer297- `.claude/agents/rte.md` - Release Train Engineer298299## Human-in-the-Loop (HITL) Model300301**Product Owner / Product Manager**: {{POPM_NAME}}302303- All work requires evidence in Linear before POPM review304- Swimlane workflow: Backlog → Ready → In Progress → Testing → Ready for Review → Done305- POPM has final approval on all deliverables306307---308309## 🎯 Agent Invocation Examples310311### Simple Invocation (Direct Mention)312313Use `@agent-name` for simple, single-step tasks:314315```bash316# Planning317@bsa Create a spec for user profile API endpoint318@system-architect Review the RLS policy for user_profiles table319320# Implementation321@be-developer Implement the GET /api/user/profile endpoint322@fe-developer Create a UserProfile component with form validation323@data-engineer Add email_verified column to users table324325# Quality & Documentation326@qas Write integration tests for user profile feature327@security-engineer Audit RLS policies for user_profiles table328@tech-writer Document the user profile API in README329330# Coordination331@tdm Coordinate implementation of {{TICKET_PREFIX}}-123 user profile feature332@rte Create PR for {{TICKET_PREFIX}}-123 and run CI validation333```334335### Task Tool Invocation (Complex Tasks)336337Use `Task()` for complex, multi-step tasks with detailed instructions:338339```typescript340// BSA: Create comprehensive spec341Task({342 subagent_type: "bsa",343 description: "Create spec for {{TICKET_PREFIX}}-123",344 prompt: `Create comprehensive spec for {{TICKET_PREFIX}}-123 user profile feature.345346Requirements:347- User can view and edit their profile348- Profile includes: name, email, bio, avatar349- Email verification required350- Admin can view all profiles351352Please:3531. Search for existing user/profile patterns in patterns_library/3542. Create user story with acceptance criteria3553. Define testing strategy (unit, integration, E2E)3564. Add #EXPORT_CRITICAL tags for security requirements3575. Reference relevant patterns from pattern library`,358});359360// Backend Developer: Implement with pattern discovery361Task({362 subagent_type: "be-developer",363 description: "Implement {{TICKET_PREFIX}}-123 API",364 prompt: `Read spec at specs/{{TICKET_PREFIX}}-123-user-profile-spec.md365366Implement the user profile API endpoints:3671. GET /api/user/profile - Get current user's profile3682. PUT /api/user/profile - Update current user's profile3693. GET /api/admin/users/:id/profile - Admin view any profile370371Requirements:372- Use withUserContext for user endpoints373- Use withAdminContext for admin endpoints374- Follow RLS patterns from patterns_library/database/375- Validate input with Zod schemas376- Write unit tests for each endpoint377378Pattern discovery is MANDATORY before implementation.`,379});380381// QAS: Execute comprehensive testing382Task({383 subagent_type: "qas",384 description: "Test {{TICKET_PREFIX}}-123 feature",385 prompt: `Read spec at specs/{{TICKET_PREFIX}}-123-user-profile-spec.md386387Execute the testing strategy defined by BSA:3883891. Unit Tests:390 - Test Zod validation schemas391 - Test RLS context helpers392 - Test error handling3933942. Integration Tests:395 - Test GET /api/user/profile with user context396 - Test PUT /api/user/profile with valid/invalid data397 - Test admin endpoints with admin context398 - Test RLS isolation (user A cannot see user B's data)3994003. E2E Tests:401 - User can view their profile402 - User can edit their profile403 - Admin can view any profile404 - Unauthorized access is blocked405406Validate all acceptance criteria from the spec.`,407});408409// TDM: Reactive blocker resolution (NOT orchestration)410Task({411 subagent_type: "tdm",412 description: "Resolve blocker for {{TICKET_PREFIX}}-123",413 prompt: `A blocker has been reported for {{TICKET_PREFIX}}-123.414415TDM Responsibilities (per v1.3 SOP):4161. Monitor progress - read session archaeology, Linear, PR comments4172. Identify blocker details - search for "FAILED|error|blocked"4183. Escalate to appropriate specialist to resolve4194. Track evidence - attach session IDs, test results to Linear4205. Update Linear ticket with resolution421422NOTE: TDM is REACTIVE, not an orchestrator.423ARCHitect-in-CLI is the primary orchestrator.`,424});425```426427### When to Use Which Invocation Method428429| Scenario | Method | Example |430| ------------------------- | -------------- | --------------------------------------------------- |431| **Simple question** | Direct mention | `@bsa What patterns exist for user authentication?` |432| **Single-step task** | Direct mention | `@be-developer Add logging to the login endpoint` |433| **Multi-step task** | Task tool | BSA creating spec with pattern discovery |434| **Complex coordination** | Task tool | Multiple agents working on related features |435| **Detailed requirements** | Task tool | QAS executing comprehensive test strategy |436| **Blocker resolution** | Task tool | TDM investigating and escalating blockers |437438### Pro Tips4394401. **Always reference specs**: `Read spec at specs/{{TICKET_PREFIX}}-XXX-spec.md`4412. **Mandate pattern discovery**: `Pattern discovery is MANDATORY before implementation`4423. **Check #EXPORT_CRITICAL tags**: `Review #EXPORT_CRITICAL tags in spec first`4434. **Validate with commands**: Use success validation commands from agent prompts4445. **Update Linear**: TDM can update Linear with `mcp__{{MCP_LINEAR_SERVER}}__create_comment`4456. **TDM is reactive**: Don't use TDM for orchestration—use ARCHitect-in-CLI446447---448449**Quick Start**: Read CONTRIBUTING.md, search codebase, propose to System Architect, validate with test command, attach evidence to Linear.450
One repository carrying more than one format is the comparison this product exists for: does anyone actually write different content in each file, or is one a copy of the other?
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| bybren-llc/safe-agentic-workflow.cursor/rules/00-core-principles.mdc · 399 | Cursor rules | no sections | 48/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/01-git-workflow.mdc · 399 | Cursor rules | lint-formatstyletypesgit+2 | 85/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/02-pattern-discovery.mdc · 399 | Cursor rules | stylearchgitdo-not+2 | 73/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/03-safe-ai-dlc.mdc · 399 | Cursor rules | styledo-not | 59/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/04-knowledge-vault.mdc · 399 | Cursor rules | stylegitapido-not | 73/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/10-backend-python.mdc · 399 | Cursor rules | testlint-formatstylegit+4 | 97/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/11-frontend-react.mdc · 399 | Cursor rules | buildstyletypessecurity+3 | 65/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/12-database-sql.mdc · 399 | Cursor rules | testtypesgitsecurity+3 | 69/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/13-testing.mdc · 399 | Cursor rules | teststyletesting-strategyapi+1 | 88/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/14-spec-creation.mdc · 399 | Cursor rules | teststylegitdo-not | 69/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/15-deployment.mdc · 399 | Cursor rules | setuptestgitsecurity+2 | 80/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/16-stripe-payments.mdc · 399 | Cursor rules | testdo-not | 61/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/20-agent-architect.mdc · 399 | Cursor rules | stylearchgit | 58/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/21-agent-backend.mdc · 399 | Cursor rules | testlint-formatstyleapi+1 | 85/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/22-agent-qas.mdc · 399 | Cursor rules | teststylesecurityagent-behaviour | 81/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/23-agent-security.mdc · 399 | Cursor rules | stylesecurity | 52/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/30-background-agents.mdc · 399 | Cursor rules | testlint-formatstylegit+1 | 74/100 | today | |
| bybren-llc/safe-agentic-workflow.cursor/rules/31-mcp-integration.mdc · 399 | Cursor rules | stylesecuritydo-notagent-behaviour | 61/100 | today | |
| bybren-llc/safe-agentic-workflow.gemini/GEMINI.md · 399 | GEMINI.md | lint-formatstylearchgit+4 | 66/100 | today | |
| bybren-llc/safe-agentic-workflowCLAUDE.md · 399 | CLAUDE.md | buildtestlint-formatarch+6 | 91/100 | today |
Same format, overlapping stack, ranked by quality.
| Repository | Format | Stack | Covers | Score | Changed |
|---|---|---|---|---|---|
| vllm-project/vllmAGENTS.md · 89k | AGENTS.md | setuptestlint-formatstyle+5 | 100/100 | 14 days ago | |
| code-yeongyu/oh-my-openagentpackages/web/AGENTS.md · 68k | AGENTS.md | setupbuildtestlint-format+6 | 100/100 | 13 days ago | |
| deepseek-ai/deepseek-harnessnative/landlock-run/AGENTS.md · 104k | AGENTS.md | setupteststylearch+3 | 100/100 | today | |
| TryGhost/Ghoste2e/AGENTS.md · 55k | AGENTS.md | setupteststylearch+2 | 100/100 | today | |
| aaif-goose/gooseAGENTS.md · 53k | AGENTS.md | setupbuildtestlint-format+7 | 100/100 | 8 days ago | |
| duckduckgo/content-scope-scriptsspecial-pages/AGENTS.md · 70 | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| n8n-io/n8npackages/@n8n/agents/AGENTS.md · 201k | AGENTS.md | buildteststylearch+3 | 100/100 | 14 days ago | |
| mui/material-uiAGENTS.md · 99k | AGENTS.md | setupbuildtestlint-format+9 | 100/100 | 14 days ago |
A badge carrying the measured quality of the strongest agent config file in this repository, out of 100. It reads from this index every time somebody loads your page, so it changes when the measurement changes and there is nothing to keep up to date. Free, no account, and the value is not something you or we can set by hand.
[](https://rulestack.kynth.studio/configs/bybren-llc-safe-agentic-workflow-agents)Would rather not hotlink us? Every badge is also served in shields.io’s endpoint schema, so shields renders the image and your readers never talk to our domain:
Published by Toolproof, the masthead over this index and eight others. The method behind the number is at toolproof.kynth.studio/methodology, and the whole thing is readable as JSON with no key at /api.