Wasm llama2 tweaks (#309)

* Clean-up the llama2.c wasm example.

* Use a proper tokenizer.
This commit is contained in:
Laurent Mazare
2023-08-02 15:49:43 +01:00
committed by GitHub
parent 4f17290ce0
commit 186c308d51
6 changed files with 14 additions and 52 deletions

View File

@ -53,7 +53,7 @@ pub struct App {
}
async fn model_data_load() -> Result<ModelData, JsValue> {
let tokenizer = fetch_url("tokenizer.bin").await?;
let tokenizer = fetch_url("tokenizer.json").await?;
let model = fetch_url("model.bin").await?;
console_log!("{}", model.len());
Ok(ModelData { tokenizer, model })