Is there an existing issue for this?
Contact Details
No response
What should this feature add?
I would like custom nodes to be able to accept user-uploaded document/data files from the browser, without requiring the file to already exist on the InvokeAI server.
A concrete use case is a custom node that accepts a PDF, Markdown file, text file, CSV, JSON, or YAML file and processes it in Python. For example, a node may upload a PDF to an external document-processing service, parse a CSV, or load structured data from JSON/YAML.
Today this is difficult in hosted InvokeAI deployments. A string path only works when the file is already visible to the server, which is not true when a user accesses a remote InvokeAI instance from their own browser. The existing upload flow is image-specific and tied to ImageField, image DTOs, thumbnails, and image upload APIs.
A lightweight first version could focus only on node inputs:
- Add a managed
FileField or equivalent invocation input type
- Let users upload/select/remove a file directly from the node input UI
- Store the uploaded file in a server-managed location
- Pass a stable file reference to the invocation instead of a local path or file contents
- Expose a safe server-side API such as
context.files.get_path(file_id) or similar
- Validate uploads with extension/MIME allowlists and size limits
Alternatives
The current alternatives do not solve the hosted custom-node use case:
- Passing a string path only works when the file already exists on the server.
- Reusing
ImageField is not appropriate because it is image-specific.
- Encoding files into text/base64 values would bloat workflow and queue data.
Additional Content
No response
Is there an existing issue for this?
Contact Details
No response
What should this feature add?
I would like custom nodes to be able to accept user-uploaded document/data files from the browser, without requiring the file to already exist on the InvokeAI server.
A concrete use case is a custom node that accepts a PDF, Markdown file, text file, CSV, JSON, or YAML file and processes it in Python. For example, a node may upload a PDF to an external document-processing service, parse a CSV, or load structured data from JSON/YAML.
Today this is difficult in hosted InvokeAI deployments. A string path only works when the file is already visible to the server, which is not true when a user accesses a remote InvokeAI instance from their own browser. The existing upload flow is image-specific and tied to
ImageField, image DTOs, thumbnails, and image upload APIs.A lightweight first version could focus only on node inputs:
FileFieldor equivalent invocation input typecontext.files.get_path(file_id)or similarAlternatives
The current alternatives do not solve the hosted custom-node use case:
ImageFieldis not appropriate because it is image-specific.Additional Content
No response