/cf-scan
Manual onlyHigh>2.5K tokens injected into promptScan 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
- Warns about token cost — Asks for confirmation before proceeding
- Structural scan — Detects language, framework, package manager, test setup, CI/CD from config files
- Deep scan — Launches 2-4 targeted cf-explorer calls for architecture, conventions, infrastructure, and domain concepts
- Deduplicates — Checks existing memories via
memory_listto avoid duplicates - Stores — Creates ~10-15 memories across categories (features, conventions, decisions, infrastructure)
- 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
scanto distinguish from conversation-based memories
When to Run
- First time — After
cf initandcf memory init, run/cf-scanto 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 | |
|---|---|---|
| Source | Scans codebase directly | Extracts from conversation |
| Scope | Whole project | Specific topic |
| Output | 10-15 memories | 1-3 memories |
| When | Anytime | After coding sessions |
Memory Categories
The skill distributes memories across the standard categories:
| Category | Type | What gets stored |
|---|---|---|
features/ | fact | Major modules, features, data flows |
conventions/ | preference | Naming, patterns, code organization |
decisions/ | context | Architecture choices, tech stack rationale |
infrastructure/ | procedure | Build, 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 -->