aashish1904
commited on
Commit
•
857863a
1
Parent(s):
f17c186
Upload README.md with huggingface_hub
Browse files
README.md
ADDED
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
|
2 |
+
---
|
3 |
+
|
4 |
+
license: llama2
|
5 |
+
language:
|
6 |
+
- hi
|
7 |
+
|
8 |
+
---
|
9 |
+
|
10 |
+
[![QuantFactory Banner](https://lh7-rt.googleusercontent.com/docsz/AD_4nXeiuCm7c8lEwEJuRey9kiVZsRn2W-b4pWlu3-X534V3YmVuVc2ZL-NXg2RkzSOOS2JXGHutDuyyNAUtdJI65jGTo8jT9Y99tMi4H4MqL44Uc5QKG77B0d6-JfIkZHFaUA71-RtjyYZWVIhqsNZcx8-OMaA?key=xt3VSDoCbmTY7o-cwwOFwQ)](https://hf.co/QuantFactory)
|
11 |
+
|
12 |
+
|
13 |
+
# QuantFactory/OpenHathi-7B-Hi-v0.1-Base-GGUF
|
14 |
+
This is quantized version of [sarvamai/OpenHathi-7B-Hi-v0.1-Base](https://huggingface.co/sarvamai/OpenHathi-7B-Hi-v0.1-Base) created using llama.cpp
|
15 |
+
|
16 |
+
# Original Model Card
|
17 |
+
|
18 |
+
This repository is the first model in the OpenHathi series of models that will be released by Sarvam AI. This is a 7B parameter, based on Llama2, trained on Hindi, English, and Hinglish. More details about the model, its training procedure, and evaluations can be found [here](https://www.sarvam.ai/blog/announcing-openhathi-series).
|
19 |
+
|
20 |
+
Note: this is a base model and not meant to be used as is. We recommend first finetuning it on task(s) you are interested in.
|
21 |
+
|
22 |
+
```
|
23 |
+
# Usage
|
24 |
+
import torch
|
25 |
+
from transformers import LlamaTokenizer, LlamaForCausalLM
|
26 |
+
|
27 |
+
tokenizer = LlamaTokenizer.from_pretrained('sarvamai/OpenHathi-7B-Hi-v0.1-Base')
|
28 |
+
model = LlamaForCausalLM.from_pretrained('sarvamai/OpenHathi-7B-Hi-v0.1-Base', torch_dtype=torch.bfloat16)
|
29 |
+
|
30 |
+
prompt = "मैं एक अच्छा हाथी हूँ"
|
31 |
+
inputs = tokenizer(prompt, return_tensors="pt")
|
32 |
+
|
33 |
+
# Generate
|
34 |
+
generate_ids = model.generate(inputs.input_ids, max_length=30)
|
35 |
+
tokenizer.batch_decode(generate_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]
|
36 |
+
```
|