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

Add Warning for Downloaded Assets #4468

Open
BrianHung opened this issue Jan 21, 2025 · 0 comments
Open

Add Warning for Downloaded Assets #4468

BrianHung opened this issue Jan 21, 2025 · 0 comments
Labels
ai/core enhancement New feature or request

Comments

@BrianHung
Copy link
Contributor

Feature Description

https://github.com/vercel/ai/blob/main/packages/ai/core/prompt/convert-to-language-model-prompt.ts

Depending on the LLM, image and file are assets are downloaded and inlined into the messages fed to the model. This can lead to unexpected memory errors if the image and files are quite large. It is also a leaky abstraction if you give urls inside of messages, and they are automatically inlined as the expectation is urls are maintained.

At the minimum, I think there should be console warns that a model doesn't support URLs directly and assets have to be inlined.

Use Cases

No response

Additional context

No response

@BrianHung BrianHung added the enhancement New feature or request label Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ai/core enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants