Text Generation
Transformers
Safetensors
Persian
llama
text-generation-inference
8-bit precision
bitsandbytes
Instructions to use Neurai/NeuraLlama7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Neurai/NeuraLlama7b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Neurai/NeuraLlama7b")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Neurai/NeuraLlama7b") model = AutoModelForCausalLM.from_pretrained("Neurai/NeuraLlama7b", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Neurai/NeuraLlama7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Neurai/NeuraLlama7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Neurai/NeuraLlama7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Neurai/NeuraLlama7b
- SGLang
How to use Neurai/NeuraLlama7b 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 "Neurai/NeuraLlama7b" \ --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": "Neurai/NeuraLlama7b", "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 "Neurai/NeuraLlama7b" \ --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": "Neurai/NeuraLlama7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Neurai/NeuraLlama7b with Docker Model Runner:
docker model run hf.co/Neurai/NeuraLlama7b
Download tokenizer.model from Neurai/NeuraLlama7b: direct link, hf CLI and curl.
- Browser
- Download file 938 kB
-
https://huggingface.co/Neurai/NeuraLlama7b/resolve/main/tokenizer.model
- Command line
-
hf download hf://Neurai/NeuraLlama7b/tokenizer.model
-
curl -L -o tokenizer.model https://huggingface.co/Neurai/NeuraLlama7b/resolve/main/tokenizer.model
938 kB
- Xet hash:
- adf31512f9ddc39203cd13c16fe9ac9764b00bb4aa8397a1b004601e7cf0fc3a
- Size of remote file:
- 938 kB
- SHA256:
- 78e0803c7ea783eae5378dfa5c348d1f53e08c6f0b1efd837e36d4988672d8c5
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.