yield/Documentation

For programmers using coding agent skills

Keep your skills. Run the workflow in code.

Create one workflow by hand. Put repeatable steps, checks, approvals, and saved state in code, then register it with your coding agent.

00 / Concept

Skill workflows are portable, executable processes.

They combine agent skills with deterministic code, saved state, and verification. The workflow is canonical. Generated adapters are disposable.

See the full anatomy: source files, generated adapters, and trigger path →

coding agentgenerated adapterskill workflowagent / command / personsaved responsenext step or terminal
Skill

One reusable capability.

Skill workflow

Skills and code arranged as an executable process.

Adapter

A generated file that lets an agent discover the workflow.

Operation

One request to an agent, command, or person.

Run

One saved execution of a workflow.

Terminal

A completed, blocked, or refused outcome.

01 / Manual

Create your first workflow by hand.

Learn the complete coded-skill path once. The optional helper can accelerate the same path later.

001

Install

Add the runtime and repository-local CLI.

002

Create

Scaffold one workflow with init.

003

Edit

Write the program and deterministic fixtures.

004

Test

Run doctor --test.

005

Register

Create discovery adapters.

006

Restart

Start a new agent session.

007

Run

Invoke the registered workflow.

Package installation creates no skill or coding-agent adapter. You create the canonical workflow explicitly, test its real effects with fixtures, and register only the small discovery adapters you need.

Paste into terminal · TypeScript
npm install --save-exact @operatorstack/yield
Create, test, register, run · TypeScript
npm exec -- yskill init skills/review --language typescript \
  --description "Check and review a branch before it is shipped."
# Edit skills/review/main.ts and fixtures/responses.json.
npm exec -- yskill doctor skills/review --test
npm exec -- yskill register skills/review
# Restart your coding agent, then run the registered skill.
npm exec -- yskill run skills/review

Keep order, branches, commands, approvals, and finish rules in the program. Put deterministic answers and test-only effects in fixtures/. Keep judgment and reusable guidance in SKILL.md.

02 / Agents

Use with your coding agent.

yskill register detects verified agents in the project and writes the adapter path each host expects. The workflow and dependencies stay under skills/.

CURSOR

.cursor/skills

Verified with project-local discovery.

CODEX

.agents/skills

Verified with project-local discovery.

CLAUDE

.claude/skills

Verified with project-local discovery.

Run yskill agents with your package launcher to list every supported ID. Other hosts are registry-supported: adapter generation is tested, but Yield has not run every product end to end.

Keep every adapter in sync

register-all checks every workflow before it writes anything. Use --dry-run first. Add --prune only when you want to remove stale adapters generated from that workflow directory.

Sync every adapter · TypeScript
npm exec -- yskill register-all skills --agent cursor,codex,claude-code --dry-run
npm exec -- yskill register-all skills --agent cursor,codex,claude-code --prune

Restart after registration

The new session can discover the registered builder and skill workflows. Ask in plain language. You do not need to paste setup instructions into the agent.

03 / Existing

Run an existing workflow.

Install its language package, register the local adapter, check it, and run it. You do not recreate or move the workflow when you switch agents.

Register and run · TypeScript
npm exec -- yskill doctor skills/review --test
npm exec -- yskill register skills/review
npm exec -- yskill run skills/review
04 / Optional

Accelerate the workflow after you understand it.

The developer helper teaches and applies the same manual path. Installing a package alone never creates the helper, a skill, or an adapter.

Install the helper explicitly, review its complete plan, approve any mutation, then restart your coding agent so it discovers skills/yield-workflow-builder.

Optional helper · TypeScript
npm exec -- yskill helper install --language typescript

Seven focused modes

learn

Explain the smallest relevant concept and manual steps. Read-only.

create

Plan and create one tested workflow in a new destination.

convert

Project an existing skill into code without dropping its guidance.

check

Inspect one workflow without running its fixture or changing files. Read-only.

repair

Use doctor evidence, apply an approved repair, and verify again.

upgrade

Update one workflow to the installed Yield version.

register

Test, register selected agents, and verify their adapters.

Installer preview

Before approval, the installer shows resolved paths, dependency preparation, workflow testing, selected-agent registration, and final adapter verification.

One ordered plan.The preview and execution use the same operations in the same order.

Mutation approval

Every changing mode shows the summary, relevant primitives, exact files, and exact commands before asking to apply the plan.

Summary
Primitives
Files
Commands

Apply this plan?

Fail-closed safety

  • learn and check do not mutate files; static checks do not execute fixtures.
  • Verification may make at most two repair attempts before it stops.
  • The helper refuses path escapes, existing destinations, user-owned helper or adapter files, and unsupported version changes.
  • The helper cannot upgrade itself during an active run; exit and run yskill helper install instead.
  • Successful changing modes require doctor --test, registration for the selected agents, and adapter verification.

yskill bootstrap and npm create @operatorstack/yield@latest remain compatibility aliases only. New documentation and examples use yskill helper install.

Open the focused CLI reference and examples →

05 / API

Five operations. Ordinary code around them.

Use your language for branches, loops, functions, and local types. Yield only owns the boundaries between the program, the agent, commands, and people.

06 / SDKs

Use the language already in the repo.

Write the same workflow in Go, TypeScript, Python, or Rust. Pick the language that fits your project.

Same flow · TypeScript
import { defineSkill } from "@operatorstack/yield"

defineSkill((ctx) => {
  const check = ctx.runCommand("check", "npm test", 300)
  ctx.require(check.exit_code === 0, "tests pass", check)
  const review = ctx.agentTask("review", "Review this branch")
  ctx.require(review.critical === 0, "no critical findings", review)
  return review
})
07 / Learn

Start from engineering work you already do.

Each tutorial gives judgment to the agent and moves only the repeatable control flow into code.

  1. 001Check and review a branch

    Run type checks, inspect the diff, and finish only with zero critical findings.

  2. 002Pause before publishing

    Ask for approval before your own publish command, then verify the real exit code.

  3. 003Repair an environment

    Probe, diagnose, wait while a person applies a fix, then resume and recheck.

  4. 004Bound a debugging loop

    Try the cheapest hypotheses first and stop after a declared attempt limit instead of guessing forever.

  5. 005Run a data migration

    Dry-run, inspect, approve, apply, and verify in an order code can enforce.

08 / Examples

Skill workflow library.

Ten ready-to-adapt skill workflows are available in every language. Open one and replace the example commands with your repository commands.

10 skill workflows · 4 languagesBrowse the whole library ↗

09 / Runtime

Close the session. Keep the run.

Stop at any point and continue the same workflow later. Answer a user question with --value or send structured agent output through stdin.

Run commands · TypeScript
npm exec -- yskill run ./my-skill
npm exec -- yskill respond <run-id> --value <answer> --skill ./my-skill
npm exec -- yskill inspect <run-id> --skill ./my-skill
npm exec -- yskill replay <run-id> --skill ./my-skill

Each response is bound to the pending step before the run advances. If the workflow changes, Yield stops instead of pairing an old answer with new code.

See how a run continues across coding-agent sessions →

10 / Limits

Deterministic flow is not automatic truth.

Yield makes workflow behavior easier to inspect and test. It does not turn every model answer into a fact.

Yield enforces

  • the order of steps and branches
  • real command execution and results
  • saved progress between sessions
  • requirements before completion
  • clear completed, blocked, or refused outcomes

Yield does not claim

  • an agent answer is automatically true
  • it can observe work outside the workflow
  • commands are automatically sandboxed
  • your workflow no longer needs tests or review
  • deployment logic is provided for you

Set your examples once

Which language are you using?

We’ll open every language-aware example in your choice. You can still switch any individual code block.