Created
April 21, 2025 20:26
-
-
Save AfzalivE/0eaa65335ae252449d58d7e6a72f756a to your computer and use it in GitHub Desktop.
Ollama structured output
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<|im_start|>system | |
Only answer with a JSON string complying with the following schema: | |
{ | |
"type": "object", | |
"properties" : { | |
"emoji": { | |
"type": "string", | |
"enum": [🕶️, 🐛, ⭐, ⛳ ] | |
} | |
}, | |
"required": [emoji] | |
} | |
<|im_end|> | |
<|im_start|>user | |
hello<|im_end|> | |
<|im_start|>assistant | |
Hello! How can I assist you today? Is there anything specific you'd like to know or discuss?<|im_end|> | |
<|im_start|>user | |
Does the following commit message sound like | |
1. Internal change 🕶️ | |
2. feature ⭐ | |
3. Bug fix 🐛 | |
4. Something behind a feature flag ⛳ | |
"Remove cache access from DeleteItemsFragment"<|im_end|> | |
<|im_start|>assistant | |
{"emoji": "🕶️"}<|im_end|> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment