Dashboard › fossilize › Distillation
Distillation
ID: 2a2b16a7-4841-493f-b561-158a4038b865
Generation: 0
Tokens: 699
R_compression: 10.344
C_norm: 0.000
Archived: No
Created: 2026-06-09 14:42:13
Source IDs:
["b930db6585aebf7bc06b02422aef0621","fc9ccedae39b0bb44a0a05bfd50c2119"]
Observations
<observations>
Date: June 9, 2026
- 🟡 (11:46) Agent fetched fossilize src/impl.ts — full source reviewed; key implementation details below
- 🟡 (11:46) impl.ts imports: node:child_process (execFile), node:fs (promises), node:path, node:url (fileURLToPath), node:util (promisify), esbuild, postject (inject), p-limit; local imports: LocalContext, getNodeBinary/resolveNodeVersion (node-util), pLimit
- 🟡 (11:46) FossilizeOptions interface fields: nodeVersion, platforms?, assets?, assetManifest?, outDir, outputName?, cacheDir, noCache?, noBundle (boolean), sign (boolean), holePunch (boolean), concurrencyLimit (number)
- 🟡 (11:46) SEAConfig type fields: main, output, disableExperimentalSEAWarning?, useSnapshot?, useCodeCache?, assets? (Record<string,string>)
- 🟡 (11:46) impl.ts constants: PACKAGE_JSON="package.json", SEA_CONFIG_JSON="sea-config.json", SEA_BLOB="sea.blob", NODE_SEA_FUSE="fce680ab2cc467b6e072b8b5df1996b2"
- 🟡 (11:46) impl.ts platform normalization: process.platform "win32" → "win"; currentPlatform =
${normalizedPlatform}-${process.arch}; platforms list deduped via Set; falls back to FOSSILIZE_PLATFORMS env var or currentPlatform if --platforms not specified
- 🟡 (11:46) impl.ts build pipeline order: (1) clean outDir, (2) esbuild bundle → {outputName}.cjs (CJS, minified, tree-shaken, node target, import.meta.url injected via import-meta-url.js), (3) generate SEA blob via
node --experimental-sea-config, (4) optionally generate second code-cache blob for host platform when cross-compiling, (5) per-platform: copy node binary, strip debug symbols, inject blob via postject, hole-punch ICU data, sign+notarize
- 🟡 (11:46) impl.ts code-cache logic: useCodeCache=true only when building solely for host platform; when cross-compiling AND host is a target, generates second blob at
{blobPath}.codecache with useCodeCache=true; code-cache blob used only for host platform binary; comment notes ~15% startup time saving; bytecode is CPU-architecture-specific
- 🟡 (11:46) impl.ts strip logic: skipped for Windows (no debug symbols in release builds); macOS uses