Agent SDK Version Bump
preset-io/agor
Upgrades a pinned agent SDK in the agor project, such as the Claude, Codex or Gemini CLI one, and plans the release that carries it to packaged installs.
Sync this fork of @anthropic-ai/claude-agent-acp (packages/agent/src/adapters/claude) with a newer upstream release: bump the claude-agent-sdk / @agentclientprotocol/sdk, port upstream bug fixes and…
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install PostHog/code upgrade-claude-adapter --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .claude/skills && cp -r skills-src/packages/agent/src/adapters/claude .claude/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .claude/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claudeType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install PostHog/code upgrade-claude-adapter --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .agents/skills && cp -r skills-src/packages/agent/src/adapters/claude .agents/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .agents/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install PostHog/code upgrade-claude-adapter --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/packages/agent/src/adapters/claude .cursor/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .cursor/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/PostHog/code.git --path packages/agent/src/adapters/claude--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install PostHog/code upgrade-claude-adapter --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/packages/agent/src/adapters/claude .gemini/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .gemini/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install PostHog/code upgrade-claude-adapterInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .github/skills && cp -r skills-src/packages/agent/src/adapters/claude .github/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .github/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add PostHog/code --skill upgrade-claude-adapter -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install PostHog/code upgrade-claude-adapter --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/PostHog/code.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/packages/agent/src/adapters/claude .opencode/skills/upgrade-claude-adapter && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "upgrade-claude-adapter" agent skill from https://github.com/PostHog/code/tree/main/packages/agent/src/adapters/claude into .opencode/skills/upgrade-claude-adapter/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "upgrade-claude-adapter", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
upgrade-claude-adapterSync this fork of @anthropic-ai/claude-agent-acp (packages/agent/src/adapters/claude) with a newer upstream release: bump the claude-agent-sdk / @agentclientprotocol/sdk, port upstream bug fixes and…
Upgrade Claude Adapter is an agent skill from PostHog/code, published by the product's own GitHub organization. Sync this fork of @anthropic-ai/claude-agent-acp (packages/agent/src/adapters/claude) with a newer upstream release: bump the claude-agent-sdk / @agentclientprotocol/sdk, port upstream bug fixes and new SDK message handling, preserve the fork's divergences, verify, and update UPSTREAM.md. Use when asked to "upgrade/sync the claude adapter", "bump the agent SDK", or "port upstream claude-agent-acp changes".
Its SKILL.md is about 2.5k tokens, which your agent loads only when the skill is triggered. The skill folder holds 59 other files (for example `UPSTREAM.md`, `claude-agent.finish.test.ts` and `claude-agent.permission-mode.test.ts`).
It sits in Development, covering Debugging and Building AI agents. It works with PostHog, Claude Agent SDK and Git. The repository describes itself as: The era of self-driving development is here. The licence is MIT.
8 steps, taken from the step headings in SKILL.md.
Read from SKILL.md and the folder at commit a4c32df. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Ships script files (TypeScript, from the files we listed), which the agent can run.
Shell commands in SKILL.md call:
pnpmgitnpmrgnpxnodeFrom the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md. Its commands use pnpm, git, npm and npx, which can reach the network depending on how they are called.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Upgrade Claude Adapter loads about 2.5k tokens when it runs. Until then it costs about 108 tokens; SKILL.md has 1,097 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from PostHog/code at commit a4c32df, republished under its MIT licence (© PostHog). 1,097 words, ~2,474 tokens.
.claude/skills/upgrade-claude-adapter/SKILL.md (or your agent's skills folder). This skill also uses 58 other files; get the full folder from GitHub.This is a runbook for syncing our fork of @anthropic-ai/claude-agent-acp (the upstream
Zed/agentclientprotocol ACP agent) that lives in packages/agent/src/adapters/claude/ with a newer
upstream release. The fork is heavily diverged. The job is to port the valuable upstream changes
(SDK bumps, bug fixes, new SDK-message handling) while preserving every intentional divergence — not
to make the fork identical to upstream.
UPSTREAM.md (this directory) is the source of truth for the fork point, last-synced
version/commit, the file mapping, the PostHog-only code, and the intentional
divergences. Read it first, update it last.
This file is a runbook, not an auto-registered slash command. Invoke it by telling Claude to "follow the upgrade skill in the claude adapter dir." Move it to
.claude/skills/<name>/SKILL.mdif you ever want it runnable as/<name>.
github.com/agentclientprotocol/claude-agent-acp.
You need its history to diff. If the user hasn't given the path, ask for it (it's usually
somewhere like ~/Cloud/claude-agent-acp). Do not guess.packages/agent/.UPSTREAM.md. Note Last sync (commit + version), the pinned SDK versions, the
File Mapping, PostHog-Only Code (Do Not Sync), and Intentional Divergences.git -C <upstream> log --oneline <last-sync-sha>..HEADgit -C <upstream> show <upstream>/CHANGELOG.md:CHANGELOG.md (or just read CHANGELOG.md)package.json.Bucket each commit since the last sync:
chore(main): release …, actions/* CI bumps, pure dependabot dev-dep bumps, and
anything matching the PostHog-only / divergence lists.Read intent from source diffs (exclude tests + JSON first):
git -C <upstream> show <sha> -- src/ ':(exclude)src/tests/*' ':(exclude)*.json'A dependabot SDK-bump commit often also carries real code (new message handling). Don't assume "deps" == "no code".
Upstream is one large src/acp-agent.ts; our fork is split. Use the File Mapping in UPSTREAM.md.
Rough guide:
| Upstream | Fork |
|---|---|
acp-agent.ts prompt loop, lifecycle, cancel | claude-agent.ts |
| inline message/stream/result/system conversion | conversion/sdk-to-acp.ts |
| inline prompt→SDK conversion | conversion/acp-to-sdk.ts |
tools.ts (tool_use→ACP, PostToolUse hook) | conversion/tool-use-to-acp.ts, hooks.ts |
| model alias resolution | session/models.ts, session/model-config.ts |
| options / system prompt | session/options.ts |
| permissions | permissions/* |
For each upstream change, rg the fork for the touched symbol first — the fork usually already has a
diverged version of it, so you're editing, not adding.
In packages/agent/package.json, set @anthropic-ai/claude-agent-sdk, @agentclientprotocol/sdk,
and @anthropic-ai/sdk to the upstream package.json versions, then pnpm install from the repo
root. (packages/shared pins its own older @agentclientprotocol/sdk; leave it unless a
cross-package type error forces a bump.)
Run pnpm --filter agent typecheck. The errors are your ACP/SDK breaking-change list. Gotchas seen
in past syncs:
dist/schema/*.gen.d.ts shows enum literals as
n (e.g. StopReason = "…" | "n" | "cancelled"). Don't trust grep there. Read the hand-written
dist/acp.d.ts, or download the exact target to inspect cleanly:cd /tmp && npm pack @agentclientprotocol/sdk@<ver> && tar xzf *.tgz
rg -n "type StopReason|deleteSession|SessionModelState" package/dist/schema/types.gen.d.ts package/dist/acp.d.tsnode -e "require('<pkg>/package.json')" may fail on the SDKs (exports map blocks the subpath).
Read node_modules/<pkg>/package.json directly for the installed version.packages/agent package
must typecheck — expect to also fix adapters/codex/* and server/agent-server.ts. Keep those
fixes minimal and behavior-preserving (e.g. when ACP removed the models response field, the codex
adapter derived the model id from configOptions instead).For each ported change:
UPSTREAM.md → Intentional Divergences + PostHog-only). The big ones:
single-session this.session (not this.sessions[id]); interruptReason on cancel; gateway models
via fetchGatewayModels (not initializationResult.models); _posthog/* ext notifications;
the "Unsupported slash command" gate on knownSlashCommands; SYSTEM_REMINDER stripping; plan /
questions / MCP-metadata machinery.system subtypes are safe by default. handleSystemMessage ends in default: break,
and the prompt-loop top-level switch (message.type) only unreachable()s unknown top-level
types. So a new subtype won't crash the loop — port real handling only where there's user value
(e.g. permission_denied → failed tool_call, tool_progress → in_progress, commands_changed →
available_commands_update, mirror_error → log).stop_details, getContextUsage, thinking), confirm the
installed SDK .d.ts actually has them before porting. Skip ports the fork can't use (e.g. the
fork doesn't read MAX_THINKING_TOKENS, so upstream's resolveThinkingConfig was N/A).pnpm --filter agent typecheck
pnpm --filter agent build
npx biome check --write <changed files> # biome is the formatter/linter, not prettier/eslint
pnpm typecheck # whole repo: confirms apps/code compiles vs the new ACP SDK
pnpm --filter agent test
pnpm --filter code testapps/code renderer unit tests analytics.test.ts and panelLayoutStore.test.ts are flaky
— they sometimes throw in getElectronTRPC / electron-trpc ipcLink depending on test ordering. If
they fail, re-run; a clean rerun (or git stash + run on the clean tree) passing confirms it's the
known flake, not your change.UPSTREAM.md (do this last)## Changes Ported in v<X> Sync (one bullet per change, with PR # and short sha) and
## Skipped in v<X> Sync (with the reason for each skip).this.session (from BaseAcpAgent), not a sessions map.
Upstream's per-session refactors usually collapse to "just use this.session".prompt()
enqueues a Turn deferred; runConsumer drains the query stream for the session's life, settles
turns at their terminal result, and captures query + session.queryGeneration so the
fork-only refreshSession() can retire it (bump generation → abort wake-up → end input). Steer
mode, interruptReason, per-turn broadcast-at-activation and the unsupported-slash-command gate
all live inside it — port upstream prompt-loop changes into the consumer, not a per-prompt loop.AgentSideConnection/ClientSideConnection (still shipped in ACP 1.x) because they carry the
extMethod/extNotification surface _posthog/* uses; permission requests reach the client via
the class's generic request(..., { cancellationSignal }). Don't port the agent() builder
without a plan for the extension surface.SessionConfigOption end to
end; the renderer never reads the legacy models response field or calls unstable_setSessionModel.
That's why upstream's ACP-0.24/0.25 model-state removals are safe to follow.toolUseCache is never cleared in the fork (created once in the constructor), so long sessions
accumulate — keep the prune-at-tool_result behavior, and make any PostToolUse hook close over the
data it needs rather than re-reading the cache.claude-agent.ts calls handleSystemMessage / handleStreamEvent /
handleResultMessage / handleUserAssistantMessage from conversion/sdk-to-acp.ts. Upstream
inlines all of this in acp-agent.ts.© PostHog, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 58 other files in packages/agent/src/adapters/claude of PostHog/code.
Open the folder on GitHubat commit a4c32df
We found 2 copies of this SKILL.md (exact, near-identical or edited) in other folders. This page covers the copy in PostHog/code, which our catalogue first saw on October 7, 2026.
Upgrade Claude Adapter next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Upgrade Claude Adapter this skillPostHog/code | 179 | — | ~2.5k | Automated safety check: Pass | MIT | |
| Agent SDK Version Bumppreset-io/agor | 1.4k | — | ~1.4k | Automated safety check: Pass | Custom licence | |
| Debugging and Error Recoveryaddyosmani/agent-skills | 103k | 1 repos | ~2.6k | Automated safety check: Pass | MIT | |
| Git History Bug Auditben-manes/caffeine | 18k | — | ~3.3k | Automated safety check: Pass | Apache-2.0 | |
| Leon Coding Agentleon-ai/leon | 18k | — | ~1.1k | Automated safety check: Pass | MIT | |
| Adk Setupgoogle/adk-python | 22k | — | ~993 | Automated safety check: Notes | Apache-2.0 |
preset-io/agor
Upgrades a pinned agent SDK in the agor project, such as the Claude, Codex or Gemini CLI one, and plans the release that carries it to packaged installs.
addyosmani/agent-skills
Applies a stop-the-line rule and a step-by-step triage when tests fail, builds break or something stops working, aiming at the root cause instead of guesses.
ben-manes/caffeine
Audits a module by walking its git history commit by commit, tracking unresolved issues forward, and reporting the ones that survive to HEAD as findings.
leon-ai/leon
Has Leon's agent investigate, change and verify code in a repository with its file, search and shell tools, staying inside the scope the owner authorized.
google/adk-python
Sets up a local ADK Python development environment in a git clone of the open-source adk-python repository: a uv virtual environment, all dependency extras, pre-commit hooks, and a first unit-test…
trasta298/keifu
Drive and debug the real keifu TUI autonomously via its remote-control debug server (--debug-listen) — launch headlessly, inject keys/mouse, dump the rendered screen as text, and inspect app state.
PostHog/code
How PostHog "canvas" dashboards work end-to-end — the two rendering tiers (json-render vs freeform React-in-iframe), the agent system prompts that steer each, and the RIGHT way to fetch PostHog data…
PostHog/code
How to write JavaScript workflow scripts for the workflow tool - fanning work out across many isolated subagents with agent(), parallel(), and pipeline(), then synthesizing one result.
PostHog/code
Install, configure, authenticate, and troubleshoot MCP (Model Context Protocol) servers for this agent.
PostHog/code
Merge a PR into main through the Trunk merge queue and babysit it until it lands.
PostHog/code
Add, replace, and optimize the looping demo videos in the onboarding "welcome" bento grid (packages/ui/src/features/onboarding).
PostHog/code
Edit the @posthog/quill design system locally and consume the change in this repo (posthog-code) before it is published to npm.
Works with
Categories
Sync this fork of @anthropic-ai/claude-agent-acp (packages/agent/src/adapters/claude) with a newer upstream release: bump the claude-agent-sdk / @agentclientprotocol/sdk, port upstream bug fixes and…. Upgrade Claude Adapter is an agent skill from PostHog/code, published by the product's own GitHub organization.md.
Upgrade Claude Adapter fits situations like: asked to upgrade/sync the claude adapter; bump the agent SDK; port upstream claude-agent-acp changes.
Run `npx skills add PostHog/code --skill upgrade-claude-adapter -a claude-code`. Or copy the skill folder (packages/agent/src/adapters/claude in PostHog/code) into .claude/skills/upgrade-claude-adapter in your project. Claude Code loads it when a task matches its description.
Run `npx skills add PostHog/code --skill upgrade-claude-adapter -a codex`. Or copy the skill folder (packages/agent/src/adapters/claude in PostHog/code) into .agents/skills/upgrade-claude-adapter in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add PostHog/code --skill upgrade-claude-adapter -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/upgrade-claude-adapter, .gemini/skills/upgrade-claude-adapter, .github/skills/upgrade-claude-adapter and .opencode/skills/upgrade-claude-adapter in your project.
Going by SKILL.md and its folder, Upgrade Claude Adapter needs TypeScript for the scripts in its folder and the command-line tools its instructions call (pnpm, git, npm, rg, npx and node). Our summary lists: Node.js.
SKILL.md contains no URLs. Its commands use git, npm and npx, which can reach the network depending on how they are called. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Upgrade Claude Adapter is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.5k tokens (SKILL.md is roughly 9.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with Upgrade Claude Adapter: Agent SDK Version Bump (preset-io/agor, 1.4k stars), Debugging and Error Recovery (addyosmani/agent-skills, 103k stars), Git History Bug Audit (ben-manes/caffeine, 18k stars) and Leon Coding Agent (leon-ai/leon, 18k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
PostHog (a GitHub organization, an official publisher) maintains it in PostHog/code, which has 179 GitHub stars. The repository holds 10 skills in this directory. The repository was last updated on August 5, 2026.
Source: PostHog/code on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.