Instructions to use actionpace/EvolCodeLlama-7b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use actionpace/EvolCodeLlama-7b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="actionpace/EvolCodeLlama-7b")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("actionpace/EvolCodeLlama-7b") model = AutoModelForCausalLM.from_pretrained("actionpace/EvolCodeLlama-7b") - llama-cpp-python
How to use actionpace/EvolCodeLlama-7b with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="actionpace/EvolCodeLlama-7b", filename="EvolCodeLlama-7b_Q8_0.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use actionpace/EvolCodeLlama-7b with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf actionpace/EvolCodeLlama-7b:Q8_0 # Run inference directly in the terminal: llama-cli -hf actionpace/EvolCodeLlama-7b:Q8_0
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf actionpace/EvolCodeLlama-7b:Q8_0 # Run inference directly in the terminal: llama-cli -hf actionpace/EvolCodeLlama-7b:Q8_0
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf actionpace/EvolCodeLlama-7b:Q8_0 # Run inference directly in the terminal: ./llama-cli -hf actionpace/EvolCodeLlama-7b:Q8_0
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf actionpace/EvolCodeLlama-7b:Q8_0 # Run inference directly in the terminal: ./build/bin/llama-cli -hf actionpace/EvolCodeLlama-7b:Q8_0
Use Docker
docker model run hf.co/actionpace/EvolCodeLlama-7b:Q8_0
- LM Studio
- Jan
- vLLM
How to use actionpace/EvolCodeLlama-7b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "actionpace/EvolCodeLlama-7b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "actionpace/EvolCodeLlama-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/actionpace/EvolCodeLlama-7b:Q8_0
- SGLang
How to use actionpace/EvolCodeLlama-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 "actionpace/EvolCodeLlama-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": "actionpace/EvolCodeLlama-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 "actionpace/EvolCodeLlama-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": "actionpace/EvolCodeLlama-7b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Ollama
How to use actionpace/EvolCodeLlama-7b with Ollama:
ollama run hf.co/actionpace/EvolCodeLlama-7b:Q8_0
- Unsloth Studio new
How to use actionpace/EvolCodeLlama-7b with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for actionpace/EvolCodeLlama-7b to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for actionpace/EvolCodeLlama-7b to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for actionpace/EvolCodeLlama-7b to start chatting
- Docker Model Runner
How to use actionpace/EvolCodeLlama-7b with Docker Model Runner:
docker model run hf.co/actionpace/EvolCodeLlama-7b:Q8_0
- Lemonade
How to use actionpace/EvolCodeLlama-7b with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull actionpace/EvolCodeLlama-7b:Q8_0
Run and chat with the model
lemonade run user.EvolCodeLlama-7b-Q8_0
List all available models
lemonade list
Commit Β·
29de77b
1
Parent(s): 698d792
Upload tokenizer
Browse files- special_tokens_map.json +9 -4
- tokenizer.json +0 -0
- tokenizer_config.json +49 -11
special_tokens_map.json
CHANGED
|
@@ -1,23 +1,28 @@
|
|
| 1 |
{
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
"bos_token": {
|
| 3 |
"content": "<s>",
|
| 4 |
"lstrip": false,
|
| 5 |
-
"normalized":
|
| 6 |
"rstrip": false,
|
| 7 |
"single_word": false
|
| 8 |
},
|
| 9 |
"eos_token": {
|
| 10 |
"content": "</s>",
|
| 11 |
"lstrip": false,
|
| 12 |
-
"normalized":
|
| 13 |
"rstrip": false,
|
| 14 |
"single_word": false
|
| 15 |
},
|
| 16 |
-
"pad_token": "</s>",
|
| 17 |
"unk_token": {
|
| 18 |
"content": "<unk>",
|
| 19 |
"lstrip": false,
|
| 20 |
-
"normalized":
|
| 21 |
"rstrip": false,
|
| 22 |
"single_word": false
|
| 23 |
}
|
|
|
|
| 1 |
{
|
| 2 |
+
"additional_special_tokens": [
|
| 3 |
+
"β<PRE>",
|
| 4 |
+
"β<MID>",
|
| 5 |
+
"β<SUF>",
|
| 6 |
+
"β<EOT>"
|
| 7 |
+
],
|
| 8 |
"bos_token": {
|
| 9 |
"content": "<s>",
|
| 10 |
"lstrip": false,
|
| 11 |
+
"normalized": true,
|
| 12 |
"rstrip": false,
|
| 13 |
"single_word": false
|
| 14 |
},
|
| 15 |
"eos_token": {
|
| 16 |
"content": "</s>",
|
| 17 |
"lstrip": false,
|
| 18 |
+
"normalized": true,
|
| 19 |
"rstrip": false,
|
| 20 |
"single_word": false
|
| 21 |
},
|
|
|
|
| 22 |
"unk_token": {
|
| 23 |
"content": "<unk>",
|
| 24 |
"lstrip": false,
|
| 25 |
+
"normalized": true,
|
| 26 |
"rstrip": false,
|
| 27 |
"single_word": false
|
| 28 |
}
|
tokenizer.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
tokenizer_config.json
CHANGED
|
@@ -1,11 +1,9 @@
|
|
| 1 |
{
|
| 2 |
-
"add_bos_token": true,
|
| 3 |
-
"add_eos_token": false,
|
| 4 |
"added_tokens_decoder": {
|
| 5 |
"0": {
|
| 6 |
"content": "<unk>",
|
| 7 |
"lstrip": false,
|
| 8 |
-
"normalized":
|
| 9 |
"rstrip": false,
|
| 10 |
"single_word": false,
|
| 11 |
"special": true
|
|
@@ -13,7 +11,7 @@
|
|
| 13 |
"1": {
|
| 14 |
"content": "<s>",
|
| 15 |
"lstrip": false,
|
| 16 |
-
"normalized":
|
| 17 |
"rstrip": false,
|
| 18 |
"single_word": false,
|
| 19 |
"special": true
|
|
@@ -21,23 +19,63 @@
|
|
| 21 |
"2": {
|
| 22 |
"content": "</s>",
|
| 23 |
"lstrip": false,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 24 |
"normalized": false,
|
| 25 |
"rstrip": false,
|
| 26 |
"single_word": false,
|
| 27 |
"special": true
|
| 28 |
}
|
| 29 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 30 |
"bos_token": "<s>",
|
| 31 |
"clean_up_tokenization_spaces": false,
|
| 32 |
"eos_token": "</s>",
|
| 33 |
-
"
|
|
|
|
|
|
|
|
|
|
| 34 |
"model_max_length": 1000000000000000019884624838656,
|
| 35 |
-
"pad_token":
|
|
|
|
| 36 |
"sp_model_kwargs": {},
|
| 37 |
-
"
|
| 38 |
-
"tokenizer_class": "
|
| 39 |
-
"trust_remote_code": false,
|
| 40 |
"unk_token": "<unk>",
|
| 41 |
-
"use_default_system_prompt":
|
| 42 |
-
"use_fast": true
|
| 43 |
}
|
|
|
|
| 1 |
{
|
|
|
|
|
|
|
| 2 |
"added_tokens_decoder": {
|
| 3 |
"0": {
|
| 4 |
"content": "<unk>",
|
| 5 |
"lstrip": false,
|
| 6 |
+
"normalized": true,
|
| 7 |
"rstrip": false,
|
| 8 |
"single_word": false,
|
| 9 |
"special": true
|
|
|
|
| 11 |
"1": {
|
| 12 |
"content": "<s>",
|
| 13 |
"lstrip": false,
|
| 14 |
+
"normalized": true,
|
| 15 |
"rstrip": false,
|
| 16 |
"single_word": false,
|
| 17 |
"special": true
|
|
|
|
| 19 |
"2": {
|
| 20 |
"content": "</s>",
|
| 21 |
"lstrip": false,
|
| 22 |
+
"normalized": true,
|
| 23 |
+
"rstrip": false,
|
| 24 |
+
"single_word": false,
|
| 25 |
+
"special": true
|
| 26 |
+
},
|
| 27 |
+
"32007": {
|
| 28 |
+
"content": "β<PRE>",
|
| 29 |
+
"lstrip": false,
|
| 30 |
+
"normalized": false,
|
| 31 |
+
"rstrip": false,
|
| 32 |
+
"single_word": false,
|
| 33 |
+
"special": true
|
| 34 |
+
},
|
| 35 |
+
"32008": {
|
| 36 |
+
"content": "β<SUF>",
|
| 37 |
+
"lstrip": false,
|
| 38 |
+
"normalized": false,
|
| 39 |
+
"rstrip": false,
|
| 40 |
+
"single_word": false,
|
| 41 |
+
"special": true
|
| 42 |
+
},
|
| 43 |
+
"32009": {
|
| 44 |
+
"content": "β<MID>",
|
| 45 |
+
"lstrip": false,
|
| 46 |
+
"normalized": false,
|
| 47 |
+
"rstrip": false,
|
| 48 |
+
"single_word": false,
|
| 49 |
+
"special": true
|
| 50 |
+
},
|
| 51 |
+
"32010": {
|
| 52 |
+
"content": "β<EOT>",
|
| 53 |
+
"lstrip": false,
|
| 54 |
"normalized": false,
|
| 55 |
"rstrip": false,
|
| 56 |
"single_word": false,
|
| 57 |
"special": true
|
| 58 |
}
|
| 59 |
},
|
| 60 |
+
"additional_special_tokens": [
|
| 61 |
+
"β<PRE>",
|
| 62 |
+
"β<MID>",
|
| 63 |
+
"β<SUF>",
|
| 64 |
+
"β<EOT>"
|
| 65 |
+
],
|
| 66 |
"bos_token": "<s>",
|
| 67 |
"clean_up_tokenization_spaces": false,
|
| 68 |
"eos_token": "</s>",
|
| 69 |
+
"eot_token": "β<EOT>",
|
| 70 |
+
"fill_token": "<FILL_ME>",
|
| 71 |
+
"legacy": null,
|
| 72 |
+
"middle_token": "β<MID>",
|
| 73 |
"model_max_length": 1000000000000000019884624838656,
|
| 74 |
+
"pad_token": null,
|
| 75 |
+
"prefix_token": "β<PRE>",
|
| 76 |
"sp_model_kwargs": {},
|
| 77 |
+
"suffix_token": "β<SUF>",
|
| 78 |
+
"tokenizer_class": "CodeLlamaTokenizer",
|
|
|
|
| 79 |
"unk_token": "<unk>",
|
| 80 |
+
"use_default_system_prompt": false
|
|
|
|
| 81 |
}
|