Skip to content

feat(r-lib): add r-mizu skill - #101

Draft
shikokuchuo wants to merge 2 commits into
posit-dev:mainfrom
shikokuchuo:r-mizu
Draft

shikokuchuo wants to merge 2 commits into
posit-dev:mainfrom
shikokuchuo:r-mizu

Conversation

@shikokuchuo

Copy link
Copy Markdown
Member

Purpose

Adds the r-mizu skill: guidance for writing correct R code for async and parallel computing with the mizu package — task pools, mizu_map() parallel map, channels, and promises over shared memory on one machine. The content ships in the mizu package at inst/skills/r-mizu and is synced here byte-identically.

Use cases

Running R code in parallel or in the background, speeding up a loop or lapply(), using promises or Shiny ExtendedTask, sharing data with R or Python processes, or converting from future/parallel/mirai. Defers to the r-mirai skill for work spanning more than one machine.

Testing

  • Byte-identical with the canonical copy in the mizu package (verified with diff), where the skill has eval coverage.
  • Registered in .claude-plugin/marketplace.json under the r-lib plugin and documented in the root and r-lib READMEs.

Dependencies

R >= 4.3, 64-bit, Linux kernel >= 5.3, with the mizu package installed. No harness assumptions.

Documentation

Single comprehensive SKILL.md; category notes in r-lib/README.md and a listing entry in the root README.md.

Token count

### r-mizu (380 lines, ~4,285 tokens)

Skill description: ~97 tokens

> Write correct R code for async and parallel computing with mizu: task pools, parallel map, channels and promises over shared memory on one machine. Use when running R code in parallel or in the background, speeding up a loop or lapply, using promises or Shiny ExtendedTask, sharing data with R or Python processes, or converting from future, parallel or mirai. Defer to the r-mirai skill for work spanning more than one machine (SSH, HPC).

| File | Lines | ~Tokens |
|---|---:|---:|
| SKILL.md | 380 | 4,285 |

@shikokuchuo shikokuchuo left a comment

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

mizu routes to mirai for distributed work. At the moment this is one way as the mirai skill doesn't route to mizu. This is fine for now, but when mizu is more mature, we'd want to update the mirai skill for bi-directional routing.

@shikokuchuo shikokuchuo changed the title docs(r-mizu): add r-mizu skill for async/parallel R over shared memory feat(r-lib): add r-mizu skill Nov 6, 2026
@gadenbuie

Copy link
Copy Markdown
Collaborator

Thanks @shikokuchuo! I've been thinking about this a bit and I kind of think we should keep package-specific skills in their packages. I think that what's a good fit here would be skills that span several packages (eg mirai ecosystem) that wouldn't fit nicely in one package source.

Maybe instead we could move to a list at the top of the readme? Something like an "Awesome Package Skills" section?

@shikokuchuo

Copy link
Copy Markdown
Member Author

@gadenbuie agree skills living in packages is a good idea - and it's what I do already. This submission was for the specific purpose of the Positron bundle / what PA has access to. I realise that I will need to make changes to the mirai skill to have them work well together, so pls hold off on this.

@shikokuchuo
shikokuchuo marked this pull request as draft November 12, 2026 10:19
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.

2 participants