ONNX Model Zoo

onnx-community/jais-family-590m-chat

By onnx-community · ↓ 6 · ♥ 0 · Updated 2025-03-06

What's in this repo

This page lists the files in onnx-community/jais-family-590m-chat, including model.onnx, model_fp16.onnx, model_quantized.onnx.

  • 3 ONNX models (.onnx files)
  • 12 files, including 6 .json, 3 .onnx, 1 .md, 1 .onnx_data
  • Last updated 2025-03-06

ONNX files

File Size Download
onnx/model.onnx — Download
onnx/model_fp16.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

https://huggingface.co/inceptionai/jais-family-590m-chat with ONNX weights to be compatible with Transformers.js.

Usage (Transformers.js)

If you haven't already, you can install the Transformers.js JavaScript library from NPM using:

npm i @huggingface/transformers

Example: Text generation with onnx-community/jais-family-590m-chat.

import { pipeline } from '@huggingface/transformers';

const generator = await pipeline('text-generation', 'onnx-community/jais-family-590m-chat', {
    dtype: 'q8',
});

const question = "What is the capital of UAE?";
const prompt_eng = `### Instruction: Your name is 'Jais', and you are named after Jebel Jais, the highest mountain in UAE. You were made by 'Inception' in the UAE. You are a helpful, respectful, and honest assistant. Always answer as helpfully as possible, while being safe. Complete the conversation between [|Human|] and [|AI|]:\n### Input: [|Human|] ${question}\n[|AI|]\n### Response:`;

const result = await generator(prompt_eng, { max_new_tokens: 128, return_full_text: false });
console.log(result[0].generated_text);
// "The capital city of the United Arab Emirates, a federation of seven emirates on the eastern side of the Arabian peninsula, is Abu Dhabi. This bustling metropolis is not only the political, economic, and cultural hub of the UAE but also a global hub for tourism and trade. It is home to the world's largest oil refinery, the Abu Dhabi National Petroleum Company (ADNOC), and the world's largest seafaring company, the Abu Dhabi Ports Corporation (ADPOC). The city is also a major hub for the United Arab Emirates'"

Note: Having a separate repo for ONNX weights is intended to be a temporary solution until WebML gains more traction. If you would like to make your models web-ready, we recommend converting to ONNX using 🤗 Optimum and structuring your repo like this one (with ONNX weights located in a subfolder named onnx).

Model info

text-generation transformers.js
transformers.js onnx jais text-generation conversational custom_code base_model:inceptionai/jais-family-590m-chat base_model:quantized:inceptionai/jais-family-590m-chat region:us
↓ 6 ♥ 0

Created: 2024-08-28

Updated: 2025-03-06

View on Hugging Face

Files (12)

.gitattributes
README.md
config.json
generation_config.json
onnx/model.onnx ONNX
onnx/model.onnx_data
onnx/model_fp16.onnx ONNX
onnx/model_quantized.onnx ONNX
quantize_config.json
special_tokens_map.json
tokenizer.json
tokenizer_config.json

Related models