ONNX Model Zoo

benjaminchazelle/camembert-onnx

By benjaminchazelle · ↓ 16 · ♥ 2 · Updated 2023-10-16

What's in this repo

This page lists the files in benjaminchazelle/camembert-onnx, including model.onnx, model_quantized.onnx.

  • 2 ONNX models (.onnx files)
  • 10 files, including 5 .json, 2 .onnx, 1 .md, 1 .model
  • Last updated 2023-10-16

ONNX files

File Size Download
onnx/model.onnx — Download
onnx/model_quantized.onnx — Download

How to use

These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.

README

The camembert/camembert-base model converted in ONNX format.

This model handles the Fill-Mask pipeline and can therefore be used for offline text completion through Transformers.js.

<script type="module">
    import { pipeline } from 'https://cdn.jsdelivr.net/npm/@xenova/transformers@2.6.2';

    const unmasker = await pipeline('fill-mask', 'benjaminchazelle/camembert-onnx', { quantized: false })

    console.log(await unmasker('La capitale de la France est<mask>'))
    
    /*
    [
      {
        "score": 0.45410260558128357,
        "token": 186,
        "token_str": "▁...",
        "sequence": "La capitale de la France est..."
      },
      {
        "score": 0.06095331534743309,
        "token": 300,
        "token_str": "▁Paris",
        "sequence": "La capitale de la France est Paris"
      },
      {
        "score": 0.04425867274403572,
        "token": 16,
        "token_str": "▁le",
        "sequence": "La capitale de la France est le"
      },
      {
        "score": 0.035498425364494324,
        "token": 807,
        "token_str": "▁[...]",
        "sequence": "La capitale de la France est [...]"
      },
      {
        "score": 0.03408252075314522,
        "token": 13,
        "token_str": "▁la",
        "sequence": "La capitale de la France est la"
      }
    ]
    */
</script>

Model info

fill-mask transformers.js
transformers.js onnx camembert fill-mask fr license:mit region:us
↓ 16 ♥ 2

Created: 2023-09-29

Updated: 2023-10-16

View on Hugging Face

Files (10)

.gitattributes
README.md
config.json
onnx/model.onnx ONNX
onnx/model_quantized.onnx ONNX
quantize_config.json
sentencepiece.bpe.model
special_tokens_map.json
tokenizer.json
tokenizer_config.json

Related models