Dashboard › opencode-lore › Distillation
7fcf0a11-5783-49af-9600-50788e7bf87b["lore_tm_v1_TiIb-fYUqbSoVH99MGpnyti4dePxwcGJJt4lHShFfLc","lore_tm_v1_7sUwFsHZ9eEzNhjXNlVwEubI4WUgJakT0kVAtc4HPtg"]
Date: Sep 16, 2026
try/catch.localStackMissing self-healing tracks the epoch milliseconds of the last re-probe, where 0 means never and is primed on the first tick.__filename (always defined), while ESM uses import.meta.url.packages/core/src/embedding/local.ts includes container-aware memory handling via resolveMemoryHeadroom, containerFreeBytes(), and capFreememAtLearn; its constrained-memory helper returns 0 when unconstrained and is available in Node ≥18.15 and Bun.packages/core/src/embedding/local.ts creates an embedding Worker with eval: true, derives a CJS/ESM-compatible worker entrypoint, and supports deterministic fake workers through a production-disabled test seam.packages/core/src/embedding/local.ts treats worker errors as potentially transient runtime/model startup-pressure failures, performs OOM backoff through handleOomBackoff(), supports a one-time WASM fallback guarded by wasmFallbackTried, and handles worker "init-error" messages separately.packages/core/src/embedding/local.ts preserves typed local-provider failure handling: a generic Error could bypass the intended path and cause silent data loss, so failures use the relevant local-provider error type such as LocalProviderUnavailableError.packages/core/src/embedding/pool.ts requires invalid pool-size environment values to resolve to undefined, never NaN, and to fall through to configuration; valid values must be finite and ≥1 and are normalized with Math.floor(n).packages/core/src/embedding/pool.ts defines MAX_QUEUED_EMBED_OPERATIONS = 256 and tracks queued memory through queuedBytes.packages/core/src/embedding/pool.ts pools LocalProvider workers so concurrent embedding requests execute in parallel rather than serially.packages/core/src/embedding/pool.ts routes new work only to proven healthy sibling slots and selects among candidates using their inflight counts.packages/core/src/embedding/pool.ts supports operation deduplication/tracking through operations, queue cleanup that clears operation.texts, abort handling with EmbeddingRequestAbortedError, retry dispatch through retryDispatchTimer, and token-batch progress through tokenBatchCheckpoints.packages/core/src/embedding/pool.ts recognizes localEmbeddingState.failureCause === "transient-init-exhausted" as a distinct failure state.