Text Generation
Transformers
PyTorch
Safetensors
Serbian
gpt2
Srpski
Serbian
GPT2
generisanje
text-generation-inference
Instructions to use jerteh/gpt2-vrabac with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jerteh/gpt2-vrabac with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="jerteh/gpt2-vrabac")# Load model directly from transformers import AutoTokenizer, AutoModelForMultimodalLM tokenizer = AutoTokenizer.from_pretrained("jerteh/gpt2-vrabac") model = AutoModelForMultimodalLM.from_pretrained("jerteh/gpt2-vrabac") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use jerteh/gpt2-vrabac with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "jerteh/gpt2-vrabac" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jerteh/gpt2-vrabac", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/jerteh/gpt2-vrabac
- SGLang
How to use jerteh/gpt2-vrabac 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 "jerteh/gpt2-vrabac" \ --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": "jerteh/gpt2-vrabac", "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 "jerteh/gpt2-vrabac" \ --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": "jerteh/gpt2-vrabac", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use jerteh/gpt2-vrabac with Docker Model Runner:
docker model run hf.co/jerteh/gpt2-vrabac
Update README.md
Browse files
README.md
CHANGED
|
@@ -90,14 +90,19 @@ Modeli su obučavani na Nacionalnoj platformi za veštačku inteligenciju Srbije
|
|
| 90 |
.highlight{
|
| 91 |
color:white;
|
| 92 |
text-transform:uppercase;
|
| 93 |
-
font-size: 16pt
|
|
|
|
| 94 |
}
|
| 95 |
|
|
|
|
|
|
|
|
|
|
|
|
|
| 96 |
.highlight-container:before {
|
| 97 |
content: " ";
|
| 98 |
display: block;
|
| 99 |
-
height:
|
| 100 |
-
width:
|
| 101 |
margin-left: 0px;
|
| 102 |
margin-right: 0px;
|
| 103 |
position: absolute;
|
|
@@ -106,7 +111,7 @@ Modeli su obučavani na Nacionalnoj platformi za veštačku inteligenciju Srbije
|
|
| 106 |
top: -1px;
|
| 107 |
left: -1px;
|
| 108 |
border-radius: 20% 25% 20% 24%;
|
| 109 |
-
padding: 10px
|
| 110 |
}
|
| 111 |
|
| 112 |
div.grb, #zastava>table {
|
|
|
|
| 90 |
.highlight{
|
| 91 |
color:white;
|
| 92 |
text-transform:uppercase;
|
| 93 |
+
font-size: 16pt;
|
| 94 |
+
|
| 95 |
}
|
| 96 |
|
| 97 |
+
.highlight-container{
|
| 98 |
+
padding:5px 10px
|
| 99 |
+
}
|
| 100 |
+
|
| 101 |
.highlight-container:before {
|
| 102 |
content: " ";
|
| 103 |
display: block;
|
| 104 |
+
height: 100%;
|
| 105 |
+
width: 100%;
|
| 106 |
margin-left: 0px;
|
| 107 |
margin-right: 0px;
|
| 108 |
position: absolute;
|
|
|
|
| 111 |
top: -1px;
|
| 112 |
left: -1px;
|
| 113 |
border-radius: 20% 25% 20% 24%;
|
| 114 |
+
padding: 10px 18px 18px 10px;
|
| 115 |
}
|
| 116 |
|
| 117 |
div.grb, #zastava>table {
|