Free Tool
Prompt Formatter
Convert prompts between different model formats. Enter your system prompt and user message, pick a format, copy the output.
Select Target Format
MOCK API SESSION SANDBOX PREVIEW
⚙️ System Rules Configuration
You are an expert technical editor auditing technical docs for flow.
🧑 User Input Message
Review this chapter and suggest adjustments.
🤖 Expected Assistant Completion
formatting rules mapped...
Calculations utilize official schema profiles. Verification in dev contexts is recommended prior to scripting automated prompts.
Why prompt formats matter
When you use an LLM API or a fine-tuned model locally, the model expects input in a specific format. Using the wrong format will cause the model to ignore your system prompt, produce worse outputs, or fail entirely.
This is especially important when:
- Running instruct-tuned models locally via Ollama or llama.cpp
- Fine-tuning models on your own dataset
- Switching between API providers
- Creating synthetic training data
Supported formats
- ChatML: Used by OpenAI's GPT models and most compatible derivatives.
<|im_start|>/<|im_end|>tokens. - Llama 3: Meta's format using
<|begin_of_text|>,<|start_header_id|>, and<|eot_id|>tokens. - Mistral: Simple
[INST]/[/INST]wrapping. System prompt is merged into the first user message. - Gemma 2: Google's format using
<start_of_turn>/<end_of_turn>. - Phi-3: Microsoft's format using
<|system|>,<|user|>,<|assistant|>with<|end|>. - Anthropic Messages API: JSON format for the Claude API.
- OpenAI Chat API: JSON messages format for GPT-4 and compatible APIs.
Related tools
- AI Token Calculator — Count tokens in your formatted prompts
- Context Window Calculator — Plan context allocation