Downloads · 30 days
19
1% of all-time downloads
thesven/Phi-nut-Butter-Codebagel-v1-GPTQ
Phi-nut-Butter-Codebagel-v1-GPTQ is a text generation model from thesven. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as mit.
Downloads · 30 days
19
1% of all-time downloads
All-time downloads
2K
Public
Parameters
3.8B
2.3 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors2.3 GB · 100%
How the weights are stored.
I323.6B · 95%
From the Hugging Face model README

Model Name: Phi-nut-Butter-Codebagel-v1 Quantization Data: 4bit GPTQ
This is a GPTQ 4 bit quantization of thesven/Phi-nut-Butter-Codebagel-v1. For more details on the model please see the model card.
This model is designed to improve instruction-following capabilities, particularly for code-related tasks.
<|system|>
{system_message} <|end|>
<|user|>
{Prompt) <|end|>
<|assistant|>
from transformers import AutoModelForCausalLM, AutoTokenizer
model_name_or_path = "thesven/Phi-nut-Butter-Codebagel-v1-GPTQ"
tokenizer = AutoTokenizer.from_pretrained(model_name_or_path, use_fast=True)
model = AutoModelForCausalLM.from_pretrained(
model_name_or_path,
device_map="auto",
trust_remote_code=False,
revision="main",
)
model.pad_token = model.config.eos_token_id
prompt_template = '''
<|system|>
You are an expert developer. Please help me with any coding questions.<|end|>
<|user|>
In typescript how would I use a function that looks like this <T>(config:T):T<|end|>
<|assistant|>
'''
input_ids = tokenizer(prompt_template, return_tensors='pt').input_ids.cuda()
output = model.generate(inputs=input_ids, temperature=0.1, do_sample=True, top_p=0.95, top_k=40, max_new_tokens=256)
generated_text = tokenizer.decode(output[0, len(input_ids[0]):], skip_special_tokens=True)
display(generated_text)