File size: 979 Bytes
840fbfa
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
d2a238c
 
 
840fbfa
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
language: en
tags:
  - causal-lm
  - secure-model
  - merged-lora
license: apache-2.0
---

# Llama-3.1-8b-Instruct-Secure

This model is fine-tuned with LoRA adapters for secure behavior and low ASR (Attack Success Rate).

## Model Details

- **Base Model**: Llama-3.1-8b-Instruct
- **Fine-tuning**: LoRA method
- **Purpose**: Secure language model with defenses against jailbreaking.

## Training Details

- **Dataset**: Custom synthetic data
- **Framework**: PyTorch
- **Sharding**: Model is saved in shards of 100MB to ensure compatibility.

## Usage

Load the model and tokenizer as follows:

```python
from transformers import AutoTokenizer, AutoModelForCausalLM

model_name = "SanjanaCodes/Llama-3.1-8b-Instruct-Secure"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(model_name)

inputs = tokenizer("Your input prompt here", return_tensors="pt")
outputs = model.generate(**inputs)
print(tokenizer.decode(outputs[0]))