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

Files created with client.Files.New() don't have names. Impossible to use them on vectorStore. #163

Open
ThadeuMelo opened this issue Jan 9, 2025 · 1 comment

Comments

@ThadeuMelo
Copy link

I'm trying to push some files and later use them on vectorstore assistants.
However, I can't add the files to VS because it rejects the names as not supported.

"{\n \"message\": \"Files with extensions [none] are not supported for retrieval. See https://platform.openai.com/docs/assistants/tools/file-search/supported-files\",\n \"type\": \"invalid_request_error\",\n \"param\": \"file_ids\",\n \"code\": \"unsupported_file\"\n }"

Checking the files created with this code.
I noticed that all of them are named 'anonymous_file'

content, err := os.ReadFile(config.FilePath + filename) // the file is inside the local directory if err != nil { fmt.Println("Err") } file, err := client.Files.New(context.TODO(), openai.FileNewParams{ File: openai.F(io.Reader(bytes.NewBuffer([]byte(content)))), Purpose: openai.F(openai.FilePurposeAssistants), })
Is that expected behavior?
I'm missing something?

@jacobzim-stl
Copy link
Collaborator

jacobzim-stl commented Jan 9, 2025

Thanks for bringing this up, try the solution in #91. We'll look into a better solution for the next launch too.

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

No branches or pull requests

2 participants