Bundle agent skills into generated templates - #242
Merged
Conversation
Templates now automatically include relevant agent skills in generated projects so coding agents have MADSci domain knowledge from day one. - Add `skills` field to TemplateManifest and `skills_included` to GeneratedProject - Add skill-copy logic in TemplateEngine.render() with _resolve_skills_dir() - Create canonical _skills/ directory in bundled_templates with 4 SKILL.md files - Replace .agents/skills/madsci-* dirs with symlinks to bundled copies - Update all 26 template.yaml manifests with category-appropriate skills - Add TestSkillsCopying test class (8 tests) and update file-count assertions - Update template_catalog.md, agent_skills.md docs, and init CLI output Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Coverage reportClick to see where and how coverage changed
This report was generated by python-coverage-comment-action |
||||||||||||||||||||||||||||||||||||||||||||||||
…dd madsci-cli skill - Refactor init command by extracting _collect_parameters() and _display_results() helpers to remove noqa: PLR0915 suppression - Fix _resolve_skills_dir() walk-up to check current directory before walking up to parent, so _skills/ sibling of template_dir itself is found - Add madsci-cli skill to workcell/basic, workflow/basic, and workflow/multi_step template manifests alongside madsci-managers Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Change .gitignore to only ignore .claude/settings.local.json instead of the entire .claude/ directory, so skills symlink and agent configs are version-controlled - Extract inline skills-copying block from render() into _copy_skills() helper method, removing PLR0915 suppression - Add comment explaining walk-up depth limit in _resolve_skills_dir() Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
RyanTheRobothead
marked this pull request as ready for review
March 24, 2026 21:26
Provides a structured framework (inspired by Brooker's "Better Mousetraps") that nudges agents to research existing libraries before writing functionality from scratch. Includes evaluation criteria, research guidance, and a quick reference of commonly solved domains. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…st robustness, improve types - Add madsci-nodes skill to workflow and workcell templates so operators have node context available - Replace fragile parents[4] repo root lookup with .git walk-up in test_bundled_skills_match_repo_skills - Add test_resolve_skills_dir_importlib_fallback to cover the importlib fallback path in _resolve_skills_dir - Replace Any type hints in _display_results with Console and GeneratedProject using TYPE_CHECKING guard - Update docs (agent_skills.md, template_catalog.md) to reflect new workflow/workcell skill set Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
RyanTheRobothead
added a commit
that referenced
this pull request
Mar 31, 2026
- Complete CHANGELOG for v0.8.0 with all 9 merged PRs (#228, #235, #242, #255–#260), properly categorized under Added/Changed/Fixed - Fix broken ActionHandler import in module/basic and node/basic templates (replaced with @action decorator pattern) - Fix self.node_definition → self.node_info in 5 module templates (device, instrument, camera, liquid_handler, robot_arm) and their READMEs - Modernize self.logger.log() → self.event_client.info() in same 5 templates - Fix stale infrastructure references in example lab README (MongoDB→FerretDB, MinIO→SeaweedFS, wrong ports, deprecated /definition endpoint) - Update node module README to remove deprecated --node_definition reference Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
6 tasks
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.
Summary
.agents/skills/) so coding agents have MADSci domain knowledge from day oneskillsfield toTemplateManifestandskills_includedtoGeneratedProject;TemplateEngine.render()copies SKILL.md files from a shared_skills/directory inbundled_templates/madsci-nodes, experiment getsmadsci-experiments, workflow/workcell getmadsci-managers+madsci-cli, lab gets all 4Changes
Core:
template_types.py: Newskillsandskills_includedfieldsengine.py:_resolve_skills_dir()+ skill-copy logic inrender()(dry-run aware)bundled_templates/_skills/: Canonical location for 4 SKILL.md files.agents/skills/madsci-*: Replaced directories with symlinks to bundled copiesTemplates: All 26
template.yamlfiles updated withskills:fieldCLI:
madsci initnow prints skill count after rendering; refactored into helper functionsDocs: Updated
template_catalog.md(bundled skills table) andagent_skills.md(generated project section)Tests: New
TestSkillsCopyingclass with 8 tests (copy, dry-run, result tracking, all-templates-declare, bundled-matches-repo) + updated file-count assertionsTest plan
pytest src/madsci_common/tests/test_templates/— 183 tests passpytestfull suite — 2929 tests passjust allpipeline passes (checks, tests, build, docs).agents/skills/and.claude/skills/madsci init --no-interactivein temp dir, verify.agents/skills/in output🤖 Generated with Claude Code