feat(agents): ship the agent skill in the SDK and hint once per session - #911
Merged
RapidPoseidon merged 8 commits intoSep 29, 2026
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
RapidPoseidon
force-pushed
the
feat(agents)/per-session-hint-and-skill-freshness
branch
from
September 28, 2026 08:56
71e9491 to
ce3f03c
Compare
…ion-hint-and-skill-freshness
The skill in src/rapidata/_skill/ (SKILL.md plus reference, examples and the flows guide, moved from RapidataAI/skills) is now edited only here and ships in every wheel. `python -m rapidata skill [guide]` and the new `rapidata` console script print the bundled copy with no network access. --install stamps the SDK version instead of a content hash, and the import hint compares that stamp to rapidata.__version__ locally. The live GitHub fetch, the daily freshness check and the release-time refresh step are gone. A new `Agent Skill` status fails PRs that leave the skill untouched until a reviewer applies skill-unchanged-approved; generator-only and version-bump PRs are exempt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
…atter `--install` now writes `metadata.rapidata-sdk-version` into the front matter and opens the copy with a version check, so an agent that loads the installed skill without importing the SDK is still told to reinstall on a mismatch. The import hint reads the version from the front matter only. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
The skill ships with the SDK, so the agent docs now start from `pip install rapidata` and `rapidata skill`. The import hint no longer checks for the Claude Code plugin: the plugin only tells the agent to run `python -m rapidata skill`, which marks the session as read anyway. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
The skills repo now carries a static pointer to `python -m rapidata skill` and no longer syncs on SDK releases. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
…hange The repo's agent instructions move from CLAUDE.md to AGENTS.md so Codex and Cursor read them too; CLAUDE.md imports AGENTS.md. The new "Agent skill" section asks for a skill review with every change, matching the Agent Skill PR check. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
One spelling for agents and humans: `python -m rapidata skill` runs against the interpreter the caller uses, while the `rapidata` console script is only on PATH inside an activated environment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: lino@rapidata.ai <68745352+LinoGiger@users.noreply.github.com>
LinoGiger
marked this pull request as ready for review
September 29, 2026 08:57
LinoGiger
approved these changes
Sep 29, 2026
RapidPoseidon
deleted the
feat(agents)/per-session-hint-and-skill-freshness
branch
September 29, 2026 08:58
This was referenced Sep 29, 2026
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.
This PR makes the SDK the single source of truth for the Rapidata agent skill. The full skill now lives in
src/rapidata/_skill/, is edited only in this repo, and ships in every wheel.RapidataAI/skillsbecomes a short stub that tells agents to runpython -m rapidata skill(RapidataAI/skills#14).Follow-up to #904 and #909. This replaces #911's earlier design, which fetched the skill live from GitHub and checked freshness by content hash.
The skill moves into the SDK
src/rapidata/_skill/now holdsSKILL.md,reference.md,examples.mdandflows-for-preference-data.md, copied fromRapidataAI/skillsmain (SDK v3.25.9 content).raw.githubusercontent.comare replaced by commands such aspython -m rapidata skill reference.Command
python -m rapidata skill [main|reference|examples|flows-for-preference-data]prints the bundled copy. It uses no network.[project.scripts] rapidata = "rapidata.__main__:main"makes plainrapidata skillwork too.--installwrites the main guide for the chosen--agent, and records the SDK version in two places:metadata: { rapidata-sdk-version: "<version>" }. The import hint reads it from there, and only from there.rapidata.__version__and to run the exact--installcommand on a mismatch. An agent that loads the installed skill without importing the SDK still catches the drift.rapidata skill | headno longer raisesBrokenPipeError.Import hint
CLAUDE_CODE_SESSION_ID/CODEX_THREAD_ID/CODEX_SESSION_ID.~/.config/rapidata/agent-state.json, with a temp-dir fallback.--installed copy carries the current version. The Claude Code plugin check is gone: the plugin only tells the agent to runpython -m rapidata skill.…installed by rapidata X, but Y is installed. Update it with: python -m rapidata skill --install […]. This is a plain string compare againstrapidata.__version__, with no network.status/loginlines.RAPIDATA_AGENT_HINT=0is still the only override, and it is documented indocs/ai_agents.md, not in the hint.rapidataconsole script itself runs.Removed from the earlier #911
record_live_skill.release_and_publish.yml.sdk-releasedispatch to RapidataAI/skills, which now carries a static pointer and no longer syncs on releases. The dispatch token is scoped torapidata-mcponly.New
Agent Skillcheck (.github/workflows/agent-skill.yml+.github/scripts/agent-skill-check.js, modelled on rapidata-backend'sopenapi-diff.yml)src/rapidata/_skill/. That coversSKILL.mdand, deliberately, the companion guides next to it.skill-unchanged-approved. The label now exists in this repo.labeled/unlabeledre-evaluate the status in a separateackjob.synchronizestrips the label.openapi/**,src/rapidata/api_client/**andsrc/rapidata/api_client_README.md. This is a superset ofautomerge-openapi-client.yml's Guard 2, so the daily generator PR stays green.pyproject.toml/src/rapidata/__init__.pywhose commits are allBump version from X to Y.Agent Skillstill has to be added as a required status in branch protection. I can't change that setting.Docs
CLAUDE.mdto a rootAGENTS.md, so Codex and Cursor read them too.CLAUDE.mdis now@AGENTS.md. A new "Agent skill" section asks for a review ofsrc/rapidata/_skill/with every change. When no update is needed, the PR body should say so, so the reviewer can applyskill-unchanged-approved.docs/ai_agents.mdno longer mentions the plugin /npx skillsinstall. It starts frompip install -U rapidataandrapidata skill/--install.README.md,docs/ai_agents.md,src/rapidata/AGENTS.mdand the module docstrings now point atrapidata skill/python -m rapidata skill.src/rapidata/_skill/as the place to edit the skill.SKILL.mdin RapidataAI/skills are dropped.Rollout order: SDK versions ≤ 3.25.9 fetch
SKILL.mdfrom RapidataAI/skills main at runtime. The stub PR stays a draft until a release containing this PR is on PyPI.Verified
uv run --frozen python -m pytest -q: 324 passed.blackhas been run on the changed files.pyright1.1.396: 0 errors onsrc/rapidata/rapidata_client,__main__.py,_agent_hint.py,__init__.pyand the changed tests.uv build: the wheel containsrapidata/_skill/{SKILL,reference,examples,flows-for-preference-data}.mdand therapidataconsole script.rapidata skillprints the 930-line guide, andrapidata skill referenceprints the reference.rapidata skill, it is not hinted again.--install, the front matter carriesrapidata-sdk-version: "3.25.9"and the copy opens with the version check. A new session is silent.Agent Skillon this PR: success, "Agent skill updated in this PR."skill-unchanged-approved. Each event ran theAcknowledge label changejob, and both runs succeeded. The status stayed success because SKILL.md changed.pyproject.tomledit → failure🔗 Session: https://poseidon.rapidata.internal/chat/node-844bac89
🤖 Generated with Claude Code