Run this model with HF Jobs

Run sahil2801/instruct-codegen-16B on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.

Paste one of these prompts into your coding agent:

Fine-tune on my dataset

Use HF Jobs and TRL to fine-tune https://huggingface.co/sahil2801/instruct-codegen-16B. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.

Run batch inference

Use HF Jobs to run batch inference with https://huggingface.co/sahil2801/instruct-codegen-16B on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.

Evaluate on a benchmark

Use HF Jobs to evaluate https://huggingface.co/sahil2801/instruct-codegen-16B. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.

Quantize for lower memory use

Use HF Jobs to create a 4-bit version of https://huggingface.co/sahil2801/instruct-codegen-16B. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.

Model Card for instruct-codegen-16B

Instruct-codegen-16B is an instruction following codegen model based on Salesforce codegen-16B-multi , finetuned on a dataset of 250k instruction-following samples in the alpaca format.

The data was not generated using any commercial LLM api.

The model achieves a result of 37.1% pass@1 on the HumanEval benchmark.

Generation

# pip install -q transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
checkpoint = "sahil2801/instruct-codegen-16B"
device = "cuda"
tokenizer = AutoTokenizer.from_pretrained(checkpoint)
model = AutoModelForCausalLM.from_pretrained(checkpoint).half().to(device)
instruction = "Write a function to scrape hacker news."
prompt = f"Below is an instruction that describes a task.\n Write a response that appropriately completes the request.\n\n ### Instruction:\n{instruction}\n\n### Response:"
inputs = tokenizer(prompt, return_tensors="pt").to(device)
outputs = model.generate(**inputs,temperature=0.3,do_sample=True,max_new_tokens=256)
print(tokenizer.decode(outputs[0],skip_special_tokens=True))
Downloads last month
155
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Evaluation results