Give your coding agent the knowledge to work with Memrail: policy design, SDK integration, decision topology, and production workflows. Choose the agent you already use. You do not need a Memrail account or API key to install the skill.
Ask your agent to install it#
Copy this request and paste it into Codex, Claude Code, or OpenCode:
Read https://docs.memrail.com/agents/install-skill.md and install the complete Memrail skill for the coding agent I am using. Install only the skill, preserve any existing copy, and verify that SKILL.md and its references are available. Do not install the SDK or change this project.
The agent installation link is plain Markdown with the steps and verification checks. Your agent needs permission to fetch the source and write its skill directory; approve those actions when prompted. If it cannot access the internet or install files, use the terminal method below.
Install from your terminal#
On macOS, Linux, or inside WSL, run:
curl -fsSL https://docs.memrail.com/install.sh | sh
This installs only the skill. It checks for the codex, claude, and opencode commands or their usual configuration directories. When exactly one is detected, it selects that agent. When none or several are detected, it stops without downloading the skill or changing files and shows how to choose. Detection is a convenience, not proof of which client you prefer.
Choose your agent explicitly#
Codex
curl -fsSL https://docs.memrail.com/install.sh | sh -s -- --agent codex
Claude Code
curl -fsSL https://docs.memrail.com/install.sh | sh -s -- --agent claude
OpenCode
curl -fsSL https://docs.memrail.com/install.sh | sh -s -- --agent opencode
The client does not have to be running. The script copies the complete portable skill from the official Memrail repository, including its references. It does not install the full Claude plugin, configure credentials, edit project files, or register policies.
Review before running#
A shell installer executes code with your user permissions. To inspect it and preview the destination first, download it to a fresh temporary directory:
memrail_setup="$(mktemp -d)"
curl -fsSL https://docs.memrail.com/install.sh -o "$memrail_setup/install.sh"
less "$memrail_setup/install.sh"
sh "$memrail_setup/install.sh" --agent codex --dry-run
sh "$memrail_setup/install.sh" --agent codex
Replace codex with your choice. --dry-run makes no writes or downloads. The installer pins the skill to a specific repository commit and verifies its archive's SHA-256 before extracting it. This protects against a mismatched download; review the installer itself before trusting it.
Where does the skill go?#
Installation is user-level, available across projects:
| Agent | Default skill directory | Client documentation |
|---|---|---|
| Codex | ~/.agents/skills/memrail/ |
Codex skills |
| Claude Code | ~/.claude/skills/memrail/ |
Claude Code skills |
| OpenCode | ~/.config/opencode/skills/memrail/ |
OpenCode skills |
These are native skill locations; no plugin conversion is needed. OpenCode also discovers shared .agents/skills and .claude/skills locations, so you may already have access after installing for another client. Check before making duplicate copies. OpenCode discovery
For Claude Code, the installer honors CLAUDE_CONFIG_DIR. For another configured location, a repository-scoped install, or an older client using a different path, pass an absolute skills parent directory:
curl -fsSL https://docs.memrail.com/install.sh | sh -s -- --dir "$PWD/.agents/skills"
This writes .agents/skills/memrail in the current repository; use it only when you want project files added. For native Windows shells, use the agent-assisted path or manually copy the complete skills/memrail folder from the repository to your client's documented skill location.
Advanced overrides: MEMRAIL_CODEX_SKILLS_DIR, MEMRAIL_CLAUDE_SKILLS_DIR, and MEMRAIL_OPENCODE_SKILLS_DIR set per-client parents; AGENT_SKILLS_DIR is a fallback for Codex. --dir takes precedence. MEMRAIL_INSTALL_HOME changes the installer's default user-directory root, useful for isolated testing; it does not reconfigure your agent.
Install the Python SDK too#
The skill teaches your coding agent; the SDK is a dependency of your application. To install both in one command, activate your project's Python 3.9+ virtualenv first:
curl -fsSL https://docs.memrail.com/install.sh | sh -s -- --agent codex --with-sdk
Substitute claude or opencode, or omit --agent for single-agent detection. The SDK option requires an active virtualenv and installs memrail with that environment's pip, or uv pip targeting the same Python. It does not create an environment, modify a lockfile, or use system Python. Add the dependency through your existing package manager when your project manages a manifest or lockfile. See Start from scratch or Python SDK.
For TypeScript, install the skill alone and follow the TypeScript SDK guide.
Verify and start using it#
Ask your agent:
Use the memrail skill. Confirm its installed location and list the reference files you can read. Do not change anything else.
A complete installation has SKILL.md and references/; copying just SKILL.md is not sufficient. Reload or restart your agent if the new skill is not discovered. Check the client's skill permissions if access is denied.
Then give it a bounded first task:
Use the memrail skill to audit this repository's decision topology.
Map consequential decisions, hidden model authority, context sources,
event gaps, and action executors. Return a prioritized report.
Do not edit files, install dependencies, register EMUs, or change external state.
See Audit decision topology for the full workflow.
Update, replace, or remove#
An existing memrail directory or symlink stops the installer before download. Review local modifications before repeating your command with --replace. The old copy is moved under ~/.local/state/memrail/skill-backups/, outside the usual skill-discovery directories; the installer prints its exact path. A failed SDK installation can leave a successfully installed skill in place, and is reported separately.
Older installations may have copies in more than one client directory. Check those separately: this installer does not delete or relocate other copies. To remove the skill, remove only the installed memrail directory after reviewing any local edits. If you opted into the SDK, uninstall it through the same project environment or dependency manager. Neither operation removes Memrail policy, events, credentials, or application integration.
Need the full Claude plugin?#
The Claude plugin repository also includes specialized topology, architecture, implementation, and validation agents. The portable skill is enough for Memrail guidance across clients; use the full plugin only when you want its Claude-specific orchestration:
git clone https://github.com/cadenzai/memrail-claude-plugin.git
claude --plugin-dir ./memrail-claude-plugin
Guidance for agent implementers#
When the skill is active, use the integration invariants as the shared contract, with these implementation conventions:
- detect Python or TypeScript SDK usage before proposing code;
- use
decide(context=...)ordecide({ context: [...] }); - write modern dot-notation triggers with uppercase operators;
- verify trigger reachability before designing an EMU;
- enforce same-project tool availability in the application's deployment and execution contract; registration alone is not a runtime authorization guarantee;
- use JSONL pull/plan/apply for production writes;
- start consequential policies in shadow, with diagnostics separate from live arbitration;
- validate model tags against fixed taxonomies at runtime and preserve their provenance;
- never treat a model proposal as a safe fallback when control evaluation fails;
- use named
decision_pointbindings and preserve the reviewed execution boundary.
Follow the production workflow for validation, lifecycle changes, and application-controlled rollout.