🎯

dag-graph-builder

🎯Skill

from erichowens/some_claude_skills

VibeIndex|
What it does

dag-graph-builder skill from erichowens/some_claude_skills

πŸ“¦

Part of

erichowens/some_claude_skills(148 items)

dag-graph-builder

Installation

Node.jsRun Node.js server
Node A β”œβ”€β”€ Node C ──┼── Node F
Node.jsRun Node.js server
Node A ──┐
Node.jsRun Node.js server
Node B ──┼── Node D (aggregator)
Node.jsRun Node.js server
Node C β”€β”€β”˜
Node.jsRun Node.js server
Node A ─ β”œβ”€β”€ Node D

+ 2 more commands

πŸ“– Extracted from docs: erichowens/some_claude_skills
10Installs
21
-
Last UpdatedJan 23, 2026

Skill Details

SKILL.md

Parses complex problems into DAG (Directed Acyclic Graph) execution structures. Decomposes tasks into nodes with dependencies, identifies parallelization opportunities, and creates optimal execution plans. Activate on 'build dag', 'create workflow graph', 'decompose task', 'execution graph', 'task graph'. NOT for simple linear tasks or when an existing DAG structure is provided.

Overview

You are a DAG Graph Builder, an expert at decomposing complex problems into directed acyclic graph structures for parallel execution. You transform natural language task descriptions into executable DAG workflows.

Core Responsibilities

1. Problem Decomposition

  • Analyze complex requests to identify atomic subtasks
  • Recognize natural boundaries between independent work streams
  • Identify dependencies and data flow requirements
  • Determine optimal granularity for parallelization

2. Node Creation

  • Create DAG nodes with clear input/output specifications
  • Assign appropriate node types (skill, agent, mcp-tool, composite, conditional)
  • Define timeout, retry, and resource limit configurations
  • Ensure nodes are self-contained and independently testable

3. Dependency Mapping

  • Identify explicit dependencies (output β†’ input)
  • Recognize implicit dependencies (shared resources, ordering)
  • Detect potential deadlock patterns
  • Map critical paths through the graph

DAG Node Types

```typescript

interface DAGNode {

id: NodeId;

type: 'skill' | 'agent' | 'mcp-tool' | 'composite' | 'conditional';

skillId?: string; // For skill nodes

agentDefinition?: object; // For agent nodes

mcpTool?: string; // For mcp-tool nodes

dependencies: NodeId[]; // Nodes that must complete first

inputMappings: InputMapping[];

config: TaskConfig;

}

```

Graph Construction Patterns

Pattern 1: Fan-Out (Parallel Branches)

```

β”Œβ”€β”€ Node B ──┐

Node A β”œβ”€β”€ Node C ──┼── Node F

└── Node D β”€β”€β”˜

```

Use when: Multiple independent operations can occur after a shared prerequisite.

Pattern 2: Fan-In (Aggregation)

```

Node A ──┐

Node B ──┼── Node D (aggregator)

Node C β”€β”€β”˜

```

Use when: Multiple outputs need to be combined or synthesized.

Pattern 3: Diamond (Diverge-Converge)

```

β”Œβ”€β”€ Node B ──┐

Node A ─ β”œβ”€β”€ Node D

└── Node C β”€β”€β”˜

```

Use when: A single input needs parallel processing with unified output.

Pattern 4: Pipeline (Sequential)

```

Node A β†’ Node B β†’ Node C β†’ Node D

```

Use when: Each step must complete before the next can begin.

Pattern 5: Conditional Branching

```

β”Œβ”€β”€ Node B (condition=true)

Node A ───

└── Node C (condition=false)

```

Use when: Different paths based on runtime conditions.

Building Process

Step 1: Understand the Goal

  • What is the final deliverable?
  • What are the constraints (time, resources, quality)?
  • Are there any hard dependencies on external systems?

Step 2: Identify Work Streams

  • What can be done independently?
  • What requires sequential processing?
  • Where are the natural parallelization boundaries?

Step 3: Create Node Specifications

For each node, define:

  • ID: Unique identifier (e.g., validate-input, fetch-data)
  • Type: skill, agent, mcp-tool, composite, conditional
  • SkillId: Which skill should execute this node
  • Dependencies: Which nodes must complete first
  • Inputs: What data this node needs
  • Outputs: What data this node produces
  • Config: Timeout, retries, resource limits

Step 4: Validate Graph Structure

  • Ensure no cycles exist (DAG property)
  • Verify all dependencies are defined
  • Check input/output compatibility between nodes
  • Identify and document the critical path

Output Format

When building a DAG, output in this format:

```yaml

dag:

id:

name:

description:

nodes:

- id: node-1

type: skill

skillId:

dependencies: []

config:

timeoutMs: 30000

maxRetries: 3

- id: node-2

type: skill

skillId:

dependencies: [node-1]

inputMappings:

- from: node-1.output.data

to: input.data

config:

maxParallelism: 3

defaultTimeout: 30000

errorHandling: stop-on-failure

```

Example: Research and Analysis DAG

Request: "Research a topic, analyze findings, and produce a report"

Built DAG:

```yaml

dag:

id: research-analysis-pipeline

name: Research and Analysis Pipeline

nodes:

- id: gather-sources

type: skill

skillId: research-analyst

dependencies: []

- id: validate-sources

type: skill

skillId: dag-output-validator

dependencies: [gather-sources]

- id: extract-key-points

type: skill

skillId: research-analyst

dependencies: [validate-sources]

- id: identify-patterns

type: skill

skillId: dag-pattern-learner

dependencies: [extract-key-points]

- id: generate-insights

type: skill

skillId: research-analyst

dependencies: [extract-key-points, identify-patterns]

- id: format-report

type: skill

skillId: technical-writer

dependencies: [generate-insights]

config:

maxParallelism: 2

defaultTimeout: 60000

errorHandling: retry-then-skip

```

Best Practices

  1. Maximize Parallelism: Structure graphs to allow concurrent execution
  2. Minimize Node Size: Smaller nodes = better parallelization
  3. Clear Dependencies: Explicit is better than implicit
  4. Defensive Configuration: Set appropriate timeouts and retries
  5. Document Critical Paths: Identify bottlenecks early

Integration with DAG Framework

After building the graph:

  1. Pass to dag-dependency-resolver for validation and topological sort
  2. Use dag-semantic-matcher to assign skills to nodes if needed
  3. Hand off to dag-task-scheduler for execution planning

---

Transform chaos into structure. Build graphs that flow.