Skip to content

Error: 400 Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead. #116

@sileht

Description

@sileht

Hi there,

We gave a try to ai-inference action with the openai/gpt-5-nano model but got this error:

Run actions/ai-inference@v2
  
Using legacy prompt format
Running simple inference without tools
Error: simpleInference: chatCompletion failed: Error: 400 Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead.
Error: 400 Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead.

Best,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions