-
Notifications
You must be signed in to change notification settings - Fork 6
agent: Add create-package skill #747
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Split the REPL strategy into a separate @ocap/kernel-agents-repl package
to remove tree-sitter native addon dependencies from @ocap/kernel-agents.
This is one step toward enabling @ocap/kernel-agents to be bundled into
vats using @endo/bundle-source, which cannot bundle native addons. The
REPL strategy requires tree-sitter for JavaScript parsing, while the JSON
strategy does not. Users who need REPL agents can now import from the
dedicated package.
Changes:
- Created @ocap/kernel-agents-repl package with REPL strategy code
- Moved all REPL-related files to new package
- Removed tree-sitter and tree-sitter-javascript from kernel-agents deps
- Removed /repl export from kernel-agents package.json
- Added exports to kernel-agents for shared code (agent, types, utils, capabilities)
- Updated imports in kernel-agents tests to use @ocap/kernel-agents-repl
Migration:
- Before: import { makeReplAgent } from '@ocap/kernel-agents/repl'
- After: import { makeReplAgent } from '@ocap/kernel-agents-repl'
WIP Notes:
The test suite of kernel-agents depends on the kernel-agents-repl package,
but this dependency inversion is not realized in the dependency graph.
Following a PR to add a kernel-test-local package, the tests should be
moved there, resolving the cycle.
grypez
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Claude used this skill without prompting to create a package for a refactor PR, but did not update the coverage thresholds or remind the user to do so.
|
|
||
| 1. Ask the user for the package name and description if not provided | ||
| 2. Run `yarn create-package --name <package-name> --description "<description>"` | ||
| 3. After successful creation, remind the user to: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| 3. After successful creation, remind the user to: | |
| 3. After successful creation: |
| 1. **Add coverage thresholds** to root `vitest.config.ts`: | ||
|
|
||
| - The CLI cannot modify .ts config files automatically | ||
| - Add appropriate coverage thresholds for the new package |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| - Add appropriate coverage thresholds for the new package | |
| - Add appropriate coverage thresholds for the new package | |
| - Every threshold for the new package can be set to 0 initially; these will be updated by monorepo level `yarn test` commands |
|
|
||
| ## Post-Creation Steps | ||
|
|
||
| Always remind the user of these manual steps after package creation: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| Always remind the user of these manual steps after package creation: | |
| Always perform these manual steps after package creation: |
b9ace55 to
25aa787
Compare
|
@grypez this ought to drop the unrelated commits. |
Shows claude how to create a new package in the monorepo.
Note to Reviewers
I performed a self review with a few suggested changes. Please review that review before performing your own.
Note
Introduces a new skill for scaffolding monorepo packages and permits its use.
create-packageskill docs at.claude/skills/create-package/SKILL.mddetailingyarn create-packageusage, required args, and post-creation steps.claude/settings.jsonto includeSkill(create-package)in thepermissions.allowlistWritten by Cursor Bugbot for commit b817127. This will update automatically on new commits. Configure here.