Logo Continuous Claude

Continuous Claude

Cộng đồngPhổ biến
parcadei

Context management for Claude Code. Hooks maintain state via ledgers and handoffs. MCP execution without context pollution. Agent orchestration with isolated context windows.

Nhà phát hànhparcadei
Kho mãContinuous-Claude-v3
Ngôn ngữPython
Bản fork
303
Sao
3.9K
Công cụ có sẵn
0
Phương thức truyền tảistdio
Danh mục
Giấy phépMIT
Liên kết
  • Kết nối công cụ với quy trình làm việc AI

    Continuous Claude cung cấp các khả năng MCP mà ứng dụng khách và tác nhân AI tương thích có thể sử dụng.

  • 0 công cụ có sẵn

    Xem các thao tác có thể gọi bên dưới, kèm tên và mô tả nếu máy chủ cung cấp.

  • Cấu hình sẵn để sao chép

    Dùng các đoạn cấu hình cài đặt mẫu để thiết lập máy chủ này trong ứng dụng khách MCP bạn muốn dùng.

  • Chỉ số quan tâm đến mã nguồn mở

    3.9K sao và 303 bản fork từ kho mã được liên kết.

Continuous Claude

A persistent, learning, multi-agent development environment built on Claude Code

License: MIT Claude Code Skills Agents Hooks

Continuous Claude transforms Claude Code into a continuously learning system that maintains context across sessions, orchestrates specialized agents, and eliminates wasting tokens through intelligent code analysis.

Table of Contents


Why Continuous Claude?

Claude Code has a compaction problem: when context fills up, the system compacts your conversation, losing nuanced understanding and decisions made during the session.

Continuous Claude solves this with:

ProblemSolution
Context loss on compactionYAML handoffs - more token-efficient transfer
Starting fresh each sessionMemory system recalls + daemon auto-extracts learnings
Reading entire files burns tokens5-layer code analysis + semantic index
Complex tasks need coordinationMeta-skills orchestrate agent workflows
Repeating workflows manually109 skills with natural language triggers

The mantra: Compound, don't compact. Extract learnings automatically, then start fresh with full context.

Why "Continuous"? Why "Compounding"?

The name is a pun. Continuous because Claude maintains state across sessions. Compounding because each session makes the system smarter—learnings accumulate like compound interest.


Design Principles

An agent is five things: Prompt + Tools + Context + Memory + Model.

ComponentWhat We Optimize
PromptSkills inject relevant context; hooks add system reminders
ToolsTLDR reduces tokens; agents parallelize work
ContextNot just what Claude knows, but how it's provided
MemoryDaemon extracts learnings; recall surfaces them
ModelBecomes swappable when the other four are solid

Anti-Complexity

We resist plugin sprawl. Every MCP, subscription, and tool you add promises improvement but risks breaking context, tools, or prompts through clashes.

Our approach:

  • Time, not money — No required paid services. Perplexity and NIA are optional, high-value-per-token.
  • Learn, don't accumulate — A system that learns handles edge cases better than one that collects plugins.
  • Shift-left validation — Hooks run pyright/ruff after edits, catching errors before tests.

The failure modes of complex systems are structurally invisible until they happen. A learning, context-efficient system doesn't prevent all failures—but it recovers and improves.


How to Talk to Claude

You don't need to memorize slash commands. Just describe what you want naturally.

The Skill Activation System

When you send a message, a hook injects context that tells Claude which skills and agents are relevant. Claude infers from a rule-based system and decides which tools to use.

> "Fix the login bug in auth.py"

🎯 SKILL ACTIVATION CHECK
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

⚠️ CRITICAL SKILLS (REQUIRED):
  → create_handoff

📚 RECOMMENDED SKILLS:
  → fix
  → debug

🤖 RECOMMENDED AGENTS (token-efficient):
  → debug-agent
  → scout

ACTION: Use Skill tool BEFORE responding
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Priority Levels

LevelMeaning
⚠️ CRITICALMust use (e.g., handoffs before ending session)
📚 RECOMMENDEDShould use (e.g., workflow skills)
💡 SUGGESTEDConsider using (e.g., optimization tools)
📌 OPTIONALNice to have (e.g., documentation helpers)

Natural Language Examples

What You SayWhat Activates
"Fix the broken login"/fix workflow → debug-agent, scout
"Build a user dashboard"/build workflow → plan-agent, kraken
"I want to understand this codebase"/explore + scout agent
"What could go wrong with this plan?"/premortem
"Help me figure out what I need"/discovery-interview
"Done for today"create_handoff (critical)
"Resume where we left off"resume_handoff
"Research auth patterns"oracle agent + perplexity
"Find all usages of this API"scout agent + ast-grep

Why This Approach?

BenefitHow
More DiscoverableDon't need to know commands exist
Context-AwareSystem knows when you're 90% through context
Reduces Cognitive LoadDescribe intent naturally, get curated suggestions
Power User FriendlyStill supports /fix, /build, etc. directly

Skill vs Workflow vs Agent

TypePurposeExample
SkillSingle-purpose toolcommit, tldr-code, qlty-check
WorkflowMulti-step process/fix (sleuth → premortem → kraken → commit)
AgentSpecialized sub-sessionscout (exploration), oracle (research)

See detailed skill activation docs →


Quick Start

Prerequisites

  • Python 3.11+
  • uv package manager
  • Docker (for PostgreSQL)
  • Claude Code CLI

Installation

bash
# Clone
git clone https://github.com/parcadei/Continuous-Claude-v3.git
cd Continuous-Claude-v3/opc

# Run setup wizard (12 steps)
uv run python -m scripts.setup.wizard

Note: The pyproject.toml is in opc/. Always run uv commands from the opc/ directory.

What the Wizard Does

StepWhat It Does
1Backup existing .claude/ config (if present)
2Check prerequisites (Docker, Python, uv)
3-5Database + API key configuration
6-7Start Docker stack, run migrations
8Install Claude Code integration (32 agents, 109 skills, 30 hooks)
9Math features (SymPy, Z3, Pint - optional)
10TLDR code analysis tool
11-12Diagnostics tools + Loogle (optional)

To Uninstall:

cd Continuous-Claude-v3/opc
  uv run python -m scripts.setup.wizard --uninstall

What it does

  1. Archives your current setup → Moves ~/.claude to ~/.claude-v3.archived.
  2. Restores your backup → Finds the most recent ~/.claude.backup.* (created during install) and restores it
  3. Preserves user data → Copies these back from the archive:
  • history.jsonl (your command history)
  • mcp_config.json (MCP servers)
  • .env (API keys)
  • projects.json (project configs)
  • file-history/ directory
  • projects/ directory
  1. Removes CC-v3 additions → Everything else (hooks, skills, agents, rules)

Safety Features

  • Your current setup is archived with timestamp - nothing gets deleted
  • The wizard asks for confirmation before proceeding
  • It restores from the backup that was made during installation
  • All your Claude Code settings stay intact

Remote Database Setup

By default, CC-v3 runs PostgreSQL locally via Docker. For remote database setups:

1. Database Preparation

bash
# Connect to your remote PostgreSQL instance
psql -h hostname -U user -d continuous_claude

# Enable pgvector extension (requires superuser or rds_superuser)
CREATE EXTENSION IF NOT EXISTS vector;

# Apply the schema (from your local clone)
psql -h hostname -U user -d continuous_claude -f docker/init-schema.sql

Managed PostgreSQL tips:

  • AWS RDS: Add vector to shared_preload_libraries in DB Parameter Group
  • Supabase: Enable via Database Extensions page
  • Azure Database: Use Extensions pane to enable pgvector

2. Connection Configuration

Set CONTINUOUS_CLAUDE_DB_URL in ~/.claude/settings.json:

json
{
  "env": {
    "CONTINUOUS_CLAUDE_DB_URL": "postgresql://user:password@hostname:5432/continuous_claude"
  }
}

Or export before running Claude:

bash
export CONTINUOUS_CLAUDE_DB_URL="postgresql://user:password@hostname:5432/continuous_claude"
claude

See .env.example for all available environment variables.

First Session

bash
# Start Claude Code
claude

# Try a workflow
> /workflow

First Session Commands

CommandWhat it does
/workflowGoal-based routing (Research/Plan/Build/Fix)
/fix bug <description>Investigate and fix a bug
/build greenfield <feature>Build a new feature from scratch
/exploreUnderstand the codebase
/premortemRisk analysis before implementation

Architecture

┌─────────────────────────────────────────────────────────────────────┐
│                        CONTINUOUS CLAUDE                            │
├─────────────────────────────────────────────────────────────────────┤
│                                                                     │
│  ┌─────────────┐    ┌─────────────┐    ┌─────────────┐             │
│  │   Skills    │    │   Agents    │    │    Hooks    │             │
│  │   (109)     │───▶│    (32)     │◀───│    (30)     │             │
│  └─────────────┘    └─────────────┘    └─────────────┘             │
│         │                  │                  │                     │
│         ▼                  ▼                  ▼                     │
│  ┌─────────────────────────────────────────────────────────────┐   │
│  │                     TLDR Code Analysis                       │   │
│  │   L1:AST → L2:CallGraph → L3:CFG → L4:DFG → L5:Slicing      │   │
│  │                    (95% token savings)                       │   │
│  └─────────────────────────────────────────────────────────────┘   │
│         │                  │                  │                     │
│         ▼                  ▼                  ▼                     │
│  ┌─────────────┐    ┌─────────────┐    ┌─────────────┐             │
│  │   Memory    │    │ Continuity  │    │ Coordination│             │
│  │   System    │    │   Ledgers   │    │    Layer    │             │
│  └─────────────┘    └─────────────┘    └─────────────┘             │
│                                                                     │
└─────────────────────────────────────────────────────────────────────┘

Data Flow: Session Lifecycle

SessionStart                    Working                      SessionEnd
    │                              │                             │
    ▼                              ▼                             ▼
┌─────────┐                  ┌─────────┐                   ┌─────────┐
│  Load   │                  │  Track  │                   │  Save   │
│ context │─────────────────▶│ changes │──────────────────▶│  state  │
└─────────┘                  └─────────┘                   └─────────┘
    │                              │                             │
    ├── Continuity ledger          ├── File claims               ├── Handoff
    ├── Memory recall              ├── TLDR indexing             ├── Learnings
    └── Symbol index               └── Blackboard                └── Outcome
                                         │
                                         ▼
                                    ┌─────────┐
                                    │ /clear  │
                                    │ Fresh   │
                                    │ context │
                                    └─────────┘

The Continuity Loop (Detailed)

┌─────────────────────────────────────────────────────────────────────────────┐
│                            THE CONTINUITY LOOP                              │
└─────────────────────────────────────────────────────────────────────────────┘

  1. SESSION START                     2. WORKING
  ┌────────────────────┐               ┌────────────────────┐
  │                    │               │                    │
  │  Ledger loaded ────┼──▶ Context    │  PostToolUse ──────┼──▶ Index handoffs
  │  Handoff loaded    │               │  UserPrompt ───────┼──▶ Skill hints
  │  Memory recalled   │               │  Edit tracking ────┼──▶ Dirty flag++
  │  TLDR cache warmed │               │  SubagentStop ─────┼──▶ Agent reports
  │                    │               │                    │
  └────────────────────┘               └────────────────────┘
           │                                    │
           │                                    ▼
           │                           ┌────────────────────┐
           │                           │ 3. PRE-COMPACT     │
           │                           │                    │
           │                           │  Auto-handoff ─────┼──▶ thoughts/shared/
           │                           │  (YAML format)     │    handoffs/*.yaml
           │                           │  Dirty > 20? ──────┼──▶ TLDR re-index
           │                           │                    │
           │                           └────────────────────┘
           │                                    │
           │                                    ▼
           │                           ┌────────────────────┐
           │                           │ 4. SESSION END     │
           │                           │                    │
           │                           │  Stale heartbeat ──┼──▶ Daemon wakes
           │                           │  Daemon spawns ────┼──▶ Headless Claude
           │                           │  Thinking blocks ──┼──▶ archival_memory
           │                           │                    │
           │                           └────────────────────┘
           │                                    │
           │                                    │
           └──────────────◀────── /clear ◀──────┘
                          Fresh context + state preserved

Workflow Chains

┌─────────────────────────────────────────────────────────────────────────────┐
│                           META-SKILL WORKFLOWS                              │
└─────────────────────────────────────────────────────────────────────────────┘

  /fix bug                              /build greenfield
  ─────────                             ─────────────────
  ┌──────────┐  ┌──────────┐            ┌──────────┐  ┌──────────┐
  │  sleuth  │─▶│ premortem│            │discovery │─▶│plan-agent│
  │(diagnose)│  │  (risk)  │            │(clarify) │  │ (design) │
  └──────────┘  └────┬─────┘            └──────────┘  └────┬─────┘
                     │                                      │
                     ▼                                      ▼
              ┌──────────┐                          ┌──────────┐
              │  kraken  │                          │ validate │
              │  (fix)   │                          │ (check)  │
              └────┬─────┘                          └────┬─────┘
                   │                                      │
                   ▼                                      ▼
              ┌──────────┐                          ┌──────────┐
              │  arbiter │                          │  kraken  │
              │ (test)   │                          │(implement│
              └────┬─────┘                          └────┬─────┘
                   │                                      │
                   ▼                                      ▼
              ┌──────────┐                          ┌──────────┐
              │  commit  │                          │  commit  │
              └──────────┘                          └──────────┘


  /tdd                                  /refactor
  ────                                  ─────────
  ┌──────────┐  ┌──────────┐            ┌──────────┐  ┌──────────┐
  │plan-agent│─▶│  arbiter │            │ phoenix  │─▶│  warden  │
  │ (design) │  │(tests 🔴)│            │(analyze) │  │ (review) │
  └──────────┘  └────┬─────┘            └──────────┘  └────┬─────┘
                     │                                      │
                     ▼                                      ▼
              ┌──────────┐                          ┌──────────┐
              │  kraken  │                          │  kraken  │
              │(code 🟢) │                          │(transform│
              └────┬─────┘                          └────┬─────┘
                   │                                      │
                   ▼                                      ▼
              ┌──────────┐                          ┌──────────┐
              │  arbiter │                          │  judge   │
              │(verify ✓)│                          │ (review) │
              └──────────┘                          └──────────┘

Data Layer Architecture

┌─────────────────────────────────────────────────────────────────────────────┐
│                           DATA LAYER ARCHITECTURE                           │
├─────────────────────────────────────────────────────────────────────────────┤
│                                                                             │
│  TLDR 5-LAYER CODE ANALYSIS              SEMANTIC INDEX                     │
│  ┌────────────────────────┐              ┌────────────────────────┐         │
│  │ L1: AST (~500 tok)     │              │ BGE-large-en-v1.5      │         │
│  │     └── Functions,     │              │ ├── All 5 layers       │         │
│  │         classes, sigs  │              │ ├── 10 lines context   │         │
│  │                        │              │ └── FAISS index        │         │
│  │ L2: Call Graph (+440)  │              │                        │         │
│  │     └── Cross-file     │──────────────│ Query: "auth logic"    │         │
│  │         dependencies   │              │ Returns: ranked funcs  │         │
│  │                        │              └────────────────────────┘         │
│  │ L3: CFG (+110 tok)     │                                                 │
│  │     └── Control flow   │                                                 │
│  │                        │              MEMORY (PostgreSQL+pgvector)       │
│  │ L4: DFG (+130 tok)     │              ┌────────────────────────┐         │
│  │     └── Data flow      │              │ sessions (heartbeat)   │         │
│  │                        │              │ file_claims (locks)    │         │
│  │ L5: PDG (+150 tok)     │              │ archival_memory (BGE)  │         │
│  │     └── Slicing        │              │ handoffs (embeddings)  │         │
│  └────────────────────────┘              └────────────────────────┘         │
│         ~1,200 tokens                                                       │
│         vs 23,000 raw                                                       │
│         = 95% savings                    FILE SYSTEM                        │
│                                          ┌────────────────────────┐         │
│                                          │ thoughts/              │         │
│                                          │ ├── ledgers/           │         │
│                                          │ │   └── CONTINUITY_*.md│         │
│                                          │ └── shared/            │         │
│                                          │     ├── handoffs/*.yaml│         │
│                                          │     └── plans/*.md     │         │
│                                          │                        │         │
│                                          │ .tldr/                 │         │
│                                          │ └── (daemon cache)     │         │
│                                          └────────────────────────┘         │
│                                                                             │
└─────────────────────────────────────────────────────────────────────────────┘

Core Systems

Skills System

Skills are modular capabilities triggered by natural language. Located in .claude/skills/.

Meta-Skills (Workflow Orchestrators)

Meta-SkillChainUse When
/workflowRouter → appropriate workflowDon't know where to start
/builddiscovery → plan → validate → implement → commitBuilding features
/fixsleuth → premortem → kraken → test → commitFixing bugs
/tddplan → arbiter (tests) → kraken (implement) → arbiterTest-first development
/refactorphoenix → plan → kraken → reviewer → arbiterSafe code transformation
/reviewparallel specialized reviews → synthesisCode review
/explorescout (quick/deep/architecture)Understand codebase
/securityvulnerability scan → verificationSecurity audits
/releaseaudit → E2E → review → changelogShip releases

Meta-Skill Reference

Each meta-skill supports modes, scopes, and flags. Type the skill alone (e.g., /build) to get an interactive question flow.

/build <mode> [options] [description]

ModeChainUse For
greenfielddiscovery → plan → validate → implement → commit → PRNew feature from scratch
brownfieldonboard → research → plan → validate → implementFeature in existing codebase
tddplan → test-first → implementTest-driven development
refactorimpact analysis → plan → TDD → implementSafe refactoring
OptionEffect
--skip-discoverySkip interview phase (have clear spec)
--skip-validateSkip plan validation
--skip-commitDon't auto-commit
--skip-prDon't create PR description
--parallelRun research agents in parallel

/fix <scope> [options] [description]

ScopeChainUse For
bugdebug → implement → test → commitGeneral bug fix
hookdebug-hooks → hook-developer → implement → testHook issues
depspreflight → oracle → plan → implement → qltyDependency errors
pr-commentsgithub-search → research → plan → implement → commitPR feedback
OptionEffect
--no-testSkip regression test
--dry-runDiagnose only, don't fix
--no-commitDon't auto-commit

/explore <depth> [options]

DepthTimeWhat It Does
quick~1 mintldr tree + structure overview
deep~5 minonboard + tldr + research + documentation
architecture~3 mintldr arch + call graph + layers
OptionEffect
--focus "area"Focus on specific area (e.g., --focus "auth")
--output handoffCreate handoff for implementation
--output docCreate documentation file
--entry "func"Start from specific entry point

/tdd, /refactor, /review, /security, /release

These follow their defined chains without mode flags. Just run:

/tdd "implement retry logic"
/refactor "extract auth module"
/review                           # reviews current changes
/security "authentication code"
/release v1.2.0

Key Skills (High-Value Tools)

Planning & Risk

  • premortem: TIGERS & ELEPHANTS risk analysis - use before any significant implementation
  • discovery-interview: Transform vague ideas into detailed specs

Context Management

  • create_handoff: Capture session state for transfer
  • resume_handoff: Resume from handoff with context
  • continuity_ledger: Track state within session

Code Analysis (95% Token Savings)

  • tldr-code: Call graph, CFG, DFG, slicing
  • ast-grep-find: Structural code search
  • morph-search: Fast text search (20x faster than grep)

Research

  • perplexity-search: AI-powered web search
  • nia-docs: Library documentation search
  • github-search: Search GitHub code/issues/PRs

Quality

  • qlty-check: 70+ linters, auto-fix
  • braintrust-analyze: Session analysis, replay, and debugging failed sessions

Math & Formal Proofs

  • math: Unified computation (SymPy, Z3, Pint) — one entry point for all math
  • prove: Lean4 theorem proving with 5-phase workflow (Research → Design → Test → Implement → Verify)
  • pint-compute: Unit-aware arithmetic and conversions
  • shapely-compute: Computational geometry

The /prove skill enables machine-verified proofs without learning Lean syntax. Used to create the first Lean formalization of Sylvester-Gallai theorem.

The Thought Process

What do I want to do?
├── Don't know → /workflow (guided router)
├── Building → /build greenfield or brownfield
├── Fixing → /fix bug
├── Understanding → /explore
├── Planning → premortem first, then plan-agent
├── Researching → oracle or perplexity-search
├── Reviewing → /review
├── Proving → /prove (Lean4 formal verification)
├── Computing → /math (SymPy, Z3, Pint)
└── Shipping → /release

See detailed skills breakdown →


Agents System

Agents are specialized AI workers spawned via the Task tool. Located in .claude/agents/.

Agent Categories (32 active)

Note: There are likely too many agents—consolidation is a v4 goal. Use what fits your workflow.

Orchestrators (2)

  • maestro: Multi-agent coordination with patterns (Pipeline, Swarm, Jury)
  • kraken: TDD implementation agent with checkpoint/resume support

Planners (4)

  • architect: Feature planning + API integration
  • phoenix: Refactoring + framework migration planning
  • plan-agent: Lightweight planning with research/MCP tools
  • validate-agent: Validate plans against best practices

Explorers (4)

  • scout: Codebase exploration (use instead of Explore)
  • oracle: External research (web, docs, APIs)
  • pathfinder: External repository analysis
  • research-codebase: Document codebase as-is

Implementers (3)

  • kraken: TDD implementation with strict test-first workflow
  • spark: Lightweight fixes and quick tweaks
  • agentica-agent: Build Python agents using Agentica SDK

Debuggers (3)

  • sleuth: General bug investigation and root cause
  • debug-agent: Issue investigation via logs/code search
  • profiler: Performance profiling and race conditions

Validators (2) - arbiter, atlas

Reviewers (6) - critic, judge, surveyor, liaison, plan-reviewer, review-agent

Specialized (8) - aegis, herald, scribe, chronicler, session-analyst, braintrust-analyst, memory-extractor, onboard

Common Workflows

WorkflowAgent Chain
Featurearchitect → plan-reviewer → kraken → review-agent → arbiter
Refactoringphoenix → plan-reviewer → kraken → judge → arbiter
Bug Fixsleuth → spark/kraken → arbiter → scribe

See detailed agent guide →


Hooks System

Hooks intercept Claude Code at lifecycle points. Located in .claude/hooks/.

Hook Events (30 hooks total)

EventKey HooksPurpose
SessionStartsession-start-continuity, session-register, braintrust-tracingLoad context, register session
PreToolUsetldr-read-enforcer, smart-search-router, tldr-context-inject, file-claimsToken savings, search routing
PostToolUsepost-edit-diagnostics, handoff-index, post-edit-notifyValidation, indexing
PreCompactpre-compact-continuityAuto-save before compaction
UserPromptSubmitskill-activation-prompt, memory-awarenessSkill hints, memory recall
SubagentStopsubagent-stop-continuitySave agent state
SessionEndsession-end-cleanup, session-outcomeCleanup, extract learnings

Key Hooks

HookPurpose
tldr-context-injectAdds code analysis to agent prompts
smart-search-routerRoutes grep to AST-grep when appropriate
post-edit-diagnosticsRuns pyright/ruff after edits
memory-awarenessSurfaces relevant learnings

See all 30 hooks →


TLDR Code Analysis

TLDR provides token-efficient code summaries through 5 analysis layers.

The 5-Layer Stack

LayerNameWhat it providesTokens
L1ASTFunctions, classes, signatures~500 tokens
L2Call GraphWho calls what (cross-file)+440 tokens
L3CFGControl flow, complexity+110 tokens
L4DFGData flow, variable tracking+130 tokens
L5PDGProgram slicing, impact analysis+150 tokens

Total: ~1,200 tokens vs 23,000 raw = 95% savings

CLI Commands

bash
# Structure analysis
tldr tree src/                      # File tree
tldr structure src/ --lang python   # Code structure (codemaps)

# Search and extraction
tldr search "process_data" src/     # Find code
tldr context process_data --project src/ --depth 2  # LLM-ready context

# Flow analysis
tldr cfg src/main.py main           # Control flow graph
tldr dfg src/main.py main           # Data flow graph
tldr slice src/main.py main 42      # What affects line 42?

# Codebase analysis
tldr impact process_data src/       # Who calls this function?
tldr dead src/                      # Find unreachable code
tldr arch src/                      # Detect architectural layers

# Semantic search (natural language)
tldr daemon semantic "find authentication logic"

Semantic Index

Beyond structural analysis, TLDR builds a semantic index of your codebase:

  • Natural language queries — Ask "where is error handling?" instead of grepping
  • Auto-rebuild — Dirty flag hook tracks file changes; index rebuilds after N edits
  • Selective indexing — Use .tldrignore to control what gets indexed
bash
# .tldrignore example
__pycache__/
*.test.py
node_modules/
.venv/

The semantic index uses all 5 layers plus 10 lines of surrounding code context—not just docstrings.

Hook Integration

TLDR is automatically integrated via hooks:

  • tldr-read-enforcer: Returns L1+L2+L3 instead of full file reads
  • smart-search-router: Routes Grep to tldr search
  • post-tool-use-tracker: Updates indexes when files change

See TLDR documentation →


Memory System

Cross-session learning powered by PostgreSQL + pgvector.

How It Works

Session ends → Database detects stale heartbeat (>5 min)
            → Daemon spawns headless Claude (Sonnet)
            → Analyzes thinking blocks from session
            → Extracts learnings to archival_memory
            → Next session recalls relevant learnings

The key insight: thinking blocks contain the real reasoning—not just what Claude did, but why. The daemon extracts this automatically.

Conversational Interface

What You SayWhat Happens
"Remember that auth uses JWT"Stores learning with context
"Recall authentication patterns"Searches memory, surfaces matches
"What did we decide about X?"Implicit recall via memory-awareness hook

Database Schema (4 tables)

TablePurpose
sessionsCross-terminal awareness
file_claimsCross-terminal file locking
archival_memoryLong-term learnings with BGE embeddings
handoffsSession handoffs with embeddings

Recall Commands

bash
# Recall learnings (hybrid text + vector search)
cd opc && uv run python scripts/core/recall_learnings.py \
    --query "authentication patterns"

# Store a learning explicitly
cd opc && uv run python scripts/core/store_learning.py \
    --session-id "my-session" \
    --type WORKING_SOLUTION \
    --content "What I learned" \
    --confidence high

Automatic Memory

The memory-awareness hook surfaces relevant learnings when you send a message. You'll see MEMORY MATCH indicators—Claude can use these without you asking.


Continuity System

Preserve state across context clears and sessions.

Continuity Ledger

Within-session state tracking. Location: thoughts/ledgers/CONTINUITY_<topic>.md

markdown
# Session: feature-x
Updated: 2026-01-08

## Goal
Implement feature X with proper error handling

## Completed
- [x] Designed API schema
- [x] Implemented core logic

## In Progress
- [ ] Add error handling

## Blockers
- Need clarification on retry policy

Handoffs

Between-session knowledge transfer. Location: thoughts/shared/handoffs/<session>/

yaml
---
date: 2026-01-08T15:26:01+0000
session_name: feature-x
status: complete
---

# Handoff: Feature X Implementation

## Task(s)
| Task | Status |
|------|--------|
| Design API | Completed |
| Implement core | Completed |
| Error handling | Pending |

## Next Steps
1. Add retry logic to API calls
2. Write integration tests

Commands

CommandEffect
"save state"Updates continuity ledger
"done for today" / /handoffCreates handoff document
"resume work"Loads latest handoff

Math System

Two capabilities: computation (SymPy, Z3, Pint) and formal verification (Lean4 + Mathlib).

The Stack

ToolPurposeExample
SymPySymbolic mathSolve equations, integrals, matrix operations
Z3Constraint solvingProve inequalities, SAT problems
PintUnit conversionConvert miles to km, dimensional analysis
Lean4Formal proofsMachine-verified theorems
Mathlib100K+ theoremsPre-formalized lemmas to build on
LoogleType-aware searchFind Mathlib lemmas by signature

Two Entry Points

SkillUse When
/mathComputing, solving, calculating
/proveFormal verification, machine-checked proofs

/math Examples

bash
# Solve equation
"Solve x² - 4 = 0"  →  x = ±2

# Compute eigenvalues
"Eigenvalues of [[2,1],[1,2]]"  →  {1: 1, 3: 1}

# Prove inequality
"Is x² + y² ≥ 2xy always true?"  →  PROVED (equals (x-y)²)

# Convert units
"26.2 miles to km"  →  42.16 km

/prove - Formal Verification

5-phase workflow for machine-verified proofs:

📚 RESEARCH → 🏗️ DESIGN → 🧪 TEST → ⚙️ IMPLEMENT → ✅ VERIFY
  1. Research: Search Mathlib with Loogle, find proof strategy
  2. Design: Create skeleton with sorry placeholders
  3. Test: Search for counterexamples before proving
  4. Implement: Fill sorries with compiler-in-the-loop feedback
  5. Verify: Audit axioms, confirm zero sorries
/prove every group homomorphism preserves identity
/prove continuous functions on compact sets are uniformly continuous

Achievement: Used to create the first Lean formalization of the Sylvester-Gallai theorem.

Prerequisites (Optional)

Math features require installation via wizard step 9:

bash
# Installed automatically by wizard
uv pip install sympy z3-solver pint shapely

# Lean4 (for /prove)
curl https://raw.githubusercontent.com/leanprover/elan/master/elan-init.sh -sSf | sh

Workflows

/workflow - Goal-Based Router

> /workflow

? What's your goal?
  ○ Research - Understand codebase/docs
  ○ Plan - Design implementation approach
  ○ Build - Implement features
  ○ Fix - Investigate and resolve issues

/fix - Bug Resolution

bash
/fix bug "login fails silently"

Chain: sleuth → [checkpoint] → [premortem] → kraken → test → commit

ScopeWhat it does
bugGeneral bug investigation
hookHook-specific debugging
depsDependency issues
pr-commentsAddress PR feedback

/build - Feature Development

bash
/build greenfield "user dashboard"

Chain: discovery → plan → validate → implement → commit → PR

ModeWhat it does
greenfieldNew feature from scratch
brownfieldModify existing codebase
tddTest-first development
refactorSafe code transformation

/premortem - Risk Analysis

bash
/premortem deep thoughts/shared/plans/feature-x.md

Output:

  • TIGERS: Clear threats (HIGH/MEDIUM/LOW severity)
  • ELEPHANTS: Unspoken concerns

Blocks on HIGH severity until user accepts/mitigates risks.


Installation

Full Installation (Recommended)

bash
# Clone
git clone https://github.com/parcadei/continuous-claude.git
cd continuous-claude/opc

# Run the setup wizard
uv run python -m scripts.setup.wizard

The wizard walks you through all configuration options interactively.

Updating

Pull latest changes and sync your installation:

bash
cd continuous-claude/opc
uv run python -m scripts.setup.update

This will:

  • Pull latest from GitHub
  • Update hooks, skills, rules, agents
  • Upgrade TLDR if installed
  • Rebuild TypeScript hooks if changed

What Gets Installed

ComponentLocation
Agents (32)~/.claude/agents/
Skills (109)~/.claude/skills/
Hooks (30)~/.claude/hooks/
Rules~/.claude/rules/
Scripts~/.claude/scripts/
PostgreSQLDocker container

Installation Mode: Copy vs Symlink

The wizard offers two installation modes:

ModeHow It WorksBest For
Copy (default)Copies files from repo to ~/.claude/End users, stable setup
SymlinkCreates symlinks to repo filesContributors, development

Copy Mode (Default)

Files are copied from continuous-claude/.claude/ to ~/.claude/. Changes you make in ~/.claude/ are local only and will be overwritten on next update.

text
continuous-claude/.claude/  ──COPY──>  ~/.claude/
     (source)                          (user config)

Pros: Stable, isolated from repo changes Cons: Local changes lost on update, manual sync needed

Symlink Mode (Recommended for Contributors)

Creates symlinks so ~/.claude/ points directly to repo files. Changes in either location affect the same files.

text
~/.claude/rules  ──SYMLINK──>  continuous-claude/.claude/rules
~/.claude/skills ──SYMLINK──>  continuous-claude/.claude/skills
~/.claude/hooks  ──SYMLINK──>  continuous-claude/.claude/hooks
~/.claude/agents ──SYMLINK──>  continuous-claude/.claude/agents

Pros:

  • Changes auto-sync to repo (can git commit improvements)
  • No re-installation needed after git pull
  • Contribute back easily

Cons:

  • Breaking changes in repo affect your setup immediately
  • Need to manage git workflow

Switching to Symlink Mode

If you installed with copy mode and want to switch:

bash
# Backup current config
mkdir -p ~/.claude/backups/$(date +%Y%m%d)
cp -r ~/.claude/{rules,skills,hooks,agents} ~/.claude/backups/$(date +%Y%m%d)/

# Verify backup succeeded before proceeding
ls -la ~/.claude/backups/$(date +%Y%m%d)/

# Remove copies (only after verifying backup above)
rm -rf ~/.claude/{rules,skills,hooks,agents}

# Create symlinks (adjust path to your repo location)
REPO="$HOME/continuous-claude"  # or wherever you cloned
ln -s "$REPO/.claude/rules" ~/.claude/rules
ln -s "$REPO/.claude/skills" ~/.claude/skills
ln -s "$REPO/.claude/hooks" ~/.claude/hooks
ln -s "$REPO/.claude/agents" ~/.claude/agents

# Verify
ls -la ~/.claude | grep -E "rules|skills|hooks|agents"

Windows users: Use PowerShell (as Administrator or with Developer Mode enabled):

powershell
# Enable Developer Mode first (Settings → Privacy & security → For developers)
# Or run PowerShell as Administrator

# Backup current config
$BackupDir = "$HOME\.claude\backups\$(Get-Date -Format 'yyyyMMdd')"
New-Item -ItemType Directory -Path $BackupDir -Force
Copy-Item -Recurse "$HOME\.claude\rules","$HOME\.claude\skills","$HOME\.claude\hooks","$HOME\.claude\agents" $BackupDir

# Verify backup succeeded before proceeding
Get-ChildItem $BackupDir

# Remove copies (only after verifying backup above)
Remove-Item -Recurse "$HOME\.claude\rules","$HOME\.claude\skills","$HOME\.claude\hooks","$HOME\.claude\agents"

# Create symlinks (adjust path to your repo location)
$REPO = "$HOME\continuous-claude"  # or wherever you cloned
New-Item -ItemType SymbolicLink -Path "$HOME\.claude\rules" -Target "$REPO\.claude\rules"
New-Item -ItemType SymbolicLink -Path "$HOME\.claude\skills" -Target "$REPO\.claude\skills"
New-Item -ItemType SymbolicLink -Path "$HOME\.claude\hooks" -Target "$REPO\.claude\hooks"
New-Item -ItemType SymbolicLink -Path "$HOME\.claude\agents" -Target "$REPO\.claude\agents"

# Verify
Get-ChildItem "$HOME\.claude" | Where-Object { $_.LinkType -eq "SymbolicLink" }

For Brownfield Projects

After installation, start Claude and run:

> /onboard

This analyzes the codebase and creates an initial continuity ledger.


Configuration

.claude/settings.json

Central configuration for hooks, tools, and workflows.

json
{
  "hooks": {
    "SessionStart": [...],
    "PreToolUse": [...],
    "PostToolUse": [...],
    "UserPromptSubmit": [...]
  }
}

.claude/skills/skill-rules.json

Skill activation triggers.

json
{
  "rules": [
    {
      "skill": "fix",
      "keywords": ["fix this", "broken", "not working"],
      "intentPatterns": ["fix.*(bug|issue|error)"]
    }
  ]
}

Environment Variables

VariablePurposeRequired
DATABASE_URLPostgreSQL connection stringYes
BRAINTRUST_API_KEYSession tracingNo
PERPLEXITY_API_KEYWeb searchNo
NIA_API_KEYDocumentation searchNo
CLAUDE_OPC_DIRPath to CC's opc/ directory (set by wizard)Auto
CLAUDE_PROJECT_DIRCurrent project directory (set by SessionStart hook)Auto

Services without API keys still work:

  • Continuity system (ledgers, handoffs)
  • TLDR code analysis
  • Local git operations
  • TDD workflow

Directory Structure

continuous-claude/
├── .claude/
│   ├── agents/           # 32 specialized AI agents
│   ├── hooks/            # 30 lifecycle hooks
│   │   ├── src/          # TypeScript source
│   │   └── dist/         # Compiled JavaScript
│   ├── skills/           # 109 modular capabilities
│   ├── rules/            # System policies
│   ├── scripts/          # Python utilities
│   └── settings.json     # Hook configuration
├── opc/
│   ├── packages/
│   │   └── tldr-code/    # 5-layer code analysis
│   ├── scripts/
│   │   ├── setup/        # Wizard, Docker, integration
│   │   └── core/         # recall_learnings, store_learning
│   └── docker/
│       └── init-schema.sql  # 4-table PostgreSQL schema
├── thoughts/
│   ├── ledgers/          # Continuity ledgers (CONTINUITY_*.md)
│   └── shared/
│       ├── handoffs/     # Session handoffs (*.yaml)
│       └── plans/        # Implementation plans
└── docs/                 # Documentation

Contributing

See CONTRIBUTING.md for guidelines on:

  • Adding new skills
  • Creating agents
  • Developing hooks
  • Extending TLDR

Acknowledgments

Patterns & Architecture

Tools & Services

  • uv - Python packaging
  • tree-sitter - Code parsing
  • Braintrust - LLM evaluation, logging, and session tracing
  • qlty - Universal code quality CLI (70+ linters)
  • ast-grep - AST-based code search and refactoring
  • Nia - Library documentation search
  • Morph - WarpGrep fast code search
  • Firecrawl - Web scraping API
  • RepoPrompt - Token-efficient codebase maps

Star History

Star History Chart


License

MIT - Use freely, contribute back.


Continuous Claude: Not just a coding assistant—a persistent, learning, multi-agent development environment that gets smarter with every session.

Cài đặt

TypingMind
{
  "mcpServers": {
    "continuous-claude-v3": {
      "command": "uv",
      "args": [
        "run",
        "python",
        "-m",
        "runtime.harness",
        "scripts/<script>.py"
      ]
    }
  }
}

Dùng MCP Continuous Claude với nhiều mô hình AI

TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên sau khi kết nối Continuous Claude, bạn có thể dùng với nhiều mô hình AI khác nhau trong TypingMind thay vì phải thiết lập riêng cho từng mô hình. MCP này chạy cục bộ thông qua trình kết nối MCP của TypingMind trên thiết bị của bạn.

Hướng dẫn thiết lập để dùng trình kết nối cục bộ

Dùng cách này khi máy chủ MCP cần truy cập các tệp, ứng dụng hoặc tài nguyên riêng tư trên máy tính của bạn.

1

Mở cài đặt MCP

Trong TypingMind, vào Cài đặt, Cài đặt nâng cao, rồi đến Giao thức ngữ cảnh mô hình và chọn Cài trình kết nối.

  1. Mở TypingMind trong trình duyệt của bạn.
  2. Nhấp vào biểu tượng Cài đặt.
  3. Vào Cài đặt nâng cao.
  4. Mở mục Giao thức ngữ cảnh mô hình.
  5. Nhấp vào Cài trình kết nối rồi chọn Thiết bị này.
Màn hình thiết lập trình kết nối MCP của TypingMind với tùy chọn Thiết bị này được chọn
2

Chạy lệnh trình kết nối

Chọn Thiết bị này, sao chép lệnh từ TypingMind và chạy trong Terminal. Giữ tiến trình chạy trong khi bạn dùng MCP.

  1. Sao chép lệnh thiết lập hiển thị trong TypingMind.
  2. Mở Terminal trên macOS hoặc Windows Terminal trên Windows.
  3. Dán và chạy lệnh.
  4. Xác nhận cài đặt gói nếu Terminal hỏi bạn có muốn tiếp tục không.
  5. Giữ tiến trình trong cửa sổ Terminal chạy trong khi dùng các công cụ MCP.
3

Thêm Continuous Claude làm máy chủ

Khi trạng thái trình kết nối là Sẵn sàng, nhấp vào Sửa máy chủ và dán cấu hình máy chủ MCP.

  1. Đợi đến khi trạng thái trình kết nối hiển thị Sẵn sàng.
  2. Nhấp vào Sửa máy chủ.
  3. Dán cấu hình máy chủ MCP của Continuous Claude.
  4. Lưu danh sách máy chủ.
  5. Làm mới nếu bạn muốn xác nhận trình kết nối vẫn sẵn sàng.
Cài đặt MCP của TypingMind hiển thị máy chủ đang hoạt động và nút Sửa máy chủ
{
  "mcpServers": {
    "continuous-claude-v3": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Dùng kết nối với nhiều mô hình

Lưu danh sách máy chủ, mở Plugin, bật các công cụ MCP của Continuous Claude, sau đó chọn bất kỳ mô hình AI nào được hỗ trợ trong TypingMind và dùng các công cụ trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.

  1. Mở trang Plugin trong TypingMind.
  2. Bật các công cụ MCP của Continuous Claude.
  3. Bắt đầu cuộc trò chuyện và chọn mô hình AI bạn muốn dùng.
  4. Dùng các công cụ MCP trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.
  5. Chuyển sang mô hình AI khác bất cứ khi nào cần mà không phải kết nối lại MCP.
Cuộc trò chuyện TypingMind dùng các công cụ MCP đã bật với một mô hình AI được chọn
Bạn có thể dùng Continuous Claude giúp tôi làm việc này không?
Continuous Claude
Được. Tôi đã đọc.
Đây là kết quả tôi tìm được bằng Continuous Claude.

Câu hỏi thường gặp

Máy chủ MCP Continuous Claude dùng để làm gì?

Continuous Claude là máy chủ MCP cho phép các ứng dụng AI tương thích kết nối với công cụ và ngữ cảnh bên ngoài. Trong TypingMind, bạn chỉ cần thêm máy chủ MCP này một lần để các công cụ của nó có sẵn trong không gian làm việc AI của bạn.

Bạn có thể dùng MCP Continuous Claude với nhiều mô hình AI trong TypingMind không?

Có. TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên bạn có thể dùng Continuous Claude với nhiều mô hình AI như Claude, ChatGPT, Gemini hoặc các mô hình khác đã cấu hình trong TypingMind mà không cần thiết lập máy chủ MCP riêng cho từng mô hình.

Vì sao nên dùng MCP Continuous Claude với TypingMind?

TypingMind là một trong những giao diện trò chuyện với LLM tốt nhất vì tập hợp nhiều mô hình AI, prompt, plugin, tác nhân AI, khóa API và công cụ MCP vào một không gian làm việc. Khi kết nối Continuous Claude, bạn có thể dùng các công cụ MCP của dịch vụ này với những mô hình ưa thích, đồng thời giữ quy trình trò chuyện gọn gàng trong TypingMind.

Làm cách nào để kết nối MCP Continuous Claude với TypingMind?

Continuous Claude hoạt động thông qua trình kết nối MCP cục bộ của TypingMind. Đây là lựa chọn phù hợp nhất khi máy chủ MCP cần truy cập tệp cục bộ, ứng dụng máy tính, công cụ dòng lệnh hoặc tài nguyên riêng trên máy tính của bạn.

MCP Continuous Claude cung cấp những công cụ nào trong TypingMind?

Continuous Claude cung cấp các chức năng MCP mà bạn có thể bật từ trang Plugin của TypingMind để dùng trong trò chuyện hoặc gán cho tác nhân AI.

Bạn có cần chia sẻ khóa API với TypingMind để dùng MCP Continuous Claude không?

Không. TypingMind ưu tiên xử lý cục bộ và cho phép bạn kiểm soát nhà cung cấp mô hình, khóa API, prompt và cấu hình MCP. Nếu Continuous Claude yêu cầu xác thực, hãy thêm các header, cài đặt OAuth hoặc cấu hình cục bộ cần thiết cho máy chủ MCP đó khi tạo kết nối.

Máy chủ MCP liên quan

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇