gorango/flowcraft/compiler-workflows

Claude Code and agent skill by gorango/flowcraft

Trust tier 2
  • community
LLM review pending
Source check pending

Checking that the SKILL.md file is still in the repository.

Write workflows using imperative TypeScript with the Flowcraft Compiler. Covers @flow and @step annotations, control flow patterns, subflows, configuration, and build tool integration. Use when the user mentions the compiler, imperative workflows, @flow, @step, or wants to write workflows without manually constructing graphs.

Install

npx vskill@latest install gorango/flowcraft/compiler-workflows

SKILL.md

Compiler Workflows (Alpha)

Flowcraft's compiler transforms imperative TypeScript into declarative blueprints at build time. Write familiar async functions with control flow — the compiler generates the graph.

[!WARNING]
The compiler is in alpha. Contributions are welcome.

Quick start

Installation
bash
npm install --save-dev @flowcraft/compiler
Write a workflow
typescript
/** @flow */
export async function myWorkflow(input: string) {
const data = await fetchData(input)
const result = await processData(data)
return result
}
/** @step */
async function fetchData(input: string) {
// Implementation — this becomes a durable node
return fetch(`/api/data?q=${input}`).then((r) => r.json())
}
/** @step */
async function processData(data: unknown) {
// Implementation — this becomes a durable node
return { processed: true, data }
}
Execute
typescript
import { FlowRuntime } from 'flowcraft'
import manifest from './generated/manifest'
const runtime = new FlowRuntime()
const result = await runtime.run(manifest['myWorkflow'], { input: 'hello' })

The Golden Rules

  1. Mark orchestrators with `/ @flow \/`\\* — Functions that define workflow orchestration
  2. Mark durable operations with `/ @step \/`\\* — Async operations that should be retried/tracked
  3. Never await plain async functions — The compiler errors if you await a non-@step function

Supported Control Flow

PatternSyntaxCompiles to
Sequentialawait stepA(); await stepB()Linear nodes with edges
Conditionalif/else with @step callsConditional edges with actions
Switchswitch(val) { case ... } with @step callsConditional multi-branch
Loopsfor/while/do-while with @step callsLoop controller node
Fallbackstry/catch/finally with @step callsFallback/finally node routing
ParallelismPromise.all([...]), Promise.allSettled([...]), Promise.race([...])Fan-out/fan-in with join
Subflowsawait otherFlow(input)Subflow node

Configuration

Create flowcraft.config.ts:

typescript
import { defineConfig } from '@flowcraft/compiler'
export default defineConfig({
entryPoints: ['./src/workflows/**/*.ts'],
manifestPath: './src/generated/manifest.ts',
tsConfigPath: './tsconfig.json',
})

Build Tool Integration

Compilation happens automatically with plugins:

typescript
// vite.config.ts
import flowcraft from '@flowcraft/plugin-vite'
export default {
plugins: [flowcraft()],
}

Available plugins: Vite, Next.js, Nuxt, Astro, esbuild, tsup.

Unsupported Syntax

  • Complex variable re-assignments within loops
  • Dynamic function calls or eval
  • Generator functions or async generators
  • Class methods as steps (use standalone functions)

Runtime compilation (compileCode)

For testing, REPL environments, or low-frequency runtime configuration, use compileCode() to compile raw TypeScript strings into blueprints:

typescript
import { compileCode } from '@flowcraft/compiler'
const { blueprint, diagnostics } = compileCode(
`
/** @flow */
export async function myFlow() {
const data = await fetchData()
return await processData(data)
}
/** @step */
async function fetchData() { return { value: 42 } }
/** @step */
async function processData(d: any) { return { result: d.value * 2 } }
`,
{ id: 'myFlow' },
)
Note: compileCode() writes temporary files and spins up a full compiler instance per call. For production, always use pre-compiled builds via compileProject() or framework plugins.

Advanced topics

Security

  • Security scanPassed, 93 of 100Pattern checks on the skill's files.
  • Model reviewNot runA model review is scheduled for the next rescan.

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

Repository stars
199
Repository forks
13
7-day trend score
26

Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/gorango/flowcraft/compiler-workflows/badge)](https://verified-skill.com/skills/gorango/flowcraft/compiler-workflows)

Something wrong with this skill or its page? Tell us.