monsoon-nlp / mGPT-quantized

huggingface.co
Total runs: 843
24-hour runs: 0
7-day runs: 86
30-day runs: 219
Model's Last Updated: September 21 2023
text-generation

Introduction of mGPT-quantized

Model Details of mGPT-quantized

mGPT-quantized

The concept: 8-bit quantized version of mGPT , a 1.3B param model released by AI-Forever / Sberbank AI in April 2022.

On the GPT scale, it is a similar # of parameters to GPT2-XL, but on 60+ languages.

AI-Forever also released a 13B-parameter model. I made an 8-bit quantized version with weights available here: https://huggingface.co/monsoon-nlp/mGPT-13B-quantized

My goal is to evaluate this on Arabic, Hindi, and Indonesian tasks, where there are fewer autoregressive language models in this size range.

For English: use a GPT model or LLaMa2-7B

In August 2023 AI-Forever added 1.3B-param models for about 1/3 of the model's languages. If your language is Mongolian, for example, use mGPT-1.3B-mongol and not this one.

How was the model created?

Quantization of mGPT 1.3B was done using bitsandbytes library:

from transformers import BitsAndBytesConfig, GPT2LMHeadModel

quantization_config = BitsAndBytesConfig(
    load_in_8bit=True,
    bnb_8bit_compute_dtype=torch.bfloat16,
    bnb_8bit_use_double_quant=True,
    bnb_8bit_quant_type="nf4",
)

qmodel = GPT2LMHeadModel.from_pretrained(
    "ai-forever/mGPT",
    load_in_8bit=True,
    torch_dtype=torch.bfloat16,
    quantization_config=quantization_config,
    device_map="auto"
)

qmodel.save_pretrained("model_name")
Future steps
  • mGPT could be further quantized (4-bit), but model.save_pretrained() currently throws a NotImplementedError error.

Runs of monsoon-nlp mGPT-quantized on huggingface.co

843
Total runs
0
24-hour runs
82
3-day runs
86
7-day runs
219
30-day runs

More Information About mGPT-quantized huggingface.co Model

More mGPT-quantized license Visit here:

https://choosealicense.com/licenses/apache-2.0

mGPT-quantized huggingface.co

mGPT-quantized huggingface.co is an AI model on huggingface.co that provides mGPT-quantized's model effect (), which can be used instantly with this monsoon-nlp mGPT-quantized model. huggingface.co supports a free trial of the mGPT-quantized model, and also provides paid use of the mGPT-quantized. Support call mGPT-quantized model through api, including Node.js, Python, http.

monsoon-nlp mGPT-quantized online free

mGPT-quantized huggingface.co is an online trial and call api platform, which integrates mGPT-quantized's modeling effects, including api services, and provides a free online trial of mGPT-quantized, you can try mGPT-quantized online for free by clicking the link below.

monsoon-nlp mGPT-quantized online free url in huggingface.co:

https://huggingface.co/monsoon-nlp/mGPT-quantized

mGPT-quantized install

mGPT-quantized is an open source model from GitHub that offers a free installation service, and any user can find mGPT-quantized on GitHub to install. At the same time, huggingface.co provides the effect of mGPT-quantized install, users can directly use mGPT-quantized installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

mGPT-quantized install url in huggingface.co:

https://huggingface.co/monsoon-nlp/mGPT-quantized

Url of mGPT-quantized

mGPT-quantized huggingface.co Url

Provider of mGPT-quantized huggingface.co

monsoon-nlp
ORGANIZATIONS

Other API from monsoon-nlp

huggingface.co

Total runs: 49
Run Growth: 29
Growth Rate: 61.70%
Updated:September 03 2023
huggingface.co

Total runs: 17
Run Growth: 8
Growth Rate: 47.06%
Updated:February 25 2025
huggingface.co

Total runs: 15
Run Growth: -2
Growth Rate: -14.29%
Updated:February 03 2025
huggingface.co

Total runs: 7
Run Growth: -8
Growth Rate: -114.29%
Updated:May 23 2021