Views
No views yet
| Property | Value |
|---|---|
| Base model | Qwen/Qwen2.5-1.5B-Instruct |
| Adapter version | AYI-NEDJIMI/ISO27001-Expert-1.5B |
| Parameters | 1.5B |
| LoRA rank (r) | 64 |
| LoRA alpha | 128 |
| Precision | float16 |
| License | Apache 2.0 |
1from transformers import AutoModelForCausalLM, AutoTokenizer
2
3model_id = "AYI-NEDJIMI/ISO27001-Expert-1.5B-Merged"
4
5tokenizer = AutoTokenizer.from_pretrained(model_id)
6model = AutoModelForCausalLM.from_pretrained(
7 model_id,
8 torch_dtype="auto",
9 device_map="auto",
10)
11
12messages = [
13 {"role": "system", "content": "You are a helpful assistant."},
14 {"role": "user", "content": "Explain the key principles of ISO 27001."},
15]
16
17text = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
18inputs = tokenizer(text, return_tensors="pt").to(model.device)
19outputs = model.generate(**inputs, max_new_tokens=512)
20print(tokenizer.decode(outputs[0], skip_special_tokens=True))Note: No need to install or importpeft— this model is fully standalone.
model.merge_and_unload() from the PEFT library to produce this standalone checkpoint.