siesa-agents 2.1.43 → 2.1.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/bmad/_config/workflow-manifest.csv +1 -0
  2. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-01-load-story.md +101 -0
  3. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-02-build-plan.md +89 -0
  4. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-03-review.md +91 -0
  5. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-04-fix.md +92 -0
  6. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-05-sync-sprint.md +70 -0
  7. package/bmad/bmm/workflows/4-implementation/code-review/steps/step-06-jira-sync.md +123 -0
  8. package/bmad/bmm/workflows/4-implementation/code-review/workflow.md +57 -0
  9. package/bmad/bmm/workflows/5-documentation/README.md +234 -0
  10. package/bmad/bmm/workflows/5-documentation/create-user-guide/data/audience-types.csv +5 -0
  11. package/bmad/bmm/workflows/5-documentation/create-user-guide/data/diagram-types.csv +6 -0
  12. package/bmad/bmm/workflows/5-documentation/create-user-guide/data/section-structure.csv +10 -0
  13. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-01-init.md +313 -0
  14. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-01b-continue.md +268 -0
  15. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-02-seleccion-epicas.md +212 -0
  16. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-03-analisis-fuentes.md +308 -0
  17. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-04-elicitacion.md +332 -0
  18. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-05-generacion-espanol.md +608 -0
  19. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-06-traduccion-ingles.md +607 -0
  20. package/bmad/bmm/workflows/5-documentation/create-user-guide/steps/step-07-validacion-guardado.md +549 -0
  21. package/bmad/bmm/workflows/5-documentation/create-user-guide/templates/user-guide-template-en.md +50 -0
  22. package/bmad/bmm/workflows/5-documentation/create-user-guide/templates/user-guide-template-es.md +50 -0
  23. package/bmad/bmm/workflows/5-documentation/create-user-guide/workflow-plan-create-user-guide.md +949 -0
  24. package/bmad/bmm/workflows/5-documentation/create-user-guide/workflow.md +61 -0
  25. package/bmad/bmm/workflows/sync-epics-stories/completion-summary-sync-epics-stories.md +43 -0
  26. package/bmad/bmm/workflows/sync-epics-stories/steps/step-01-init.md +150 -0
  27. package/bmad/bmm/workflows/sync-epics-stories/steps/step-01b-continue.md +79 -0
  28. package/bmad/bmm/workflows/sync-epics-stories/steps/step-02-setup.md +117 -0
  29. package/bmad/bmm/workflows/sync-epics-stories/steps/step-03-scope.md +70 -0
  30. package/bmad/bmm/workflows/sync-epics-stories/steps/step-04-epics.md +124 -0
  31. package/bmad/bmm/workflows/sync-epics-stories/steps/step-05-stories.md +189 -0
  32. package/bmad/bmm/workflows/sync-epics-stories/workflow-plan-sync-epics-stories.md +252 -0
  33. package/bmad/bmm/workflows/sync-epics-stories/workflow.md +54 -0
  34. package/claude/commands/bmad/bmm/workflows/create-user-guide.md +5 -0
  35. package/claude/commands/bmad/bmm/workflows/sync-epics-stories.md +5 -0
  36. package/gemini/commands/bmad-workflow-bmm-create-user-guide.toml +4 -0
  37. package/gemini/commands/bmad-workflow-bmm-sync-epics-stories.toml +4 -0
  38. package/package.json +1 -1
  39. /package/bmad/bmm/workflows/4-implementation/code-review/{instructions.xml → instructions.xml.bak} +0 -0
  40. /package/bmad/bmm/workflows/4-implementation/code-review/{workflow.yaml → workflow.yaml.bak} +0 -0
@@ -0,0 +1,61 @@
1
+ ---
2
+ name: create-user-guide
3
+ description: Genera guías de usuario comprehensivas en español e inglés desde épicas y PRDs, con diagramas Mermaid y trazabilidad completa
4
+ web_bundle: true
5
+ ---
6
+
7
+ # Create User Guide
8
+
9
+ **Goal:** Generar guías de usuario comprehensivas desde documentación existente (PRDs, épicas, stories) para diferentes audiencias (usuarios finales, administradores, consumidores de API). Producir guías en español e inglés con diagramas Mermaid, screenshot placeholders, trazabilidad a fuentes y estructura navegable.
10
+
11
+ **Your Role:** In addition to your name, communication_style, and persona, you are also a technical writer and documentation specialist (Marcus ✍️) collaborating with Product Managers, Technical Writers, and documentation teams. This is a partnership, not a client-vendor relationship. You bring expertise in documentation structure, technical writing, and user experience, while the user brings their domain knowledge and specific project requirements. Work together as equals.
12
+
13
+ ---
14
+
15
+ ## WORKFLOW ARCHITECTURE
16
+
17
+ This uses **step-file architecture** for disciplined execution:
18
+
19
+ ### Core Principles
20
+
21
+ - **Micro-file Design**: Each step is a self contained instruction file that is a part of an overall workflow that must be followed exactly
22
+ - **Just-In-Time Loading**: Only the current step file is in memory - never load future step files until told to do so
23
+ - **Sequential Enforcement**: Sequence within the step files must be completed in order, no skipping or optimization allowed
24
+ - **State Tracking**: Document progress in output file frontmatter using `stepsCompleted` array when a workflow produces a document
25
+ - **Append-Only Building**: Build documents by appending content as directed to the output file
26
+
27
+ ### Step Processing Rules
28
+
29
+ 1. **READ COMPLETELY**: Always read the entire step file before taking any action
30
+ 2. **FOLLOW SEQUENCE**: Execute all numbered sections in order, never deviate
31
+ 3. **WAIT FOR INPUT**: If a menu is presented, halt and wait for user selection
32
+ 4. **CHECK CONTINUATION**: If the step has a menu with Continue as an option, only proceed to next step when user selects 'C' (Continue)
33
+ 5. **SAVE STATE**: Update `stepsCompleted` in frontmatter before loading next step
34
+ 6. **LOAD NEXT**: When directed, load, read entire file, then execute the next step file
35
+
36
+ ### Critical Rules (NO EXCEPTIONS)
37
+
38
+ - 🛑 **NEVER** load multiple step files simultaneously
39
+ - 📖 **ALWAYS** read entire step file before execution
40
+ - 🚫 **NEVER** skip steps or optimize the sequence
41
+ - 💾 **ALWAYS** update frontmatter of output files when writing the final output for a specific step
42
+ - 🎯 **ALWAYS** follow the exact instructions in the step file
43
+ - ⏸️ **ALWAYS** halt at menus and wait for user input
44
+ - 📋 **NEVER** create mental todo lists from future steps
45
+ - ✅ YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
46
+
47
+ ---
48
+
49
+ ## INITIALIZATION SEQUENCE
50
+
51
+ ### 1. Configuration Loading
52
+
53
+ Load and read full config from {project-root}/_bmad/bmm/config.yaml and resolve:
54
+
55
+ - `project_name`, `output_folder`, `user_name`, `communication_language`, `document_output_language`
56
+ - `planning_artifacts`, `implementation_artifacts`, `project_knowledge`
57
+ - ✅ YOU MUST ALWAYS SPEAK OUTPUT In your Agent communication style with the config `{communication_language}`
58
+
59
+ ### 2. First Step EXECUTION
60
+
61
+ Load, read the full file and then execute `{workflow_path}/steps/step-01-init.md` to begin the workflow.
@@ -0,0 +1,43 @@
1
+ ---
2
+ workflowName: sync-epics-stories
3
+ creationDate: 2026-01-13
4
+ module: bmm
5
+ status: COMPLETE
6
+ stepsCompleted: [1, 2, 3, 4, 5, 6, 7, 8, 9]
7
+ ---
8
+
9
+ # Workflow Creation Summary
10
+
11
+ ## Workflow Information
12
+
13
+ - **Name:** sync-epics-stories
14
+ - **Module:** bmm (Created via bmb-creations)
15
+ - **Created:** 2026-01-13
16
+ - **Location:** _bmad-output/bmb-creations/workflows/sync-epics-stories
17
+
18
+ ## Generated Files
19
+
20
+ - `workflow.md`
21
+ - `steps/step-01-init.md`
22
+ - `steps/step-01b-continue.md`
23
+ - `steps/step-02-setup.md`
24
+ - `steps/step-03-scope.md`
25
+ - `steps/step-04-epics.md`
26
+ - `steps/step-05-stories.md`
27
+
28
+ ## Quick Start Guide
29
+
30
+ **To run this workflow:**
31
+
32
+ 1. Ensure you have `mcp-atlassian` configured and authenticated.
33
+ 2. Ensure you have your artifacts ready at:
34
+ - `_bmad-output/planning-artifacts/epics.md`
35
+ - `_bmad-output/planning-artifacts/stories.md`
36
+ 3. Command an agent to run the workflow:
37
+ > "Execute the workflow at `_bmad-output/bmb-creations/workflows/sync-epics-stories/workflow.md`"
38
+
39
+ ## Next Steps
40
+
41
+ 1. **Run a Test:** Execute the workflow with a small set of epics/stories (or backups) first.
42
+ 2. **Verify Jira:** Check that issues are created correctly and linked.
43
+ 3. **Check Docs:** Verify that your local markdown files are updated with the Sync Status blocks.
@@ -0,0 +1,150 @@
1
+ ---
2
+ name: 'step-01-init'
3
+ description: 'Initialize the Jira synchronization workflow by detecting continuation state'
4
+
5
+ # Path Definitions
6
+ workflow_path: '{project-root}/_bmad/bmm/workflows/sync-epics-stories'
7
+
8
+ # File References
9
+ thisStepFile: '{workflow_path}/steps/step-01-init.md'
10
+ nextStepFile: '{workflow_path}/steps/step-02-setup.md'
11
+ workflowFile: '{workflow_path}/workflow.md'
12
+ outputFile: '{project-root}/_bmad-output/jira_docs/project_config.yaml' # Using config file as main state tracker
13
+ continueFile: '{workflow_path}/steps/step-01b-continue.md'
14
+ # Input Files
15
+ epicsFile: '{output_folder}/planning-artifacts/epics.md'
16
+ storiesFolder: '{output_folder}/implementation-artifacts/'
17
+
18
+ # Task References
19
+ advancedElicitationTask: '{project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml'
20
+ partyModeWorkflow: '{project-root}/_bmad/core/workflows/party-mode/workflow.md'
21
+
22
+ ---
23
+
24
+ # Step 1: Workflow Initialization
25
+
26
+ ## MANDATORY EXECUTION RULES (READ FIRST):
27
+
28
+ ### Universal Rules:
29
+
30
+ - 🛑 NEVER generate content without user input
31
+ - 📖 CRITICAL: Read the complete step file before taking any action
32
+ - 🔄 CRITICAL: When loading next step with 'C', ensure entire file is read
33
+ - 📋 YOU ARE A FACILITATOR, not a content generator
34
+
35
+ ### Role Reinforcement:
36
+
37
+ - ✅ You are a Jira Integration Specialist
38
+ - ✅ We engage in collaborative dialogue, not command-response
39
+ - ✅ You bring technical precision, user brings product requirements
40
+ - ✅ Maintain collaborative and precise tone throughout
41
+
42
+ ### Step-Specific Rules:
43
+
44
+ - 🎯 Focus ONLY on initialization and setup
45
+ - 🚫 FORBIDDEN to look ahead to future steps
46
+ - 💬 Handle initialization professionally
47
+ - 🚪 DETECT existing workflow state and handle continuation properly
48
+
49
+ ## EXECUTION PROTOCOLS:
50
+
51
+ - 🎯 Show analysis before taking any action
52
+ - 💾 Initialize document and update frontmatter
53
+ - 📖 Set up frontmatter `stepsCompleted: [1]` before loading next step
54
+ - 🚫 FORBIDDEN to load next step until setup is complete
55
+
56
+ ## CONTEXT BOUNDARIES:
57
+
58
+ - Variables from workflow.md are available in memory
59
+ - Previous context = what's in output document + frontmatter
60
+ - Don't assume knowledge from other steps
61
+
62
+ ## STEP GOAL:
63
+
64
+ To initialize the synchronization workflow by detecting continuation state, verifying input files, and preparing for setup.
65
+
66
+ ## INITIALIZATION SEQUENCE:
67
+
68
+ ### 1. Check for Existing Workflow State
69
+
70
+ First, check if the project configuration already exists:
71
+
72
+ - Look for file at `{outputFile}` (`_bmad-output/jira_docs/project_config.yaml`)
73
+ - If exists, read the complete file including any frontmatter or comments
74
+ - **Note:** This workflow tracks state in the config file or within the markdown files themselves. For this step, we check if we have a valid config to potentially resume.
75
+
76
+ ### 2. Handle Continuation (If Config Exists)
77
+
78
+ If the config file exists AND has frontmatter with `stepsCompleted`:
79
+
80
+ - **STOP here** and load `{continueFile}` immediately
81
+ - Do not proceed with any initialization tasks
82
+ - Let step-01b handle the continuation logic
83
+
84
+ ### 3. Fresh Workflow Setup
85
+
86
+ If no config exists or no `stepsCompleted`:
87
+
88
+ #### A. Input Document Discovery
89
+
90
+ This workflow requires existing artifacts:
91
+
92
+ - Check existence of `{epicsFile}`
93
+ - Check for Markdown files in `{storiesFolder}` (e.g., `*.md`)
94
+
95
+ If files are missing, WARN the user: "I cannot find `epics.md` or any story files in `implementation-artifacts/`. Please ensure artifacts exist before synchronizing."
96
+
97
+ #### B. Create Initial State (Virtual)
98
+
99
+ Since `project_config.yaml` is a strict YAML file, we might not want to pollute it with frontmatter if it's used by other tools.
100
+ **Decision:** We will manage `stepsCompleted` in a virtual state or append it as a comment block if supported, OR we treat the *first run* as creating the config in Step 2.
101
+
102
+ For this Initialization Step, if no config exists, we simply proceed to Step 2 to create it.
103
+
104
+ #### C. Show Welcome Message
105
+
106
+ "Welcome to the **Jira Synchronization Workflow**.
107
+
108
+ I am your Jira Integration Specialist. I will help you synchronize your Epics and Stories with Jira.
109
+
110
+ We will:
111
+ 1. Configure/Validate your Jira Connection.
112
+ 2. Select what to synchronize (Epics, Stories, or Both).
113
+ 3. Execute the synchronization with duplicate prevention."
114
+
115
+ ## ✅ SUCCESS METRICS:
116
+
117
+ - Input files verified
118
+ - User welcomed to the process
119
+ - Ready to proceed to step 2
120
+ - OR continuation properly routed to step-01b-continue.md
121
+
122
+ ### 4. Present MENU OPTIONS
123
+
124
+ Display: **Proceeding to Jira Setup...**
125
+
126
+ #### Menu Handling Logic:
127
+
128
+ - Immediately load, read entire file, then execute `{nextStepFile}` to begin setup.
129
+
130
+ ---
131
+
132
+ ## 🚨 SYSTEM SUCCESS/FAILURE METRICS
133
+
134
+ ### ✅ SUCCESS:
135
+
136
+ - Input files verified
137
+ - User welcomed
138
+ - Ready to proceed to step 2
139
+ - OR existing workflow routed to step-01b
140
+
141
+ ### ❌ SYSTEM FAILURE:
142
+
143
+ - Proceeding without checking input files
144
+ - Not routing to step-01b when appropriate
145
+
146
+ **Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
147
+
148
+ ## CRITICAL STEP COMPLETION NOTE
149
+
150
+ ONLY WHEN initialization setup is complete, will you then immediately load, read entire file, then execute `{nextStepFile}` to begin setup.
@@ -0,0 +1,79 @@
1
+ ---
2
+ name: 'step-01b-continue'
3
+ description: 'Handle workflow continuation from previous session'
4
+
5
+ # Path Definitions
6
+ workflow_path: '{project-root}/_bmad/bmm/workflows/sync-epics-stories'
7
+
8
+ # File References
9
+ thisStepFile: '{workflow_path}/steps/step-01b-continue.md'
10
+ outputFile: '{project-root}/_bmad-output/jira_docs/project_config.yaml'
11
+ workflowFile: '{workflow_path}/workflow.md'
12
+
13
+ # Task References
14
+ advancedElicitationTask: '{project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml'
15
+ partyModeWorkflow: '{project-root}/_bmad/core/workflows/party-mode/workflow.md'
16
+
17
+ # Step 1B: Workflow Continuation
18
+
19
+ ## STEP GOAL:
20
+
21
+ To resume the synchronization workflow from where it was left off, ensuring smooth continuation without loss of context.
22
+
23
+ ## MANDATORY EXECUTION RULES (READ FIRST):
24
+
25
+ ### Universal Rules:
26
+
27
+ - 🛑 NEVER generate content without user input
28
+ - 📖 CRITICAL: Read the complete step file before taking any action
29
+ - 🔄 CRITICAL: When loading next step with 'C', ensure entire file is read
30
+ - 📋 YOU ARE A FACILITATOR, not a content generator
31
+
32
+ ### Step-Specific Rules:
33
+
34
+ - 🎯 Focus ONLY on analyzing and resuming workflow state
35
+ - 🚫 FORBIDDEN to modify content completed in previous steps
36
+ - 🚪 DETECT exact continuation point from `stepsCompleted`
37
+
38
+ ## CONTINUATION SEQUENCE:
39
+
40
+ ### 1. Analyze Current State
41
+
42
+ Review the `stepsCompleted` in `{outputFile}` (if available) or ask the user.
43
+
44
+ - **stepsCompleted: [1, 2]** -> Completed Setup. Next: Scope Selection (Step 3).
45
+ - **stepsCompleted: [1, 2, 3]** -> Scope Selected. Next: Execution (Step 4 or 5 depending on scope, but usually Step 3 loops to menu).
46
+ - **stepsCompleted: [1, 2, 3, 4]** -> Epics synced. Next: Stories (Step 5) or Finish.
47
+
48
+ ### 2. Determine Next Step
49
+
50
+ Based on analysis:
51
+ - If Setup (2) done -> Go to Step 3 (Scope).
52
+ - If Epics (4) done -> Go to Step 3 (Scope) or Step 5 (Stories) if previously selected "Both".
53
+
54
+ ### 3. Welcome Back Dialog
55
+
56
+ "Welcome back! We have an existing configuration.
57
+ Last completed step: [Analyze last step].
58
+
59
+ Ready to continue?"
60
+
61
+ ### 4. Present MENU OPTIONS
62
+
63
+ Display: "**Resuming - Select an Option:** [C] Continue"
64
+
65
+ #### Menu Handling Logic:
66
+
67
+ - IF C: Load, read entire file, then execute the determined next step file.
68
+
69
+ ---
70
+
71
+ ## 🚨 SYSTEM SUCCESS/FAILURE METRICS
72
+
73
+ ### ✅ SUCCESS:
74
+
75
+ - Correctly identified last completed step
76
+ - User confirmed readiness
77
+ - Workflow resumed at appropriate next step
78
+
79
+ **Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
@@ -0,0 +1,117 @@
1
+ ---
2
+ name: 'step-02-setup'
3
+ description: 'Configure and validate Jira integration'
4
+
5
+ # Path Definitions
6
+ workflow_path: '{project-root}/_bmad/bmm/workflows/sync-epics-stories'
7
+
8
+ # File References
9
+ thisStepFile: '{workflow_path}/steps/step-02-setup.md'
10
+ nextStepFile: '{workflow_path}/steps/step-03-scope.md'
11
+ outputFile: '{project-root}/_bmad-output/jira_docs/project_config.yaml'
12
+
13
+ # Task References
14
+ advancedElicitationTask: '{project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml'
15
+ partyModeWorkflow: '{project-root}/_bmad/core/workflows/party-mode/workflow.md'
16
+
17
+ ---
18
+
19
+ # Step 2: Jira Configuration & Setup
20
+
21
+ ## STEP GOAL:
22
+
23
+ To configure the Jira integration by authenticating via MCP, validating project access, and saving the configuration file.
24
+
25
+ ## MANDATORY EXECUTION RULES:
26
+
27
+ - 🛑 NEVER generate content without user input
28
+ - 📖 CRITICAL: Read the complete step file before taking any action
29
+ - 📋 YOU ARE A JIRA INTEGRATION SPECIALIST
30
+ - 🔒 **STRICT MCP ONLY:** You must ONLY use the provided MCP tools. NO curl, NO fetch, NO custom API calls.
31
+
32
+ ## EXECUTION SEQUENCE:
33
+
34
+ ### 1. 🔒 PRE-FLIGHT CHECK: MCP Authentication
35
+
36
+ **CRITICAL FIRST STEP:** Before reading any files or configurations, verify we can talk to Jira.
37
+
38
+ **Action:** Execute MCP Tool `getAccessibleAtlassianResources`.
39
+
40
+ - **FAILURE CONDITION:** If the tool fails, returns an error, or returns an empty list `[]`.
41
+ - **STOP IMMEDIATELY.**
42
+ - **Display Error:** "❌ **MCP Authentication Failed.** I cannot connect to Jira. Please ensure you are authenticated with the Atlassian MCP server."
43
+ - **Instruction:** "Run the following command to authenticate (copy and paste into your terminal/chat):"
44
+ - **Display:**
45
+ ```bash
46
+ /mcp auth mcp-atlassian
47
+ ```
48
+ - **Display Info:**
49
+ ```text
50
+ ℹ Note: Authentication requires completing an OAuth flow in your web browser.
51
+ Follow the on-screen instructions provided by the CLI after running the command.
52
+ ```
53
+ - **Instruction:** "After validating in the browser, please choose an option:"
54
+ - **Menu:**
55
+ - **[R] Retry Authentication:** Re-run the check (`getAccessibleAtlassianResources`).
56
+ - **[E] Exit:** Stop the workflow.
57
+ - **Logic:**
58
+ - **IF R:** Restart this Step 2 from the beginning.
59
+ - **IF E:** Terminate the workflow with a message: "Workflow aborted due to authentication failure."
60
+ - **DO NOT PROCEED** past this point without successful authentication.
61
+
62
+ - **SUCCESS CONDITION:** If the tool returns a valid list of resources.
63
+ - Proceed to Section 2.
64
+
65
+ ### 2. Check Existing Configuration
66
+
67
+ Check if `{outputFile}` exists.
68
+ - If YES: Read and Display current settings (Project Key, Cloud ID). Ask: "Do you want to use this configuration? [Y/N]"
69
+ - If NO: Proceed to setup.
70
+
71
+ ### 3. Elicit Project Key
72
+
73
+ If not already known (from config), ask: "Please enter your Jira Project Key (e.g., PROJ, SCRUM):"
74
+
75
+ ### 4. Validate Project Access
76
+
77
+ **Action:** Execute MCP Tool `getVisibleJiraProjects` with `cloudId` and search for `projectKey`.
78
+
79
+ - **Success:** Confirm Project Name and Key match.
80
+ - **Failure:** Stop and ask user to check permissions or key.
81
+
82
+ ### 5. Save Configuration
83
+
84
+ Create/Update `{outputFile}` with:
85
+
86
+ ```yaml
87
+ project_key: "{{project_key}}"
88
+ project_name: "{{project_name}}"
89
+ cloud_id: "{{cloud_id}}"
90
+ jira_url: "https://siesa-team.atlassian.net"
91
+ # stepsCompleted: [1, 2] # (Optional tracking)
92
+ ```
93
+
94
+ ### 6. Present MENU OPTIONS
95
+
96
+ Display: "**Configuration Complete - Select an Option:** [C] Continue to Scope Selection"
97
+
98
+ #### Menu Handling Logic:
99
+
100
+ - IF C: Save content to `{outputFile}`, load, read entire file, then execute `{nextStepFile}`.
101
+
102
+ ---
103
+
104
+ ## 🚨 SYSTEM SUCCESS/FAILURE METRICS
105
+
106
+ ### ✅ SUCCESS:
107
+
108
+ - Valid `project_config.yaml` created
109
+ - Access verified via MCP
110
+ - User confirmed configuration
111
+
112
+ ### ❌ SYSTEM FAILURE:
113
+
114
+ - Creating config with invalid credentials
115
+ - Skipping MCP validation
116
+
117
+ **Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
@@ -0,0 +1,70 @@
1
+ ---
2
+ name: 'step-03-scope'
3
+ description: 'Select synchronization scope (Epics, Stories, or Both)'
4
+
5
+ # Path Definitions
6
+ workflow_path: '{project-root}/_bmad/bmm/workflows/sync-epics-stories'
7
+
8
+ # File References
9
+ thisStepFile: '{workflow_path}/steps/step-03-scope.md'
10
+ stepEpics: '{workflow_path}/steps/step-04-epics.md'
11
+ stepStories: '{workflow_path}/steps/step-05-stories.md'
12
+ outputFile: '{project-root}/_bmad-output/jira_docs/project_config.yaml'
13
+ workflowFile: '{workflow_path}/workflow.md'
14
+
15
+ # Task References
16
+ advancedElicitationTask: '{project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml'
17
+ partyModeWorkflow: '{project-root}/_bmad/core/workflows/party-mode/workflow.md'
18
+
19
+ ---
20
+
21
+ # Step 3: Scope Selection
22
+
23
+ ## STEP GOAL:
24
+
25
+ To determine the scope of synchronization: Epics, Stories, or Both.
26
+
27
+ ## MANDATORY EXECUTION RULES:
28
+
29
+ - 🛑 **STOP AND WAIT:** You MUST halt execution at the menu options. Do NOT proceed until the user explicitly selects an option.
30
+ - 🛑 **NO AUTO-PILOT:** Even if you "think" you know what the user wants based on available files, you MUST ask.
31
+ - 📖 **READ FIRST:** Read the complete step file before taking any action.
32
+
33
+ ## EXECUTION SEQUENCE:
34
+
35
+ ### 1. Present Options
36
+
37
+ "**Select Synchronization Scope:**
38
+
39
+ 1. **Epics Only** (Syncs `epics.md` -> Jira Epics)
40
+ 2. **Stories & Tasks** (Syncs `stories.md` -> Jira Stories & Sub-tasks, requires Parent Epics to exist)
41
+ 3. **Both** (Syncs Epics first, then Stories & Tasks)"
42
+
43
+ ### 2. Handle Selection
44
+
45
+ **Logic:**
46
+
47
+ - **Option 1 (Epics):** Load `{stepEpics}`. Set next step after Epics to "Finish".
48
+ - **Option 2 (Stories):** Load `{stepStories}`.
49
+ - **Option 3 (Both):** Load `{stepEpics}`. Set next step after Epics to `{stepStories}` (Chain).
50
+
51
+ ### 3. Present MENU OPTIONS
52
+
53
+ Display: "**Select Scope:** [1] Epics [2] Stories & Tasks [3] Both"
54
+
55
+ #### Menu Handling Logic:
56
+
57
+ - IF 1: Update frontmatter `target_scope: epics`, load `{stepEpics}`.
58
+ - IF 2: Update frontmatter `target_scope: stories`, load `{stepStories}`.
59
+ - IF 3: Update frontmatter `target_scope: both`, load `{stepEpics}` (and pass flag to chain next step).
60
+
61
+ ---
62
+
63
+ ## 🚨 SYSTEM SUCCESS/FAILURE METRICS
64
+
65
+ ### ✅ SUCCESS:
66
+
67
+ - User selection captured
68
+ - Correct next step loaded
69
+
70
+ **Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.
@@ -0,0 +1,124 @@
1
+ ---
2
+ name: 'step-04-epics'
3
+ description: 'Synchronize Epics from markdown to Jira'
4
+
5
+ # Path Definitions
6
+ workflow_path: '{project-root}/_bmad/bmm/workflows/sync-epics-stories'
7
+
8
+ # File References
9
+ thisStepFile: '{workflow_path}/steps/step-04-epics.md'
10
+ nextStepStories: '{workflow_path}/steps/step-05-stories.md'
11
+ epicsFile: '{output_folder}/planning-artifacts/epics.md'
12
+ configFile: '{project-root}/_bmad-output/jira_docs/project_config.yaml'
13
+ workflowFile: '{workflow_path}/workflow.md'
14
+
15
+ # Task References
16
+ advancedElicitationTask: '{project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml'
17
+ partyModeWorkflow: '{project-root}/_bmad/core/workflows/party-mode/workflow.md'
18
+
19
+ ---
20
+
21
+ # Step 4: Epic Synchronization
22
+
23
+ ## STEP GOAL:
24
+
25
+ To read `epics.md`, check for existing Epics in Jira, create missing ones, and update the markdown file with synchronization status.
26
+
27
+ ## MANDATORY EXECUTION RULES:
28
+
29
+ - 🛑 NEVER generate content without user input
30
+ - 📖 CRITICAL: Read the complete step file before taking any action
31
+ - 🔒 **STRICT MCP ONLY:** You must ONLY use the provided MCP tools (`searchJiraIssuesUsingJql`, `createJiraIssue`).
32
+ - ⛔ **FORBIDDEN:** Do NOT use `fetch`, `curl`, or raw HTTP requests.
33
+
34
+ ## EXECUTION SEQUENCE:
35
+
36
+ ### 1. Load Data
37
+
38
+ - Read `{configFile}` to get `project_key` and `cloud_id`.
39
+ - Read `{epicsFile}`.
40
+
41
+ ### 2. Iterate and Sync
42
+
43
+ For each Epic in the file:
44
+
45
+ 1. **Local Idempotency Check (CRITICAL):**
46
+ - Check if the Epic Title in the markdown ALREADY contains a Jira Key (e.g., `[PROJ-123]`).
47
+ - If found: **SKIP creation**. Log Key.
48
+ - If not found: Proceed to JQL check.
49
+
50
+ 2. **Remote Idempotency Check:**
51
+ - Execute `searchJiraIssuesUsingJql`: `project = KEY AND issuetype = Epic AND summary ~ "Epic Name"`
52
+ - If found: **SKIP creation**. Log Key. Update markdown with found key.
53
+ - If not found: **PROCEED**.
54
+
55
+ 3. **Creation (Atomic Transaction):**
56
+
57
+ - Execute `createJiraIssue` using the following REFERENCE TEMPLATE:
58
+
59
+ - ⚠️ **CRITICAL CONSTRAINT:** `issueTypeName` MUST be exactly `"Epic"`. DO NOT translate to "Épica" or any other language. The API requires the English identifier.
60
+
61
+
62
+
63
+ ```json
64
+
65
+ {
66
+
67
+ "provider": "jira",
68
+
69
+ "issueTypeName": "Epic",
70
+
71
+ "summary": "[Epic] {{Epic Name}}",
72
+
73
+
74
+ "description": "## Epic Goal\n{{goal}}\n\n## Details\n{{description}}\n\n---\n*Source: {{file_path}}*",
75
+ "projectKey": "{{project_key}}",
76
+ "additional_fields": {
77
+ "priority": { "name": "Medium" },
78
+ "labels": ["prd-sync", "automated", "epic-file-sync", "{{epic-slug}}"],
79
+ "customfield_10011": "{{Epic Name}}"
80
+ }
81
+ }
82
+ ```
83
+
84
+ 4. **Immediate File Persistence (CRITICAL):**
85
+ - **IMMEDIATELY** after obtaining the new `key` (or finding an existing one):
86
+ - Update `{epicsFile}` **RIGHT NOW**. Do not wait for the loop to finish.
87
+ - **Action:**
88
+ 1. Append/Update the `[Key]` to the Epic Header in the file.
89
+ 2. Append a "Jira Information" block at the end of the Epic section:
90
+ ```markdown
91
+ > **Jira Sync:** [{{KEY}}]({{jira_url}}/browse/{{KEY}}) | Status: Synced
92
+ ```
93
+ - *Why?* This ensures that if the process fails at Epic #5, Epics #1-4 are safely saved.
94
+
95
+ ### 3. Report Results
96
+
97
+ Display summary: "Created: X, Skipped: Y, Failed: Z".
98
+
99
+ ### 4. Determine Next Step
100
+
101
+ - If `target_scope` was "Both", proceed to Stories.
102
+ - Else, Finish.
103
+
104
+ ### 5. Present MENU OPTIONS
105
+
106
+ Display: "**Epics Synced - Select an Option:** [C] Continue"
107
+
108
+ #### Menu Handling Logic:
109
+
110
+ - IF C:
111
+ - If scope == both: Load `{nextStepStories}`.
112
+ - Else: Display "Workflow Complete" and exit.
113
+
114
+ ---
115
+
116
+ ## 🚨 SYSTEM SUCCESS/FAILURE METRICS
117
+
118
+ ### ✅ SUCCESS:
119
+
120
+ - All epics processed
121
+ - No duplicates created
122
+ - `epics.md` updated with IDs
123
+
124
+ **Master Rule:** Skipping steps, optimizing sequences, or not following exact instructions is FORBIDDEN and constitutes SYSTEM FAILURE.