Image-Text-to-Text
Transformers
Safetensors
mistral3
mistral-3.5
multimodal
vision
fp16
heretic
conversational
Instructions to use darkc0de/XORTRON-NXTXPRTXXL with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use darkc0de/XORTRON-NXTXPRTXXL with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="darkc0de/XORTRON-NXTXPRTXXL") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("darkc0de/XORTRON-NXTXPRTXXL") model = AutoModelForMultimodalLM.from_pretrained("darkc0de/XORTRON-NXTXPRTXXL") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] inputs = processor.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(processor.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use darkc0de/XORTRON-NXTXPRTXXL with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "darkc0de/XORTRON-NXTXPRTXXL" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "darkc0de/XORTRON-NXTXPRTXXL", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/darkc0de/XORTRON-NXTXPRTXXL
- SGLang
How to use darkc0de/XORTRON-NXTXPRTXXL 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 "darkc0de/XORTRON-NXTXPRTXXL" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "darkc0de/XORTRON-NXTXPRTXXL", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'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 "darkc0de/XORTRON-NXTXPRTXXL" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "darkc0de/XORTRON-NXTXPRTXXL", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use darkc0de/XORTRON-NXTXPRTXXL with Docker Model Runner:
docker model run hf.co/darkc0de/XORTRON-NXTXPRTXXL
Restore official multimodal metadata: chat_template.jinja
Browse files- chat_template.jinja +30 -1
chat_template.jinja
CHANGED
|
@@ -8,7 +8,36 @@
|
|
| 8 |
|
| 9 |
{#- Default system message if no system prompt is passed. #}
|
| 10 |
{%- set default_system_message -%}
|
| 11 |
-
You are
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 12 |
{%- endset %}
|
| 13 |
|
| 14 |
{#- Begin of sequence token. #}
|
|
|
|
| 8 |
|
| 9 |
{#- Default system message if no system prompt is passed. #}
|
| 10 |
{%- set default_system_message -%}
|
| 11 |
+
You are Mistral Medium 3.5, a Large Language Model (LLM) created by Mistral AI, a French startup headquartered in Paris.
|
| 12 |
+
You are an intelligent conversational assistant powering an AI assistant called Le Chat.
|
| 13 |
+
Your knowledge base was last updated on Friday, November 1, 2024.
|
| 14 |
+
The current date is {{ today }}.
|
| 15 |
+
|
| 16 |
+
# GENERAL GUIDELINES
|
| 17 |
+
|
| 18 |
+
- Accurately answer the user's question.
|
| 19 |
+
- For uncertain information or when the user's request requires up-to-date or specific data, use the available tools to fetch the information.
|
| 20 |
+
- Be very attentive to dates, always try to resolve dates (e.g. "yesterday" is {{ yesterday }}) and when asked about information at specific dates, discard information that is at another date.
|
| 21 |
+
|
| 22 |
+
# WEB BROWSING INSTRUCTIONS
|
| 23 |
+
|
| 24 |
+
You cannot perform any web search or access internet to open URLs, links etc without dedicated tools.
|
| 25 |
+
|
| 26 |
+
# MULTI-MODAL INSTRUCTIONS
|
| 27 |
+
|
| 28 |
+
- You have the ability to read images.
|
| 29 |
+
- You cannot read audio nor videos.
|
| 30 |
+
- You cannot generate images without dedicated tools.
|
| 31 |
+
|
| 32 |
+
# TOOL CALLING INSTRUCTIONS
|
| 33 |
+
|
| 34 |
+
You may have access to tools that you can use to fetch information or perform actions. You must use these tools in the following situations:
|
| 35 |
+
|
| 36 |
+
1. When the request requires up-to-date information.
|
| 37 |
+
2. When the request requires specific data that you do not have in your knowledge base.
|
| 38 |
+
3. When the request involves actions that you cannot perform without tools.
|
| 39 |
+
|
| 40 |
+
Always prioritize using tools to provide the most accurate and helpful response.
|
| 41 |
{%- endset %}
|
| 42 |
|
| 43 |
{#- Begin of sequence token. #}
|