Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

o1 API endpoint not supported #3698

Open
3 tasks done
RudyD opened this issue Jan 13, 2025 · 3 comments
Open
3 tasks done

o1 API endpoint not supported #3698

RudyD opened this issue Jan 13, 2025 · 3 comments
Assignees
Labels
area:configuration Relates to configuration options ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior "needs-triage" priority:medium Indicates medium priority

Comments

@RudyD
Copy link

RudyD commented Jan 13, 2025

Before submitting your bug report

Relevant environment info

- OS: Windows 11 Pro (24H2)
- Continue version: 0.8.66
- IDE version: VS Code 1.96.2
- Model: o1
- config.json:
  
{
  "models": [
    {
      "model": "o1",
      "title": "o1",
      "systemMessage": "You are an expert software developer. You give helpful and concise responses.",
      "apiKey": "super-secret-api-key",
      "completionOptions": {},
      "provider": "openai"
}
]

Description

When attempting to use OpenAI o1 model, I receive the following error message:

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

To reproduce

  1. Update your config.json to use OpenAI o1 model.
  2. Select the o1 model via VS Code Continue plugin.
  3. Send a message (e.g. - "Can you read this?") to o1 thru the plugin.
  4. BUG!: The following error message appears 400 Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead.

Log output

console.ts:137 [Extension Host] Error handling webview message: {
  "msg": {
    "messageId": "f31f07a1-e573-4dc8-ad94-dfccd2e025d5",
    "messageType": "llm/streamChat",
    "data": {
      "messages": [
        {
          "role": "user",
          "content": [
            {
              "type": "text",
              "text": "Can you read this?"
            }
          ]
        },
        {
          "role": "assistant",
          "content": ""
        }
      ],
      "title": "o1",
      "completionOptions": {}
    }
  }
}

Error: 400 Unsupported parameter: 'max_tokens' is not supported with this model. Use 'max_completion_tokens' instead.
EYi	@	console.ts:137
@RudyD
Copy link
Author

RudyD commented Jan 13, 2025

I also posted on Discord. Someone else was running into the same issue:
https://discord.com/channels/1108621136150929458/1327756273126477985/1327757333107052637

@dosubot dosubot bot added area:configuration Relates to configuration options ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior priority:medium Indicates medium priority labels Jan 13, 2025
@RudyD
Copy link
Author

RudyD commented Jan 13, 2025

I also tried pre-release version of the VS Code Extension and it provided a different message when running the same reproduction steps.

console.ts:137 [Extension Host] Error handling webview message: {
  "msg": {
    "messageId": "e58a531a-a0db-4201-88fa-35af4d659e3f",
    "messageType": "llm/streamChat",
    "data": {
      "messages": [
        {
          "role": "user",
          "content": [
            {
              "type": "text",
              "text": "Hello, World!"
            }
          ]
        },
        {
          "role": "assistant",
          "content": ""
        }
      ],
      "title": "o1",
      "completionOptions": {}
    }
  }
}

Error: 400 Unsupported value: 'stream' does not support true with this model. Supported values are: false.

@RudyD
Copy link
Author

RudyD commented Jan 13, 2025

Hi @Patrick-Erichsen : I see you're assigned to the potential bug. I can help try to resolve it by coding a fix and submitting a pull request, but I am struggling to create a branch that I can actively work the issue on. I suspect my ability to create a branch has been disabled by design for security reasons. If you want me to pitch in, let me know how. Thanks in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:configuration Relates to configuration options ide:vscode Relates specifically to VS Code extension kind:bug Indicates an unexpected problem or unintended behavior "needs-triage" priority:medium Indicates medium priority
Projects
None yet
Development

No branches or pull requests

2 participants