[rig-claude] Improve Claude dynamic-workflow compatibility for rig - #524
Draft
github-actions[bot] wants to merge 1 commit into
Draft
[rig-claude] Improve Claude dynamic-workflow compatibility for rig#524github-actions[bot] wants to merge 1 commit into
github-actions[bot] wants to merge 1 commit into
Conversation
The parallel row in the context table was missing the single-type TypeScript constraint and the Promise.all avoidance note. Both were documented in claude-workflow-conversion.md but not in the primary dynamic-workflows.md reference, so users who read only the API doc would not see the hint about heterogeneous casts or the concurrency limiter bypass warning. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Compatibility gap addressed
dynamic-workflows.md(the primary rig workflow API reference) was missing the TypeScript single-type constraint forparalleland thePromise.allavoidance note. Both were documented inclaude-workflow-conversion.md's primitive mapping table, but a user reading only the core API reference would not see either warning.This is the most impactful discoverability gap for Claude dynamic-workflow porters: they commonly use
parallelwith different agent output types (e.g., one thunk returning{ findings }, another returning{ verdict }), andPromise.allis the natural reflex whenparallelisn't known. Missing this information silently produces TypeScript errors or bypasses the concurrency limiter.Why this improves transfer
Claude's
parallel(thunks)injects each thunk's result asany, so mixed return types compile without cast. Rig'sparallel<Result>is generic over a single type, so porting users hit a TypeScript error when their thunks return different shapes. Surfacing the cast pattern directly indynamic-workflows.mdmakes the mapping obvious without requiring a second pass through the conversion reference.Files changed
skills/rig/references/dynamic-workflows.md— expanded theparallelrow in the Context table with the TypeScript constraint note and thePromise.allavoidance guidanceValidation
Only docs changed; no TypeScript sources were modified. Verified no broken relative links in the edited file. The sample typecheck test (
npm run sample -- --testNamePattern="skill markdown samples typecheck") timed out onnpx tsc— a pre-existing environment issue unrelated to this doc-only change.Remaining intentional differences
parallelrequires homogeneous types (by design in rig's typed API); the cast workaround is now documented in both references.Promise.allis not forbidden but bypasses the limiter; both references now warn against it.