Skip to main content
Connectors
Coding Agent
OpenCode

OpenCode

Native OpenCode plugin with Context Bundle, Working Memory, search/save tools, idle-event automatic thread capture, pre-compaction flush, handoff, and status.

Start with the setup prompt or connection guide. Open the guide for detailed steps.

Agent shortcut

Ask your agent to set it up

Copy the setup prompt. Your agent will open this guide, use the recommended path, and verify the setup.

Install

Install the plugin:

Check opencode --version first. On OpenCode 1.x, install globally with:

Command
opencode plugin opencode-nowledge-mem@0.3.10 --global

On OpenCode 2.x, this command manages the global installation:

Command
opencode plugin add opencode-nowledge-mem

Restart OpenCode to load the plugin.

What You Get

Nine tools registered directly in OpenCode, plus an idle-event hook that saves the current session as a Mem thread after OpenCode finishes a turn:

Tool What it does
nowledge_mem_context_bundle Loads startup context: identity, active space, Rules, Working Memory, and KFS paths
nowledge_mem_working_memory Loads your daily briefing: focus areas, priorities, recent changes
nowledge_mem_search Searches past decisions and procedures, with label and deep mode filters
nowledge_mem_save Saves decisions, insights, and procedures as durable memories
nowledge_mem_update Updates an existing memory with refined information
nowledge_mem_thread_search Searches past conversations from any tool
nowledge_mem_save_thread Saves the full session as a conversation thread on demand
nowledge_mem_save_handoff Creates a resumable session handoff summary
nowledge_mem_status Checks Nowledge Mem server connectivity

Behavioral guidance is injected into the system prompt automatically. New OpenCode sessions are captured through the plugin when OpenCode reports idle, and long sessions flush before compaction.

Remote Mode

Configure this machine once:

Command
nmem config client set url https://your-server
nmem config client set api-key your-key

The plugin uses that shared client config for memory tools, idle-event thread capture, manual nowledge_mem_save_thread, and historical nmem t sync.

Import Older Sessions

Command
nmem t sync --from opencode --all-projects --limit 20
nmem t sync --from opencode --all-projects --apply

Use -p /path/to/project instead of --all-projects when you only want one project.

More Coding Agent Connectors