Downloads · 30 days
64
1% of all-time downloads
Eurdem/megatron_v3_2x7B
megatron_v3_2x7B is a text generation model from Eurdem. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as apache-2.0.
Megatronv32x7B is a bilingual Mixure of Experts (MoE) which can comprehend and speak English/Turkish. Megatron, MoE mimarisine sahip Türkçe ve İngilizce talimatları anlayan ve cevap veren bir modeldir.
Downloads · 30 days
64
1% of all-time downloads
All-time downloads
8.2K
Public
Parameters
12.9B
25.8 GB on disk
Likes
3
Public
Click a slice to open those files.
.safetensors25.8 GB · 100%
From the Hugging Face model README
Megatron_v3_2x7B is a bilingual Mixure of Experts (MoE) which can comprehend and speak English/Turkish. Megatron, MoE mimarisine sahip Türkçe ve İngilizce talimatları anlayan ve cevap veren bir modeldir.
!pip install -qU transformers bitsandbytes accelerate
from transformers import AutoTokenizer
import transformers
import torch
model = "Eurdem/Megatron_v3_2x7B"
tokenizer = AutoTokenizer.from_pretrained(model)
pipeline = transformers.pipeline(
"text-generation",
model=model,
model_kwargs={"torch_dtype": torch.float16, "load_in_4bit": True},
)
messages = [{"role": "user", "content": "Tell me about AI"}]
prompt = pipeline.tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
outputs = pipeline(prompt, max_new_tokens=1024, do_sample=True, temperature=0.7, top_k=500, top_p=0.95)
print(outputs[0]["generated_text"])