Downloads · 30 days
1
1% of all-time downloads
gandhiraketla277/finance-llama-3.1-8b-peft-trained
finance-llama-3.1-8b-peft-trained is a text generation model from gandhiraketla277. Use it when you need the model to write or continue text. It is set up for peft.
This model is a PEFT (Parameter Efficient Fine-Tuning) version of the finance LLaMA model, fine-tuned on financial question-answering data using LoRA adapters.
Downloads · 30 days
1
1% of all-time downloads
All-time downloads
83
Public
Repo size
185 MB
Likes
0
Public
Click a slice to open those files.
.safetensors168 MB · 91%
From the Hugging Face model README
This model is a PEFT (Parameter Efficient Fine-Tuning) version of the finance LLaMA model, fine-tuned on financial question-answering data using LoRA adapters.
import unsloth
from unsloth import FastLanguageModel
from peft import PeftModel
# Load base model
base_model, tokenizer = FastLanguageModel.from_pretrained(
"gandhiraketla277/finance-llama-3.1-8b-merged",
max_seq_length=2048,
dtype=None,
load_in_4bit=True,
)
# Load PEFT adapters
model = PeftModel.from_pretrained(base_model, "gandhiraketla277/finance-llama-3.1-8b-peft-trained")
# Enable inference mode
FastLanguageModel.for_inference(model)
# Generate response
prompt = "What is the best investment strategy for beginners?"
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=200, temperature=0.7)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)
print(response)
This model is designed for educational and informational purposes in the finance domain. It should not be used as the sole basis for financial decisions.