/cf-scan

Manual onlyHigh>2.5K tokens injected into prompt

Scan project and bootstrap memory with architecture, conventions, and key features.

Context footprint: ⚡⚡⚡ (high) — what does this mean?

The /cf-scan skill scans your project and populates the memory system with knowledge — architecture, conventions, tech stack, key features, and infrastructure. Unlike /cf-remember (which extracts from conversations), this reads the codebase directly.

Usage

/cf-scan [project description]

The optional [project description] guides the scan. Without it, the skill infers everything from the codebase.

What It Does

  1. Warns about token cost — Asks for confirmation before proceeding
  2. Structural scan — Detects language, framework, package manager, test setup, CI/CD from config files
  3. Deep scan — Launches 2-4 targeted cf-explorer calls for architecture, conventions, infrastructure, and domain concepts
  4. Deduplicates — Checks existing memories via memory_list to avoid duplicates
  5. Stores — Creates ~10-15 memories across categories (features, conventions, decisions, infrastructure)
  6. Summarizes — Prints a table of created/updated memories

Examples

# Scan with no context
/cf-scan

# Guide the scan with a description
/cf-scan This is a Next.js e-commerce app with Stripe payments and PostgreSQL

# Focus on a specific area
/cf-scan Focus on the API layer and auth system

Idempotent

Safe to run multiple times. On subsequent runs:

  • Existing memories are updated (not duplicated)
  • New discoveries create new memories
  • Source field is set to scan to distinguish from conversation-based memories

When to Run

  • First time — After cf init and cf memory init, run /cf-scan to bootstrap project knowledge
  • After major refactors — Re-run to refresh architecture and convention memories
  • Anytime — Scan a specific aspect of your codebase whenever you need fresh context

Comparison with /cf-remember

/cf-scan/cf-remember
SourceScans codebase directlyExtracts from conversation
ScopeWhole projectSpecific topic
Output10-15 memories1-3 memories
WhenAnytimeAfter coding sessions

Memory Categories

The skill distributes memories across the standard categories:

CategoryTypeWhat gets stored
features/factMajor modules, features, data flows
conventions/preferenceNaming, patterns, code organization
decisions/contextArchitecture choices, tech stack rationale
infrastructure/procedureBuild, deploy, CI/CD setup

Custom Guide

Extend with .coding-friend/skills/cf-scan-custom/SKILL.md:

## Before

<!-- Run before the scan starts -->

## Rules

<!-- Additional rules during scanning -->

## After

<!-- Run after scan completes -->