# Offline RWKV engine

This directory contains the corresponding source for the WebAssembly module served at /rwkv.wasm. The neural network, feature extraction and interval calculation come from the Anki RWKV fork at commit 990508f4605a, rslib/src/rwkv/mod.rs, under GNU AGPL v3 or later. Recall adapts its loader to accept in-memory weights, replaces Rayon with sequential iteration, adds WASM SIMD dot products and provides a single-threaded web worker ABI. The source is also served under /engine-source/.

Build from the project directory:

    rustc --edition=2021 --crate-type=cdylib --target wasm32-unknown-unknown -C opt-level=3 -C target-feature=+simd128 -C panic=abort engine/bridge.rs -o public/rwkv.wasm

Weights are supplied privately per library from the owner's RWKV4Anki V1 101–4999 .safetensors or .ankiaddon. They are verified by SHA-256 and never included in the public frontend. One model estimates recall and intervals at 90% target retention. Again uses a one-minute relearning step. The other ratings use their own post-answer model state. Candidate selection scores due review cards by immediate recall. Learning cards are handled first and new cards follow scheduled reviews.
