prototype: reframe disposal around primary vs secondary source

Retain the prototype as a primary source on a throwaway branch linked
from the relevant issue, rather than deleting it, while the distilled
answer remains the secondary source. Keeps prototype scaffolding out of
the main branch without destroying the runnable evidence.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Matt Pocock
2026-07-09 14:53:43 +01:00
co-authored by Claude Opus 4.8
parent d574778f94
commit d6274600ab
5 changed files with 24 additions and 11 deletions
+4 -2
View File
@@ -31,9 +31,11 @@ The question decides the shape, and there are two shapes:
Picking the wrong branch wastes the whole prototype, so the question comes first. Both branches keep state in memory, run from one command, and surface the full state on every step.
## The answer is the artifact
## Primary and secondary source
The code is disposable; the **answer** is the only thing worth keeping. When the prototype has settled its question, capture the verdict somewhere durable a commit message, an ADR, an issue, or a `NOTES.md` next to it — alongside the question it answered, then delete or absorb the code. A prototype left rotting in the repo has outlived its purpose.
A finished prototype leaves two things, and they're kept differently. The **secondary source** is the _answer_ — the verdict plus the question it settled, distilled into durable prose (a commit message, an ADR, an issue). That's what future readers consult, and it's the part that matters most. The **primary source** is the _prototype itself_ — the runnable evidence the answer came from.
The prototype doesn't belong in the main repo: no tests, no error handling, nothing to maintain. But that's not a reason to destroy it. Once the answer is captured, fold any validated decision into the real code, then move the prototype onto a throwaway branch linked from the relevant issue — never merged. The main branch stays clean; the raw exploration stays one click away for anyone who wants to re-run it. A prototype left rotting in the main branch has outlived its purpose — a prototype preserved as a primary source on a side branch hasn't.
## Where it fits