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

Assistants API support #91

Closed
KenyonY opened this issue Nov 16, 2023 · 5 comments
Closed

Assistants API support #91

KenyonY opened this issue Nov 16, 2023 · 5 comments
Labels
enhancement New feature or request

Comments

@KenyonY
Copy link
Owner

KenyonY commented Nov 16, 2023

Detailed Description

ref: https://platform.openai.com/docs/api-reference/assistants

curl "https://api.openai.com/v1/assistants" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $OPENAI_API_KEY" \
  -H "OpenAI-Beta: assistants=v1" \
  -d '{
    "instructions": "You are a personal math tutor. When asked a question, write and run Python code to answer the question.",
    "name": "Math Tutor",
    "tools": [{"type": "code_interpreter"}],
    "model": "gpt-4"
  }'
@KenyonY KenyonY added the enhancement New feature or request label Nov 16, 2023
@wsdo
Copy link

wsdo commented Nov 16, 2023

所以 这个加上了吗?

BadRequestError: Error code: 400 - {'error': {'message': "You must provide the 'OpenAI-Beta' header to access the Assistants API. Please try again by setting the header 'OpenAI-Beta: assistants=v1'.", 'type': 'invalid_request_error', 'param': None, 'code': 'invalid_beta'}}

@wsdo
Copy link

wsdo commented Nov 16, 2023

有没有群,可以直接反馈交流

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


Is there a group where we can give feedback and communicate directly?

@KenyonY
Copy link
Owner Author

KenyonY commented Nov 16, 2023

@wsdo 已经合并进main分支了,可以试试看

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically.


@wsdo has been merged into the main branch, you can give it a try

@KenyonY KenyonY closed this as completed Nov 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants