PowerContext plugin

A long-term memory plugin and server for Claude Code and Codex: decisions and handoffs move between sessions and agents

  • 1,484 ★ on the repository
  • Last commit
  • Apache-2.0
Plugin

Broad access

Why this level

  • The hook reads every user prompt and sends it to the PowerContext server, where it is stored as a source
  • Writes hooks and MCP into Claude Code and Codex settings and changes the status line
  • In full memory mode texts go to external generation and embedding APIs, and the keys sit in the `.env` file
All reasons and checks

oceanbase/powercontext

Install

In your terminal, with SkillFoxx CLI

npx skillfoxx add plugins/powercontext

Detects the agents on your machine, shows the access level and pins the version.

Other ways to install

Access and checks

How we review

Broad accessThe tool can change data, run commands or handle secrets.

  • The hook reads every user prompt and sends it to the PowerContext server, where it is stored as a source
  • Writes hooks and MCP into Claude Code and Codex settings and changes the status line
  • In full memory mode texts go to external generation and embedding APIs, and the keys sit in the `.env` file

This is third-party code. Review the repository files before installing.

What it does

PowerContext is an open-source context service for AI agents from OceanBase. Its Claude Code and Codex plugin connects to a running PowerContext server and adds three things to a session. A `UserPromptSubmit` hook injects a size-limited prepared context into each request. The same hook saves the prompt text as a source by default. MCP tools let the agent write memory explicitly and hand work over. The server keeps four kinds of versioned records: memory (decisions, constraints, next steps), work handoff, experience and skills. Experience and skills wait in a review queue and take part in recall only after you approve them. An approved skill must still be exported separately and runs nothing by itself. The basic memory mode needs no model APIs: you ask the agent to save a decision and find it in a new session. The full memory mode extracts topics from sources automatically and needs separate generation and embedding credentials. You need Python 3.11 or newer, Git and uv. The server can also be deployed in Kubernetes with an external OceanBase.

Who it is for. For developers and teams who run one project across several sessions and agents, such as Codex and Claude Code, and want decisions and work state stored apart from chat history.

Good fit when

  • You start a new Claude Code session and do not want to re-explain earlier decisions, such as leaving the old auth module alone
  • Work moves from Codex to Claude Code or to a teammate, and you need a snapshot of the current state instead of the whole transcript
  • The agent's results and lessons must be reviewed and approved before the next tasks use them
  • You want context stored on your own server: SQLite is enough for a first run

Not a fit when

  • You need one note for one project: a rules file in the repository is enough without a separate server
  • Prompt text must never leave the machine, even for your own server: the hook saves every prompt as a source by default
  • You work on Windows and need stability: Windows support is marked experimental

Example request

Save a decision in PowerContext: manage dependencies with uv and keep settings in .env. Then prepare a handoff for the next session

Limitations

  • The plugin is a client: without a running PowerContext server it does nothing. Server and network errors do not block Claude Code.
  • Automatic topic extraction runs on a schedule and needs separate generation and embedding credentials. An agent subscription does not replace them.
  • The hook does not use `Stop` and does not save Claude's answer; only the user's prompt becomes a source.
  • In Codex you must open `/hooks` before the first message and trust the PowerContext hooks, or automatic capture and recall do not run.
  • Benchmark results reflect the author's setup. The project owner supplied six LoCoMo Plus scores, and public artifacts cannot verify them.

How to disable. Disable the plugin with `/plugin` in Claude Code and remove PowerContext entries from the MCP configuration. Stop the server with Ctrl+C in the terminal running `powercontext server run`. Collected data stays in the server storage you chose during setup.

FAQ

How do I install PowerContext in Claude Code?

Install and start the server first: `uv tool install --force "powercontext[cli,server]==1.4.1"`, then the wizard `powercontext config init`. After that `powercontext setup claude-code` connects the plugin and configures the Claude Code status line.

How is basic memory different from full memory?

Basic memory needs no model APIs: you explicitly ask the agent to save a decision and look it up in a new session. Full memory processes sources and builds topics automatically and needs separate generation and embedding credentials.

What does the plugin save from my prompts?

Only the current prompt text: by default the `UserPromptSubmit` hook saves it as a source. A Scope sets the data boundary, with its own source journal, memory and handoff history.

How does PowerContext differ from memory files inside an agent?

Records live on a server and any agent connected to the same Scope can read them, and each record has revisions and a reference like `FAMILY/ARTIFACT_ID@REVISION`. A memory file in one agent's folder stays behind when you switch agents.

Do I need a separate server?

Yes. The plugin is only a client. A local server with SQLite at `http://127.0.0.1:8000` is enough for a first run, and OceanBase can back a production setup.

Discussion

No questions or reviews yet.

Plugins

Knowledge-graph memory for agents: Claude Code and Codex plugins, an MCP server and a Python library

PluginExtended access33.1KRepository stars
Official

A Claude Code plugin that connects the agent to shared organizational memory with access control, audit and signed erasure

PluginBroad access319Repository stars

A plugin for Claude Code and Codex: a shared task wall, project memory, reports and a dashboard that shows agents' work across sessions

PluginBroad access374Repository stars

An MCP server that preserves Claude Code context between sessions: decisions, checkpoints and a file cache kept in local SQLite.

MCP serverExtended access136Repository stars

A long-term memory plugin that keeps decisions, preferences and task state across sessions and injects only what a query needs

PluginBroad access400Repository stars
Official

Skills and plugins that connect Claude Code, Cursor, Codex and other agents to Nowledge Mem long-term memory

SkillExtended access202Repository stars

Comparison with similar tools

Cards that share the main search query, and how they differ.

ToolOfficialAuthenticationRepository starsMain difference
PowerContext (this card)no1,484
Claude-Memno113,534automatic memory inside Claude Code, without a shared server for several agents or a review queue
Mem0no68,456a memory layer for AI apps, without work handoff between agents and people
MCP Memory Servicenonot required2,090an MCP server that stores memories, without record revisions or an experience approval queue

README in short

The README explains a three-layer model: protocol, built-in runtime, and server with integrations. It continues with sections on memory, handoff, experience and skills, a comparison with chat history and transcript search, benchmark numbers and a quick start with a setup wizard. It closes with Jupyter notebooks, some of which run without keys.

README badge

Report a problem

Foxx AIPowerContext
Foxx AI

I am Foxx AI and I have already vetted this tool. Ask about install, setup or anything else, and I will keep it simple.