Views
No views yet
| Metric | Value |
|---|---|
| Model size | ~147 MB |
| Inference time | 50-100ms (browser) |
| Accuracy | ~97% F1 (minimal loss from quantization) |
1import { pipeline } from '@xenova/transformers';
2
3const detector = await pipeline(
4 'token-classification',
5 'joneauxedgar/pasteproof-pii-detector-onnx'
6);
7
8const results = await detector('const key = "sk_live_abc123";');
9console.log(results);1import * as ort from 'onnxruntime-web';
2
3const session = await ort.InferenceSession.create('model.onnx');
4// ... tokenize and run inferencemodel.onnx - Quantized ONNX modeltokenizer.json - Tokenizer vocabularytokenizer_config.json - Tokenizer settingsconfig.json - Model configurationspecial_tokens_map.json - Special token mappings