Openclaw

From AndreaGriffiths11/agent-context-system · View interactive version

Openclaw is an AI agent skill from the GitHub repository AndreaGriffiths11/agent-context-system. Bootstrap persistent project context for AI coding agents.

How to use this skill

Skill file

Agent Context System

Agents start from zero every session. This skill fixes that.

The Two-File System

Quick Start

# Clone into your OpenClaw skills directory
git clone https://github.com/AndreaGriffiths11/agent-context-system.git skills/agent-context-system

# Initialize in your project
agent-context init

All files (CLI, templates, docs) are included in the repo. No external downloads.

Commands

agent-context init      # Set up context system in current project
agent-context validate  # Check setup is correct
agent-context promote   # Find patterns to move from scratchpad to AGENTS.md

Workflow

  1. Init: Run agent-context init. Creates .agents.local.md, ensures it's gitignored, creates CLAUDE.md symlink (Claude Code reads CLAUDE.md, not AGENTS.md — the symlink lets you maintain one file).
  1. Work: Read both files at session start. AGENTS.md = project knowledge. .agents.local.md = personal learnings.
  1. Log: At session end, propose a session log entry to the user (see Session Protocol below).
  1. Compress: When scratchpad hits 300 lines, compress: dedupe, merge related entries.
  1. Promote: Patterns recurring across 3+ sessions get flagged. Run agent-context promote to see candidates. You decide what moves to AGENTS.md.

Key Resources

Important Context

Session Protocol

  1. Read AGENTS.md and .agents.local.md before starting any task
  2. Follow project conventions and boundaries
  3. At session end, propose the log entry to the user before writing. Do not append directly. Use this format:
### YYYY-MM-DD — Topic

- **Done:** (what changed)
- **Worked:** (reuse this)
- **Didn't work:** (avoid this)
- **Decided:** (choices and reasoning)
- **Learned:** (new patterns)
  1. Wait for user approval before appending to .agents.local.md
  2. When scratchpad exceeds 300 lines, compress and flag recurring patterns for promotion

Security

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.