jimmc414

Claude Code System 3 Thinking — Development skill for Claude Code

Development community

Implementation of System 3 (meta-cognitive layer) from the Sophia paper as a Claude Code extension for persistent memory and self-improvement.

How to install Claude Code System 3 Thinking

This entry records only its repository, not the path inside it, so there is no exact command to give. Open jimmc414/claude-code-system-3-thinking and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Claude Code System 3 Thinking does

Implementation of System 3 (meta-cognitive layer) from the Sophia paper as a Claude Code extension for persistent memory and self-improvement.

Alternatives in Development

  • Hermes Agent Self Evolution — ⚒ Evolutionary self-improvement for Hermes Agent — optimize skills, prompts, and code using DSPy + GEPA 5.2k ★
  • Claude Supermemory — Persistent memory across sessions and projects using Supermemory 2.3k ★
  • /remember — Save a finding or successful pattern to persistent hunt memory 1.2k ★

README

Sophia System 3

A persistent memory and self-model layer for Claude Code, based on the Sophia research paper.

The Problem

Claude Code is stateless. Every session starts fresh with no memory of previous interactions. This means:

  • You repeat the same instructions across sessions
  • Claude makes the same mistakes it made last week
  • No learning or improvement over time
  • Preferences must be re-explained constantly
  • Each session is isolated from all others

What This Project Does

System 3 adds a persistence layer to Claude Code that maintains:

  • Episodic Memory: Records of past interactions, what worked, what failed
  • Self-Model: Claude's understanding of its own capabilities and limitations
  • Learned Heuristics: Lessons extracted from experience ("always check Docker daemon before deploying")
  • User Model: Remembered preferences and context about you

The result is a Claude Code that can reference past sessions, apply learned lessons, and improve over time.

How It Works

Claude Code already provides tool execution (System 1) and reasoning (System 2). This project adds System 3 as an extension layer using Claude Code's native mechanisms:

Claude Code (existing)
├── Tools: Bash, Read, Write, Edit, etc.
└── Reasoning: Native chain-of-thought

System 3 Extension (this project)
├── Hooks: Capture actions automatically
├── Skills: User commands for memory access
├── Agents: Background processing for reflection
└── Storage: Persistent files in ~/.sophia/

Components

**Hooks** (automatic, fast)

  • PreToolUse: Safety checks before tool execution
  • PostToolUse: Log actions to session buffer
  • Stop: Commit episode when session ends

**Skills** (user-invoked)

  • /s3-init: Set up the persistence layer
  • /s3-status: View self-model and capabilities
  • /s3-recall: Search past episodes
  • /s3-learn: Manually capture an insight
  • /s3-reflect: Trigger reflection on recent work

**Agents** (background processing)

  • s3-memory: