# Project Prompt — singularity-forge ## What this is SF — Singularity Forge — is a **purpose-to-software compiler**. The foundational contract is documented in [`docs/adr/0000-purpose-to-software-compiler.md`](../../docs/adr/0000-purpose-to-software-compiler.md). Every milestone exists to serve a stated purpose; mechanics (paths, schemas, commit refs) are subordinate to that purpose. For the longer narrative form see [`AGENTS.md`](../../AGENTS.md) and [`CLAUDE.md`](../../CLAUDE.md). For style decisions see [`.sf/STYLE.md`](../../.sf/STYLE.md). For invariants see [`.sf/PRINCIPLES.md`](../../.sf/PRINCIPLES.md). For things we explicitly will not do see [`.sf/NON-GOALS.md`](../../.sf/NON-GOALS.md). ## Non-negotiables - **DB-first**: all state lives in SQLite via Node's built-in `node:sqlite` (`DatabaseSync`). Never use `better-sqlite3` or any native SQLite addon. Never use file-based fallbacks for state that belongs in the DB (milestone context, sessions, memories, mode state). If a pattern uses files as a proxy for DB state, that's a bug to fix, not a convention to follow. - **Two work modes**: Ask and Build. Shift+Tab cycles between them. YOLO (Ctrl+Y) is a flag on Build that drops confirmations; it is never a third mode and is not a Shift+Tab stop. - **Build pipeline**: source TypeScript files under `src/resources/extensions/sf/` compile to `dist/resources/...` via `npm run copy-resources`. Files installed at `~/.sf/agent/extensions/sf/` are not auto-redirected to TS source — edits to `.ts` only take effect after `copy-resources`. - **Tests**: vitest, no pre-compile. ## Workflow - `/todo triage` empties `TODO.md` and routes items into structured plan artifacts (`docs/plans/`), backlog rows, and BUILD_PLAN tier lists. Run before starting work if the inbox has content. - New milestones via `sf headless new-milestone --context ` — see SF's own TODO.md for the headless-unattended-mode caveat. - Bulk import of a flat roadmap via `sf headless import-backlog ` (this one works headless).