Skip to content

[plan] Improve prompt step density guidance in create-agentic-workflow.md #27499

@github-actions

Description

@github-actions

Objective

Add a "step-then-example" prompt template pattern to .github/aw/create-agentic-workflow.md to help reduce density in multi-step workflow prompts.

Context

From discussion #27482 (Agent Persona Exploration - 2026-04-21), every scenario scored 4/5 (not 5) on prompt clarity. Multi-step prompts (6–7 steps) were correct but dense. Complex analysis steps (e.g., multi-format coverage parsing with format classification tables) would benefit from an example-first layout. No prompt template section currently exists with this guidance.

Approach

In .github/aw/create-agentic-workflow.md, add a section on prompt authoring style. Insert a "Prompt Template Best Practices" subsection that includes:

  1. Step-then-example pattern: For each complex analysis step, immediately follow the instruction with a concrete example:

    ❌ Dense:
    3. Parse coverage: extract total.lines.pct from JSON Summary, covered/total from Go cover output, or SF/DA/LF/LH from LCOV.
    
    ✅ Step-then-example:
    3. Parse coverage from whatever format CI produced:
       - JSON Summary: `{ "total": { "lines": { "pct": 87.5 } } }` → use `total.lines.pct`
       - Go cover: `github.com/foo/bar/pkg 87.5%` → use the percentage column
       - LCOV: `LF:100` / `LH:87` → compute `LH/LF * 100`
    
  2. Decision tree format: For branching logic steps, use a simple if/else block rather than a prose paragraph.

  3. Maximum 2 decision points per step: If a step has more than 2 branches, split it into sub-steps.

Files to Modify

  • .github/aw/create-agentic-workflow.md — add "Prompt Authoring Best Practices" section with step-then-example pattern and decision tree guidance

Acceptance Criteria

  • A prompt authoring section exists with the step-then-example pattern
  • At least one ❌/✅ example contrasting dense vs. clear prompt steps
  • Decision tree format is recommended for branching logic
  • The guidance is actionable: agents can follow it when writing new workflow prompts

Generated by Plan Command for issue #discussion #27482 · ● 292.8K ·

  • expires on Apr 23, 2026, 5:16 AM UTC

Metadata

Metadata

Labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions