Skip to content

[rig-claude] Improve Claude dynamic-workflow compatibility for rig - #396

Merged
pelikhan merged 1 commit into
mainfrom
rig-claude-compat/2026-08-10-f75cd210eb8b78db
Aug 10, 2026
Merged

[rig-claude] Improve Claude dynamic-workflow compatibility for rig#396
pelikhan merged 1 commit into
mainfrom
rig-claude-compat/2026-08-10-f75cd210eb8b78db

Conversation

@github-actions

Copy link
Copy Markdown
Contributor

Compatibility gap addressed

Claude dynamic-workflow users know how to select models with { model: "sonnet" } and quality with { effort: "high" }, but the conversion reference didn't show:

  1. How to configure rig to run on Claude / Anthropic (which engine, which env var)
  2. Which full Claude model IDs to use (the primitive table just said "rig passes the id straight to the engine")
  3. What to do instead of effort: "high" (the table said with no actionable guidance)

This is the single highest-confidence discoverability gap: a user porting a Claude workflow would copy model: "sonnet" and wonder why it doesn't resolve, then have no docs pointing them to anthropicEngine() or claude-sonnet-4-5.

Why this improves transfer

  • Adds a concrete "Running with the Anthropic engine" section with a configureAgent(anthropicEngine()) snippet, RIG_ENGINE=anthropic note, and a model tier table (haiku/sonnet/opus)
  • Makes the effort row actionable: "use a more capable model id or increase maxTurns"
  • Expands the model row note to surface the full-id requirement with anthropicEngine()
  • Updates the SKILL.md focused-reference blurb to surface "model selection" so agents load this reference when the task involves Anthropic

Files changed

  • skills/rig/references/claude-workflow-conversion.md — new section + expanded table rows
  • skills/rig/SKILL.md — blurb update for the claude-workflow-conversion reference

Validation

Docs-only change; no typecheck or test run required per the validation rules. Checked for broken relative links — all sample and reference links are unchanged.

Remaining intentional differences

  • No effort field in rig (by design); the guidance now directs users to the model tier table instead.
  • No agentType: "Explore" equivalent; the existing guidance (prompt wording + narrow tools list) remains correct.

Generated by Daily Rig Claude Dynamic Workflow Compatibility · sonnet46 67 AIC · ⌖ 8.46 AIC · ⊞ 5.4K ·

…kflow-conversion

Fills the gap where Claude dynamic-workflow users know model = 'sonnet' but
don't know how to configure the Anthropic engine in rig or which full Claude
model IDs to use.

- Expand model/effort rows in the primitive mapping table with concrete ids
- Add 'Running with the Anthropic engine' section with configureAgent() snippet
  and a model tier table (haiku/sonnet/opus)
- Update SKILL.md focused-reference blurb to surface 'model selection'

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@pelikhan
pelikhan marked this pull request as ready for review August 10, 2026 10:38
@pelikhan
pelikhan merged commit b853910 into main Aug 10, 2026
1 check passed
@github-actions

github-actions Bot commented Aug 10, 2026

Copy link
Copy Markdown
Contributor Author

🧠 Matt Pocock Skills Reviewer has completed the skills-based review. ✅

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skills-Based Review 🧠

Applied /grill-with-docs — requesting changes on two correctness issues in the new section.

📋 Key Themes & Highlights

Issues

  • Incorrect call usage (line 184): call is not a named export from "rig" — it is a destructured parameter in a workflow body. The snippet imports { agent, s, workflow } but uses call as a free function, which is a ReferenceError.
  • Inaccurate RIG_ENGINE description (line 169): described as "auto-select" when it is actually an explicit override. True auto-selection happens when RIG_ENGINE is absent and ANTHROPIC_API_KEY is set.

Positive Highlights

  • ✅ The overall structure of the new section is well-targeted; it fills a real discoverability gap
  • ✅ The model tier table is clear and useful
  • ✅ The effort row expansion gives actionable guidance where before there was none
  • ✅ SKILL.md blurb update correctly surfaces "model selection" for routing

🧠 Reviewed using Matt Pocock's skills by Matt Pocock Skills Reviewer · sonnet46 50.9 AIC · ⌖ 4.27 AIC · ⊞ 6.3K
Comment /matt to run again

});

// Per-call model override — equivalent to { model: "claude-opus-4-5" } in a dynamic workflow:
const result = await call(classifier, { text }, { model: "claude-opus-4-5" });

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/grill-with-docs] call is not a named export from "rig" — it is only available as a destructured parameter inside a workflow body (body: async ({ call }) => { ... }). Using it as a standalone function will cause a ReferenceError at runtime and mislead readers porting Claude workflows.

💡 Suggested fix

Either wrap the per-call override in a workflow body:

const myWorkflow = workflow({
  input: s.object({ text: s.string }),
  body: async ({ call }, { text }) => {
    return await call(classifier, { text }, { model: "claude-opus-4-5" });
  },
});

Or use the callable AgentFn signature directly (since AgentFn is callable):

const result = await classifier({ text }, { model: "claude-opus-4-5" });

configureAgent(anthropicEngine()); // reads ANTHROPIC_API_KEY
```

Or set `RIG_ENGINE=anthropic` to let the launcher auto-select based on

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[/grill-with-docs] Slight inaccuracy: RIG_ENGINE=anthropic is an explicit override, not auto-selection. Auto-selection happens when RIG_ENGINE is not set and ANTHROPIC_API_KEY is present. Swapping the description avoids confusion for users who rely on env-based auto-detection.

💡 Suggested wording
Or omit `configureAgent` entirely — if `ANTHROPIC_API_KEY` is set and `COPILOT_SDK_URI` is not,
rig auto-selects the Anthropic engine. Set `RIG_ENGINE=anthropic` to force it explicitly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant