open-webui/backend/open_webui
silentoplayz fe28097817 feat: refactor model import to a single backend endpoint
This refactors the model import functionality to improve performance and user experience by centralizing the logic on the backend.

Previously, the frontend would parse an imported JSON file and send an individual API request for each model, which was slow and inefficient.

This change introduces a new backend endpoint, `/api/v1/models/import`, that accepts a list of model objects. The frontend now reads the selected JSON file, parses it, and sends the entire payload to the backend in a single request. The backend then processes this list, creating or updating models as necessary.

This commit also includes the following fixes:
- Handles cases where the imported JSON contains models without `meta` or `params` fields by providing default empty values.
2025-09-28 18:49:42 -04:00
..
data refac: mv backend files to /open_webui dir 2024-09-04 16:54:48 +02:00
internal refactor: format 2025-08-10 22:28:31 +08:00
migrations enh: reply to message 2025-09-27 04:05:12 -05:00
models feat: add backend handling for unarchiving all chats 2025-09-28 13:25:34 -04:00
retrieval Merge pull request #17770 from Classic298/feat-milvus-diskann-support 2025-09-26 14:23:53 -05:00
routers feat: refactor model import to a single backend endpoint 2025-09-28 18:49:42 -04:00
socket refac 2025-09-28 14:46:01 -05:00
static refac 2025-08-10 00:02:58 +04:00
storage refac/fix: s3 checksum validation 2025-08-21 12:44:16 +04:00
test chore: format, lint 2025-07-16 15:23:18 +09:00
utils refac 2025-09-28 14:46:01 -05:00
__init__.py Update __init__.py 2025-04-15 09:55:35 +02:00
alembic.ini fix: Alembic CLI commands from failing 2025-08-15 04:17:47 -04:00
config.py Merge pull request #17801 from Classic298/feature/notes-public-sharing-permission 2025-09-26 16:11:17 -05:00
constants.py feat: follow ups 2025-06-03 18:07:29 +04:00
env.py enh: oauth2.1 dynamic client registration 2025-09-25 00:28:13 -05:00
functions.py refac: user valves 2025-09-26 17:49:42 -05:00
main.py fix: session middleware should be required by default 2025-09-28 16:35:13 -05:00
tasks.py fix: fix error when stopping non-existent task 2025-09-04 16:52:19 +08:00