Instructions to use Tap-M/Luna-AI-Llama2-Uncensored with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Tap-M/Luna-AI-Llama2-Uncensored with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Tap-M/Luna-AI-Llama2-Uncensored")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Tap-M/Luna-AI-Llama2-Uncensored") model = AutoModelForCausalLM.from_pretrained("Tap-M/Luna-AI-Llama2-Uncensored") - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Tap-M/Luna-AI-Llama2-Uncensored with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Tap-M/Luna-AI-Llama2-Uncensored" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Tap-M/Luna-AI-Llama2-Uncensored", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Tap-M/Luna-AI-Llama2-Uncensored
- SGLang
How to use Tap-M/Luna-AI-Llama2-Uncensored 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 "Tap-M/Luna-AI-Llama2-Uncensored" \ --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": "Tap-M/Luna-AI-Llama2-Uncensored", "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 "Tap-M/Luna-AI-Llama2-Uncensored" \ --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": "Tap-M/Luna-AI-Llama2-Uncensored", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Tap-M/Luna-AI-Llama2-Uncensored with Docker Model Runner:
docker model run hf.co/Tap-M/Luna-AI-Llama2-Uncensored
Model Description
βLuna AI Llama2 Uncensoredβ is a Llama2 based Chat model
fine-tuned on over 40,000 long form chat discussions
This model was fine-tuned by Tap, the creator of Luna AI.
Model Training
The fine-tuning process was performed on an 8x a100 80GB machine.
The model was trained on synthetic outputs which include multiple rounds of chats between Human & AI.
4bit GPTQ Version provided by @TheBloke - for GPU inference
GGML Version provided by @TheBloke - For CPU inference
Prompt Format
The model follows the Vicuna 1.1/ OpenChat format:
USER: I have difficulties in making friends, and I really need someone to talk to. Would you be my friend?
ASSISTANT: Of course! Friends are always here for each other. What do you like to do?
Benchmark Results
| Task | Version | Metric | Value | Stderr |
| arc_challenge | 0 | acc_norm | 0.5512 | 0.0146 |
| hellaswag | 0 | |||
| mmlu | 1 | acc_norm | 0.46521 | 0.036 |
| truthfulqa_mc | 1 | mc2 | 0.4716 | 0.0155 |
| Average | - | - | 0.5114 | 0.0150 |
- Downloads last month
- 159