1948 Commits
Author SHA1 Message Date
Classic298 a9adb2b78e perf: posting in a channel takes seconds when many members are online (#32889)
Every message posted in a channel waited until the server had re-checked the login of every online member of that channel, one connected session at a time with a few database lookups each, before the post went through. In a large channel that added seconds to every single message. The result only decides who gets a notification, and the message is already delivered to everyone before this step, so the check now runs right after the post returns, as the first step of the work that sends notifications and bot replies. Members are re-checked exactly as before, including disconnecting any session whose login is no longer valid.

Postgres 16, standard channel, median time for a post to return:

| Online members | Before | After |
| --- | --- | --- |
| 100 | 0.37 s | 0.03 s |
| 300 | 1.6 s | 0.05 s |
| 1,000 | 3.4 s | 0.10 s |
2026-10-22 07:48:19 +09:00
Classic298 cb7d7e851d fix: model import silently skips a model whose ID is already taken (#32866)
Importing a model JSON on the Workspace Models page as a regular user skipped any model whose ID already belonged to another user's model they cannot edit, or to a model from one of the instance's connections such as OpenAI or Ollama. There was no message, so the model just never showed up. The import now stops at that model with the error "Uh-oh! This model id is already registered. Please choose another model id string."; the models before it in the file are imported and the ones after it are not. Admins, and users who can edit the existing model, are unaffected and still overwrite it.
2026-10-22 06:12:10 +09:00
Classic298 d1e31cbb81 refactor: remove unused development route (#32869)
Removes a leftover development-only route that nothing in the app calls.
2026-10-22 06:11:00 +09:00
Classic298 db5b874944 feat: let everyone who can use a model pick its model controls (#32860)
Picking a model control option, such as a Thinking level, needed both the Allow Chat Controls and Allow Chat Params permissions, so admins had to hand out the Advanced Parameters panel just to let people pick a preset. Model control picks now work for anyone with access to the model and are saved per model to their account. Allow Chat Controls still hides the Chat Controls panel and Allow Chat Params still hides the Advanced Parameters panel, in the chat and in personal Settings. Parameters a person saves to their account are no longer filtered by these two permissions, since any chat message could already set any parameter without them.

Fixes #32626
2026-10-22 04:44:53 +09:00
Timothy Jaeryang Baek 3539ad6321 refac 2026-10-21 16:35:31 +09:00
Timothy Jaeryang Baek dc2ac86060 refac 2026-10-21 16:01:14 +09:00
Timothy Jaeryang Baek d1705c1078 refac 2026-10-21 15:04:00 +09:00
Timothy Jaeryang Baek f5e8f84e69 refac 2026-10-21 12:58:04 +09:00
Timothy Jaeryang Baek 131ddc32ec refac 2026-10-21 11:07:10 +09:00
Timothy Jaeryang Baek 2a86805648 refac 2026-10-21 11:06:17 +09:00
Timothy Jaeryang Baek b4a58be193 refac 2026-10-21 09:15:15 +09:00
Classic298 cd74e6d126 fix: dropped realtime call sometimes shows "Voice connection failed" (#32730)
When the voice provider ended a realtime call, the overlay sometimes said "Voice connection failed" instead of "Voice provider connection closed". It happened when microphone audio reached the server at the same moment the provider hung up, so forwarding that audio failed and the generic error was shown. Anything that fails to reach the provider because it just closed the connection now reports that the provider closed the call.

Fixes #32729
2026-10-21 04:45:54 +09:00
Classic298 c7e159bdd6 fix: voice calls do not forward user info headers to the realtime provider (#32733)
With ENABLE_FORWARD_USER_INFO_HEADERS turned on, voice calls in Realtime mode connected to the configured realtime provider without any user info headers, so a gateway in front of the provider could not tell which user was on the call. The call connection now sends the same user headers (or the signed user JWT, when configured) as chat requests and realtime text-to-speech already do.
2026-10-21 03:13:37 +09:00
G30 54fc21d685 fix: deleting a channel message also deletes its thread replies (#32666) 2026-10-21 02:44:43 +09:00
Classic298 c901bc39d3 fix: embeddings API fails for connections with a Prefix ID (#32724)
Calling the embeddings API with a model from a connection that has a Prefix ID sent the prefixed model name to the provider, which rejected it as an unknown model. The prefix is now removed before the request goes out, the same way chat requests already do it, so every model on such a connection works through the embeddings API again.

Fixes #32715
2026-10-21 02:01:29 +09:00
Timothy Jaeryang Baek 079fb19e75 refac 2026-10-16 18:58:58 +04:00
Timothy Jaeryang Baek 4b81b12ed4 chore: format 2026-10-16 15:20:15 +04:00
Timothy Jaeryang Baek 92e64c1d59 refac 2026-10-16 14:31:39 +04:00
G30 5dff6489d2 fix: someone with Write access saving a shared prompt or tool no longer makes it private (#32493)
The prompt and tool editors resend every stored grant on Save, and the
update routes ran that whole list through filter_allowed_access_grants.
A collaborator without the public sharing permission therefore had the
owner's Public grant stripped, and the stripped list replaced the stored
one, so one Save made the prompt or tool private for everyone else.

Keep grants that are already stored and filter only the ones the save
adds, as the model update route has done since 754c4b576.
2026-10-16 03:20:45 +04:00
G30 ad3e5a6c42 fix: a chat you clone or fork from someone's share is yours to regenerate in (#32508)
Since cloned and forked chats keep each message's original author, a
copy of someone else's shared chat kept the sharer as the author of
every prompt and reply. Regenerate and Continue in the copy then failed
with "You can only regenerate your own messages.", and edits to those
messages were dropped on save, although the copy belongs to the person
who made it.

When a shared chat is cloned, or forked by someone other than its owner,
give the source owner's messages to the new owner, the same per-message
loop shared_chat_response uses to set authors. Messages written by other
participants of an Allow replies chat keep their authors.
2026-10-16 03:13:44 +04:00
Timothy Jaeryang Baek ef28e99e58 refac 2026-10-16 02:53:00 +04:00
Timothy Jaeryang Baek b4db56ae96 refac 2026-10-16 02:46:20 +04:00
Timothy Jaeryang Baek 4a70253bc8 refac 2026-10-16 01:25:30 +04:00
Timothy Jaeryang Baek 0b3812f285 refac 2026-10-15 17:56:56 +04:00
Timothy Jaeryang Baek 7dc91de86c refac 2026-10-15 17:08:00 +04:00
G30 58b821a464 fix: searching for a tag whose chats are all archived no longer deletes the tag (#32452) 2026-10-15 13:12:19 +04:00
G30 fd47370e85 fix: an imported chat shows its tags (#32454) 2026-10-15 13:12:11 +04:00
Classic298 fb3d92a6ef feat: record the requested model as its own field in the audit log (#32429)
The audit log only showed which model a request used inside the logged request body, which is cut off at MAX_BODY_LOG_SIZE, so the model went missing whenever a long prompt came before it. Audit entries for chat and completion requests, including the OpenAI, Ollama and Anthropic-compatible endpoints, now carry a model_id field with the model the client asked for, at every AUDIT_LOG_LEVEL and however long the request is. Other requests log it as null.

Fixes #30097
2026-10-15 00:00:19 +04:00
Classic298 6276e81cec fix: SCIM can delete admin accounts (#32415)
An identity provider could delete an admin account through SCIM, including the first admin account, for example when its sync pruned users it no longer had assigned. SCIM already ignores deactivation requests for admins so a sync cannot demote them, and the admin panel refuses to delete the first admin, but a SCIM delete request still went through and could leave the instance without anyone who has admin access. Deleting an admin through SCIM is now refused with a 403 and the account stays; admins are removed from the admin panel instead.

Fixes #27662
2026-10-14 23:25:28 +04:00
Timothy Jaeryang Baek 7b47c3b22c refac 2026-10-14 23:21:22 +04:00
Classic298 8bddf9bc62 fix: memory reindex ignores the Embedding Concurrent Requests limit (#32420)
Reindexing memories (the admin "Reindex Knowledge and Memory Vectors" button, a user resetting their memory vectors, or the automatic reindex after switching to an embedding model with a different vector size) ignored the "Embedding Concurrent Requests" setting and sent one embedding request per memory at once. With a rate-limited embedding provider, most of those requests came back as 429 errors. Reindexing memories now respects that setting and the embedding batch size, like knowledge file uploads already do.

Fixes #32212
2026-10-14 23:15:25 +04:00
Classic298 44953df70e Merge pull request #32421 from Classic298/channel-message-meta
refac: keep channel message metadata server-side
2026-10-14 23:15:17 +04:00
Timothy Jaeryang Baek 00f12c0e47 refac 2026-10-14 18:49:51 +04:00
Timothy Jaeryang Baek a70e96525d refac 2026-10-14 18:22:33 +04:00
Timothy Jaeryang Baek 3ec0774503 refac 2026-10-14 17:49:31 +04:00
Classic298 3b2b89205e fix: no channel message webhooks from group channels and direct messages (#32404)
Users with a notification webhook for channel messages received no webhook when someone posted in a group channel or direct message they belong to. Only regular channels they had been given access to sent it. Members of group channels and direct messages now get the webhook too, and muting one of these channels stops the webhook except for messages that mention them.

Fixes #32403
2026-10-14 17:16:22 +04:00
Timothy Jaeryang Baek fe0e725997 refac 2026-10-14 16:57:58 +04:00
Timothy Jaeryang Baek 35c927ba99 refac 2026-10-14 14:59:41 +04:00
Timothy Jaeryang Baek e5c80682b9 refac 2026-10-14 14:41:26 +04:00
Timothy Jaeryang Baek 4c5668696b refac 2026-10-14 13:46:36 +04:00
Timothy Jaeryang Baek ed8c744e77 refac 2026-10-14 00:19:15 +04:00
Timothy Jaeryang Baek a94a2068e2 refac 2026-10-13 18:32:14 +04:00
G30 d7803a8ce2 fix: keep the open knowledge file open when an unrelated folder is deleted (#32319) 2026-10-13 16:48:57 +04:00
G30 5477d5a773 fix: set an older model version as production when it has a note attached as knowledge (#32317) 2026-10-13 16:48:26 +04:00
Timothy Jaeryang Baek 4ca8fdc3fd refac 2026-10-13 01:55:12 +04:00
Timothy Jaeryang Baek 03f5191aca refac 2026-10-13 01:49:55 +04:00
Timothy Jaeryang Baek 1786d6cdb0 refac 2026-10-13 00:43:00 +04:00
Timothy Jaeryang Baek 53a8f131f3 refac 2026-10-13 00:42:34 +04:00
Timothy Jaeryang Baek e9635596dd refac 2026-10-12 23:22:18 +04:00
Timothy Jaeryang Baek 4ab60527e7 refac 2026-10-12 22:14:04 +04:00