Downloads · 30 days
3
5% of all-time downloads
pshahabinejad/Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged
Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged is a text generation model from pshahabinejad. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as llama3.1.
A fully merged model based on meta-llama/Llama-3.1-8B-Instruct fine-tuned with SecAlign++ Flex to make the model resistant to prompt injection attacks with flexible injection positions.
Downloads · 30 days
3
5% of all-time downloads
All-time downloads
55
Public
Parameters
8B
32.2 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors16.1 GB · 100%
From the Hugging Face model README
A fully merged model based on meta-llama/Llama-3.1-8B-Instruct fine-tuned with SecAlign++ Flex to make the model resistant to prompt injection attacks with flexible injection positions.
This is the merged (standalone) version of the PEFT LoRA adapter trained with the flex variant. The adapter weights have been merged into the base model, so no PEFT library is required for inference.
Since the adapter is fully merged, the model can be loaded directly with transformers:
from transformers import AutoTokenizer, AutoModelForCausalLM
model = AutoModelForCausalLM.from_pretrained("FlorianJK/Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged")
tokenizer = AutoTokenizer.from_pretrained("FlorianJK/Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged")
It is also compatible with vLLM:
from vllm import LLM
llm = LLM(model="FlorianJK/Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged")
SecAlign++ Flex extends SecAlign++ with flexible/random injection positions for improved robustness.
| Model | Description |
|---|---|
| FlorianJK/Meta-Llama-3.1-8B-SecAlign-pp-Flex-Merged | This model |
| FlorianJK/Meta-Llama-3.1-8B-SecAlign-pp-Merged | Standard SecAlign++ merged model |
| FlorianJK/Meta-Llama-3.1-8B-SecUnalign-pp-Merged | Inverted preferences (vulnerable baseline) |