Views
No views yet
1import { AutoTokenizer, AutoModelForCausalLM } from "@huggingface/transformers";
2
3const modelId = "tomvaillant/qwen3-4b-abliterated-v2-journalist-ONNX";
4const tokenizer = await AutoTokenizer.from_pretrained(modelId);
5const model = await AutoModelForCausalLM.from_pretrained(modelId, {
6 dtype: "q4",
7 device: "webgpu",
8});
9
10const messages = [
11 { role: "user", content: "What records should I check to verify who owns a local company?" },
12];
13
14const inputs = tokenizer.apply_chat_template(messages, {
15 add_generation_prompt: true,
16 return_dict: true,
17 enable_thinking: false,
18});
19
20const output = await model.generate({ ...inputs, max_new_tokens: 512 });
21console.log(tokenizer.decode(output[0], { skip_special_tokens: true }));onnx/model_q4.onnxonnx/model_q4.onnx_data*genai_config.jsononnxruntime-genai int4 export with external data split for browser loadingtomvaillant/investigative-journalism-trainingtomvaillant/investigative-journalism-training — 687 instruction/response pairs synthesized by Claude Opus 4.6 (Anthropic) from the Buried Signals OSINT and investigative-journalism corpus: OSINT Navigator tool data, Indicator Media briefings, Buried Signals investigative skills, GIJN, Bellingcat, Verification Handbook 3, SPJ Code of Ethics, RCFP, and public manuals from UNESCO, Al Jazeera Media Institute, CiFAR, CIPE, and EJF/TEMPO Institute.