Image-Text-to-Text
Transformers
Safetensors
gemma3
Generated from Trainer
trl
sft
text-generation-inference
Instructions to use JZSG/ack-annotator-v1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use JZSG/ack-annotator-v1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="JZSG/ack-annotator-v1")# Load model directly from transformers import AutoProcessor, AutoModelForImageTextToText processor = AutoProcessor.from_pretrained("JZSG/ack-annotator-v1") model = AutoModelForImageTextToText.from_pretrained("JZSG/ack-annotator-v1") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use JZSG/ack-annotator-v1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "JZSG/ack-annotator-v1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "JZSG/ack-annotator-v1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/JZSG/ack-annotator-v1
- SGLang
How to use JZSG/ack-annotator-v1 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 "JZSG/ack-annotator-v1" \ --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": "JZSG/ack-annotator-v1", "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 "JZSG/ack-annotator-v1" \ --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": "JZSG/ack-annotator-v1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use JZSG/ack-annotator-v1 with Docker Model Runner:
docker model run hf.co/JZSG/ack-annotator-v1
Commit ·
d802eef
1
Parent(s): 0dad1f0
Update README.md
Browse files
README.md
CHANGED
|
@@ -6,52 +6,4 @@ tags:
|
|
| 6 |
- trl
|
| 7 |
- sft
|
| 8 |
licence: license
|
| 9 |
-
---
|
| 10 |
-
|
| 11 |
-
# Model Card for ack-annotator-v1
|
| 12 |
-
|
| 13 |
-
This model is a fine-tuned version of [None](https://huggingface.co/None).
|
| 14 |
-
It has been trained using [TRL](https://github.com/huggingface/trl).
|
| 15 |
-
|
| 16 |
-
## Quick start
|
| 17 |
-
|
| 18 |
-
```python
|
| 19 |
-
from transformers import pipeline
|
| 20 |
-
|
| 21 |
-
question = "If you had a time machine, but could only go to the past or the future once and never return, which would you choose and why?"
|
| 22 |
-
generator = pipeline("text-generation", model="None", device="cuda")
|
| 23 |
-
output = generator([{"role": "user", "content": question}], max_new_tokens=128, return_full_text=False)[0]
|
| 24 |
-
print(output["generated_text"])
|
| 25 |
-
```
|
| 26 |
-
|
| 27 |
-
## Training procedure
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
This model was trained with SFT.
|
| 33 |
-
|
| 34 |
-
### Framework versions
|
| 35 |
-
|
| 36 |
-
- TRL: 0.19.1
|
| 37 |
-
- Transformers: 4.52.4
|
| 38 |
-
- Pytorch: 2.6.0
|
| 39 |
-
- Datasets: 3.6.0
|
| 40 |
-
- Tokenizers: 0.21.1
|
| 41 |
-
|
| 42 |
-
## Citations
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
Cite TRL as:
|
| 47 |
-
|
| 48 |
-
```bibtex
|
| 49 |
-
@misc{vonwerra2022trl,
|
| 50 |
-
title = {{TRL: Transformer Reinforcement Learning}},
|
| 51 |
-
author = {Leandro von Werra and Younes Belkada and Lewis Tunstall and Edward Beeching and Tristan Thrush and Nathan Lambert and Shengyi Huang and Kashif Rasul and Quentin Gallou{\'e}dec},
|
| 52 |
-
year = 2020,
|
| 53 |
-
journal = {GitHub repository},
|
| 54 |
-
publisher = {GitHub},
|
| 55 |
-
howpublished = {\url{https://github.com/huggingface/trl}}
|
| 56 |
-
}
|
| 57 |
-
```
|
|
|
|
| 6 |
- trl
|
| 7 |
- sft
|
| 8 |
licence: license
|
| 9 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|