Instructions to use Barkavi/LLAMA_7B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Barkavi/LLAMA_7B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Barkavi/LLAMA_7B")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("Barkavi/LLAMA_7B") model = AutoModelForCausalLM.from_pretrained("Barkavi/LLAMA_7B") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use Barkavi/LLAMA_7B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Barkavi/LLAMA_7B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Barkavi/LLAMA_7B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Barkavi/LLAMA_7B
- SGLang
How to use Barkavi/LLAMA_7B 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 "Barkavi/LLAMA_7B" \ --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": "Barkavi/LLAMA_7B", "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 "Barkavi/LLAMA_7B" \ --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": "Barkavi/LLAMA_7B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Barkavi/LLAMA_7B with Docker Model Runner:
docker model run hf.co/Barkavi/LLAMA_7B
[WIP] Upload folder using huggingface_hub (multi-commit 8a56b98d8ebcc4ccd340c86dd707bcdfe5e585a1dbeae68039b2bb36278baad8)
#1
by Barkavi - opened
Upload folder using huggingface_hub
Multi commit ID: 8a56b98d8ebcc4ccd340c86dd707bcdfe5e585a1dbeae68039b2bb36278baad8
Scheduled commits:
- Upload 8 file(s) totalling 2.0G (45dabbef3bb35a60d9805d64c9cddea57424f02f542df29363019e6b34ae00ac)
- Upload 5 file(s) totalling 2.1G (4e0b541d3b41923f26a973b9c5c2ac61a5ad3b57aba7495bce6c43f04670f58e)
- Upload 5 file(s) totalling 2.0G (8a74c4cbccc44f0056ada6a000b3da44b8d44409bd999d1244bd34ceed178d77)
- Upload 5 file(s) totalling 2.1G (4e62fbe231648b9f02f1eea299df5bf1851793f0b76544f2e96f92079fce5a45)
- Upload 5 file(s) totalling 2.0G (41e60c3fd5fd7d2d239c1366406b63e561901f509e066024a4aa7bfb04359aa6)
- Upload 5 file(s) totalling 2.1G (aa309ed869128e324640b22887d832e483963c3b021f276a5e7c847da37c523c)
- Upload 5 file(s) totalling 2.0G (3f56d28a766f9b74ed4f19cf1067dc772d7baf3d1b4e9d4b174f70266bcd6092)
- Upload 5 file(s) totalling 2.1G (3d5b4b63c0c44625b0e0fbbd31a085e8a6e24cb60cf5d3bc8190164f2bf2dca6)
- Upload 5 file(s) totalling 2.0G (03a27ef155b6f64aabce938e289d4c86f855f299bd464f8d57bdab50163871be)
- Upload 5 file(s) totalling 2.1G (da0b956e5ffe938104baa7c76bc68f2c97c5d3d9d1be1c0b8f334d7b77c930cb)
- Upload 5 file(s) totalling 2.0G (3bb808d46227918a53cf0b351bdda6718095c0fc2fb8896a0af44953b62ae95a)
- Upload 5 file(s) totalling 2.1G (f34b5c80497ac2e5c6dd38fe230cf5f7c0bb6c1ced919ed2f377cbba587164ca)
- Upload 5 file(s) totalling 2.0G (2ce2ed3ed937317e80af0891e3d6cea48ff34aa277ac2befdc80d40d6ed7c890)
- Upload 1 file(s) totalling 27.0G (16ba851d327d092a65dae56594cfeec36da9e8b6cd69bcc7f0771efba6ed1624)
- Upload 7 file(s) totalling 707.1M (128ba394fdd8595ea12c450a9aa750700f4975804903755e1d9d980eb2bbe0d2)
This is a PR opened using the huggingface_hub library in the context of a multi-commit. PR can be commented as a usual PR. However, please be aware that manually updating the PR description, changing the PR status, or pushing new commits, is not recommended as it might corrupt the commit process. Learn more about multi-commits in this guide.