Views
No views yet
unsloth/llama-3.2-1b-bnb-4bit/hackrx/run)1from transformers import AutoModelForCausalLM, AutoTokenizer, pipeline
2import torch
3
4model_id = "aravsaxena/legal-tech-llama-1b-lora"
5
6tokenizer = AutoTokenizer.from_pretrained(model_id)
7model = AutoModelForCausalLM.from_pretrained(model_id, torch_dtype=torch.float16, device_map="auto")
8
9qa = pipeline("text-generation", model=model, tokenizer=tokenizer)
10qa("Q: What are the key clauses in a Non-Disclosure Agreement?\nA:")