Назад к моделям
GPT OSS Safeguard 20B
openaiopenai/gpt-oss-safeguard-20b
Гид по API
Классификация безопасности через Chat API
Модели gpt-oss-safeguard используют формат Harmony от OpenAI. Передайте политику и контент в сообщении пользователя. Модель вернёт структурированные рассуждения и заключение.
cURL
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-oss-safeguard-20b",
"messages": [
{
"role": "system",
"content": "You are a safety classifier. You must respond in the Harmony format."
},
{
"role": "user",
"content": "[POLICY]\nClassify the following user message as:\n- hate_speech: content that attacks or demeans a group based on protected attributes\n- harassment: content that targets an individual with threats or degrading language\n- safe: none of the above\n\n[CONTENT]\nI completely disagree with your opinion on this topic."
}
],
"reasoning_effort": "medium"
}'Настраиваемое усилие рассуждения
Модели gpt-oss-safeguard поддерживают низкое, среднее и высокое усилие рассуждений. 'low' для высокопроизводительной фильтрации, 'high' для сложных решений с детальной цепью рассуждений.
cURL
curl https://api.therouter.ai/v1/chat/completions \
-H "Authorization: Bearer $THEROUTER_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-oss-safeguard-20b",
"messages": [
{
"role": "system",
"content": "You are a safety classifier. Use the Harmony format."
},
{
"role": "user",
"content": "[POLICY]\n[your policy here]\n\n[CONTENT]\n[content to classify]"
}
],
"reasoning_effort": "high"
}'Реестр фактов — каждая утверждаемая величина имеет источник
| источник | URL | получено | |
|---|---|---|---|
| Дата релиза | openai.com ↗ | 2026-05-29 | проверено |
| Лицензия | huggingface.co ↗ | 2026-05-29 | проверено |
| Архитектура | github.com ↗ | 2026-05-29 | проверено |
| Базовая модель | openai.com ↗ | 2026-05-29 | проверено |
| Требования к GPU | huggingface.co ↗ | 2026-05-29 | проверено |
| Формат ответа | github.com ↗ | 2026-05-29 | проверено |
| Размер весов | huggingface.co ↗ | 2026-05-29 | проверено |
| Дата отсечения данных | — | — | неизвестно |
| Multi-policy accuracy (internal eval) | openai.com ↗ | 2026-05-29 | проверено |
| 2022 Moderation Evaluation Set | openai.com ↗ | 2026-05-29 | проверено |
| ToxicChat | openai.com ↗ | 2026-05-29 | проверено |
| OpenAI выпускает gpt-oss-safeguard — open-weight модели безопасности | openai.com ↗ | 2026-05-29 | проверено |
| Что такое формат Harmony и почему он обязателен? | cookbook.openai.com ↗ | 2026-05-29 | к проверке |
| Чем это отличается от Moderation API OpenAI? | openai.com ↗ | 2026-05-29 | к проверке |
| Какое усилие рассуждений следует использовать? | github.com ↗ | 2026-05-29 | к проверке |