Downloads · 30 days
3
18% of all-time downloads
Orenbac/fingpt-forecaster
fingpt-forecaster is a machine learning model from Orenbac. Use it for the machine learning task on the model card, and read the license before you ship it in a product. It is set up for peft.
Check out our github: https://github.com/AI4Finance-Foundation/FinGPT/tree/master/fingpt/FinGPTForecaster
Downloads · 30 days
3
18% of all-time downloads
All-time downloads
17
Public
Repo size
27 GB
Likes
0
Public
Click a slice to open those files.
.bin13.5 GB · 50%
From the Hugging Face model README
Check out our github: https://github.com/AI4Finance-Foundation/FinGPT/tree/master/fingpt/FinGPT_Forecaster
from datasets import load_dataset
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import PeftModel
base_model = AutoModelForCausalLM.from_pretrained(
'meta-llama/Llama-2-7b-chat-hf',
trust_remote_code=True,
device_map="auto",
torch_dtype=torch.float16, # optional if you have enough VRAM
)
tokenizer = AutoTokenizer.from_pretrained('meta-llama/Llama-2-7b-chat-hf')
model = PeftModel.from_pretrained('FinGPT/fingpt-forecaster_dow30_llama2-7b_lora')
model = model.eval()