Skip to content

support developer role in chat completions API#867

Merged
adilhafeez merged 1 commit intomainfrom
adil/support-developer-role
Apr 3, 2026
Merged

support developer role in chat completions API#867
adilhafeez merged 1 commit intomainfrom
adil/support-developer-role

Conversation

@adilhafeez
Copy link
Copy Markdown
Contributor

@adilhafeez adilhafeez commented Apr 2, 2026

Adds support for the developer message role in the OpenAI Chat Completions API.

Problem

Clients sending "role": "developer" (introduced by OpenAI for reasoning models like o1/o3) get a 400 error because Plano's Role enum only accepted system, user, assistant, and tool.

Changes

  • Added Developer variant to the Role enum in openai.rs
  • When targeting OpenAI: developer passes through natively
  • When targeting Anthropic/Bedrock: developer maps to system prompt (those providers don't have a developer role)
  • Router/orchestrator: developer messages filtered out same as system (not used for routing decisions)

@adilhafeez adilhafeez merged commit 7606c55 into main Apr 3, 2026
21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants