Initial commit of the L'Ami Fiduciaire SaaS platform built on Laravel 12, Vue 3, Inertia.js 2, and Tailwind CSS 4. Story 0.1 (rename folders to declarations in database) is implemented and code-reviewed: migration, rollback, and 6 Pest tests all passing. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
8.8 KiB
name, description, nextStepFile, agentPlan, agentBuildOutput, agentYamlOutput, agentYamlOutputNoSidecar, sidecarOutput, agentTemplate, agentArch, agentCompilation, criticalActions, noSidecarExample, withSidecarExample, advancedElicitationTask, partyModeWorkflow
| name | description | nextStepFile | agentPlan | agentBuildOutput | agentYamlOutput | agentYamlOutputNoSidecar | sidecarOutput | agentTemplate | agentArch | agentCompilation | criticalActions | noSidecarExample | withSidecarExample | advancedElicitationTask | partyModeWorkflow |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| step-07-build-agent | Generate agent YAML from plan (with or without sidecar) | ./step-08-celebrate.md | {bmb_creations_output_folder}/agent-plan-{agent_name}.md | {bmb_creations_output_folder}/{agent-name}/ | {bmb_creations_output_folder}/{agent-name}/{agent-name}.agent.yaml | {bmb_creations_output_folder}/{agent-name}.agent.yaml | {bmb_creations_output_folder}/{agent-name}/{agent-name}-sidecar/ | ../templates/agent-template.md | ../data/agent-architecture.md | ../data/agent-compilation.md | ../data/critical-actions.md | ../data/reference/without-sidecar/commit-poet.agent.yaml | ../data/reference/with-sidecar/journal-keeper/journal-keeper.agent.yaml | {project-root}/_bmad/core/workflows/advanced-elicitation/workflow.xml | {project-root}/_bmad/core/workflows/party-mode/workflow.md |
STEP GOAL
Assemble the agent plan content into a complete agent YAML file. The build approach (with or without sidecar) is determined by the hasSidecar decision made in Step 3.
MANDATORY EXECUTION RULES
- DETERMINE BUILD APPROACH FIRST: Check
hasSidecarfrom agentPlan before starting - TEMPLATE COMPLIANCE: Follow agent-template.md structure exactly
- YAML VALIDATION: Ensure valid YAML syntax with proper indentation (2-space)
- EXISTING CHECK: If output file exists, ask user before overwriting
- NO DRIFT: Use ONLY content from agentPlan - no additions or interpretations
- SIDECAR REQUIREMENT: If hasSidecar=true, MUST create sidecar folder structure
EXECUTION PROTOCOLS
Phase 1: Load Architecture and Templates
- Read
agentTemplate- defines YAML structure for agents - Read
agentArch- architecture requirements for agents - Read
agentCompilation- assembly rules for YAML generation - Read
criticalActions- validation requirements for critical_actions
Phase 2: Load Agent Plan
- Read
agentPlancontaining all collected content from Steps 2-5 - Verify plan contains:
- hasSidecar decision (true/false)
- Persona content
- Commands structure
- All metadata fields
- Activation decisions (critical_actions)
Phase 3: Determine Build Approach
Check hasSidecar from plan:
hasSidecar: false
→ Build: Agent WITHOUT sidecar
→ Output: Single YAML file at {agentYamlOutputNoSidecar}
→ Structure: Everything in one file (~250 lines max)
hasSidecar: true
→ Build: Agent WITH sidecar
→ Output: YAML + sidecar folder structure
→ Structure: YAML file + {agent-name}-sidecar/ folder
Inform user of build approach:
"Building: Agent {WITH|WITHOUT} sidecar
hasSidecar: {true/false}
Output: {output path description}"
Phase 4: Assemble Agent YAML
For Agents WITHOUT Sidecar (hasSidecar: false)
Structure:
name: '{agent-name}'
description: '{short-description}'
author:
name: '{author}'
created: '{date}'
persona: |
{multi-line persona content from plan}
system-context: |
{expanded context from plan}
capabilities:
- {capability from plan}
- {capability from plan}
# ... all capabilities
commands:
- name: '{command-name}'
description: '{what command does}'
trigger: '{menu trigger}'
steps:
- {step 1}
- {step 2}
# ... all commands from plan
configuration:
temperature: {temperature}
max-tokens: {max-tokens}
response-format: {format}
# ... other configuration from plan
metadata:
hasSidecar: false
agent-type: 'agent'
Output: Single YAML file at {agentYamlOutputNoSidecar}
For Agents WITH Sidecar (hasSidecar: true)
Structure:
name: '{agent-name}'
description: '{short-description}'
author:
name: '{author}'
created: '{date}'
persona: |
{multi-line persona content from plan}
system-context: |
{expanded context from plan}
capabilities:
- {capability from plan}
- {capability from plan}
# ... all capabilities
critical-actions:
- name: '{action-name}'
description: '{what it does}'
invocation: '{when/how to invoke}'
implementation: |
{multi-line implementation}
output: '{expected-output}'
sidecar-folder: '{sidecar-folder-name}'
sidecar-files:
- '{project-root}/_bmad/_memory/{sidecar-folder}/{file1}.md'
- '{project-root}/_bmad/_memory/{sidecar-folder}/{file2}.md'
# ... all critical actions referencing sidecar structure
commands:
- name: '{command-name}'
description: '{what command does}'
trigger: '{menu trigger}'
steps:
- {step 1}
- {step 2}
# ... all commands from plan
configuration:
temperature: {temperature}
max-tokens: {max-tokens}
response-format: {format}
# ... other configuration from plan
metadata:
sidecar-folder: '{sidecar-folder-name}'
sidecar-path: '{project-root}/_bmad/_memory/{sidecar-folder}/'
hasSidecar: true
agent-type: 'agent'
memory-type: 'persistent'
Output: YAML file at {agentYamlOutput} + sidecar folder structure
Phase 5: Create Sidecar Structure (IF hasSidecar: true)
Skip this phase if hasSidecar: false
-
Create Sidecar Directory:
mkdir -p {sidecarOutput} -
Create Starter Files (if specified in critical_actions):
touch {sidecarOutput}/memories.md touch {sidecarOutput}/instructions.md # ... additional files from critical_actions -
Add README to Sidecar:
# {sidecar-folder} Sidecar This folder stores persistent memory for the **{agent-name}** agent. ## Purpose {purpose from critical_actions} ## Files - memories.md: User profile, session history, patterns - instructions.md: Protocols, boundaries, startup behavior - {additional files} ## Runtime Access After BMAD installation, this folder will be accessible at: `{project-root}/_bmad/_memory/{sidecar-folder}/{filename}.md`
Phase 6: Write Agent YAML
If hasSidecar: false:
- Write YAML to
{agentYamlOutputNoSidecar} - Confirm write success
- Display file location to user
If hasSidecar: true:
- Create directory:
mkdir -p {agentBuildOutput} - Write YAML to
{agentYamlOutput} - Confirm write success
- Display file location to user
Phase 7: Present MENU OPTIONS
Display: "Select an Option: [A] Advanced Elicitation [P] Party Mode [C] Continue"
Menu Handling Logic:
- IF A: Execute {advancedElicitationTask}, and when finished redisplay the menu
- IF P: Execute {partyModeWorkflow}, and when finished redisplay the menu
- IF C: Write agent YAML to appropriate output path (with or without sidecar), update frontmatter, then only then load, read entire file, then execute {nextStepFile}
- IF Any other comments or queries: help user respond then Redisplay Menu Options
EXECUTION RULES:
- ALWAYS halt and wait for user input after presenting menu
- ONLY proceed to next step when user selects 'C'
- After other menu items execution, return to this menu
- User can chat or ask questions - always respond and then end with display again of the menu options
CONTEXT BOUNDARIES
INCLUDE:
- Template structure exactly as provided
- All agent metadata from agentPlan
- Persona, commands, and rules from plan
- Configuration options specified
- Sidecar structure if hasSidecar: true
EXCLUDE:
- Any content not in agentPlan
- Sidecar references if hasSidecar: false
- Template placeholders (replace with actual content)
- Comments or notes in final YAML
CRITICAL STEP COMPLETION NOTE
ONLY WHEN [C continue option] is selected and [complete YAML generated and written to output], will you then load and read fully {nextStepFile} to execute and celebrate completion.
This step produces:
- If hasSidecar: false: Single agent YAML file
- If hasSidecar: true: Agent YAML file + sidecar folder structure
Both must exist (if applicable) before proceeding to validation.
SUCCESS METRICS
✅ SUCCESS looks like:
- Agent YAML file exists at specified output path
- YAML is syntactically valid and well-formed
- All template fields populated with plan content
- Structure matches agent architecture
- If hasSidecar: true, sidecar folder created with starter files
- User has selected continue to proceed
❌ FAILURE looks like:
- Template or architecture files not found
- Agent plan missing required sections
- YAML syntax errors in output
- Content not properly mapped to template
- File write operation fails
- hasSidecar: true but sidecar folder not created
TRANSITION CRITERIA
Ready for Step 8 when:
- Agent YAML successfully created (with or without sidecar as specified)
- User selects continue
- All build artifacts confirmed written