Repository navigation
Ship the agent skills inside the package and add an agent_skills entry point - #57
Open
ronpandolfi wants to merge 3 commits into
Open
ronpandolfi wants to merge 3 commits into
ronpandolfi wants to merge 3 commits into
Conversation
…try point
The skills lived in a top-level skills/ folder outside the gpcam package, so
wheels and pip installs left them out. Move them to gpcam/skills/ (a regular
package, so importlib.resources.files("gpcam.skills") works from an install)
and point the Claude Code plugin at the new folder with plugin.json's
"skills" field; no second copy, no symlink.
Add an agent_skills entry point (gpcam = "gpcam.skills") so agent hosts such
as Lightfall can discover the skills. Contract: the entry point loads to a
package; each subfolder of importlib.resources.files(pkg) that contains a
SKILL.md is one skill.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #57 +/- ##
=======================================
Coverage 98.60% 98.60%
=======================================
Files 8 8
Lines 1509 1509
=======================================
Hits 1488 1488
Misses 21 21 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…are names Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ills # Conflicts: # HISTORY.rst
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
The Claude Code skills lived in a top-level
skills/folder outside thegpcampackage, so wheels andpip install git+...installs didn't include them. This PR:skills/togpcam/skills/(git mv, layout unchanged, includingacquisition-functions/references/). An__init__.pywith only a docstring makes it a regular package, soimportlib.resources.files("gpcam.skills")works from an install.packages = ["gpcam"]picks up the files with no extra include rules..claude-plugin/plugin.jsongains"skills": "./gpcam/skills/". Per the plugin manifest reference, this field names directories to scan for skills and adds to the defaultskills/scan.importlib.resources.files(pkg)that contains aSKILL.mdis one skill. As far as we know there is no established cross-tool group for this, so it sets a convention. Lightfall (the ALS beamline control dashboard) uses it to load these skills into its agents.skills/paths inCLAUDE.md,README.mdanddocs/source/claude-skills.md(new section "Skills in the Python package"), and adds aHISTORY.rstentry.Verification
uv build --wheel):gpcam/skills/__init__.py, all 11gpcam/skills/*/SKILL.md,gpcam/skills/acquisition-functions/references/choosing-an-acquisition-function.md.entry_points.txtreads[agent_skills] gpcam = gpcam.skills.files("gpcam.skills") / "experiment-designer" / "SKILL.md"exists,entry_points(group="agent_skills")listsgpcam, and all 11 skills plus the references file are found through it.claude plugin validate .passes (only the existing no-versionand root-CLAUDE.mdwarnings), and it fails with "Path not found" when the path is deliberately wrong. Loading a copy of the plugin withclaude -p --plugin-dirlisted all 11 skills./plugin marketplace add lbl-camera/gpCAMflow, which needs this merged; the pytest suite (no library code changed); the Sphinx build.Skill names
Skill names stay bare (
kernel-designer,troubleshooting, ...), with nogpcam-prefix. Claude Code already shows them asgpcam:kernel-designer, and a prefix would make thatgpcam:gpcam-kernel-designer. A host that merges skills from several packages should namespace them by entry-point name instead;docs/source/claude-skills.mdsays so.🤖 Generated with Claude Code