APAM Init - Bootstrap Project Memory
You are setting up APAM memory for a project that has little or no memory recorded. Explore the codebase, learn its shape, and write an initial memory snapshot.
Steps
1. Load existing memory
Run /apam:apam-status or run apam status in the current repository. Copy the project_id from the Project: line exactly.
Call apam_recall with that project_id. Note what already exists and do not re-write facts already in L1.
2. Explore the project
Read enough to answer these questions:
- What does this project do? (README, package.json description, main file)
- What language, framework, and key libraries does it use?
- What is the folder structure? (top-level dirs, where src/tests/config live)
- What are the entry points? (main file, CLI command, server start)
- What APIs or endpoints exist, if any?
- What database or data layer is used, if any?
- What external services does it integrate with?
- Are there any stated constraints or rules? (linting, testing, deployment)
Do not read every file. Scan strategically. package.json, README.md, a top-level folder listing, and a few key source files is usually enough.
3. Pin L1 atoms
For each fact you learn, pin one atom per fact using apam_pin (scope: "project", confidence: "agent_inferred"):
- What this project is - one sentence
- Tech stack: languages, frameworks, key libraries
- Key folder structure - where things live
- Entry points - main file, CLI, or server command
- APIs/endpoints - names and one-line purpose each (if applicable)
- Database/data layer - what DB, what main models (if applicable)
- Key external services or integrations (if applicable)
- Any constraints or rules
One fact per atom. Do not write compound atoms. Skip categories that genuinely do not apply.
4. Write L3 Project Intelligence records
Write at least:
apam_update_intelligence(type='architecture', title='System Overview', content='...')
apam_update_intelligence(type='entity', title='Key Modules', content='...')
- Any other records that capture important structure, such as "API Endpoints" or "Database Schema"
5. Report what was written
Tell the user:
- Project ID detected
- How many L1 atoms were pinned
- What L3 records were created
- What was skipped (for example, "no database found, skipped DB atom")
- Invite them to correct anything that looks wrong
1---2name: apam-init3description: Initialize APAM memory for a new project. Explores the codebase and writes L1 atoms and L3 Project Intelligence records so future sessions start with full context.4---56# APAM Init - Bootstrap Project Memory78You are setting up APAM memory for a project that has little or no memory recorded. Explore the codebase, learn its shape, and write an initial memory snapshot.910## Steps1112### 1. Load existing memory1314Run `/apam:apam-status` or run `apam status` in the current repository. Copy the `project_id` from the `Project:` line exactly.1516Call `apam_recall` with that `project_id`. Note what already exists and do not re-write facts already in L1.1718### 2. Explore the project1920Read enough to answer these questions:21- What does this project do? (README, package.json description, main file)22- What language, framework, and key libraries does it use?23- What is the folder structure? (top-level dirs, where src/tests/config live)24- What are the entry points? (main file, CLI command, server start)25- What APIs or endpoints exist, if any?26- What database or data layer is used, if any?27- What external services does it integrate with?28- Are there any stated constraints or rules? (linting, testing, deployment)2930Do not read every file. Scan strategically. `package.json`, `README.md`, a top-level folder listing, and a few key source files is usually enough.3132### 3. Pin L1 atoms3334For each fact you learn, pin one atom per fact using `apam_pin` (`scope: "project"`, `confidence: "agent_inferred"`):35361. What this project is - one sentence372. Tech stack: languages, frameworks, key libraries383. Key folder structure - where things live394. Entry points - main file, CLI, or server command405. APIs/endpoints - names and one-line purpose each (if applicable)416. Database/data layer - what DB, what main models (if applicable)427. Key external services or integrations (if applicable)438. Any constraints or rules4445One fact per atom. Do not write compound atoms. Skip categories that genuinely do not apply.4647### 4. Write L3 Project Intelligence records4849Write at least:50- `apam_update_intelligence(type='architecture', title='System Overview', content='...')`51- `apam_update_intelligence(type='entity', title='Key Modules', content='...')`52- Any other records that capture important structure, such as "API Endpoints" or "Database Schema"5354### 5. Report what was written5556Tell the user:57- Project ID detected58- How many L1 atoms were pinned59- What L3 records were created60- What was skipped (for example, "no database found, skipped DB atom")61- Invite them to correct anything that looks wrong