Download for MacApple silicon, macOS 14+
Skill

implementing-agent-modes

@posthog Updated 2026-08-26

Guidelines to create/update a new mode for PostHog AI agent. Modes are a way to limit what tools, prompts, and prompt injections are applied and under what conditions. Achieve better results using your plan mode.

ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascript

Install

git clone https://github.com/PostHog/posthog /tmp/posthog && ln -s /tmp/posthog/.agents/skills/implementing-agent-modes ~/.claude/skills/implementing-agent-modes

From README

Agent modes Use the steps below to plan or implement a new mode. A mode is a way to manage the context of the agent and inject tools, prompts, and mode-related behavior relevant to a product, use case, JTBD, etc. The agent has the switchmode tool that allows it to switch itself to another mode, which might change tools, prompt, and executables, preserving the current context. Some previously created tools are contextual, meaning they're injected on particular pages of the frontend. The modes change the approach and always have tools in the mode context. Determine mode name Explore the ee/hogai/core/agentmodes/presets directory and check if there are already modes that match the user's intent. If you want to create a new mode, you should scope it by a PostHog product (Product analytics), product area (SQL), or agent (Instrumentation agent).