mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-06 10:58:17 -05:00
issue: Metadata lists and objects are incorrectly serialized to strings #5880
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @christian-hawk on GitHub (Jul 27, 2025).
Check Existing Issues
Installation Method
Docker
Open WebUI Version
0.6.18
Ollama Version (if applicable)
No response
Operating System
Ubuntu 22.04
Browser (if applicable)
No response
Confirmation
README.md.Expected Behavior
Python
listanddictobjects in metadata must be correctly serialized and stored as native JSON array and object types in the vector database. Thestr()conversion should be restricted to unsupported types likedatetime.A metadata field that is a Python list (e.g., {'headings': ['Header 1', 'Header 2']}) must be stored in the vector database as a native JSON array: {'headings': ['Header 1', 'Header 2']}. The conversion to a string should be restricted only to unsupported data types.
Actual Behavior
A metadata field that is a Python list (e.g., {'headings': ['Header 1', 'Header 2']}) is incorrectly stored in the vector database as a single string: {'headings': "['Header 1', 'Header 2']"}. This renders the metadata useless for structured filtering.
Steps to Reproduce
TEXT_SPLITTER=markdown_header.file-*collection.Logs & Screenshots
owui250726.log
Additional Information
Additional Finding
The root cause is probably a faulty loop around line 1245 in
routers/retrieval.pythat overzealously appliesstr()conversion tolistanddicttypes.@tjbck commented on GitHub (Jul 28, 2025):
Intended behaviour, some vectorDB do not play well with nested dicts.