Run this model with HF Jobs

Run rvv-karma/BASH-Coder-Mistral-7B 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/rvv-karma/BASH-Coder-Mistral-7B. 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/rvv-karma/BASH-Coder-Mistral-7B 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/rvv-karma/BASH-Coder-Mistral-7B. 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/rvv-karma/BASH-Coder-Mistral-7B. 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.

Commonsense-QA-Mistral-7B

This is a finetuned model of mistralai/Mistral-7B-Instruct-v0.1 with neulab/tldr dataset.

The model is loaded in 4-bit and fine-tuned with LoRA.

Usage

Loading of model:

# Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM

model = AutoModelForCausalLM.from_pretrained(
    "rvv-karma/BASH-Coder-Mistral-7B",
    low_cpu_mem_usage=True,
    return_dict=True,
    torch_dtype=torch.bfloat16,
    device_map="auto",
)

tokenizer = AutoTokenizer.from_pretrained("rvv-karma/BASH-Coder-Mistral-7B", trust_remote_code=True)
tokenizer.pad_token = tokenizer.eos_token
tokenizer.padding_side = "left"

Sample:

pipe = pipeline(
    task="text-generation",
    model=model,
    tokenizer=tokenizer,
    return_full_text=False,
    pad_token_id=tokenizer.pad_token_id,
    eos_token_id=13,
    max_new_tokens=8
)

prompt = """QUESTION: fix a given ntfs partition
ANSWER: """
result = pipe(prompt)
generated = result[0]['generated_text']
print(generated)

# Output: sudo ntfsfix {{/dev/sdXN}}

Fine-tuning script

Kaggle Notebook

Downloads last month
32
Safetensors
Model size
7B params
Tensor type
BF16
ยท
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for rvv-karma/BASH-Coder-Mistral-7B

Merges
1 model

Dataset used to train rvv-karma/BASH-Coder-Mistral-7B