{
  "uid": "cogitave.learn.reuse-first-engineering.build-from-scratch-as-the-exception",
  "kind": "moduleUnit",
  "href": "/modules/reuse-first-engineering/build-from-scratch-as-the-exception/",
  "title": "Build from scratch as the exception",
  "summary": "",
  "type": null,
  "products": [],
  "roles": [],
  "levels": [],
  "subjects": [],
  "headings": [
    "&quot;From scratch&quot; does not mean blind reinvention",
    "The decision: port best-in-class, rebuild native",
    "When &quot;from scratch&quot; is actually earned"
  ],
  "source": "The previous unit was about components inside the estate: discover an existing\ngolden component before authoring a rival. The same instinct applies one level\nup, to whole engines and tools, with its own decision:\n[ADR-0003, \"Port best-in-class, rebuild native; references not dependencies\"](../../../../standards/docs/decisions/0003-build-from-scratch-reference-not-dependency.md).\n\n## \"From scratch\" does not mean blind reinvention\n\nCogitave is an agent OS/kernel company, and stitched-together third-party tools\ncannot be harmonic - each ships its own data model, UX, and boundary - so the\nmoat is vertical integration over one canonical model, Cogitave Core. That\n\"full-scratch\" stance was being misread as **blind reinvention**: rewriting\nsolved problems for their own sake, slowly and worse. That is explicitly not the\nintent. The best engineering teams have already discovered the right shapes for\nschedulers, parsers, inference loops, and permission models. Cogitave wants those\nshapes - then wants them native and vertically integrated, inside the single\nmodel.\n\n## The decision: port best-in-class, rebuild native\n\n> [!IMPORTANT]\n> Port best-in-class references and rebuild them better; do not reinvent\n> blindly.\n\n- **References, not dependencies.** Best-in-class tools - DocFX, Tauri, UniFFI,\n  Candle, Base UI/Radix, lefthook, release-please, llama.cpp - are the **spec\n  and reference implementation studied and ported**, not permanent runtime\n  dependencies. Cogitave adopts the *shape*, not the lock-in.\n- **Rebuild native, maximum speed.** The rebuild is harmonic (one Core model),\n  closest to the machine, and measured against the reference.\n- **Reinvent only where you beat the reference.** If a team cannot do it\n  materially better - faster, more integrated, more correct, more secure - it\n  does **not** reinvent yet. The reference stays a **sanctioned bootstrap\n  crutch** behind a stable interface, explicit and scheduled for replacement.\n- **Correctness and certification compliance are the goal**, not delivery speed.\n- **Operationalized by the Technology Radar.** Every layer names its default,\n  the reference it ports, and when to deviate; a changed default is its own ADR.\n\n## When \"from scratch\" is actually earned\n\nReinvention is earned, not assumed:\n\n1. Can a best-in-class reference be **ported** (its shape studied and adopted)\n   instead of ignored? If yes, start there.\n2. Can the native rebuild be **materially better**? If not yet, keep the\n   reference as the explicit, time-boxed bootstrap crutch and revisit later.\n3. Is the deviation **recorded** as its own ADR, so a reviewer can always answer\n   \"reference, bootstrap, or native primitive?\"\n\nThe ADR names its own accepted exception: an off-the-shelf tool is acceptable in\nthe diagram render layer, because the notation spec itself stays Cogitave's own\nreference. That is the pattern to copy - not \"no third-party tool, ever,\" but\n\"the shape is ours to keep, the implementation is earned.\"\n\n> [!NOTE]\n> Both ADRs converge on one instinct: discover what already exists - internally\n> in the registry, externally in best-in-class references - before generating or\n> reinventing. [ADR-0013](../../../../standards/docs/decisions/0013-reuse-first-convergent-ai-development.md)\n> names its own revisit trigger too: reconsider when the native Core\n> duplication checker and registry ship, or the golden-component library proves\n> too coarse.\n",
  "partOf": "cogitave.learn.reuse-first-engineering",
  "durationInMinutes": 8,
  "quiz": null
}