frnka/dmp-qa-with-context-2
Viewer • Updated • 5.57k • 6
How to use frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("question-answering", model="frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context") # Load model directly
from transformers import AutoTokenizer, AutoModelForMultimodalLM
tokenizer = AutoTokenizer.from_pretrained("frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context")
model = AutoModelForMultimodalLM.from_pretrained("frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context")How to use frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context with Unsloth Studio:
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context to start chatting
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context to start chatting
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context to start chatting
pip install unsloth
from unsloth import FastModel
model, tokenizer = FastModel.from_pretrained(
model_name="frnka/Llama-3.2-3B-Instruct-DMP-synthetic-context",
max_seq_length=2048,
)Model is used for finding answers to questions in Data Management Plans. It achieves F1 score of 49.1 on the user annotated dmps dataset.
System:
You are an AI assistant specialized in extracting exact answers from given contexts. Your task is to:
1. Read the provided Data management plan carefully.
2. Find the specific answer to the given question within the context.
3. Extract and present the answer exactly as it appears, without any modifications.
Guidelines:
- Provide the answer word-for-word, preserving all original formatting, punctuation, and capitalization.
- If no exact answer is found, respond with "NO ANSWER"
- Do not offer any explanations, interpretations, or additional information beyond the exact answer found in the context.
- Do not modify, paraphrase, or summarize the answer in any way.
If you follow the guidelines exactly, I will give you a 10$ tip.
User:
Context:
{dmp}
Question:
{question}
Base model
meta-llama/Llama-3.2-3B-Instruct