Error when uploading files assistant purpose

from openai import OpenAI
client = OpenAI(api_key=“”)

client.files.create(
file=open(“filese.pdf”, “rb”),
purpose=“assistants”
)

Error code: 400 - {‘error’: {‘message’: “‘assistants’ is not one of [‘fine-tune’] - ‘purpose’”, ‘type’: ‘invalid_request_error’, ‘param’: None, ‘code’: None}}

5 Likes

Not going live until 1 PM Pacific time according to docs. Stay tuned…

2 Likes

Its still broken?

It can’t read any file topic I upload. It will either say unsupported file format or “Failed to create assistant: UserError: Failed to index file: Unsupported file”

This is for a .csv file

4 Likes

yes, getting this error for PDF’s while plain text files do upload:
{
“error”: {
“message”: “Invalid file format. Supported formats: [‘c’, ‘cpp’, ‘csv’, ‘docx’, ‘html’, ‘java’, ‘json’, ‘md’, ‘pdf’, ‘php’, ‘pptx’, ‘py’, ‘rb’, ‘tex’, ‘txt’, ‘css’, ‘jpeg’, ‘jpg’, ‘js’, ‘gif’, ‘png’, ‘tar’, ‘ts’, ‘xlsx’, ‘xml’, ‘zip’]”,
“type”: “invalid_request_error”,
“param”: null,
“code”: null
}
}