Instructions to use valiant9000/bert4ner-base-chinese-onnx with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers.js
How to use valiant9000/bert4ner-base-chinese-onnx with Transformers.js:
// npm i @huggingface/transformers import { pipeline } from '@huggingface/transformers'; // Allocate pipeline const pipe = await pipeline('token-classification', 'valiant9000/bert4ner-base-chinese-onnx');
bert4ner-base-chinese (ONNX)
ONNX export of shibing624/bert4ner-base-chinese
at revision 5d660ed2aa9da482bf2d99c6bc8cf2ce66758f6a, for use with Transformers.js / ONNX Runtime.
Weights are unchanged (FP32); only the format was converted.
- Labels:
O,B-/I-PER,B-/I-ORG,B-/I-LOC,B-/I-TIME(seeconfig.json) - Layout:
onnx/model.onnxplustokenizer.json(BertNormalizer, vocab identical tobert-base-chinese) - Inputs:
input_ids,attention_mask,token_type_ids; outputlogits
Export
optimum-cli export onnx -m <local snapshot of the pinned revision> --task token-classification out/
Tool versions: optimum 2.1.0, optimum-onnx 0.1.0, transformers 4.57.6, torch 2.15.0+cpu. Exported logits match the PyTorch model within 4e-6 (max abs) with identical argmax labels on a check sentence.
License
Apache-2.0, inherited from the original model. See LICENSE.txt and NOTICE.txt.
All credit for training goes to the original author (shibing624, nerpy).
- Downloads last month
- 91
Model tree for valiant9000/bert4ner-base-chinese-onnx
Base model
shibing624/bert4ner-base-chinese