Skip to content

feat(subagents): add Reasonix native subagents adapter#2249

Open
dyoshikawa wants to merge 1 commit into
mainfrom
resolve-scrap-issue-2235-reasonix-subagents
Open

feat(subagents): add Reasonix native subagents adapter#2249
dyoshikawa wants to merge 1 commit into
mainfrom
resolve-scrap-issue-2235-reasonix-subagents

Conversation

@dyoshikawa

Copy link
Copy Markdown
Owner

Background

Reasonix supports native subagents, exposed as Skill profiles: directory-layout .reasonix/skills/<name>/SKILL.md files whose YAML frontmatter declares invocation: manual and runAs: subagent. rulesync already had Reasonix adapters for rules, commands, MCP, permissions, hooks, and skills, but reasonix was absent from the subagents feature, so rulesync generate --features subagents skipped it.

Primary source: SUBAGENT_PROFILES.md. The documented frontmatter is name, description, color, invocation: manual, runAs: subagent, model, effort, allowed-tools.

Change

  • New ReasonixSubagent adapter (src/features/subagents/reasonix-subagent.ts), modeled on the directory-per-agent Devin adapter since the <name>/SKILL.md layout matches Devin's <name>/AGENT.md.
    • Always injects the invocation: manual / runAs: subagent markers on generate.
    • Maps model/effort/allowed-tools/color through the reasonix: tool-specific block; z.looseObject preserves unknown upstream keys on round-trip.
    • Same .reasonix/skills/ directory for project and global scope (supportsGlobal: true).
  • Registered in the subagents tuple + toolSubagentFactories map, e2e project + global matrices, processor test target lists, tables (README / supported-tools), and file-formats.md (synced to skills/rulesync/).

Verification

  • pnpm cicheck (code + content) green.
  • e2e src/e2e/e2e-subagents.spec.ts green (project + global generate paths produce .reasonix/skills/planner/SKILL.md).

Closes #2235

Reasonix supports native subagents as Skill profiles: directory-layout
`.reasonix/skills/<name>/SKILL.md` files whose frontmatter declares
`invocation: manual` and `runAs: subagent`. Add a ReasonixSubagent
adapter (modeled on the directory-per-agent Devin adapter), register it
in the subagents tuple/factory map, and wire the e2e project + global
matrices, tables, and docs. The reasonix tool-specific block passes
through model/effort/allowed-tools/color; the loose schema preserves
unknown upstream keys on round-trip.

Primary source: https://github.com/esengine/DeepSeek-Reasonix/blob/main-v2/docs/SUBAGENT_PROFILES.md

Closes #2235

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@dyoshikawa

Copy link
Copy Markdown
Owner Author

⚠️ Do not merge as-is — this ships confirmed data loss.

Reasonix stores skills and subagents in the same directory/filename (.reasonix/skills/<name>/SKILL.md), split only by the runAs: subagent marker. Because rulesync treats skills and subagents as separate features with independent orphan-deletion, --delete on either feature removes the other's files (reproduced in both directions).

The adapter itself is complete and CI-green, but it needs marker-aware discovery + orphan-deletion on both this adapter and reasonix-skill.ts before it can safely land. See #2235 for the design decision. Holding this PR open pending that call.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Follow up Reasonix upstream updates: subagents surface (Skill runAs: subagent) unsupported

2 participants