Workflow mapping

From LowyShin/giip-dev-agent · View interactive version

Workflow mapping is an AI agent skill from the GitHub repository LowyShin/giip-dev-agent. Map every branch of a system's execution paths before implementation — entry points, state transitions, workers, routes, and migrations, recorded as WORKFLOW-<name>.md with the happy path, every branch, payload/response contracts, and a cleanup inventory. Use before implementing a new feature or API

How to use this skill

Skill file

Skill: Workflow Mapping

This skill provides the methodology for exhaustive system path discovery and specification. It ensures that before implementation, every possible branch is accounted for.

💡 When to use

🛠️ Step-by-Step Methodology

1. Discovery Pass (Scouting)

Identify all entry points and state transitions in the existing codebase:

2. Map the Workflow Tree

Create a structured document (WORKFLOW-[name].md) covering:

3. Cleanup Inventory

List every resource created during the workflow that must be destroyed on failure to prevent orphans (DB records, files, cloud resources).

4. Test Case Derivation

Every branch in the tree must correspond to exactly one test case.

📄 Template: WORKFLOW-spec.md

# WORKFLOW: [Name]
**Status**: Draft | Approved

## Overview
[Description]

## Workflow Tree
### STEP 1: [Action]
- **Success**: Go to Step 2
- **Failure (Timeout)**: Retry x2 -> ABORT_CLEANUP
- **Failure (Error)**: Return Error -> ABORT_CLEANUP

## Cleanup Inventory
| Resource | Destroy Method |
|---|---|
| ... | ... |

🔍 Discovery Commands

# Find API routes
Select-String -Path "src\**\*.ts" -Pattern "router\.(post|put|get|delete)"
# Find state transitions
Select-String -Path "src\**\*.ts" -Pattern "status\s*="
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.