Skip to main content

brainstorm-with-file

Interactive brainstorming with documented thought evolution, multi-perspective analysis, and iterative refinement. Serial execution with no agent delegation.

Source facts

Repository
catlog22/Claude-Code-Workflow
Last source activity
April 16, 2026 at 07:20
Detected SKILL.md language
English
Stars
2,128
Forks
166

Install options

The review-first prompt is selected by default. You can switch to a direct command or download a local copy.

Review the source files

Read SKILL.md and any companion files shown by SkillsMP before deciding whether to install.

Showing SKILL.md

SKILL.md
Source instructions ยท Read-only preview
name
brainstorm-with-file
description
Interactive brainstorming with documented thought evolution, multi-perspective analysis, and iterative refinement. Serial execution with no agent delegation.
argument-hint
TOPIC="<idea or topic>" [--perspectives=creative,pragmatic,systematic] [--max-ideas=<n>]
# Codex Brainstorm-With-File Prompt ## Overview Interactive brainstorming workflow with **documented thought evolution**. Expands initial ideas through questioning, inline multi-perspective analysis, external research, and iterative refinement. **Core workflow**: Seed Idea โ†’ Expand โ†’ Multi-Perspective Explore โ†’ Research โ†’ Refine โ†’ Crystallize โ†’ Next Step **Key features**: - **brainstorm.md**: Complete thought evolution timeline - **Multi-perspective analysis**: Creative + Pragmatic + Systematic (serial, inline) - **External research**: Web search for inspiration, patterns, and best practices via `web.run` - **Idea expansion**: Progressive questioning and exploration - **Diverge-Converge cycles**: Generate options then focus on best paths - **Progress tracking**: `functions.update_plan` for real-time phase progress visibility - **Structured handoff**: Terminal gate with execution planning, issue creation, or completion ## Auto Mode When `--yes` or `-y`: Auto-confirm exploration decisions, use recommended perspectives, skip interactive scoping. ## Quick Start ```bash # Basic usage /codex:brainstorm-with-file TOPIC="How to improve developer onboarding experience" # With perspective selection /codex:brainstorm-with-file TOPIC="New caching strategy" --perspectives=creative,pragmatic,systematic # Continue existing session /codex:brainstorm-with-file TOPIC="caching strategy" --continue # Auto mode (skip confirmations) /codex:brainstorm-with-file -y TOPIC="Plugin architecture ideas" ``` ## Target Topic **$TOPIC** ## Configuration | Flag | Default | Description | |------|---------|-------------| | `-y, --yes` | false | Auto-confirm all decisions | | `--continue` | false | Continue existing session | | `--perspectives` | creative,pragmatic,systematic | Comma-separated perspective list | | `--max-ideas` | 15 | Maximum ideas to track | **Session ID format**: `BS-{YYYY-MM-DD}-{slug}` - slug: lowercase, alphanumeric + CJK characters, max 40 chars - date: YYYY-MM-DD (UTC+8) - Auto-detect continue: session folder + brainstorm.md exists โ†’ continue mode ## Brainstorm Flow ``` Step 0: Session Setup โ”œโ”€ Parse topic, flags (--perspectives, --continue, -y) โ”œโ”€ Generate session ID: BS-{date}-{slug} โ”œโ”€ Create session folder (or detect existing โ†’ continue mode) โ””โ”€ functions.update_plan (5 phases: Seed โ†’ Explore โ†’ Refine โ†’ Converge โ†’ GATE) Step 1: Seed Understanding โ”œโ”€ Parse topic, identify brainstorm dimensions โ”œโ”€ Role/perspective selection with user (or auto) โ”œโ”€ Initial scoping via functions.request_user_input (mode, focus, constraints) โ”œโ”€ Expand seed into exploration vectors โ””โ”€ Initialize brainstorm.md Step 2: Divergent Exploration (Inline, No Agents) โ”œโ”€ Detect codebase โ†’ search relevant modules, patterns โ”‚ โ”œโ”€ Run `ccw spec load --category exploration` (if spec system available) โ”‚ โ””โ”€ Use Grep, Glob, Read, mcp__ace-tool__search_context โ”œโ”€ Multi-perspective analysis (serial, inline) โ”‚ โ”œโ”€ Creative perspective: innovation, cross-domain, challenge assumptions โ”‚ โ”œโ”€ Pragmatic perspective: feasibility, effort, blockers โ”‚ โ””โ”€ Systematic perspective: decomposition, patterns, scalability โ”œโ”€ External research via web.run (optional โ€” patterns, best practices, inspiration) โ”œโ”€ Aggregate findings โ†’ perspectives.json + research.json โ”œโ”€ Update brainstorm.md with Round 1 โ””โ”€ Initial Idea Coverage Check Step 3: Interactive Refinement (Multi-Round, max 6) โ”œโ”€ Present current ideas and perspectives (Cumulative Context) โ”œโ”€ Record findings to brainstorm.md BEFORE updating Current Ideas โ”œโ”€ Gather user feedback via functions.request_user_input โ”œโ”€ Process response: โ”‚ โ”œโ”€ Deep Dive โ†’ deeper inline analysis on selected ideas โ”‚ โ”œโ”€ Diverge โ†’ new inline analysis with different angles โ”‚ โ”œโ”€ Challenge โ†’ devil's advocate inline analysis โ”‚ โ”œโ”€ Merge โ†’ synthesize complementary ideas inline โ”‚ โ”œโ”€ ๅค–้ƒจ็ ”็ฉถ โ†’ web.run for external inspiration/validation โ”‚ โ””โ”€ Converge โ†’ exit loop for synthesis โ”œโ”€ Update brainstorm.md with round details โ””โ”€ Repeat until user selects converge or max rounds Step 4: Convergence & Crystallization โ”œโ”€ Consolidate all insights โ†’ synthesis.json โ”œโ”€ Update brainstorm.md with final synthesis โ”œโ”€ Batch top-idea review via functions.request_user_input โ””โ”€ MANDATORY Terminal Gate: ๆ‰ง่กŒไปปๅŠก / ไบงๅ‡บIssue / ๅฎŒๆˆ โ”œโ”€ Execute Task โ†’ handoff-spec.json with implementation scope โ”œโ”€ Create Issue โ†’ display issue creation command โ””โ”€ Done โ†’ end workflow ``` ## Output Artifacts ### Phase 1: Seed Understanding | Artifact | Purpose | |----------|---------| | `brainstorm.md` | Initialized with session metadata, seed expansion, and exploration vectors | | Session variables | Topic slug, brainstorm mode, dimensions, exploration vectors | ### Phase 2: Divergent Exploration | Artifact | Purpose | |----------|---------| | `exploration-codebase.json` | Codebase context: relevant files, patterns, architecture constraints | | `perspectives/*.json` | Individual perspective outputs (creative, pragmatic, systematic) | | `perspectives.json` | Aggregated findings with synthesis (convergent/conflicting themes) | | Updated `brainstorm.md` | Round 1: Exploration results and multi-perspective analysis | ### Phase 3: Interactive Refinement | Artifact | Purpose | |----------|---------| | `ideas/{idea-slug}.md` | Deep-dive analysis for selected ideas | | `ideas/merged-idea-{n}.md` | Merged idea documents | | Updated `brainstorm.md` | Round 2-6: User feedback, idea selections, refinement cycles | ### Phase 4: Convergence & Crystallization | Artifact | Purpose | |----------|---------| | `synthesis.json` | Final synthesis: top ideas, recommendations, insights | | Final `brainstorm.md` | Complete thought evolution with conclusions | --- ## Recording Protocol **CRITICAL**: During brainstorming, the following situations **MUST** trigger immediate recording to brainstorm.md: | Trigger | What to Record | Target Section | |---------|---------------|----------------| | **Idea generated** | Idea content, source perspective, novelty/feasibility ratings | `#### Ideas Generated` | | **Perspective shift** | Old framing โ†’ new framing, trigger reason | `#### Decision Log` | | **User feedback** | User's original input, which ideas selected/rejected | `#### User Input` | | **Assumption challenged** | Original assumption โ†’ challenge result, survivability | `#### Challenged Assumptions` | | **Ideas merged** | Source ideas, merged concept, what was preserved/discarded | `#### Decision Log` | | **Scope adjustment** | Before/after scope, trigger reason | `#### Decision Log` | ### Decision Record Format ```markdown > **Decision**: [Description of the decision] > - **Context**: [What triggered this decision] > - **Options considered**: [Alternatives evaluated] > - **Chosen**: [Selected approach] โ€” **Reason**: [Rationale] > - **Rejected**: [Why other options were discarded] > - **Impact**: [Effect on brainstorming direction] ``` ### Narrative Synthesis Format Append after each round update: ```markdown ### Round N: Narrative Synthesis **Starting point**: Based on previous round's [conclusions/questions], this round explored [starting point]. **Key progress**: [New ideas/findings] [confirmed/refuted/expanded] previous understanding of [topic area]. **Decision impact**: User selected [feedback type], directing brainstorming toward [adjusted/deepened/maintained]. **Current state**: After this round, top ideas are [updated idea rankings]. **Open directions**: [remaining exploration angles for next round] ``` ## Implementation Details ### Phase 0: Session Initialization ```javascript const getUtc8ISOString = () => new Date(Date.now() + 8 * 60 * 60 * 1000).toISOString() // Parse flags const autoYes = $ARGUMENTS.includes('--yes') || $ARGUMENTS.includes('-y') const continueMode = $ARGUMENTS.includes('--continue') const perspectivesMatch = $ARGUMENTS.match(/--perspectives[=\s]([\w,]+)/) const selectedPerspectiveNames = perspectivesMatch ? perspectivesMatch[1].split(',') : ['creative', 'pragmatic', 'systematic'] // Extract topic const topic = $ARGUMENTS.replace(/--yes|-y|--continue|--perspectives[=\s][\w,]+|--max-ideas[=\s]\d+|TOPIC=/g, '').replace(/^["']|["']$/g, '').trim() // Determine project root const projectRoot = functions.exec_command('git rev-parse --show-toplevel 2>/dev/null || pwd').trim() const slug = topic.toLowerCase().replace(/[^a-z0-9\u4e00-\u9fa5]+/g, '-').substring(0, 40) const dateStr = getUtc8ISOString().substring(0, 10) const sessionId = `BS-${dateStr}-${slug}` const sessionFolder = `${projectRoot}/.workflow/.brainstorm/${sessionId}` // Auto-detect continue: session folder + brainstorm.md exists โ†’ continue mode // If continue โ†’ load brainstorm.md + perspectives, resume from last round functions.exec_command(`mkdir -p ${sessionFolder}`) // Initialize progress tracking (MANDATORY) functions.update_plan([ { id: "phase-1", title: "Phase 1: Seed Understanding", status: "in_progress" }, { id: "phase-2", title: "Phase 2: Divergent Exploration", status: "pending" }, { id: "phase-3", title: "Phase 3: Interactive Refinement", status: "pending" }, { id: "phase-4", title: "Phase 4: Convergence & Crystallization", status: "pending" }, { id: "next-step", title: "GATE: Post-Completion Next Step", status: "pending" } ]) ``` ### Phase 1: Seed Understanding **Objective**: Parse the initial idea, identify exploration vectors, scope preferences, and initialize the brainstorm document. ##### Step 1.1: Parse Seed & Identify Dimensions Match topic keywords against brainstorm dimensions (see [Dimensions Reference](#brainstorm-dimensions)): ```javascript // Match topic text against keyword lists from Dimensions Reference // If multiple dimensions match, include all // If none match, default to "technical" and "innovation" const dimensions = identifyDimensions(topic, BRAINSTORM_DIMENSIONS) ``` ##### Step 1.2: Role Selection Recommend roles based on topic keywords, then let user confirm or override. **Professional Roles** (recommended based on topic keywords): | Role | Perspective Focus | Keywords | |------|------------------|----------| | system-architect | Architecture, patterns | ๆžถๆž„, architecture, system, ็ณป็ปŸ, design pattern | | product-manager | Business value, roadmap | ไบงๅ“, product, feature, ๅŠŸ่ƒฝ, roadmap | | ui-designer | Visual design, interaction | UI, ็•Œ้ข, interface, visual, ่ง†่ง‰ | | ux-expert | User research, usability | UX, ไฝ“้ชŒ, experience, user, ็”จๆˆท | | data-architect | Data modeling, storage | ๆ•ฐๆฎ, data, database, ๅญ˜ๅ‚จ, storage | | test-strategist | Quality, testing | ๆต‹่ฏ•, test, quality, ่ดจ้‡, QA | | subject-matter-expert | Domain knowledge | ้ข†ๅŸŸ, domain, industry, ่กŒไธš, expert | **Simple Perspectives** (fallback โ€” always available): | Perspective | Focus | Best For | |-------------|-------|----------| | creative | Innovation, cross-domain | Generating novel ideas | | pragmatic | Implementation, feasibility | Reality-checking ideas | | systematic | Architecture, structure | Organizing solutions | **Selection Strategy**: 1. **Auto mode**: Select top 3 recommended professional roles based on keyword matching 2. **Manual mode**: Present recommended roles + "Use simple perspectives" option 3. **Continue mode**: Use roles from previous session ##### Step 1.3: Initial Scoping (New Session Only) For new brainstorm sessions, gather user preferences before exploration (skipped in auto mode or continue mode): ```javascript if (!autoYes && !continueMode) { // Single batch: Mode + Focus + Constraints (max 4 questions per call) const scoping = functions.request_user_input({ questions: [ { header: "Mode", // max 12 chars question: "Select brainstorming intensity:", multiSelect: false, options: [ { label: "Balanced (Recommended)", description: "Moderate, 3 perspectives" }, { label: "Creative", description: "Fast, high novelty, 1 perspective" }, { label: "Deep", description: "Comprehensive, 3 perspectives + deep refinement" } ] }, { header: "Focus", question: "Select brainstorming focus areas:", multiSelect: true, options: generateFocusOptions(dimensions) // Dynamic based on dimensions }, { header: "Constraints", question: "Any constraints to consider?", multiSelect: true, options: [ { label: "Existing Arch", description: "Must fit current system" }, { label: "Time Limited", description: "Short implementation timeline" }, { label: "Resource Limited", description: "Limited team/budget" }, { label: "No Constraints", description: "Blue-sky thinking" } ]
View on GitHub
This SKILL.md is very large, so SkillsMP previews the first section here. View on GitHub