<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: JackTT</title>
    <description>The latest articles on DEV Community by JackTT (@jacktt).</description>
    <link>https://dev.to/jacktt</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1105551%2Fa1df8b06-fd60-4bb5-9337-f66f4e4540d8.jpg</url>
      <title>DEV Community: JackTT</title>
      <link>https://dev.to/jacktt</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/jacktt"/>
    <language>en</language>
    <item>
      <title>BMAD cheat sheet</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 11 Mar 2026 09:19:14 +0000</pubDate>
      <link>https://dev.to/jacktt/bmad-cheat-sheet-5ab2</link>
      <guid>https://dev.to/jacktt/bmad-cheat-sheet-5ab2</guid>
      <description>&lt;h2&gt;
  
  
  Module 1: BMM (Business Model Management)
&lt;/h2&gt;

&lt;p&gt;The main product development module, designed for end-to-end project delivery following the BMad Method.&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase 1 — Analysis
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-brainstorming&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BP&lt;/td&gt;
&lt;td&gt;Facilitated brainstorming using one or more structured techniques&lt;/td&gt;
&lt;td&gt;At the very start, when exploring ideas or when stuck generating them&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-market-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;MR&lt;/td&gt;
&lt;td&gt;Competitive landscape, customer needs, and market trends analysis&lt;/td&gt;
&lt;td&gt;Before committing to a product direction; validate there's a market&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-domain-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;DR&lt;/td&gt;
&lt;td&gt;Deep dive into industry domain, terminology, and subject matter&lt;/td&gt;
&lt;td&gt;When entering an unfamiliar domain or needing expert vocabulary&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-technical-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;TR&lt;/td&gt;
&lt;td&gt;Technical feasibility study, architecture options, implementation approaches&lt;/td&gt;
&lt;td&gt;When tech choices are unclear or high-risk before planning begins&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-product-brief&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CB&lt;/td&gt;
&lt;td&gt;Guided session to crystallize the product idea into a brief&lt;/td&gt;
&lt;td&gt;After brainstorming; when you need to lock down "what are we building?"&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h3&gt;
  
  
  Phase 2 — Planning
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CP&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Expert-facilitated session to produce the Product Requirements Document&lt;/td&gt;
&lt;td&gt;After analysis is done; the PRD gates entry into solutioning&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-validate-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;VP&lt;/td&gt;
&lt;td&gt;Checks that the PRD is comprehensive, lean, well-organized, and cohesive&lt;/td&gt;
&lt;td&gt;After creating the PRD; run before architecture to catch gaps early&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-edit-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;EP&lt;/td&gt;
&lt;td&gt;Improve and enhance an existing PRD&lt;/td&gt;
&lt;td&gt;When the PRD fails validation or stakeholders request changes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-ux-design&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CU&lt;/td&gt;
&lt;td&gt;Guides the planning of UX patterns and design specifications&lt;/td&gt;
&lt;td&gt;Strongly recommended when a UI is a primary part of the product&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h3&gt;
  
  
  Phase 3 — Solutioning
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-architecture&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CA&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Guided workflow to document all technical decisions&lt;/td&gt;
&lt;td&gt;After PRD is approved; establishes the technical foundation before stories&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-epics-and-stories&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CE&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Breaks requirements into structured Epics and User Stories&lt;/td&gt;
&lt;td&gt;After architecture is set; creates the delivery roadmap&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-check-implementation-readiness&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;IR&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Validates PRD, UX, Architecture, and Epics/Stories are all aligned&lt;/td&gt;
&lt;td&gt;Final gate before implementation; run with a high-quality LLM if available&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h3&gt;
  
  
  Phase 4 — Implementation
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-sprint-planning&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;SP&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Generates the sprint plan from epics — the implementation kick-off&lt;/td&gt;
&lt;td&gt;Once readiness is confirmed; produces the plan all dev agents will follow&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-sprint-status&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;SS&lt;/td&gt;
&lt;td&gt;Summarizes current sprint status and routes to the next workflow&lt;/td&gt;
&lt;td&gt;Anytime during a sprint to check progress&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-story&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CS&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Prepares the next story in the sprint plan with full context&lt;/td&gt;
&lt;td&gt;Start of every story cycle; run before Dev Story&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-dev-story&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;DS&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;[Required]&lt;/strong&gt; Executes story implementation tasks and tests&lt;/td&gt;
&lt;td&gt;After story is created and validated; the main coding step&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-code-review&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CR&lt;/td&gt;
&lt;td&gt;Adversarial code review; routes back to Dev Story if issues found&lt;/td&gt;
&lt;td&gt;After Dev Story completes; the final checkpoint before moving to next story&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-retrospective&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;ER&lt;/td&gt;
&lt;td&gt;Post-epic review to extract lessons learned and assess success&lt;/td&gt;
&lt;td&gt;Optional; at the end of each epic or when something went significantly wrong&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h3&gt;
  
  
  Anytime (BMM)
&lt;/h3&gt;

&lt;p&gt;These BMM commands work at any point in the workflow:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-document-project&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;DP&lt;/td&gt;
&lt;td&gt;Analyzes an existing codebase and produces useful documentation&lt;/td&gt;
&lt;td&gt;For brownfield/legacy projects before starting new development&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-generate-project-context&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;GPC&lt;/td&gt;
&lt;td&gt;Scans codebase and generates a lean LLM-optimized &lt;code&gt;project-context.md&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Essential for brownfield projects; run before any dev agent work&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;QS&lt;/td&gt;
&lt;td&gt;Fast one-page tech spec for small changes or features&lt;/td&gt;
&lt;td&gt;Quick one-offs, small changes, brownfield additions; &lt;strong&gt;not&lt;/strong&gt; for complex features&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;QD&lt;/td&gt;
&lt;td&gt;Implement small tasks without full planning overhead&lt;/td&gt;
&lt;td&gt;Single ad-hoc tasks not already in the sprint plan&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-correct-course&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;CC&lt;/td&gt;
&lt;td&gt;Navigates significant mid-sprint changes (may trigger PRD update, architecture redo, etc.)&lt;/td&gt;
&lt;td&gt;When a major blocker, pivot, or requirement change disrupts the current plan&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Agent-based BMM commands&lt;/strong&gt; (load agent first, then invoke by code):&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;Agent&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;WD&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer) — &lt;code&gt;/bmad-bmm-tech-writer&lt;/code&gt;
&lt;/td&gt;
&lt;td&gt;Write a detailed document following documentation best practices&lt;/td&gt;
&lt;td&gt;Producing any formal documentation artifact&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;US&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer)&lt;/td&gt;
&lt;td&gt;Update &lt;code&gt;documentation-standards.md&lt;/code&gt; with project-specific conventions&lt;/td&gt;
&lt;td&gt;When you discover missing or incorrect documentation conventions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;MG&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer)&lt;/td&gt;
&lt;td&gt;Generate a Mermaid diagram from a description&lt;/td&gt;
&lt;td&gt;Visualizing flows, architecture, or sequences&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;VD&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer)&lt;/td&gt;
&lt;td&gt;Review a document against documentation standards&lt;/td&gt;
&lt;td&gt;Quality check before publishing or finalizing any document&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;EC&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer)&lt;/td&gt;
&lt;td&gt;Create clear technical explanations with examples and diagrams&lt;/td&gt;
&lt;td&gt;When a concept needs to be explained to the team or new members&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Module 2: CIS (Creative Innovation Suite)
&lt;/h2&gt;

&lt;p&gt;Focused on creative thinking, innovation, and strategic problem solving. All CIS commands work &lt;strong&gt;anytime&lt;/strong&gt;.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-cis-innovation-strategy&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;IS&lt;/td&gt;
&lt;td&gt;Identify disruption opportunities and architect business model innovation&lt;/td&gt;
&lt;td&gt;When exploring new business models or seeking competitive advantage&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-cis-problem-solving&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;PS&lt;/td&gt;
&lt;td&gt;Apply systematic problem-solving methodologies to complex challenges&lt;/td&gt;
&lt;td&gt;When stuck on a difficult problem or needing a structured approach&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-cis-design-thinking&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;DT&lt;/td&gt;
&lt;td&gt;Guide human-centered design using empathy-driven methodologies&lt;/td&gt;
&lt;td&gt;For user-centered design challenges or improving user experience&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-cis-brainstorming&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BS&lt;/td&gt;
&lt;td&gt;Facilitate brainstorming using proven structured techniques&lt;/td&gt;
&lt;td&gt;Early in ideation, or whenever idea generation is needed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-cis-storytelling&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;ST&lt;/td&gt;
&lt;td&gt;Craft compelling narratives using proven story frameworks&lt;/td&gt;
&lt;td&gt;When preparing persuasive communications, pitches, or story-driven content&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Module 3: Core (Universal Tools)
&lt;/h2&gt;

&lt;p&gt;These commands work across &lt;strong&gt;all modules&lt;/strong&gt; and all workflow phases. No module context required.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;What is this&lt;/th&gt;
&lt;th&gt;When to use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-brainstorming&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BSP&lt;/td&gt;
&lt;td&gt;Generate diverse ideas through interactive techniques&lt;/td&gt;
&lt;td&gt;Any time creative input is needed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-party-mode&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;PM&lt;/td&gt;
&lt;td&gt;Orchestrate a multi-agent discussion with all installed agents&lt;/td&gt;
&lt;td&gt;When you want multiple agent perspectives or collaborative agent input&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-help&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BH&lt;/td&gt;
&lt;td&gt;Show the next recommended workflow steps based on context&lt;/td&gt;
&lt;td&gt;When you're unsure what to do next&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-index-docs&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;ID&lt;/td&gt;
&lt;td&gt;Create a lightweight index of available docs for quick LLM scanning&lt;/td&gt;
&lt;td&gt;Before starting work in a docs-heavy folder so agents can navigate quickly&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-shard-doc&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;SD&lt;/td&gt;
&lt;td&gt;Split a large document into smaller files organized by section&lt;/td&gt;
&lt;td&gt;When a doc exceeds ~500 lines and becomes hard to manage&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-editorial-review-prose&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;EP&lt;/td&gt;
&lt;td&gt;Review prose for clarity, tone, and communication issues&lt;/td&gt;
&lt;td&gt;After drafting any written content to polish it&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-editorial-review-structure&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;ES&lt;/td&gt;
&lt;td&gt;Propose cuts, reorganization, and simplification while preserving comprehension&lt;/td&gt;
&lt;td&gt;When a doc was assembled from multiple sub-processes or feels disorganized&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-review-adversarial-general&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;AR&lt;/td&gt;
&lt;td&gt;Critically review content to find issues and weaknesses&lt;/td&gt;
&lt;td&gt;Quality assurance before finalizing any deliverable or document&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;/bmad-review-edge-case-hunter&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;ECH&lt;/td&gt;
&lt;td&gt;Walk every branch and boundary in code/content, report only unhandled edge cases&lt;/td&gt;
&lt;td&gt;Use alongside adversarial review for orthogonal, method-driven coverage&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Quick Cheat Sheet: Where am I? What do I run?
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Stage&lt;/th&gt;
&lt;th&gt;Must-run commands&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Starting a new product&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-create-product-brief&lt;/code&gt; → &lt;code&gt;/bmad-bmm-create-prd&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Planning tech&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-create-architecture&lt;/code&gt; → &lt;code&gt;/bmad-bmm-create-epics-and-stories&lt;/code&gt; → &lt;code&gt;/bmad-bmm-check-implementation-readiness&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Starting a sprint&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-sprint-planning&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Each story cycle&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-create-story&lt;/code&gt; → &lt;code&gt;/bmad-bmm-dev-story&lt;/code&gt; → &lt;code&gt;/bmad-bmm-code-review&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Brownfield / existing codebase&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-generate-project-context&lt;/code&gt; first, then proceed&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Quick one-off task&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt; → &lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Something went wrong&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-correct-course&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Don't know what's next&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-help&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;This content is summarized by /bmad-help, the agent that helps us with anything about BMAD. You can also ask it for more details about BMAD usage.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>bmad</category>
    </item>
    <item>
      <title>BMAD Quick Flow</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 11 Mar 2026 06:49:07 +0000</pubDate>
      <link>https://dev.to/jacktt/bmad-quick-flow-15en</link>
      <guid>https://dev.to/jacktt/bmad-quick-flow-15en</guid>
      <description>&lt;h1&gt;
  
  
  BMAD Quick Flow
&lt;/h1&gt;

&lt;p&gt;Quick Flow is the lean path inside the BMAD Method. It skips the full planning ceremony (PRD → Architecture → Epics → Sprint Planning) and gets you from idea to shipped code in as few steps as possible. Use it for small changes, isolated features, or brownfield additions where the full workflow would be overkill.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Three Commands
&lt;/h2&gt;

&lt;h3&gt;
  
  
  1. &lt;code&gt;/bmad-agent-bmm-quick-flow-solo-dev&lt;/code&gt; — The Hub Agent
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;What it is:&lt;/strong&gt; Loads &lt;strong&gt;Barry&lt;/strong&gt;, an AI persona acting as an Elite Full-Stack Developer and Quick Flow specialist. Barry presents an interactive menu of all Quick Flow operations in one place.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Barry's menu:&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Code&lt;/th&gt;
&lt;th&gt;Action&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;QS&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Quick Spec — create a tech spec&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;QD&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Quick Dev — implement a spec&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Code Review&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;PM&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Party Mode (multi-agent discussion)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DA&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Dismiss Agent&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;When to use it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You want a single entry point and prefer to pick your next step interactively&lt;/li&gt;
&lt;li&gt;You're new to Quick Flow and want guidance on what to do next&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;When to skip it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You already know what you want — call &lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt; or &lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt; directly instead&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  2. &lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt; — Write a Technical Spec
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;What it is:&lt;/strong&gt; A conversational workflow that produces an &lt;strong&gt;implementation-ready technical specification&lt;/strong&gt;. It asks you sharp questions about the feature, investigates existing code, and outputs a complete, self-contained spec file.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What "ready for development" means:&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Criterion&lt;/th&gt;
&lt;th&gt;Requirement&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Actionable&lt;/td&gt;
&lt;td&gt;Every task has a specific file path and a clear action&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Logical&lt;/td&gt;
&lt;td&gt;Tasks are ordered by dependency (lowest level first)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Testable&lt;/td&gt;
&lt;td&gt;All acceptance criteria follow Given / When / Then&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Complete&lt;/td&gt;
&lt;td&gt;All investigation results are inlined — no placeholders or TBDs&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Self-contained&lt;/td&gt;
&lt;td&gt;A fresh agent can implement the feature without reading the conversation history&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;When to use it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The change is small to medium in scope and does not need a full PRD&lt;/li&gt;
&lt;li&gt;You are adding to a well-established codebase pattern&lt;/li&gt;
&lt;li&gt;You want to plan before you code — produce the spec first, implement later&lt;/li&gt;
&lt;li&gt;You need a written record of exactly what will be changed and why&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;When to skip it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The task is so simple it fits in one sentence — just tell Quick Dev directly&lt;/li&gt;
&lt;li&gt;The change is large and complex — use the full BMM workflow instead&lt;/li&gt;
&lt;/ul&gt;




&lt;h3&gt;
  
  
  3. &lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt; — Implement the Spec
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;What it is:&lt;/strong&gt; A step-by-step implementation workflow. The AI acts as an autonomous developer: it reads the tech spec (or takes direct instructions), follows existing code patterns, writes the code, and runs tests.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;How it works internally:&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Mode detection&lt;/strong&gt; — Did you provide a tech spec file, or are you giving direct instructions?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Code investigation&lt;/strong&gt; — AI reads relevant files to understand the existing patterns&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Implementation&lt;/strong&gt; — Tasks are executed sequentially, one at a time&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Verification&lt;/strong&gt; — Tests are run and output is confirmed after each change&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;When to use it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You have a spec from &lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt; and are ready to implement&lt;/li&gt;
&lt;li&gt;The task is small enough to describe directly without a formal spec&lt;/li&gt;
&lt;li&gt;You need a one-off change that is not part of the current sprint plan&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;When to skip it:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The change spans multiple stories or epics — use the full &lt;code&gt;Dev Story&lt;/code&gt; workflow (&lt;code&gt;/bmad-bmm-dev-story&lt;/code&gt;) instead&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Typical Workflows
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Spec first, then implement (recommended for anything non-trivial)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;/bmad-bmm-quick-spec
  → Discover requirements through conversation
  → AI investigates existing code
  → Outputs a tech-spec file

/bmad-bmm-quick-dev
  → Point it at the spec file
  → AI implements all tasks sequentially
  → Tests run after each change
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Direct implementation (for trivial changes)
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;/bmad-bmm-quick-dev
  → Describe what you want in plain language
  → AI implements immediately
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Using the hub agent
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;/bmad-agent-bmm-quick-flow-solo-dev
  → Barry loads and shows the menu
  → Select QS to create a spec
  → Select QD to implement it
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Quick Flow vs. Full BMM Workflow
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Situation&lt;/th&gt;
&lt;th&gt;Use&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;New product, complex feature, needs PRD + Architecture&lt;/td&gt;
&lt;td&gt;Full BMM flow&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Small feature, brownfield addition, well-known pattern&lt;/td&gt;
&lt;td&gt;Quick Flow&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;One-off fix or change during an active sprint&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt; directly&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Unsure what to do next&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-help&lt;/code&gt; or load Barry via &lt;code&gt;/bmad-agent-bmm-quick-flow-solo-dev&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Rule of thumb:&lt;/strong&gt; If you'd feel uncomfortable skipping a PRD and architecture doc, use the full flow. If the change fits on one page of notes, Quick Flow is the right tool.&lt;/p&gt;

&lt;p&gt;This content is summarized by /bmad-help, the agent that helps us with anything about BMAD. You can also ask it for more details about BMAD usage.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>bmad</category>
      <category>agents</category>
      <category>sdlc</category>
    </item>
    <item>
      <title>BMAD Standard Workflow</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 11 Mar 2026 06:38:17 +0000</pubDate>
      <link>https://dev.to/jacktt/bmad-standard-workflow-2kma</link>
      <guid>https://dev.to/jacktt/bmad-standard-workflow-2kma</guid>
      <description>&lt;h1&gt;
  
  
  BMAD Standard Workflow Guide
&lt;/h1&gt;

&lt;h2&gt;
  
  
  Overview
&lt;/h2&gt;

&lt;p&gt;BMAD (Business Methods and Development) is a structured AI-assisted workflow framework that guides teams from product discovery through implementation. It maps closely to real Scrum ceremonies and artifacts, providing AI agents for each role in the process.&lt;/p&gt;




&lt;h2&gt;
  
  
  Folder Structure
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Folder&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Framework core — contains agent definitions, workflow specs, tasks, and configuration. &lt;strong&gt;Do not modify manually.&lt;/strong&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad/_config/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BMAD catalog (&lt;code&gt;bmad-help.csv&lt;/code&gt;) and global settings.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad/_memory/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Agent memory files — agents store learned standards and preferences here across sessions.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad/bmm/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;BMM module — all business/product workflows (PRD, architecture, stories, implementation).&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad/core/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Core utilities — brainstorming, help, indexing, review, and other cross-cutting tools.&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Output:&lt;/strong&gt; All planning-phase documents (PRD, architecture, epics/stories, UX design, research).&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Output:&lt;/strong&gt; All implementation-phase artifacts (sprint plan, story files, retrospectives).&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;General output folder for miscellaneous outputs (project context, etc.).&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;docs/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Project knowledge base — documentation files that AI agents read for context (architecture references, tech stack, onboarding guides).&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  BMAD Standard Flow
&lt;/h2&gt;

&lt;p&gt;The full flow consists of four sequential phases. Required steps must be completed before advancing to the next phase.&lt;/p&gt;




&lt;h3&gt;
  
  
  Phase 1 — Analysis
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Scrum Equivalent:&lt;/strong&gt; Pre-Sprint / Product Discovery&lt;/p&gt;

&lt;p&gt;Establish context and understand the problem space before writing any requirements.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Required&lt;/th&gt;
&lt;th&gt;Output&lt;/th&gt;
&lt;th&gt;Output Folder&lt;/th&gt;
&lt;th&gt;Scrum Equivalent&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Brainstorm Project&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-brainstorming&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Brainstorming session doc&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pre-sprint ideation / product discovery workshop&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Market Research&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-market-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Research documents&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Competitor analysis in discovery sprint&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Domain Research&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-domain-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Research documents&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Domain knowledge deep-dive before backlog refinement&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Technical Research&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-technical-research&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Research documents&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Technical spike / feasibility study&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Create Product Brief&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-product-brief&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Product brief&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Product vision statement / elevator pitch doc&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;All Phase 1 steps are optional. They feed context into the PRD in Phase 2.&lt;/p&gt;




&lt;h3&gt;
  
  
  Phase 2 — Planning
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Scrum Equivalent:&lt;/strong&gt; Product Backlog Creation &amp;amp; Refinement&lt;/p&gt;

&lt;p&gt;Define what to build. The PRD is the central required artifact.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Required&lt;/th&gt;
&lt;th&gt;Output&lt;/th&gt;
&lt;th&gt;Output Folder&lt;/th&gt;
&lt;th&gt;Scrum Equivalent&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Create PRD&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Product Requirements Document&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Product Owner writing the product backlog / vision doc&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Validate PRD&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-validate-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;PRD validation report&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Peer review / Definition of Ready check on backlog&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Edit PRD&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-edit-prd&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Updated PRD&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Backlog refinement session — incorporating stakeholder feedback&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Create UX Design&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-ux-design&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;UX design specification&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;UX/UI design sprint or prototype review&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; Create PRD is the only required step in this phase. Validate and Edit PRD are recommended for quality but not blocking.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h3&gt;
  
  
  Phase 3 — Solutioning
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Scrum Equivalent:&lt;/strong&gt; Sprint 0 / Technical Refinement&lt;/p&gt;

&lt;p&gt;Define how to build it. Architecture and story decomposition must be complete before implementation begins.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Required&lt;/th&gt;
&lt;th&gt;Output&lt;/th&gt;
&lt;th&gt;Output Folder&lt;/th&gt;
&lt;th&gt;Scrum Equivalent&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Create Architecture&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-architecture&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Architecture document&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Architecture design review / technical kick-off meeting&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Create Epics &amp;amp; Stories&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-epics-and-stories&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Epics and stories list&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Backlog decomposition — breaking epics into user stories&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Check Implementation Readiness&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-check-implementation-readiness&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Readiness report&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Definition of Ready check across PRD + UX + Architecture + Stories&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;All three steps are required. The readiness check validates alignment across all prior artifacts before development starts.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h3&gt;
  
  
  Phase 4 — Implementation
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Scrum Equivalent:&lt;/strong&gt; Sprint Execution&lt;/p&gt;

&lt;p&gt;Build and ship. Stories are worked one at a time through a defined cycle.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Required&lt;/th&gt;
&lt;th&gt;Output&lt;/th&gt;
&lt;th&gt;Output Folder&lt;/th&gt;
&lt;th&gt;Scrum Equivalent&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Sprint Planning&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-sprint-planning&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Sprint status / plan&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Sprint Planning ceremony — selecting stories and creating the sprint plan&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Sprint Status&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-sprint-status&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Status summary&lt;/td&gt;
&lt;td&gt;&lt;em&gt;(inline)&lt;/em&gt;&lt;/td&gt;
&lt;td&gt;Daily Standup / sprint burndown review&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Create Story&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-create-story&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Enriched story file&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Story kick-off — Scrum Master prepares story context for dev&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Validate Story&lt;/td&gt;
&lt;td&gt;
&lt;code&gt;/bmad-bmm-create-story&lt;/code&gt; &lt;em&gt;(Validate Mode)&lt;/em&gt;
&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Story validation report&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Pre-development story review / Three Amigos&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;strong&gt;Dev Story&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-dev-story&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;Yes&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;Implemented code + tests&lt;/td&gt;
&lt;td&gt;&lt;em&gt;(codebase)&lt;/em&gt;&lt;/td&gt;
&lt;td&gt;Sprint execution — developer implements the story&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;QA Automation Test&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-qa-automate&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Automated test suite&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;QA review / automated test coverage after implementation&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Code Review&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-code-review&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Code review report&lt;/td&gt;
&lt;td&gt;&lt;em&gt;(inline)&lt;/em&gt;&lt;/td&gt;
&lt;td&gt;Pull request code review&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Retrospective&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-retrospective&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Retrospective doc&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Sprint Retrospective at end of epic&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;Story Cycle (per story):&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Create Story → Validate Story → Dev Story → Code Review
     ↑                                           |
     └── (if issues found, back to Dev Story) ───┘
                                                 |
                              (next story) → Create Story
                              (epic done)  → Retrospective
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  Anytime Tools
&lt;/h2&gt;

&lt;p&gt;These tools can be used at any phase, independent of workflow state.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Tool&lt;/th&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Purpose&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Quick Spec&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-quick-spec&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Lightweight spec for small/simple tasks without full planning&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Quick Dev&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-quick-dev&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Implement small tasks directly without full process&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Correct Course&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-correct-course&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Handle significant mid-sprint changes or pivots&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Document Project&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-document-project&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Generate docs for an existing (brownfield) codebase → &lt;code&gt;docs/&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Generate Project Context&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-bmm-generate-project-context&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Produce &lt;code&gt;project-context.md&lt;/code&gt; for AI agent grounding → &lt;code&gt;_bmad-output/&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Write Document&lt;/td&gt;
&lt;td&gt;Load &lt;code&gt;/bmad:DITA:agent:tech-writer&lt;/code&gt;, ask "WD"&lt;/td&gt;
&lt;td&gt;Write any document following documentation standards → &lt;code&gt;docs/&lt;/code&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;BMAD Help&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-help&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Get guidance on what to do next at any point&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Brainstorming&lt;/td&gt;
&lt;td&gt;&lt;code&gt;/bmad-brainstorming&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Ideation session using creative techniques&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Summary: Output Locations
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Phase&lt;/th&gt;
&lt;th&gt;Outputs Go To&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Analysis&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Planning&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Solutioning&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/planning-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Implementation&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/implementation-artifacts/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Project Knowledge / Docs&lt;/td&gt;
&lt;td&gt;&lt;code&gt;docs/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;General Output&lt;/td&gt;
&lt;td&gt;&lt;code&gt;_bmad-output/&lt;/code&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;




&lt;h2&gt;
  
  
  Key Principles
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Run each workflow in a fresh context window&lt;/strong&gt; — do not chain multiple workflows in the same conversation.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Required steps block progress&lt;/strong&gt; — you cannot skip Create PRD, Create Architecture, Create Epics &amp;amp; Stories, Check Implementation Readiness, Sprint Planning, Create Story, or Dev Story.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Artifacts drive state&lt;/strong&gt; — BMAD determines workflow state by looking for output files, not by tracking session history.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Use a different LLM for validation steps&lt;/strong&gt; — Validate PRD, Validate Story, and Check Implementation Readiness benefit from a separate high-quality model to avoid self-confirmation bias.&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;This content is summarized by /bmad-help, the agent that helps us with anything about BMAD. You can also ask it for more details about BMAD usage.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>bmad</category>
      <category>sdlc</category>
      <category>agents</category>
    </item>
    <item>
      <title>Understanding the Agents in the BMAD</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 11 Mar 2026 06:24:43 +0000</pubDate>
      <link>https://dev.to/jacktt/understanding-the-agents-in-the-bmad-235o</link>
      <guid>https://dev.to/jacktt/understanding-the-agents-in-the-bmad-235o</guid>
      <description>&lt;h1&gt;
  
  
  BMAD Agents
&lt;/h1&gt;

&lt;p&gt;BMAD uses a team of specialized agents, each representing a distinct role in the software development lifecycle. Every agent has a unique persona, focused capabilities, and a set of workflows they execute. Load an agent by running its slash command in a &lt;strong&gt;fresh context window&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Part 1 — 📊 Mary, Business Analyst
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-analyst&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;analyst&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Business Analyst&lt;/p&gt;

&lt;h3&gt;
  
  
  Who She Is
&lt;/h3&gt;

&lt;p&gt;Mary is a strategic business analyst with deep expertise in market research, competitive analysis, and requirements elicitation. She approaches every problem like a treasure hunter — thrilled by clues, energized when patterns emerge. She draws on Porter's Five Forces, SWOT analysis, root cause analysis, and competitive intelligence methodologies.&lt;/p&gt;

&lt;h3&gt;
  
  
  What She Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;BP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Brainstorm Project&lt;/strong&gt; — Facilitated ideation through structured techniques, produces a final report&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;MR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Market Research&lt;/strong&gt; — Market analysis, competitive landscape, customer needs and trends&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Domain Research&lt;/strong&gt; — Industry deep dive, subject matter expertise and terminology&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;TR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Technical Research&lt;/strong&gt; — Technical feasibility, architecture options and implementation approaches&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CB&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create Brief&lt;/strong&gt; — Guided experience to define your product idea into an executive brief&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Document Project&lt;/strong&gt; — Analyze an existing codebase and produce useful docs for humans and LLMs&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Her
&lt;/h3&gt;

&lt;p&gt;Use Mary at the &lt;strong&gt;very start&lt;/strong&gt; of any project, especially when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You have an idea but haven't validated it yet&lt;/li&gt;
&lt;li&gt;You need to understand your market or domain before writing any specs&lt;/li&gt;
&lt;li&gt;You want to explore multiple approaches and need structured brainstorming&lt;/li&gt;
&lt;li&gt;You're onboarding an AI agent to an existing (brownfield) project&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Mary is the entry point into the BMM workflow. Most projects start with her.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 2 — 📋 John, Product Manager
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-pm&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;pm&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Product Manager&lt;/p&gt;

&lt;h3&gt;
  
  
  Who He Is
&lt;/h3&gt;

&lt;p&gt;John is a veteran product manager with 8+ years launching B2B and consumer products. He asks "WHY?" relentlessly — like a detective cutting through fluff to what actually matters. He uses Jobs-to-be-Done, opportunity scoring, and user-centered design frameworks to discover what users need (not just what they say they want).&lt;/p&gt;

&lt;h3&gt;
  
  
  What He Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create PRD&lt;/strong&gt; — Expert-facilitated Product Requirements Document&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;VP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Validate PRD&lt;/strong&gt; — Checks the PRD is comprehensive, lean, well-organized, and cohesive&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Edit PRD&lt;/strong&gt; — Update or improve an existing PRD&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CE&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create Epics and Stories&lt;/strong&gt; — Break down a PRD into epics and user stories&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;IR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Implementation Readiness&lt;/strong&gt; — Verify PRD, UX, Architecture, and Stories are all aligned&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CC&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Course Correction&lt;/strong&gt; — Handle major mid-implementation change requests&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Him
&lt;/h3&gt;

&lt;p&gt;Use John in &lt;strong&gt;Phase 2 (Planning)&lt;/strong&gt;, after initial research, when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You need to produce a formal PRD from your idea or brief&lt;/li&gt;
&lt;li&gt;You need to break a PRD into development-ready epics and stories&lt;/li&gt;
&lt;li&gt;You want to validate that your product requirements are solid before building&lt;/li&gt;
&lt;li&gt;You discover a significant change is needed mid-sprint&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Creating the PRD (&lt;code&gt;CP&lt;/code&gt;) is the &lt;strong&gt;only required step&lt;/strong&gt; before moving to solutioning.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 3 — 🎨 Sally, UX Designer
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-ux-designer&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;ux-designer&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; UX Designer&lt;/p&gt;

&lt;h3&gt;
  
  
  Who She Is
&lt;/h3&gt;

&lt;p&gt;Sally is a senior UX designer with 7+ years creating intuitive experiences across web and mobile. She paints pictures with words, telling user stories that make you &lt;em&gt;feel&lt;/em&gt; the problem. She's an empathetic advocate who balances creative storytelling with rigorous attention to edge cases.&lt;/p&gt;

&lt;h3&gt;
  
  
  What She Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CU&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create UX&lt;/strong&gt; — Guided workflow to define UX patterns, flows, and specifications&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Her
&lt;/h3&gt;

&lt;p&gt;Use Sally in &lt;strong&gt;Phase 2 (Planning)&lt;/strong&gt; after the PRD is created, when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your project has a significant UI component&lt;/li&gt;
&lt;li&gt;You need interaction design details that go beyond the PRD&lt;/li&gt;
&lt;li&gt;You want to define user flows, screen patterns, and UI specifications before architecture&lt;/li&gt;
&lt;li&gt;You want to ensure UX decisions inform the technical architecture&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Sally is &lt;strong&gt;optional&lt;/strong&gt; but strongly recommended when a UI is the primary deliverable.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 4 — 🏗️ Winston, Architect
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-architect&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;architect&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; System Architect&lt;/p&gt;

&lt;h3&gt;
  
  
  Who He Is
&lt;/h3&gt;

&lt;p&gt;Winston is a senior architect with expertise in distributed systems, cloud infrastructure, and API design. He speaks in calm, pragmatic tones — balancing "what could be" with "what should be." He embraces boring technology for stability and connects every technical decision to business value.&lt;/p&gt;

&lt;h3&gt;
  
  
  What He Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CA&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create Architecture&lt;/strong&gt; — Guided workflow to document all technical decisions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;IR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Implementation Readiness&lt;/strong&gt; — Validate PRD, UX, Architecture, and Stories are aligned&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Him
&lt;/h3&gt;

&lt;p&gt;Use Winston in &lt;strong&gt;Phase 3 (Solutioning)&lt;/strong&gt; after the PRD (and optionally UX) is complete, when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You need to define the technical stack, infrastructure, and API design&lt;/li&gt;
&lt;li&gt;You need to document architectural decisions before development begins&lt;/li&gt;
&lt;li&gt;You want a readiness gate to verify all planning artifacts are coherent before starting a sprint&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Creating architecture (&lt;code&gt;CA&lt;/code&gt;) is &lt;strong&gt;required&lt;/strong&gt; before sprint planning can begin.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 5 — 🏃 Bob, Scrum Master
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-sm&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;sm&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Scrum Master&lt;/p&gt;

&lt;h3&gt;
  
  
  Who He Is
&lt;/h3&gt;

&lt;p&gt;Bob is a certified Scrum Master with a deep technical background. He is crisp, checklist-driven, and has zero tolerance for ambiguity. Every word has a purpose, every requirement must be crystal clear. He loves talking Agile theory and serves as a servant leader to the team.&lt;/p&gt;

&lt;h3&gt;
  
  
  What He Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;SP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Sprint Planning&lt;/strong&gt; — Generate the sprint plan that sequences all stories for the dev agent&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CS&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Create Story&lt;/strong&gt; — Prepare a story with all implementation context for the dev agent&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;ER&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Epic Retrospective&lt;/strong&gt; — Party Mode review of all completed work across an epic&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CC&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Course Correction&lt;/strong&gt; — Navigate significant mid-sprint changes&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Him
&lt;/h3&gt;

&lt;p&gt;Use Bob in &lt;strong&gt;Phase 4 (Implementation)&lt;/strong&gt; to set up and manage development cycles:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;At the start of implementation to generate a sprint plan from the epics and stories list&lt;/li&gt;
&lt;li&gt;Before each dev cycle to prepare a context-rich story file for Amelia (the dev agent)&lt;/li&gt;
&lt;li&gt;After completing an epic, to run a retrospective and extract lessons learned&lt;/li&gt;
&lt;li&gt;Whenever unexpected changes require re-planning&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Sprint Planning (&lt;code&gt;SP&lt;/code&gt;) is the &lt;strong&gt;required first step&lt;/strong&gt; of Phase 4. Story creation (&lt;code&gt;CS&lt;/code&gt;) must happen before each Dev Story cycle.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 6 — 💻 Amelia, Developer Agent
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-dev&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;dev&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Developer Agent&lt;/p&gt;

&lt;h3&gt;
  
  
  Who She Is
&lt;/h3&gt;

&lt;p&gt;Amelia is a senior software engineer who executes approved stories with strict adherence to story details and team standards. She is ultra-succinct — speaks in file paths and acceptance criteria IDs. No fluff, all precision. She will never lie about tests being written or passing.&lt;/p&gt;

&lt;h3&gt;
  
  
  What She Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DS&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Dev Story&lt;/strong&gt; — Execute implementation tasks and tests for a prepared story&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Code Review&lt;/strong&gt; — Comprehensive code review across multiple quality facets&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Her
&lt;/h3&gt;

&lt;p&gt;Use Amelia in &lt;strong&gt;Phase 4 (Implementation)&lt;/strong&gt; to do the actual coding:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;When Bob has prepared a story file with full context&lt;/li&gt;
&lt;li&gt;To execute each story's tasks in strict order, writing tests as she goes&lt;/li&gt;
&lt;li&gt;After story implementation is complete, to run a code review before marking it done&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Dev Story (&lt;code&gt;DS&lt;/code&gt;) is a &lt;strong&gt;required&lt;/strong&gt; workflow. It follows every story creation cycle. Tests must pass 100% before a story is marked complete.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 7 — 🧪 Quinn, QA Engineer
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-qa&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;qa&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; QA Engineer&lt;/p&gt;

&lt;h3&gt;
  
  
  Who She Is
&lt;/h3&gt;

&lt;p&gt;Quinn is a pragmatic test automation engineer focused on rapid test coverage. She uses a "ship it and iterate" mentality — coverage first, optimization later. She uses standard test framework APIs (no external utilities) and focuses on realistic user scenarios. She is a simpler, more direct alternative to the advanced Test Architect module.&lt;/p&gt;

&lt;h3&gt;
  
  
  What She Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;QA&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Automate&lt;/strong&gt; — Generate API and E2E tests for existing implemented features&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Her
&lt;/h3&gt;

&lt;p&gt;Use Quinn in &lt;strong&gt;Phase 4 (Implementation)&lt;/strong&gt; after code is written, when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You want to add automated API or E2E test coverage to implemented features&lt;/li&gt;
&lt;li&gt;You need test generation quickly without overthinking&lt;/li&gt;
&lt;li&gt;Your project is small-to-medium in scale&lt;/li&gt;
&lt;li&gt;You want beginner-friendly test automation using standard framework patterns&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Quinn is &lt;strong&gt;not&lt;/strong&gt; for code review or story validation — use Amelia's &lt;code&gt;CR&lt;/code&gt; workflow for that. For enterprise-grade test strategy, use the separate Test Architect (TEA) module.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 8 — 🚀 Barry, Quick Flow Solo Dev
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-quick-flow-solo-dev&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;quick-flow-solo-dev&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Quick Flow Solo Dev&lt;/p&gt;

&lt;h3&gt;
  
  
  Who He Is
&lt;/h3&gt;

&lt;p&gt;Barry handles Quick Flow — from tech spec creation through implementation with minimum ceremony and lean artifacts. He is direct, confident, and implementation-focused. Uses tech slang and gets straight to the point. His philosophy: "Code that ships is better than perfect code that doesn't."&lt;/p&gt;

&lt;h3&gt;
  
  
  What He Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;QS&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Quick Spec&lt;/strong&gt; — Create a complete technical spec with implementation-ready stories (no full PRD/Architecture ceremony)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;QD&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Quick Dev&lt;/strong&gt; — Implement a story/spec end-to-end (the core of Quick Flow)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;CR&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Code Review&lt;/strong&gt; — Comprehensive code review (same as Amelia's)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Him
&lt;/h3&gt;

&lt;p&gt;Use Barry when you want to &lt;strong&gt;skip the full BMM planning phase&lt;/strong&gt;, specifically for:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Quick one-off tasks and small bug fixes&lt;/li&gt;
&lt;li&gt;Simple features being added to a well-established brownfield codebase&lt;/li&gt;
&lt;li&gt;Utilities and scripts without complex architectural concerns&lt;/li&gt;
&lt;li&gt;Solo developers who find full BMM planning too heavyweight&lt;/li&gt;
&lt;li&gt;Situations where the user explicitly doesn't want extensive planning&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Do &lt;strong&gt;not&lt;/strong&gt; use Barry for potentially complex or large features — the full BMM workflow (Mary → John → Winston → Bob → Amelia) exists for a reason. Barry is the escape hatch for simplicity.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Part 9 — 📚 Paige, Technical Writer
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Command:&lt;/strong&gt; &lt;code&gt;/bmad-agent-bmm-tech-writer&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Code:&lt;/strong&gt; &lt;code&gt;tech-writer&lt;/code&gt;&lt;br&gt;
&lt;strong&gt;Title:&lt;/strong&gt; Technical Writer&lt;/p&gt;

&lt;h3&gt;
  
  
  Who She Is
&lt;/h3&gt;

&lt;p&gt;Paige is an experienced technical writer expert in CommonMark, DITA, and OpenAPI. She transforms complex concepts into accessible, structured documentation. She believes a diagram is worth a thousand words and will always use Mermaid diagrams when appropriate. She is a patient educator who explains like teaching a friend.&lt;/p&gt;

&lt;h3&gt;
  
  
  What She Does
&lt;/h3&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Command&lt;/th&gt;
&lt;th&gt;Description&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;DP&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Document Project&lt;/strong&gt; — Generate comprehensive project documentation via brownfield analysis&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;WD&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Write Document&lt;/strong&gt; — Multi-turn conversation to author any document following documentation standards&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;US&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Update Standards&lt;/strong&gt; — Update her memory with your documentation preferences and conventions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;MG&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Mermaid Generate&lt;/strong&gt; — Create Mermaid-compliant diagrams (sequence, flow, ER, etc.)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;VD&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Validate Document&lt;/strong&gt; — Review a document against standards and return actionable improvements&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;EC&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Explain Concept&lt;/strong&gt; — Break down a complex technical concept into digestible sections with examples&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  When to Use Her
&lt;/h3&gt;

&lt;p&gt;Use Paige &lt;strong&gt;at any time&lt;/strong&gt; in the workflow, when:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You need to write or improve any document (README, ADR, API docs, technical specs)&lt;/li&gt;
&lt;li&gt;You want to generate a Mermaid diagram from a description&lt;/li&gt;
&lt;li&gt;You need to validate whether a document meets quality standards&lt;/li&gt;
&lt;li&gt;You want a complex concept explained clearly for a specific audience&lt;/li&gt;
&lt;li&gt;You want to establish or update documentation standards for your project&lt;/li&gt;
&lt;/ul&gt;

&lt;blockquote&gt;
&lt;p&gt;Paige is a &lt;strong&gt;universal, anytime agent&lt;/strong&gt; — she is not tied to any specific phase and can be used throughout the entire lifecycle.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  Summary: Agent Selection at a Glance
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Phase&lt;/th&gt;
&lt;th&gt;Agent&lt;/th&gt;
&lt;th&gt;When Required&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;1 — Analysis&lt;/td&gt;
&lt;td&gt;📊 Mary (Analyst)&lt;/td&gt;
&lt;td&gt;Optional (recommended)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;2 — Planning&lt;/td&gt;
&lt;td&gt;📋 John (PM)&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Required&lt;/strong&gt; — Create PRD&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;2 — Planning&lt;/td&gt;
&lt;td&gt;🎨 Sally (UX Designer)&lt;/td&gt;
&lt;td&gt;Optional (strongly recommended for UI)&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;3 — Solutioning&lt;/td&gt;
&lt;td&gt;🏗️ Winston (Architect)&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Required&lt;/strong&gt; — Create Architecture&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;3 — Solutioning&lt;/td&gt;
&lt;td&gt;📋 John (PM)&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Required&lt;/strong&gt; — Create Epics &amp;amp; Stories + IR check&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4 — Implementation&lt;/td&gt;
&lt;td&gt;🏃 Bob (Scrum Master)&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Required&lt;/strong&gt; — Sprint Planning + Create Story&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4 — Implementation&lt;/td&gt;
&lt;td&gt;💻 Amelia (Dev)&lt;/td&gt;
&lt;td&gt;
&lt;strong&gt;Required&lt;/strong&gt; — Dev Story each cycle&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4 — Implementation&lt;/td&gt;
&lt;td&gt;🧪 Quinn (QA)&lt;/td&gt;
&lt;td&gt;Optional — Add test coverage&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;4 — Implementation&lt;/td&gt;
&lt;td&gt;🏃 Bob (Scrum Master)&lt;/td&gt;
&lt;td&gt;Optional — Retrospective&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Any phase&lt;/td&gt;
&lt;td&gt;📚 Paige (Tech Writer)&lt;/td&gt;
&lt;td&gt;Optional — Docs, diagrams, explanations&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Any phase (bypass)&lt;/td&gt;
&lt;td&gt;🚀 Barry (Quick Flow)&lt;/td&gt;
&lt;td&gt;Optional — Small tasks, skip planning&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Run each agent in a fresh context window&lt;/strong&gt; for best results. For validation workflows, use the highest-quality LLM available.  &lt;/p&gt;

&lt;p&gt;This content is summarized by /bmad-help, the agent that helps us with anything about BMAD. You can also ask it for more details about BMAD usage.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>bmad</category>
      <category>agents</category>
      <category>sdlc</category>
    </item>
    <item>
      <title>Cô bé bán diêm phiên bản 2026</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 14 Jan 2026 10:08:59 +0000</pubDate>
      <link>https://dev.to/jacktt/co-be-ban-diem-phien-ban-2026-618</link>
      <guid>https://dev.to/jacktt/co-be-ban-diem-phien-ban-2026-618</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjve9n4y6s7jyx7qhckpc.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjve9n4y6s7jyx7qhckpc.png" alt=" " width="800" height="436"&gt;&lt;/a&gt;Đêm đông 2026, văn phòng vắng tanh.&lt;br&gt;
Một cậu dev ngồi OT, tay gõ từng dòng code cho kịp deadline: &lt;strong&gt;5 feature + hơn 80 bug&lt;/strong&gt;.&lt;/p&gt;




&lt;p&gt;Chiều hôm đó công ty thưởng &lt;strong&gt;500k Tết dương lịch&lt;/strong&gt;.&lt;br&gt;
Bất lực, cậu móc thêm tiền túi, mua &lt;strong&gt;Claude $20/tháng&lt;/strong&gt;, hy vọng AI vớt vát được phần nào.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Lần 1 – Cậu prompt vu vơ 2 dòng&lt;/strong&gt;&lt;br&gt;
Claude đọc hai ba file mà gen ra một đống code. Code chạy được, test thử đúng logic luôn!&lt;br&gt;
Nhưng nhìn lại thì...không theo chuẩn chung, không đúng convention, code một mình một kiểu.&lt;br&gt;
Kiểu này mà mở PR thì mai các anh reject liền. Cậu yêu cầu nó code lại nhưng chạy được một lúc thì Claude dính rate limit. Phải đợi 1 tiếng.&lt;/p&gt;

&lt;p&gt;Cậu xuống đường làm &lt;strong&gt;hộp xôi&lt;/strong&gt;.&lt;br&gt;
Quay lên vẫn còn &lt;strong&gt;40 phút&lt;/strong&gt;.&lt;br&gt;
Ngồi code chay được vài dòng thì nản quá.&lt;br&gt;
Cậu đi dọc &lt;strong&gt;bờ sông Tô Lịch&lt;/strong&gt;, qua cầu Giấy rồi quay lại, chỉ để đốt thời gian chờ Claude mở rate.&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Lần 2 – Yêu cầu Claude đọc hiểu project trước khi code&lt;/strong&gt;&lt;br&gt;
Lần này Claude đã hiểu context, lên plan, code đúng chuẩn, chạy mượt.&lt;br&gt;
Cậu hưng phấn, xứ lý tiếp các task khác. Nhưng lần này requirement dài gấp 10 lần.&lt;/p&gt;

&lt;p&gt;AI giúp nhiều, nhưng cậu vẫn phải động tay kha khá. Với tốc độ này cậu vẫn phải OT thêm vài hôm nữa...&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Lần 3 – BMAD&lt;/strong&gt;&lt;br&gt;
Đêm khuya, cậu nhớ mấy anh từng nhắc tới &lt;strong&gt;BMAD&lt;/strong&gt; như một team software development hoàn chỉnh, có thể tự phân tích requirement, lên kế hoạch, rồi code song song.&lt;/p&gt;

&lt;p&gt;Cậu thử install. Và đúng thật:&lt;/p&gt;

&lt;p&gt;PM agent chỉ đạo, BA agent đọc requirement, break task rành rọt, trông như một team xịn đang làm việc ngay trước mặt.&lt;br&gt;
Cậu khoái chí, ngồi lướt tóp tóp, đợi &lt;strong&gt;team dev $20/tháng&lt;/strong&gt; mới thuê code hộ.&lt;/p&gt;




&lt;p&gt;Sáng hôm sau, mọi người tới văn phòng, thấy cậu dev ngủ gục trên bàn, tay vẫn cầm điện thoại, miệng cười kiểu rất mãn nguyện.&lt;/p&gt;

&lt;p&gt;Màn hình máy tính nhấp nháy dòng chữ đỏ:&lt;br&gt;
&lt;strong&gt;"You have hit your weekly limit – Your limit will reset 5pm Thursday"&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>llm</category>
      <category>productivity</category>
      <category>softwaredevelopment</category>
    </item>
    <item>
      <title>Scaling Read Tracking with Redis Bitmaps</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Tue, 16 Sep 2025 23:48:26 +0000</pubDate>
      <link>https://dev.to/jacktt/scaling-read-tracking-with-redis-bitmaps-3aip</link>
      <guid>https://dev.to/jacktt/scaling-read-tracking-with-redis-bitmaps-3aip</guid>
      <description>&lt;p&gt;A friend recently came to me with a problem. They had designed a feature to track whether each user had read the latest posts in each category (a tab in the app).&lt;/p&gt;

&lt;p&gt;The first design looked simple: store a row in MySQL for every &lt;code&gt;(user_id, category_id)&lt;/code&gt; pair and update it whenever something changed.&lt;/p&gt;

&lt;p&gt;But in production, things broke badly.&lt;/p&gt;

&lt;h2&gt;
  
  
  The initial design
&lt;/h2&gt;

&lt;p&gt;Their schema looked like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight sql"&gt;&lt;code&gt;&lt;span class="n"&gt;category_user_read&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;
  &lt;span class="n"&gt;user_id&lt;/span&gt; &lt;span class="nb"&gt;BIGINT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="n"&gt;category_id&lt;/span&gt; &lt;span class="nb"&gt;BIGINT&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="k"&gt;read&lt;/span&gt; &lt;span class="nb"&gt;BOOLEAN&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
  &lt;span class="k"&gt;PRIMARY&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;user_id&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;category_id&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
  &lt;span class="k"&gt;FOREIGN&lt;/span&gt; &lt;span class="k"&gt;KEY&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;user_id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;REFERENCES&lt;/span&gt; &lt;span class="n"&gt;users&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;id&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;The logic was:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;When a user opened a category, update their row with &lt;code&gt;read = true&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;When a new post was added, update all rows in that category with &lt;code&gt;read = false&lt;/code&gt;.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Simple enough, right?&lt;/p&gt;

&lt;h2&gt;
  
  
  Where it failed
&lt;/h2&gt;

&lt;p&gt;In practice, this design was a database bottleneck:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Every page view triggered an update.&lt;/li&gt;
&lt;li&gt;Every new post triggered a mass update across potentially millions of rows.&lt;/li&gt;
&lt;li&gt;InnoDB placed exclusive row locks for each update.&lt;/li&gt;
&lt;li&gt;The foreign key to users meant even more locking, since InnoDB had to check referential integrity.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;With thousands of concurrent users, the table essentially turned into a global contention point.&lt;/p&gt;

&lt;h2&gt;
  
  
  Clarified requirements
&lt;/h2&gt;

&lt;p&gt;After digging deeper, I asked the team what the product really needed. It turned out the requirement was much simpler:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Just show a red dot on the tab if the user hasn’t read the category yet.&lt;/li&gt;
&lt;li&gt;No need to track the exact “last read post ID”.&lt;/li&gt;
&lt;li&gt;The data isn’t critical — it can tolerate some loss.&lt;/li&gt;
&lt;li&gt;But it must be fast and able to scale with millions of users.&lt;/li&gt;
&lt;li&gt;That clarification changed everything about the design.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Redis Bitmap approach
&lt;/h2&gt;

&lt;p&gt;I suggested they throw away the heavy MySQL design and move the state into Redis bitmaps:&lt;br&gt;
Think of it as an array of 0 and 1 values, where each position in the array corresponds to a user_id.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;One bitmap per category.&lt;/li&gt;
&lt;li&gt;We simply use the user_id number as the index in the bit array.

&lt;ul&gt;
&lt;li&gt;This makes the implementation extremely simple.&lt;/li&gt;
&lt;li&gt;The trade-off is that if user IDs are sparse (e.g. max ID = 10M but only 1M active users), the bitmap may be larger than necessary.&lt;/li&gt;
&lt;li&gt;But in practice, this overhead is small compared to the simplicity gained.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;SETBIT category:&lt;span class="o"&gt;{&lt;/span&gt;category_id&lt;span class="o"&gt;}&lt;/span&gt;:read &lt;span class="o"&gt;{&lt;/span&gt;user_id&lt;span class="o"&gt;}&lt;/span&gt; 1
GETBIT category:&lt;span class="o"&gt;{&lt;/span&gt;category_id&lt;span class="o"&gt;}&lt;/span&gt;:read &lt;span class="o"&gt;{&lt;/span&gt;user_id&lt;span class="o"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;When a user opens a category → set their bit to 1.&lt;/li&gt;
&lt;li&gt;When a new post is added → Simply delete the bitmap key for that category
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;  DEL category:&lt;span class="o"&gt;{&lt;/span&gt;category_id&lt;span class="o"&gt;}&lt;/span&gt;:read
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Result &amp;amp; scalibility
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Blazing fast: Bitmap operations are constant time (O(1)), with no locking overhead.&lt;/li&gt;
&lt;li&gt;Tiny memory footprint:

&lt;ul&gt;
&lt;li&gt;1 million users → 1 million bits → ~122 KB.&lt;/li&gt;
&lt;li&gt;Even with tens of millions of users, the memory cost stays in MBs.&lt;/li&gt;
&lt;li&gt;Scales naturally: No matter how many users open categories concurrently, Redis handles it without contention.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

</description>
      <category>systemdesign</category>
      <category>redis</category>
      <category>mysql</category>
    </item>
    <item>
      <title>AWS Lambda with Go - How to Build, Deploy, and Invoke</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Wed, 20 Aug 2025 00:36:02 +0000</pubDate>
      <link>https://dev.to/jacktt/aws-lambda-with-go-how-to-build-deploy-and-invoke-1p0o</link>
      <guid>https://dev.to/jacktt/aws-lambda-with-go-how-to-build-deploy-and-invoke-1p0o</guid>
      <description>&lt;h1&gt;
  
  
  Build, Deploy, and Invoke AWS Lambda Functions in Golang
&lt;/h1&gt;

&lt;h2&gt;
  
  
  1. Initialize Lambda main function &amp;amp; handler in Go
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Go Lambda starts from the &lt;code&gt;main()&lt;/code&gt; function, usually with &lt;code&gt;lambda.Start(handler)&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Handler&lt;/strong&gt; function signatures:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TOut&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TIn&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TIn&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TOut&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Context&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Context&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TOut&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Context&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;TIn&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;
  &lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Context&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;TIn&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;TOut&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;ctx&lt;/code&gt;: context for timeout, logs, request ID&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;TIn&lt;/code&gt; and &lt;code&gt;TOut&lt;/code&gt; represent types that can be Unmarshal JSON.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Example:&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;```go
package main

import (
    "context"
    "github.com/aws/aws-lambda-go/lambda"
)

type MyEvent struct {
    Name string `json:"name"`
}

func handler(ctx context.Context, e MyEvent) (string, error) {
    return "Hello " + e.Name, nil
}

func main() {
    lambda.Start(handler)
}
```
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  2. Deployment methods
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;(a) Zip deployment&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;GOOS=linux GOARCH=amd64 go build -o bootstrap main.go
zip function.zip bootstrap
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Upload &lt;code&gt;function.zip&lt;/code&gt; to Lambda.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;(b) Docker container deployment&lt;/strong&gt;&lt;br&gt;
Dockerfile example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;FROM public.ecr.aws/lambda/go:1
COPY main ${LAMBDA_TASK_ROOT}
CMD ["main"]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Push the image to ECR and deploy.&lt;/p&gt;




&lt;h2&gt;
  
  
  3. Invocation methods
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;AWS CLI&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;aws lambda invoke --function-name MyFunction --payload '{"name":"Jack"}' response.json
cat response.json
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Go SDK (aws-sdk-go-v2)&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;lambda&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;NewFromConfig&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cfg&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Invoke&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;context&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;TODO&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;lambda&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;InvokeInput&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;FunctionName&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt; &lt;span class="n"&gt;aws&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;String&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"MyFunction"&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;Payload&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;      &lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="kt"&gt;byte&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;`{"name":"Jack"}`&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
&lt;span class="p"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  4. Create &amp;amp; Update Lambda Function via AWS CLI
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Create function (ZIP deployment)&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;aws lambda create-function \
  --function-name MyFunction \
  --runtime go1.x \
  --role arn:aws:iam::&amp;lt;account-id&amp;gt;:role/&amp;lt;lambda-execution-role&amp;gt; \
  --handler bootstrap \
  --zip-file fileb://function.zip
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Update function code (ZIP deployment)&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;aws lambda update-function-code \
  --function-name MyFunction \
  --zip-file fileb://function.zip
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docs.aws.amazon.com/lambda/latest/dg/golang-handler.html" rel="noopener noreferrer"&gt;https://docs.aws.amazon.com/lambda/latest/dg/golang-handler.html&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>aws</category>
      <category>go</category>
      <category>lambda</category>
    </item>
    <item>
      <title>Tracing error strack in Golang</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Fri, 23 May 2025 11:40:00 +0000</pubDate>
      <link>https://dev.to/jacktt/tracing-error-strack-in-golang-234o</link>
      <guid>https://dev.to/jacktt/tracing-error-strack-in-golang-234o</guid>
      <description>&lt;h2&gt;
  
  
  Problem: No Stack Trace in Native Errors
&lt;/h2&gt;

&lt;p&gt;Consider this Go snippet:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="n"&gt;function3&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;var&lt;/span&gt; &lt;span class="n"&gt;result1&lt;/span&gt; &lt;span class="k"&gt;map&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="kt"&gt;string&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="kt"&gt;int&lt;/span&gt;
    &lt;span class="n"&gt;input1&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="s"&gt;`{"key": "value"}`&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Unmarshal&lt;/span&gt;&lt;span class="p"&gt;([]&lt;/span&gt;&lt;span class="kt"&gt;byte&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input1&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;result1&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;!=&lt;/span&gt; &lt;span class="no"&gt;nil&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;var&lt;/span&gt; &lt;span class="n"&gt;result2&lt;/span&gt; &lt;span class="k"&gt;map&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="kt"&gt;string&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="kt"&gt;int&lt;/span&gt;
    &lt;span class="n"&gt;input2&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="s"&gt;`{"key": 123}`&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Unmarshal&lt;/span&gt;&lt;span class="p"&gt;([]&lt;/span&gt;&lt;span class="kt"&gt;byte&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;input2&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;result2&lt;/span&gt;&lt;span class="p"&gt;);&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;!=&lt;/span&gt; &lt;span class="no"&gt;nil&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="no"&gt;nil&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When an error occurs, you’ll get:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;json: cannot unmarshal string into Go value of &lt;span class="nb"&gt;type &lt;/span&gt;int
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;But which line caused it? The first or second Unmarshal?&lt;br&gt;
Without a stack trace, it’s unclear.&lt;/p&gt;
&lt;h2&gt;
  
  
  Solution: Attach a Stack Trace
&lt;/h2&gt;

&lt;p&gt;Using &lt;a href="https://github.com/cockroachdb/errors" rel="noopener noreferrer"&gt;github.com/cockroachdb/errors&lt;/a&gt;, you can wrap errors with &lt;code&gt;errors.WithStack&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;errors&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;WithStack&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Example output with &lt;code&gt;fmt.Printf("%+v", err)&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;json: cannot unmarshal string into Go value of &lt;span class="nb"&gt;type &lt;/span&gt;int
&lt;span class="o"&gt;(&lt;/span&gt;1&lt;span class="o"&gt;)&lt;/span&gt; attached stack trace
  &lt;span class="nt"&gt;--&lt;/span&gt; stack trace:
  | main.function3
  |     /golang-test/errror_tracing/main.go:28
  | main.function2
  |     /backend/golang-test/errror_tracing/main.go:19
  | main.function1
  |     /backend/golang-test/errror_tracing/main.go:15
  | main.main
  |     /backend/golang-test/errror_tracing/main.go:10
  | runtime.main
  |     /Users/jack/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.23.9.darwin-arm64/src/runtime/proc.go:272
  | runtime.goexit
  |     /Users/jack/go/pkg/mod/golang.org/toolchain@v0.0.1-go1.23.9.darwin-arm64/src/runtime/asm_arm64.s:1223
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you know exactly where the error occurred.&lt;/p&gt;

&lt;h2&gt;
  
  
  Under the Hood: How Stack Capture Works
&lt;/h2&gt;

&lt;p&gt;Go’s &lt;code&gt;runtime.Callers()&lt;/code&gt; lets you capture the current stack:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="n"&gt;printStack&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="c"&gt;// Declare an array to hold up to 10 program counters (PCs).&lt;/span&gt;
    &lt;span class="c"&gt;// PCs represent the addresses of the function calls in the call stack.&lt;/span&gt;
    &lt;span class="k"&gt;var&lt;/span&gt; &lt;span class="n"&gt;pcs&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="m"&gt;10&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="kt"&gt;uintptr&lt;/span&gt;

    &lt;span class="c"&gt;// Capture the call stack PCs, skipping the first 2 frames:&lt;/span&gt;
    &lt;span class="c"&gt;// 0 = runtime.Callers, 1 = printStack itself.&lt;/span&gt;
    &lt;span class="c"&gt;// pcs[:] converts the array to a slice.&lt;/span&gt;
    &lt;span class="c"&gt;// n is the number of PCs actually captured.&lt;/span&gt;
    &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;runtime&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Callers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;2&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pcs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;

    &lt;span class="c"&gt;// Create a Frames iterator from the captured PCs slice,&lt;/span&gt;
    &lt;span class="c"&gt;// which translates PCs into human-readable function/file/line info.&lt;/span&gt;
    &lt;span class="n"&gt;frames&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;runtime&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;CallersFrames&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;pcs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;

    &lt;span class="c"&gt;// Loop through the frames iterator until there are no more frames.&lt;/span&gt;
    &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="c"&gt;// Get the next frame and a boolean indicating if more frames remain.&lt;/span&gt;
        &lt;span class="n"&gt;frame&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;more&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;frames&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Next&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

        &lt;span class="c"&gt;// Print the function name, source file, and line number of this frame.&lt;/span&gt;
        &lt;span class="n"&gt;fmt&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Printf&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s"&gt;"%s&lt;/span&gt;&lt;span class="se"&gt;\n\t&lt;/span&gt;&lt;span class="s"&gt;%s:%d&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;frame&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Function&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;frame&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;File&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;frame&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Line&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="c"&gt;// If there are no more frames, break out of the loop.&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="n"&gt;more&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="k"&gt;break&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This function prints the call path to its current point in the code.&lt;/p&gt;

&lt;h2&gt;
  
  
  Rebuilding errors.WithStack
&lt;/h2&gt;

&lt;p&gt;Here’s a minimal reimplementation of &lt;code&gt;errors.WithStack&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="k"&gt;type&lt;/span&gt; &lt;span class="n"&gt;errWithStack&lt;/span&gt; &lt;span class="k"&gt;struct&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="n"&gt;err&lt;/span&gt;   &lt;span class="kt"&gt;error&lt;/span&gt;
    &lt;span class="n"&gt;stack&lt;/span&gt; &lt;span class="p"&gt;[]&lt;/span&gt;&lt;span class="kt"&gt;uintptr&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="n"&gt;WithStack&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="kt"&gt;error&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;err&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="no"&gt;nil&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="no"&gt;nil&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
    &lt;span class="k"&gt;var&lt;/span&gt; &lt;span class="n"&gt;pcs&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="m"&gt;32&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="kt"&gt;uintptr&lt;/span&gt;
    &lt;span class="n"&gt;n&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;runtime&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Callers&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="m"&gt;3&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pcs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="o"&gt;&amp;amp;&lt;/span&gt;&lt;span class="n"&gt;errWithStack&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;pcs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;&lt;span class="n"&gt;n&lt;/span&gt;&lt;span class="p"&gt;]}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="n"&gt;errWithStack&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="kt"&gt;string&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt; &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Error&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="c"&gt;// Format implemnets fmt.Formatter&lt;/span&gt;
&lt;span class="k"&gt;func&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt;&lt;span class="n"&gt;errWithStack&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="n"&gt;Format&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;s&lt;/span&gt; &lt;span class="n"&gt;fmt&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;State&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;verb&lt;/span&gt; &lt;span class="kt"&gt;rune&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;switch&lt;/span&gt; &lt;span class="n"&gt;verb&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
    &lt;span class="k"&gt;case&lt;/span&gt; &lt;span class="sc"&gt;'v'&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Flag&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sc"&gt;'+'&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="n"&gt;fmt&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Fprint&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="n"&gt;frames&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;runtime&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;CallersFrames&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;stack&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;more&lt;/span&gt; &lt;span class="o"&gt;:=&lt;/span&gt; &lt;span class="n"&gt;frames&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Next&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
                &lt;span class="n"&gt;fmt&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Fprintf&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="s"&gt;%s&lt;/span&gt;&lt;span class="se"&gt;\n\t&lt;/span&gt;&lt;span class="s"&gt;%s:%d"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Function&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;File&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Line&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="o"&gt;!&lt;/span&gt;&lt;span class="n"&gt;more&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                    &lt;span class="k"&gt;break&lt;/span&gt;
                &lt;span class="p"&gt;}&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;fallthrough&lt;/span&gt;
    &lt;span class="k"&gt;case&lt;/span&gt; &lt;span class="sc"&gt;'s'&lt;/span&gt;&lt;span class="o"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;fmt&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;Fprint&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;s&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="o"&gt;.&lt;/span&gt;&lt;span class="n"&gt;err&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="p"&gt;}&lt;/span&gt;
&lt;span class="p"&gt;}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Behavior:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;fmt.Println(err)&lt;/code&gt; → shows the error message only&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;fmt.Printf("%+v", err)&lt;/code&gt; → includes full stack trace&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Summary
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Standard errors in Go don’t include stack traces.&lt;/li&gt;
&lt;li&gt;Using libraries like &lt;code&gt;cockroachdb/errors&lt;/code&gt; gives you precise visibility into where errors happen — critical for debugging complex applications.&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>go</category>
      <category>programming</category>
    </item>
    <item>
      <title>A better pkg.go.dev</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Sun, 16 Feb 2025 12:35:06 +0000</pubDate>
      <link>https://dev.to/jacktt/a-better-pkggodev-hip</link>
      <guid>https://dev.to/jacktt/a-better-pkggodev-hip</guid>
      <description>&lt;h2&gt;
  
  
  About pkgo.dev
&lt;/h2&gt;

&lt;p&gt;I have never been able to read a package's documentation on pkg.go.dev since all the code there is in black &amp;amp; white...&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg3dpazd6dv3m8mu8qa6i.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fg3dpazd6dv3m8mu8qa6i.png" alt="Image description" width="800" height="442"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This is the reason I created this repository to make it possible to read.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl422wqphwy5ya91uxa6o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fl422wqphwy5ya91uxa6o.png" alt="Image description" width="800" height="432"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;
  
  
  Usage
&lt;/h2&gt;

&lt;p&gt;Every time you want to read a package's documentation, you just need to replace &lt;a href="https://pkg.go.dev" rel="noopener noreferrer"&gt;pkg.go.dev&lt;/a&gt; with &lt;a href="https://pkgo.dev" rel="noopener noreferrer"&gt;pkgo.dev&lt;/a&gt;. &lt;em&gt;(remove the &lt;code&gt;.g&lt;/code&gt;)&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;E.g.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://pkg.go.dev/github.com/segmentio/kafka-go#section-readme" rel="noopener noreferrer"&gt;https://pkg.go.dev/github.com/segmentio/kafka-go#section-readme&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://pkgo.dev/github.com/segmentio/kafka-go#section-readme" rel="noopener noreferrer"&gt;https://pkgo.dev/github.com/segmentio/kafka-go#section-readme&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  How it works
&lt;/h2&gt;

&lt;p&gt;We use Nginx as proxy server.&lt;/p&gt;

&lt;p&gt;Every time a request come in, we forward it to the &lt;a href="https://pkg.go.dev" rel="noopener noreferrer"&gt;pkg.go.dev&lt;/a&gt; server, then append the &lt;a href="https://highlightjs.org" rel="noopener noreferrer"&gt;highlight.js&lt;/a&gt; script to the response before sending it back to the client.&lt;/p&gt;

&lt;p&gt;Since some README files do not specify the code language, we also update &lt;code&gt;&amp;lt;code&amp;gt;&lt;/code&gt; tags to &lt;code&gt;&amp;lt;code class="language-go"&amp;gt;&lt;/code&gt; to enable syntax highlighting.&lt;/p&gt;

&lt;p&gt;If you don't trust me, no worry, you can deploy it yourself:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Append &lt;code&gt;127.0.0.1       pkg.go.dev.local&lt;/code&gt; to &lt;code&gt;/etc/hosts&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Run &lt;code&gt;docker-compose up -d --build&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Access &lt;code&gt;http://pkg.go.dev.local&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Source code
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/huantt/better-pkg-go-dev" rel="noopener noreferrer"&gt;https://github.com/huantt/better-pkg-go-dev&lt;/a&gt;&lt;br&gt;
&lt;/p&gt;
&lt;div class="ltag-github-readme-tag"&gt;
  &lt;div class="readme-overview"&gt;
    &lt;h2&gt;
      &lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fassets.dev.to%2Fassets%2Fgithub-logo-5a155e1f9a670af7944dd5e12375bc76ed542ea80224905ecaf878b9157cdefc.svg" alt="GitHub logo"&gt;
      &lt;a href="https://github.com/huantt" rel="noopener noreferrer"&gt;
        huantt
      &lt;/a&gt; / &lt;a href="https://github.com/huantt/better-pkg-go-dev" rel="noopener noreferrer"&gt;
        better-pkg-go-dev
      &lt;/a&gt;
    &lt;/h2&gt;
    &lt;h3&gt;
      Make pkg.go.dev more readable
    &lt;/h3&gt;
  &lt;/div&gt;
  &lt;div class="ltag-github-body"&gt;
    
&lt;div id="readme" class="md"&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;About&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;I have never been able to read a package's documentation on pkg.go.dev since all the code there is in black &amp;amp; white...
&lt;a rel="noopener noreferrer" href="https://github.com/huantt/better-pkg-go-dev./docs/before.png"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fgithub.com%2Fhuantt%2Fbetter-pkg-go-dev.%2Fdocs%2Fbefore.png" alt="original.png"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is the reason I created this repository to make it possible to read.&lt;/p&gt;
&lt;p&gt;&lt;a rel="noopener noreferrer" href="https://github.com/huantt/better-pkg-go-dev./docs/after.png"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fgithub.com%2Fhuantt%2Fbetter-pkg-go-dev.%2Fdocs%2Fafter.png" alt="original.png"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;Usage&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;Every time you want to read a package's documentation, you just need to replace &lt;a href="https://pkg.go.dev" rel="nofollow noopener noreferrer"&gt;pkg.go.dev&lt;/a&gt; with &lt;a href="https://pkgo.dev" rel="nofollow noopener noreferrer"&gt;pkgo.dev&lt;/a&gt;. &lt;em&gt;(remove the &lt;code&gt;.g&lt;/code&gt;)&lt;/em&gt;.&lt;/p&gt;
&lt;div class="markdown-heading"&gt;
&lt;h2 class="heading-element"&gt;How it works&lt;/h2&gt;

&lt;/div&gt;
&lt;p&gt;We use Nginx as proxy server.&lt;/p&gt;
&lt;p&gt;Every time a request come in, we forward it to the &lt;a href="https://pkg.go.dev" rel="nofollow noopener noreferrer"&gt;pkg.go.dev&lt;/a&gt; server, then append the &lt;a href="https://highlightjs.org" rel="nofollow noopener noreferrer"&gt;highlight.js&lt;/a&gt; script to the response before sending it back to the client.&lt;/p&gt;
&lt;p&gt;Since some README files do not specify the code language, we also update &lt;code&gt;&amp;lt;code&amp;gt;&lt;/code&gt; tags to &lt;code&gt;&amp;lt;code class="language-go"&amp;gt;&lt;/code&gt; to enable syntax highlighting.&lt;/p&gt;
&lt;p&gt;If you don't trust me, no worry, you can deploy it yourself:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Append &lt;code&gt;127.0.0.1       pkg.go.dev.local&lt;/code&gt; to &lt;code&gt;/etc/hosts&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Run &lt;code&gt;docker-compose up -d --build&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;Access &lt;code&gt;http://pkg.go.dev.local&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/div&gt;



&lt;/div&gt;
&lt;br&gt;
  &lt;div class="gh-btn-container"&gt;&lt;a class="gh-btn" href="https://github.com/huantt/better-pkg-go-dev" rel="noopener noreferrer"&gt;View on GitHub&lt;/a&gt;&lt;/div&gt;
&lt;br&gt;
&lt;/div&gt;
&lt;br&gt;


</description>
      <category>go</category>
    </item>
    <item>
      <title>Pod Topology Spread Constraints</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Sun, 12 Jan 2025 10:43:49 +0000</pubDate>
      <link>https://dev.to/jacktt/pod-topology-spread-constraints-2pd7</link>
      <guid>https://dev.to/jacktt/pod-topology-spread-constraints-2pd7</guid>
      <description>&lt;h2&gt;
  
  
  Pod Topology Spread Constraints
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Pod Topology Spread Constraints&lt;/strong&gt; - a.k.a &lt;strong&gt;topologySpreadConstraints&lt;/strong&gt; is a field of Pod.spec&lt;/p&gt;

&lt;p&gt;It allows you to define how Pods should be spread across different topological domains, such as zones or nodes, to achieve better availability, fault tolerance, and resource utilization.&lt;/p&gt;

&lt;h2&gt;
  
  
  Main attributes
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;topologyKey&lt;/strong&gt;: is a string representing a node label key. Kubernetes uses this key to identify and group nodes into topological domains. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Common values&lt;/strong&gt;: &lt;code&gt;kubernetes.io/hostname&lt;/code&gt; | &lt;code&gt;topology.kubernetes.io/region&lt;/code&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;&lt;p&gt;&lt;strong&gt;maxSkew&lt;/strong&gt;: Specifies the maximum difference in the number of Pods across topological domains. A lower skew ensures a more even distribution.&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;&lt;p&gt;&lt;strong&gt;labelSelector&lt;/strong&gt;: is used to find matching Pods. Pods that match this label selector are counted to determine the number of Pods in their corresponding topology domain.&lt;/p&gt;&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;&lt;strong&gt;whenUnsatisfiable&lt;/strong&gt;: indicates how to deal with a Pod if it doesn't satisfy the spread constraint. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;DoNotSchedule&lt;/strong&gt; (default) tells the scheduler not to schedule it.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ScheduleAnyway&lt;/strong&gt; tells the scheduler to still schedule it while prioritizing nodes that minimize the skew.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  Benefits of Using TSC
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Improved Fault Tolerance&lt;/strong&gt;: By spreading Pods across zones or nodes, the impact of a failure in one domain is minimized.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Better Resource Utilization&lt;/strong&gt;: Ensures even distribution of workloads, preventing overloading specific domains.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Customizable Scheduling&lt;/strong&gt;: Fine-tune how workloads are distributed based on application requirements.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Example
&lt;/h2&gt;

&lt;p&gt;The following spec prefer spreading pods across nodes based on kubernetes.io/hostname.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;topologySpreadConstraints&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
&lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;maxSkew&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="m"&gt;1&lt;/span&gt;
  &lt;span class="na"&gt;topologyKey&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;kubernetes.io/hostname&lt;/span&gt;
  &lt;span class="na"&gt;whenUnsatisfiable&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;ScheduleAnyway&lt;/span&gt;
  &lt;span class="na"&gt;labelSelector&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;matchLabels&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="na"&gt;app&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;hello-world&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Reference
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/" rel="noopener noreferrer"&gt;https://kubernetes.io/docs/concepts/scheduling-eviction/topology-spread-constraints/&lt;/a&gt;&lt;/p&gt;

</description>
      <category>kubernetes</category>
      <category>devops</category>
    </item>
    <item>
      <title>Avoid Misunderstanding ON DELETE NO ACTION</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Sun, 06 Oct 2024 02:34:34 +0000</pubDate>
      <link>https://dev.to/jacktt/avoid-misunderstanding-on-delete-no-action-gcj</link>
      <guid>https://dev.to/jacktt/avoid-misunderstanding-on-delete-no-action-gcj</guid>
      <description>&lt;p&gt;Relational databases often provide several options for handling actions when a referenced row in a foreign key relationship is deleted. &lt;br&gt;
Among these options, &lt;code&gt;ON DELETE NO ACTION&lt;/code&gt; can be a bit confusing, both in terms of its naming and its behavior.&lt;/p&gt;

&lt;p&gt;Let's read my post to ensure that you understand it correctly.&lt;/p&gt;

&lt;h3&gt;
  
  
  What Are ON DELETE Options?
&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;ON DELETE&lt;/code&gt; clause in SQL allows you to define what should happen to the rows in a child table when the related row in the parent table is deleted. &lt;code&gt;ON DELETE&lt;/code&gt; options include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;CASCADE&lt;/strong&gt;: Automatically deletes child rows when the parent row is deleted.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;SET NULL&lt;/strong&gt;: Sets the foreign key value in child rows to NULL when the parent row is deleted.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;RESTRICT&lt;/strong&gt;: Prevents deletion of the parent row if any child rows exist.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;NO ACTION&lt;/strong&gt;: Similar to RESTRICT; the action is deferred until the end of the transaction.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Comparing ON DELETE NO ACTION and ON DELETE RESTRICT
&lt;/h3&gt;

&lt;p&gt;&lt;code&gt;ON DELETE NO ACTION&lt;/code&gt; and &lt;code&gt;ON DELETE RESTRICT&lt;/code&gt; seem similar since both options ultimately prevent the deletion of the parent row if it has dependent rows in the child table. However, the difference i in the timing:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;ON DELETE NO ACTION&lt;/strong&gt;: The restriction is enforced &lt;strong&gt;at the end of the transaction&lt;/strong&gt;. If any other statements within the transaction resolve the issue (like deleting the child rows), the delete action can proceed without raising an error.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ON DELETE RESTRICT&lt;/strong&gt;: The restriction is enforced &lt;strong&gt;immediately&lt;/strong&gt;, preventing the delete action as soon as it’s attempted, without waiting for the end of the transaction.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;em&gt;If you're using Golang, you can reference "&lt;/em&gt;&lt;em&gt;ON DELETE NO ACTION&lt;/em&gt;&lt;em&gt;" similarly to "&lt;/em&gt;&lt;em&gt;defer RESTRICT&lt;/em&gt;&lt;em&gt;".&lt;/em&gt;&lt;/p&gt;

</description>
      <category>database</category>
    </item>
    <item>
      <title>[Golang] Understanding Unbuffered and Buffered Channels</title>
      <dc:creator>JackTT</dc:creator>
      <pubDate>Sat, 14 Sep 2024 08:07:26 +0000</pubDate>
      <link>https://dev.to/jacktt/golang-understanding-unbuffered-and-buffered-channels-35bh</link>
      <guid>https://dev.to/jacktt/golang-understanding-unbuffered-and-buffered-channels-35bh</guid>
      <description>&lt;h2&gt;
  
  
  Table of contents
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Channel capacity&lt;/li&gt;
&lt;li&gt;Behavior&lt;/li&gt;
&lt;li&gt;Closed channel&lt;/li&gt;
&lt;li&gt;Receive-Only &amp;amp; Send-only Channel&lt;/li&gt;
&lt;li&gt;References&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Channel capacity
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Unbuffered channel: 

&lt;ul&gt;
&lt;li&gt;Has no capacity. &lt;/li&gt;
&lt;li&gt;You can imagine it like a highway that allows one car to run through but does not support any cars to park there.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;Buffered channel: 

&lt;ul&gt;
&lt;li&gt;Has a fixed capacity at declaration time. &lt;/li&gt;
&lt;li&gt;It's like a queue that supports holding up to a fixed number of pending messages before consuming.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  Behavior
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;Unbuffered channel:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Sender is blocked until a receiver receive the message.&lt;/li&gt;
&lt;li&gt;Receiver is blocked until a sender sends a message.&lt;/li&gt;
&lt;li&gt;The sending and receiving processes are &lt;strong&gt;synchronous&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;

&lt;p&gt;Buffered channel:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Senders are blocked only when the buffer is full.&lt;/li&gt;
&lt;li&gt;Receivers are blocked when the buffer is empty.&lt;/li&gt;
&lt;li&gt;The sending and receiving processes are &lt;strong&gt;asynchronous&lt;/strong&gt;. Senders are released immediately after the sending action without waiting for the receiver.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Worth noting:&lt;/strong&gt; &lt;em&gt;An &lt;code&gt;unbuffered channel&lt;/code&gt; differs from a &lt;code&gt;buffered channel with a size of 1&lt;/code&gt; according to the behavior described above.&lt;/em&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Closed channel
&lt;/h2&gt;

&lt;p&gt;When a channel is &lt;strong&gt;closed&lt;/strong&gt; in Go using the &lt;code&gt;close()&lt;/code&gt; function:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Sending&lt;/strong&gt; to a closed channel causes a &lt;code&gt;panic&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Receiving&lt;/strong&gt; from a closed channel continues to retrieve values until the buffer is drained (for buffered channels). 
After the buffer is empty, further receives return the zero value of the channel's type and do not block.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You can &lt;strong&gt;check if a channel is closed&lt;/strong&gt; by receiving a second value from the channel, e.g., &lt;code&gt;v, ok := &amp;lt;-ch&lt;/code&gt;. The &lt;code&gt;ok&lt;/code&gt; will be &lt;code&gt;false&lt;/code&gt; if the channel is closed.&lt;/p&gt;

&lt;h2&gt;
  
  
  Receive-Only &amp;amp; Send-only Channel
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Receive-only channel&lt;/strong&gt; in Go is a channel that can only be used to receive values.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Declaration&lt;/strong&gt;: &lt;code&gt;var ch &amp;lt;-chan int&lt;/code&gt; defines a channel from which only receiving is allowed.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Behavior&lt;/strong&gt;: 

&lt;ul&gt;
&lt;li&gt;Attempting to &lt;strong&gt;send to a read-only channel&lt;/strong&gt; will result in a &lt;strong&gt;compilation error&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Attempting to &lt;strong&gt;pass a receive-only channel into a function that requires normal channel&lt;/strong&gt; also lead to a &lt;strong&gt;compilation error&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Send-only channel&lt;/strong&gt; is similar.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight go"&gt;&lt;code&gt;&lt;span class="k"&gt;var&lt;/span&gt; &lt;span class="n"&gt;ch&lt;/span&gt; &lt;span class="k"&gt;chan&lt;/span&gt;&lt;span class="o"&gt;&amp;lt;-&lt;/span&gt; &lt;span class="kt"&gt;int&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  References
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://go.dev/tour/concurrency/2" rel="noopener noreferrer"&gt;https://go.dev/tour/concurrency/2&lt;/a&gt;
&lt;em&gt;(By default, sends and receives block until the other side is ready. This allows goroutines to synchronize without explicit locks or condition variables)&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://go.dev/tour/concurrency/3" rel="noopener noreferrer"&gt;https://go.dev/tour/concurrency/3&lt;/a&gt;
&lt;em&gt;(Sends to a buffered channel block only when the buffer is full. Receives block when the buffer is empty)&lt;/em&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://golangr.com/channel-directions" rel="noopener noreferrer"&gt;https://golangr.com/channel-directions&lt;/a&gt;
(Receive-only and Send-only channels)&lt;/li&gt;
&lt;li&gt;&lt;a href="https://go101.org/article/channel.html" rel="noopener noreferrer"&gt;https://go101.org/article/channel.html&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

</description>
      <category>go</category>
    </item>
  </channel>
</rss>
