Dashboardopencode-loreEmbedding runtime safety, validation, c…

Embedding runtime safety, validation, compatibility, and backfill

Category: architecture
Confidence: 1.00
ID: 01a0a4f0-8f8a-764a-9550-561fec70032a
Project ID: 6f4be9ff-ed84-4cca-a9e7-732a0b0b8677
Cross-project: No
Recalled in other projects: 0
Source session: 0IiwozJmFR9A6QyFo
Created: 2026-08-31 23:05:10
Updated: 2026-09-15 12:00:23

Content

Before replacing any embedding worker, keep retirement owned and count active plus retiring workers against capacity. Starting replacements immediately looks responsive but can overlap model sessions and multiply memory; wait for confirmed exit, except native→WASM fallback may briefly overlap while its superseded worker remains tracked. Cooperative shutdown escalates to terminate() after 1.5 seconds and must confirm termination; otherwise latch unavailable. Validate each embed result as one finite configured-width Float32Array per input, then L2-normalize. Never purge vendored models; purge only proven-corrupt external downloads.

Move to: