Instructions to use DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged") model = AutoModelForCausalLM.from_pretrained("DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged") - Inference
- Local Apps Settings
- vLLM
How to use DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged
- SGLang
How to use DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged with Docker Model Runner:
docker model run hf.co/DS-Archive/Nous-Hermes-Llama2-13b-Limarp-Lora-Merged
Commit ·
398335c
1
Parent(s): ef4ad7c
Create README.md
Browse files
README.md
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
language:
|
| 3 |
+
- en
|
| 4 |
+
library_name: transformers
|
| 5 |
+
pipeline_tag: text-generation
|
| 6 |
+
tags:
|
| 7 |
+
- llama-2
|
| 8 |
+
---
|
| 9 |
+
|
| 10 |
+
# Model Card: Nous-Hermes-Llama-2-13b-LIMARP-Lora-Merged
|
| 11 |
+
|
| 12 |
+
This is Nous Hermes Llama 2 13b (https://huggingface.co/NousResearch/Nous-Hermes-Llama2-13b) merged with LIMARP Lora (https://huggingface.co/lemonilia/limarp-llama2) using the now-updated standard lora adapter for LIMARP (July 28, 2023).
|
| 13 |
+
|
| 14 |
+
The intended objective was to combine NH-L2's reasoning and instruction-following capabilities with LIMARP's character roleplay capabilities.
|
| 15 |
+
|
| 16 |
+
added_tokens.json was padded with dummy tokens to reach 32 added tokens in order to allow GGML conversion in llama.cpp without error due to vocab size mismatch.
|
| 17 |
+
|
| 18 |
+
## Usage:
|
| 19 |
+
|
| 20 |
+
Intended to be prompted either with Alpaca instruction format of the NH-L2 base model:
|
| 21 |
+
|
| 22 |
+
```
|
| 23 |
+
### Instruction:
|
| 24 |
+
<prompt>
|
| 25 |
+
|
| 26 |
+
### Response:
|
| 27 |
+
<leave a newline blank for model to respond>
|
| 28 |
+
```
|
| 29 |
+
|
| 30 |
+
Or the LIMARP lora instruction format:
|
| 31 |
+
|
| 32 |
+
```
|
| 33 |
+
<<SYSTEM>>
|
| 34 |
+
<character card and system prompt>
|
| 35 |
+
|
| 36 |
+
<<USER>>
|
| 37 |
+
<prompt>
|
| 38 |
+
|
| 39 |
+
<<AIBOT>>
|
| 40 |
+
<leave a newline blank for model to respond>
|
| 41 |
+
```
|