Today — predict rebuilds an oxmera::nn::Sequential from 0.weight, 1.weight, … tensor names and assumes ReLU between layers (crates/oxidelake-compute/src/predict.rs, ModelSpec has one variant; ADR-0015 records the assumption; README §"In-database inference" says "with ReLU between them"). The SQL surface predict('scorer.safetensors', emb) gives the user no way to state or learn the activation. The code's own comment says a model whose activations differ "will silently produce wrong numbers".
Why it is worth fixing — a feature whose documented failure mode is silent wrong output is not production-ready however honestly the ADR labels it.
Fix — read the activation from the safetensors __metadata__ header ({"oxidelake.activation": "relu" | "gelu" | "sigmoid" | "none"}), refuse files without the key with an error that names the key and how to add it (oxmera's nn::serialize::save can write it), and optionally accept a third literal argument predict(path, features, 'relu') that must agree with the header. Extend the predict lane tests with a GELU model and a header-less file.
Done when — a header-less model is refused with a message naming the fix; the two-activation test passes in the predict lane.
Today —
predictrebuilds anoxmera::nn::Sequentialfrom0.weight,1.weight, … tensor names and assumes ReLU between layers (crates/oxidelake-compute/src/predict.rs,ModelSpechas one variant; ADR-0015 records the assumption; README §"In-database inference" says "with ReLU between them"). The SQL surfacepredict('scorer.safetensors', emb)gives the user no way to state or learn the activation. The code's own comment says a model whose activations differ "will silently produce wrong numbers".Why it is worth fixing — a feature whose documented failure mode is silent wrong output is not production-ready however honestly the ADR labels it.
Fix — read the activation from the safetensors
__metadata__header ({"oxidelake.activation": "relu" | "gelu" | "sigmoid" | "none"}), refuse files without the key with an error that names the key and how to add it (oxmera'snn::serialize::savecan write it), and optionally accept a third literal argumentpredict(path, features, 'relu')that must agree with the header. Extend thepredictlane tests with a GELU model and a header-less file.Done when — a header-less model is refused with a message naming the fix; the two-activation test passes in the predict lane.