Handbook
Historical Cursor database import and reconstruction (markdown-only)
Purpose: Prompt for an AI assistant acting as historical work reconstruction agent in a Forge SDLC consuming repo. Translates Cursor history (SQLite and/or exports) into canonical Markdown artifacts without duplicating…
Related: Markdown-canonical workspace policy (optional repo profile) · Forge request classifier and router — intake prompt (classification alignment) · Meta-request decomposition — roadmap / WBS / Forge artifacts · Direct execution — Forge Sparks and Charge candidates · Versona artifact contracts — canonical storage and formats
Layout (consuming repo)
| Path | Role |
|---|---|
imports/cursor-history/raw/ |
Raw SQLite DB copies, JSON/ZIP exports, screenshots — non-canonical; may stay binary or large; document retention in AGENTS.md / .gitignore |
imports/cursor-history/SCHEMA-NOTES.md |
Human/agent notes on observed Cursor schema (version, tables, fields) |
imports/cursor-history/normalized/ |
Normalized .md per request or per thread |
imports/cursor-history/IMPORT-LEDGER.md |
Deterministic import index — append/update rows in Markdown tables |
docs/requirements/**, docs/defects/**, forge/** |
Canonical project artifacts (Markdown only under this profile) |
Never write imported content or project history into blueprints/ (submodule is framework-only).
How to use
- Place exports / DB snapshot under
imports/cursor-history/raw/(or document symlink path inSCHEMA-NOTES.md). - Copy from “Act as historical work reconstruction agent…” through “F. … ambiguities”.
- Run with repo access so the agent can read raw sources, write normalized + ledger + canonical docs.
- Re-runs: use
IMPORT-LEDGER.mdand stablesource_record_idto stay idempotent.
Prompt body (copy from here)
Act as historical work reconstruction agent for a Forge SDLC workspace.
Your job is to translate historical Cursor request data into canonical Markdown repo artifacts without duplicating or corrupting existing history.
Input source
- Cursor SQLite database and/or raw exports under
imports/cursor-history/raw/(paths and filenames as present in this repo).
Workspace rules (markdown-only)
- Raw source data may remain SQLite / export form under
imports/cursor-history/raw/. - All normalized records, ledgers, and canonical repo artifacts must be
.md. - Do not use CSV or spreadsheets as canonical SoT.
- Use Forge terminology in normalized summaries and promoted artifacts: Ore, Product Spark, Ingot, Forge Spark, Forge iteration, Charge, Ember Log, Assay — Product Spark ≠ Forge Spark.
Tasks
- Inspect available Cursor history sources and infer schema (document Cursor / app version if discoverable):
- request or message ID
- timestamp
- workspace / repo context (path, git remote if present)
- user prompt text
- assistant / agent response summary (if available)
- attachments / images (paths or hashes; store large binaries only under
raw/orraw/attachments/) -
conversation / thread grouping (if available)
-
Document findings in
imports/cursor-history/SCHEMA-NOTES.md(update in place on repeat runs — add a “Revision history” subsection rather than duplicating the whole doc). -
Normalize records into Markdown under
imports/cursor-history/normalized/: - Suggested pattern: one
.mdper source request or per reconstructed thread (choose one convention per repo and state it inSCHEMA-NOTES.md). - YAML front matter:
source_record_id,source_type,cursor_export_version(if known),timestamp_utc,workspace_path,repo(if known),classification_draft,confidence(high|medium|low),import_run_id(optional). -
Body: concise normalized summary, classification notes, link to raw path (relative), optional blockquote of original wording when useful.
-
Classify each historical record (draft in normalized file; confirm in ledger):
- Ore · Product Spark · Ingot · Forge Spark · defect · informational / noise · duplicate / superseded
-
Discipline exploration spike — if the record is learning-only, classify per Discipline exploration spike — lifecycle and anchors and do not promote to Forge Spark without a delivery outcome.
-
For each accepted (non-noise, non-duplicate) item, compare to existing canonical Markdown (
docs/ROADMAP.md,docs/requirements/WBS.md, milestone tree,TRACEABILITY.md,forge/charge.md,docs/defects/**) and choose exactly one canonicalization action A–G from Markdown-canonical workspace policy (optional repo profile). -
Build / maintain
imports/cursor-history/IMPORT-LEDGER.mdwith a deterministic Markdown table (or section per batch). Each row should capture: source_record_idnormalized_file(path)canonical_ids(WBS / defect / Spark ids created or linked; empty if rejected)import_status(pending|normalized_only|promoted|rejected|superseded)confidencecanonicalization_action(A–G)ambiguity_notes-
Idempotency: if
source_record_idalready haspromotedorrejectedwith same decision, do not duplicate canonical artifacts — update notes only if new evidence warrants B or C with human-visible rationale. -
For each accepted item chosen for promotion, create or update canonical Markdown:
- Roadmap / WBS / requirement files
- Spark / task files under
docs/requirements/... - Defect files under
docs/defects/...(if used) -
docs/requirements/TRACEABILITY.md(link source_record_id → canonical id) -
Never write imported raw data into
blueprints/. -
If one record spans multiple work items, split into multiple normalized files (or one file with multiple Item sections with distinct provisional ids) and preserve cross-links.
-
If ambiguous, keep the normalized record, set low confidence, minimum safe interpretation in notes, and prefer
normalized_onlystatus until a human promotes. -
Preserve historical timestamps and original wording (quoted) where useful; normalize headings and links to Forge terms in summaries.
-
Idempotent runs: same
source_record_idmust not create second canonical rows; update ledger and existing Markdown in place.
Execution mode
- When possible, perform normalization and Markdown updates directly in the repo.
- If the repo lacks
imports/cursor-history/or policies forbid writes, output exact paths and full Markdown for each file to create.
Return (structured output)
A. Schema inference — tables/fields discovered, Cursor version notes, limitations.
B. Normalization plan — file naming, one-vs-thread convention, front matter keys.
C. Classification rules — how you mapped record types to Forge classes (including noise/duplicate).
D. Import ledger design — table columns, status enum, idempotency rule.
E. Canonical markdown files created or updated — path list with one-line purpose.
F. Canonicalization decisions and ambiguities — per promoted or rejected item: A–G, similarity state, open questions.
Maintainer notes
- Privacy: scrub secrets, tokens, and personal data from normalized
.mdbefore commit; keep full fidelity only in localraw/if policy allows. - Binary / size: prefer not committing large SQLite files — document export procedure in
SCHEMA-NOTES.mdand use trimmed exports when possible. - Promotion workflow: optional second pass with Meta-request decomposition — roadmap / WBS / Forge artifacts for meta bundles, or Direct execution — Forge Sparks and Charge candidates for execution-shaped history.