Commit graph

3264 commits

Author SHA1 Message Date
Danny Avila
60a74e6cd4
🧷 fix: Promote Unapplied Steers to Durable Queued Turns at Run End (#18028)
* 🧷 fix: Promote Unapplied Steers to Durable Queued Turns at Run End

A steer the server accepted (202) but the run never applied was handed back
in FINAL as `pendingSteers` and re-owned by the browser as a tab-local queued
message. A reload, closed tab, or a predecessor race before the drain lost it.

At terminal publication, a normally completed run now promotes such steers
into server-owned agent queued turns (parent: the ended response, epoch: the
ended generation's createdAt, chained behind any turn already queued against
that epoch). The job store hands the parked copy over atomically
(`promoteSteerLeftover`: parked item removed, receipt settled `recovered`), so
status recovery, lost-ACK retries and legacy recovery starts cannot queue the
same words again. FINAL reports the receipts in `promotedSteers`; the client
adopts them as server rows instead of converting the steer locally.

Promotion is opt-in per steer (`promoteLeftover`, sent only by clients that
adopt receipts and only for steers with no tab-only context), so older
clients keep the legacy path unchanged, and older servers simply never
report `promotedSteers`.

* 🔒 fix: Settle a Promoted Steer's Hand-Off at Admission, Not Only at FINAL

The job-store hand-off of a promoted steer now returns an outcome and stamps
the receipt with the owning queued turn, so it is idempotent for that turn.
The queued-turn resolver repeats it before admitting a promoted turn: it
completes a hand-off a crash interrupted, and cancels the turn when the
parked copy was discarded or recovered elsewhere, so the words never run
twice. At FINAL, a row whose hand-off was refused and whose retirement cannot
be confirmed is withheld from `pendingSteers` and left for that admission
check. The conservative reconcile frame keeps `promotedSteers`, and the
client adopts it there before sweeping local chips.

* 🔏 fix: Give Promoted Steers Durable Ownership, Their Run's Queue Lineage and Approval Mode

A turn promoted from an unapplied steer now records its source on its own
row: the steer's ids, the generation that accepted it, and a mark set only
once the job store handed the parked copy to that row. Admission runs a
promoted turn on that mark or on a hand-off the job store confirms now;
without proof (the store's evidence expired, or the host cannot ask) the
turn is held for review instead of running.

- Hand-off replies that are lost no longer cancel the row. The row stays as
  the client's handle and its admission settles ownership, so a committed
  hand-off can no longer leave the steer with no runnable copy.
- A replayed promotion never hands the parked copy to a row that was
  cancelled or failed.
- Promoted turns join the queue lineage of the generation that accepted
  the steer, so a sibling still queued behind that run no longer strands
  them with a predecessor mismatch.
- The steer request carries the sender's code approval mode onto the
  promoted turn; an unreadable mode keeps the steer on the client path.
- A steer whose quotes its owner stripped stays on the client path.
- The queued-turn receipt names the promoted steer by both ids, and the
  receipt list retires a pane's local copies even when it missed FINAL.

* 🚧 fix: Fence Promoted Turns to Workers That Prove Steer Ownership

A promoted row without an approval mode was published under the v1 queued
turn capability, so during a rolling deploy a worker that predates the
ownership check could claim it and run an unsettled row while the parked
steer was still recoverable elsewhere.

Promoted rows now publish under a new agent_queued_turn_v3 capability and a
v3 delivery identity, always reserved before insertion. A replica that
projects an older version can neither publish the reserved delivery nor
claim it, and enqueue refuses a promoted row without a reservation.

* 🪦 fix: Keep a Dead Promoted Turn Answering for Words It Held

A pane that learns of a promoted steer from the receipt list dropped the
mapping for every dead row. A row quarantined as ADMISSION_INDETERMINATE can
still settle as admitted, and a row that died after it was proven the sole
owner of the words is their only surface, so in both cases the pane kept a
chip whose recovery could never run.

The receipt now says whether the turn owned its steer's words, and a dead
receipt keeps answering for them when it did or when its admission is
indeterminate. A replayed promotion applies the same rule to a settled row.

* 🧾 fix: Find Promoted Turns by the Steer a Pane Holds, Join Root Lineages, Redact Hand-off Errors

- A promoted turn's request id is now derived from the client steer id, and a
  pane asks for the receipts of the steers it still holds a local copy of
  (recovery rows and failed chips). A promoted turn that already ran is only
  listed when asked for by name, so a pane that missed FINAL now finds it
  and retires its copy. A client steer id too long to key a queued turn is
  not promoted.
- The lineage lookup includes a generation admitted from a root queued turn,
  which has a parent and no epoch. The promoted turn joins that lineage
  without an epoch instead of opening a second one.
- A failed hand-off at admission reports a fixed message. The job store's
  own error text stays out of the dead-letter record a client can read, and
  promotion logs carry safe error metadata instead of error text.

* 🔢 fix: Ask for Held Steers First Under the Receipt Lookup Limit

The receipt list answers for at most 100 request ids, and a pane's server
rows were listed ahead of the steers it still holds, so a full server queue
could push every held steer out of the request. A promoted turn that had
already run was then never found.

Held steers now come first. An active server row is listed whether or not
it is asked for, while a settled promoted turn is found only by name.
2026-11-10 22:43:32 -05:00
Marco Beretta
472d796c20
🪶 perf: Load MCP UI and Export Libraries on Demand (#17975)
* perf: Load MCP UI and Export Libraries on Demand
* test: Cover Opening an MCP App Before Its Bridge Arrives and Keep On-…
* test: Keep the Opened MCP App Loading While Its Binding Check Is Held
* test: Run the Lazy Load Specs on Real Hooks and Fake Only the HTTP Cl…
* fix: Keep the Legacy Renderer Fallback Valid in a Paragraph and Quiet…
* fix: Keep the App Bridge Fallback Silent So an Opened View Announces …
2026-11-10 19:20:22 +01:00
Marco Beretta
88b07c9f96
🔊 fix: Stream Manual Read Aloud Before Audio Completes 2026-11-10 17:55:38 +01:00
Marco Beretta
f867e84b79
⌨️ perf: Keep the Composer Bar From Re-rendering on Keystrokes (#17974)
* perf: Keep the Composer Bar From Re-rendering on Keystrokes
2026-11-10 17:32:50 +01:00
lia-by-librechat[bot]
3474b3b5d7
🍡 perf: Batch Sidebar Unread Cache Scans (#18004)
Co-authored-by: Lia <lia@librechat.ai>
Co-authored-by: Danny Avila <danny@librechat.ai>
2026-11-10 11:04:20 -05:00
Marco Beretta
f8ab7fe67c
⏱️ fix: Preserve Running Tool Timers Across Disclosure Remounts (#17997)
* fix: Preserve Running Tool Timers Across Disclosure Remounts

* test: Cover Running Tool Timer Disclosure Lifecycles
2026-11-10 15:56:09 +01:00
lia-by-librechat[bot]
ea8c133c0b
🥸 fix: Resolve Directory Principals Through Trusted Integration Data (#17825)
* 🥸 fix: Resolve Directory Principals Through Trusted Integration Data

* fix: Verify Permission Principals Concurrently and Preserve Stored Groups

* fix: Refresh Stored Directory Group Membership Before Sharing

* fix: Preserve Directory Membership and Surface Principal Failures

* fix: Stage Principal Reads Before Bounded Permission Persistence

* test: Classify Historical Code Capability Name Expansion

* fix: Bound Directory Verification and Propagate Graph Denials

* test: Await Principal Collections Before Transaction Verification

* test: Isolate Theme Paint Measurements From DOM Trace Capture

---------

Co-authored-by: Lia <lia@librechat.ai>
2026-11-10 09:22:08 -05:00
Marco Beretta
fa9031ae74
⌨️ fix: Preserve User Focus During Sidebar Opening (#18001)
Some checks are pending
Backend Unit Tests / Tests: api (shard 3/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: data-provider (push) Blocked by required conditions
Backend Unit Tests / Tests: data-schemas (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 1/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 2/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 3/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 4/4) (push) Blocked by required conditions
Codegraph E2E Vote Gate / Gate (push) Waiting to run
Codegraph E2E Votes / vote (shard 1/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 10/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 2/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 3/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 4/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 5/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 6/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 7/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 8/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 9/10) (push) Waiting to run
Docker Dev Branch Images Build / publish (push) Waiting to run
Frontend Unit Tests / Client build recovery regression (push) Waiting to run
Frontend Unit Tests / Codegraph select (push) Waiting to run
Frontend Unit Tests / Build packages (push) Waiting to run
Frontend Unit Tests / TypeScript type checks (client) (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/chat (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/client (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 1/2) (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 2/2) (push) Blocked by required conditions
Frontend Unit Tests / Vite build verification (push) Blocked by required conditions
Sync Locize Translations & Create Translation PR / Sync Translation Keys with Locize (push) Waiting to run
Sync Locize Translations & Create Translation PR / Create Translation PR on Version Published (push) Blocked by required conditions
Preserve deliberate focus changes during the delayed sidebar opening fallback. Fixes #17570.
2026-11-10 14:56:18 +01:00
Marco Beretta
f72fdaaa57
fix: Serialize MCP App Theme Variables as CSS Colors (#17999) 2026-11-10 14:51:46 +01:00
lia-by-librechat[bot]
e6567c7a68
📰 fix: Preview Pasted Text Without Blocking Sends (#17962)
Some checks failed
Publish `librechat-data-provider` to NPM / pack (push) Has been cancelled
Publish `@librechat/data-schemas` to NPM / pack (push) Has been cancelled
Docker Dev Images Build / publish (push) Has been cancelled
Sync Helm Chart Tags / Ignore non-main push (push) Has been cancelled
Sync Helm Chart Tags / Sync chart tags (push) Has been cancelled
Publish `librechat-data-provider` to NPM / publish-npm (push) Has been cancelled
Publish `@librechat/data-schemas` to NPM / publish-npm (push) Has been cancelled
* 📰 fix: Preview Pasted Text Without Blocking Sends

* test: Cover Paste Cleanup and Accessible Preview Text

* fix: Preserve Paste Cleanup Across Upload Races

* test: Pass Paste Identity to Draft Lock Regression

* fix: Consume Paste Replacement Chains and Enforce Upload Limits

* fix: Flatten Pending Paste Edits Onto Their Surviving Source

* fix: Transfer Recovery Ownership While Editing Pending Pastes

* fix: Persist Bounded Paste Snippets and Isolate Replay Drafts

* fix: Type File Sanitization by Its Preview Inputs

* fix: Preserve Pending Uploads Above During-Run Text Limits

* fix: Isolate Historical User Reruns From Live Paste Drafts

* fix: Restore Paste Drafts Before Persisting Composer State

* fix: Expose Paste-Only During-Run Send Controls

* test: Scope Paste Warning Assertion to Toast Viewport

---------

Co-authored-by: Lia <lia@librechat.ai>
2026-11-10 08:10:21 -05:00
Marco Beretta
fbbf343286
fix: Keep Untagged Chat Code Fences Plain (#17986)
Some checks are pending
Backend Unit Tests / Tests: api (shard 1/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: api (shard 2/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: api (shard 3/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: data-provider (push) Blocked by required conditions
Backend Unit Tests / Tests: data-schemas (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 1/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 2/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 3/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 4/4) (push) Blocked by required conditions
Codegraph E2E Vote Gate / Gate (push) Waiting to run
Codegraph E2E Votes / vote (shard 1/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 10/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 2/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 3/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 4/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 5/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 6/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 7/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 8/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 9/10) (push) Waiting to run
Docker Dev Branch Images Build / publish (push) Waiting to run
Frontend Unit Tests / Client build recovery regression (push) Waiting to run
Frontend Unit Tests / Codegraph select (push) Waiting to run
Frontend Unit Tests / Build packages (push) Waiting to run
Frontend Unit Tests / TypeScript type checks (client) (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/chat (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/client (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 1/2) (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 2/2) (push) Blocked by required conditions
Frontend Unit Tests / Vite build verification (push) Blocked by required conditions
2026-11-10 13:21:24 +01:00
Marco Beretta
317dd05a82
fix: Keep Plugin Pagination Keyboard Navigation Within Bounds (#17987) 2026-11-10 13:19:55 +01:00
Marco Beretta
37f2c4e738
🌍 fix: Use Localized Button Text for Accessible Names (#17988) 2026-11-10 13:19:53 +01:00
lia-by-librechat[bot]
cb838019a6
🛌 perf: Defer Search Key Dialog Initialization Until First Open (#17976)
Some checks are pending
Backend Unit Tests / Tests: api (shard 3/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: data-provider (push) Blocked by required conditions
Backend Unit Tests / Tests: data-schemas (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 1/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 2/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 3/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 4/4) (push) Blocked by required conditions
Codegraph E2E Vote Gate / Gate (push) Waiting to run
Codegraph E2E Votes / vote (shard 1/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 10/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 2/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 3/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 4/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 5/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 6/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 7/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 8/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 9/10) (push) Waiting to run
Docker Dev Branch Images Build / publish (push) Waiting to run
Frontend Unit Tests / Client build recovery regression (push) Waiting to run
Frontend Unit Tests / Codegraph select (push) Waiting to run
Frontend Unit Tests / Build packages (push) Waiting to run
Frontend Unit Tests / TypeScript type checks (client) (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/chat (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/client (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 1/2) (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 2/2) (push) Blocked by required conditions
Frontend Unit Tests / Vite build verification (push) Blocked by required conditions
Sync Locize Translations & Create Translation PR / Sync Translation Keys with Locize (push) Waiting to run
Sync Locize Translations & Create Translation PR / Create Translation PR on Version Published (push) Blocked by required conditions
* 🛌 perf: Defer Search Key Dialog Initialization Until First Open

* test: Reuse the Search Dialog Trigger Label in Lifecycle Tests

---------

Co-authored-by: Lia <lia@librechat.ai>
2026-11-09 20:12:52 -05:00
Marco Beretta
0dc8571ff0
🎨 fix: Move Project and PR Icons to the Left of Conversation Rows (#17747)
* fix: Move conversation project and PR icons to the leading edge

* fix: Preserve Conversation Focus With Leading PR Icons

* test: Check Icon Order After Leaving Pinned Section

* test: Enable Project Chats Before Checking Their Badges
2026-11-10 00:01:21 +01:00
Marco Beretta
e9ab98ca46
🎛️ fix: Align Agent Instruction Controls and Theme Ownership Icon (#17730)
* fix: Align agent instruction controls and theme ownership icon

* test: Verify agent instruction header controls

* test: Match ownership filter accessible label

* test: Stabilize throttled deployment theme capture

* test: Disable video during throttled theme sampling
2026-11-10 00:01:08 +01:00
Marco Beretta
91ed9748cb
🌐 fix: Localize Citation Pagination and Source Errors
Localize source pagination labels and the default sources error fallback. Add focused regression coverage and stabilize the oversized screenshot export test.
2026-11-09 23:18:59 +01:00
Marco Beretta
4e0f242557
⚡ fix: Parallelize Setup Cancel Lookups and Keep Attachment Drafts on Reload (#17963)
* fix: Read the Account and Session Together and Test Cancel on a Real Database

- Start the setup user and refresh session lookups together in the cancel controller instead of one after the other, as the opt-in confirmation already does
- Run the cancel controller spec on mongodb-memory-server with the real data-schemas methods, so the session and compare-and-swap predicates under test are the production ones, and add a negative case for each
- Keep only a module wiring test in the CJS controller spec, since the database behavior is now covered where it can run for real

* test: Pin the Cancel Response When the Session Lookup Fails

Both lookups now run before any cookie or write, so a failed session lookup answers 500 with the browser and the stored state untouched. Cover that on the real database.

* fix: Keep the Saved Files Draft Until the File List Loads

After a reload the live file map is empty until the server's file list arrives, and the restore that rebuilds it needs that list. The save effect rewrote the stored draft from the empty map in between, so a pasted-text chip or any other attachment was gone before it could be restored. It now waits for the list. This is what turned the composer-attachments restore scenario red on dev.
2026-11-09 21:57:01 +01:00
Marco Beretta
90e236354a
🍞 fix: Hold Upload Error Toasts Open Until Dismissed (#17954)
* fix: Hold Upload Error Toasts Open Until Dismissed
2026-11-09 18:24:21 +01:00
Marco Beretta
7a927fb19e
🚪 fix: Let Users Sign Out of Required Two-Factor Enrollment (#17956) 2026-11-09 17:40:50 +01:00
Marco Beretta
316a9a051b
📋 fix: Detach the Original Chip After Saving a Pasted Text Edit (#17955) 2026-11-09 17:40:23 +01:00
Marco Beretta
8412506653
⚠️ fix: Keep Warnings That Follow a File Authoring Success Summary (#17953) 2026-11-09 17:40:17 +01:00
Marco Beretta
83a5db0683
👥 fix: Keep Skill Call Output in Shared Transcripts (#17948) 2026-11-09 17:40:06 +01:00
Marco Beretta
7591e8319a
🔗 fix: Open the Child Run Activity Dialog From a Shared Link (#17945) 2026-11-09 17:40:01 +01:00
Marco Beretta
482aaa9167
🧠 fix: Hide the Reasoning Control for Hidden Enforced Model Specs (#17944) 2026-11-09 17:39:56 +01:00
lia-by-librechat[bot]
b4afbb3a1e
🛝 perf: Render Chats Independently of Catalog Discovery (#17692)
* 🛝 perf: Render Chats Independently of Catalog Discovery

* Preserve Target Authorization and Passive Startup Intent

* Keep Startup Selection, Readiness, and Catalog Keys Consistent

* Preserve Remembered Targets and Validate Scoped Presets

* Retain Remembered Assistant Resource Aliases Across Endpoint Switches

* Apply URL Targets Before Waiting for Send Readiness

* Fix First-Page Agent Discovery and Await Model Selection

* Preserve Spec Access and Refresh Selected Assistant State

* Preserve Builder Deletion State and Start History Reads Earlier

* fix: Preserve Startup Recovery and History Read Ownership

* fix: Retain Express Query Routing in Assistant Lookups

* fix: Prioritize Route Reads and Recover Credential Changes

* fix: Bind Credential Revocation to Its Requested Scope

* fix: Refresh Credential Metadata After Pending Key Reads

* fix: Revalidate Inactive Credential Metadata on Target Mount

* fix: Preserve Reviewed Chat Resolutions After Rebase

* fix: Resolve Dev Conflicts and Preserve Startup Boundaries

* test: Preserve the ChatView Slot Target Boundary

* fix: Defer Terminal Delivery Until Subscription Attachment Completes

* fix: Contain Deferred Terminal Callback Failures

* test: Classify Historical Tool Name Capability Reads

* fix: Activate Requested Catalogs and Isolate Provider Failures

* fix: Keep Healthy Provider Choices Available During Catalog Recovery

* test: Exclude Copied Trace Bundles From Dependency Comparison

---------

Co-authored-by: Lia <lia@librechat.ai>
2026-11-09 11:11:22 -05:00
Marco Beretta
5dcfff39dc
📱 fix: Wrap Action Auth and API Key Expiry Controls on Narrow Screens (#17943)
* fix: Let Action Auth and API Key Expiry Segmented Controls Wrap on Narrow Screens
2026-11-09 16:50:42 +01:00
Marco Beretta
bffa50e7a8
🚦 fix: Keep the Gateway Message on Classified Rate Limit Errors (#17903)
* fix: Keep the Provider Message on Classified Rate Limit Errors

* fix: Honor maxProviderErrorChars for Classified Generation Errors

* test: Cover Classified Gateway Errors in the Mock Harness

* test: Cover a Zero Provider Detail Limit on Generation Errors

* refactor: Resolve Classified Provider Errors in the TypeScript Backend

* fix: Redact Provider Details Before Truncating Them
2026-11-09 15:44:02 +01:00
Marco Beretta
5e2fe5c3e6
🪢 fix: Wrap Label Text Between Words Instead of Mid-Word (#17926)
* fix: Wrap Label and Prose Text Between Words Instead of Mid-Word

* test: Cover Word Wrapping in the MCP Trust Disclosure and Bookmark Delete Dialog

* test: Reopen the MCP dialog per width and treat hyphens as break points

* test: Open the bookmark delete confirmation from the keyboard

* fix: Let the MCP Dialog Segmented Controls Wrap on Narrow Screens
2026-11-09 15:37:19 +01:00
lia-by-librechat[bot]
d3ca74605c
📪 fix: Require Email Delivery for Password Reset Links (#17823)
* 📪 fix: Require Email Delivery for Password Reset Links

* fix: Sanitize Recovery Delivery Errors and Handle Disabled Email

* test: Preserve Recovery Mutation State Types and Remove Obsolete Copy

* test: Enable Email Capability in Password Recovery Shape Fixtures

---------

Co-authored-by: Lia <lia@librechat.ai>
2026-11-09 08:27:33 -05:00
Danny Avila
57ab67cbac
📏 fix: Measure Usage Percent Against the Allowance Each Period Granted (#17850)
* 📏 fix: Measure Usage Percent Against the Allowance Each Period Granted

Store the credits granted at the start of each balance period on the record and measure the usage percent against it, so changing refillAmount or startBalance no longer moves a user's percent until their next grant. Legacy records fall back to the configured amount.

* 🕰️ fix: Ignore a Stored Allotment a Later Refill Has Replaced

Stamp each stored allotment with the time of its grant and measure against it only while no refill is more recent, so a refill by a replica that predates the field falls back to the configured amount instead of reporting usage against the prior period's allowance.

* 🔒 fix: Write the Allotment Grant Atomically and Return Its Period Start

Insert lastRefill with the credit, allotment and grant time when a balance record is created, so a racing creator never moves another's period start past its grant. Return lastRefill even without auto-refill so the client can place a stored allotment in its period, and fall back when it cannot.
2026-11-09 08:27:13 -05:00
Danny Avila
23aa0f822d
🗂️ feat: Defer System Tools Behind Tool Search (#17864)
* 🎛️ fix: Treat Model Spec Tools as Defaults, Not Mandates

* 🗂️ feat: Defer System Tools Behind Tool Search
2026-11-09 08:27:01 -05:00
Garfie Chiu
3c3be30004
🧭 chore: Bump Artifact react-router-dom to v7 (#17819)
- Bump Artifact react-router-dom to v7
2026-11-09 09:39:08 +01:00
Marco Beretta
b1ff03eb67
🏎️ perf: Load Conversation Messages From the Chat Route (#17912)
Some checks are pending
Backend Unit Tests / Tests: api (shard 3/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: data-provider (push) Blocked by required conditions
Backend Unit Tests / Tests: data-schemas (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 1/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 2/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 3/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 4/4) (push) Blocked by required conditions
Codegraph E2E Vote Gate / Gate (push) Waiting to run
Codegraph E2E Votes / vote (shard 1/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 10/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 2/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 3/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 4/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 5/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 6/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 7/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 8/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 9/10) (push) Waiting to run
Docker Dev Branch Images Build / publish (push) Waiting to run
Frontend Unit Tests / Client build recovery regression (push) Waiting to run
Frontend Unit Tests / Codegraph select (push) Waiting to run
Frontend Unit Tests / Build packages (push) Waiting to run
Frontend Unit Tests / TypeScript type checks (client) (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/chat (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/client (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 1/2) (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 2/2) (push) Blocked by required conditions
Frontend Unit Tests / Vite build verification (push) Blocked by required conditions
Sync Locize Translations & Create Translation PR / Sync Translation Keys with Locize (push) Waiting to run
Sync Locize Translations & Create Translation PR / Create Translation PR on Version Published (push) Blocked by required conditions
* perf: Prefetch Conversation Messages From the Chat Route

The messages request started only when ChatView mounted, after startup config, roles, endpoints, models and the conversation record resolved, although it needs only the route id. ChatRoute now starts it as soon as the id is known for a conversation the cache has never held, sharing the view's query function, and the view's first mount uses that payload instead of fetching it again.

* fix: Keep the Messages Prefetch Mark for the Observer That Uses It

Child observers of the same conversation mount first and cleared the mark before the conversation view subscribed, so the view loaded the messages a second time.

* fix: Show a Failed Messages Prefetch Instead of Requesting It Again

A prefetch that failed left no data, so the view loaded the messages again on mount, and a link to a missing conversation sent two requests. The view now shows a fresh prefetch failure, and the prefetch retries like the view's own load except on a 4xx.

* test: Cover Route-Level Messages Loading on Cold Load, Sidebar Switch and Missing Conversation

* fix: Retry Rate-Limited and Timed-Out Messages Prefetches

* fix: Prove Prefetched History by Reply Identity and Honor Invalidation

A URL load's prefetch starts before the conversation record is cached, so it captured no reply stamp and the seen check loaded an unread conversation's history a second time. Once the record lands, the prefetched history is proven when it holds the exact reply the record names. The mount guards also yield to an invalidation, and the failed-prefetch guard is the default for every observer of the conversation's messages.
2026-11-09 00:54:11 +01:00
Marco Beretta
fc3b86acbc
🧩 fix: Match Vendor Chunk Rules Against the Module Path, Not the Checkout (#17921)
* fix: Match Vendor Chunk Rules Against the Module Path, Not the Checkout

The vendor chunk rules tested the absolute module path, so a repository under a directory whose name contains a rule's text (fetch, ky, zod) sent every dependency to that chunk and the PWA precache limit failed the build. The rules now see the path from the first node_modules segment on.

* test: Cover Vendor Chunk Rules Under a Hostile Checkout Path
2026-11-09 00:48:32 +01:00
Marco Beretta
d6fb39727b
🧺 refactor: Move the Composer Tray and Staged Items Into @librechat/chat (#17817)
* refactor: Move the Composer Tray and Staged Items Into @librechat/chat

* chore: Retest Against Current Dev
2026-11-08 23:46:39 +01:00
Marco Beretta
a04ab256df
🧰 refactor: Move Part Helpers and activityLabels Into the Chat Package (#17771)
* refactor: Move Part Helpers and activityLabels Into the Chat Package

activityLabels moves to packages/chat/src/core/parts and exports from
@librechat/chat. useLazyCollapseBody, useProgress and useThrottledValue move
to packages/chat/src/react/parts (@librechat/chat/react). useExpandCollapse,
CopyButton, ActionButton, LangIcon and its icon paths move to
packages/chat/src/components/parts (@librechat/chat/components), since they
read @librechat/client. Specs move with them, client importers and mocks point
at the package entries, and design-lint suppressions follow the moved files.
The fold-type set in activityLabels is built on first use so the module reads
no data-provider enum at load, with a spec pinning its members.

* test: Point the About Spec's Localize Mock at the Package's Copy Button

* chore: Retest Against Current Dev
2026-11-08 23:46:32 +01:00
Marco Beretta
337c566dc3
📬 fix: Require a Click to Submit Email Verification Links (#17905)
* fix: Require a Click to Submit Email Verification Links

Mail security scanners (Microsoft Defender Safe Links, Sophos, Hornetsecurity)
open links in incoming mail and run the page's scripts, so the verify page
submitted the single-use token on load and the user's own click then failed.
The page now waits for an explicit confirm button for both sign-up
verification and email-change confirmation.

* test: Cover verification links opened before the user clicks

* test: Isolate the verify click scenario from the submission limiter

* test: Confirm the sign-up link in the email e2e setup

* test: Exercise the shared Button in the verify page spec
2026-11-08 23:39:26 +01:00
Marco Beretta
b97a973d42
📦 fix: Treat Empty Sandpack Bundler URLs as Unset (#17901)
* fix: Treat Empty Sandpack Bundler URLs as Unset

An empty SANDPACK_BUNDLER_URL or SANDPACK_STATIC_BUNDLER_URL (common with
${VAR:-} passthrough in Docker Compose) was handed to Sandpack as the
bundler URL, leaving artifact panels blank. buildSandpackOptions now falls
back to the default bundler for an empty value, and the shared-link startup
payload omits empty bundler URLs.

Related to #17790

* test: Cover Empty Sandpack Bundler URLs in Artifact Previews
2026-11-08 22:34:17 +01:00
Marco Beretta
ff1f8acc46
🗑️ fix: Keep the Delete Dialog on the Chat It Was Opened For (#17891)
* fix: Key Sidebar Chat Rows by Conversation Id

Virtualized chat rows were keyed by row index, so a row's local state (an
open delete dialog, a rename field) stayed in its slot while another chat
moved into it, and confirming deleted the wrong chat.

* test: Cover Sidebar Row State When Rows Move

* test: Scope Sidebar Row Scenario Clicks to the Open Menu

* test: Release the Held Archive Reply Before Removing Its Route
2026-11-08 15:13:35 +01:00
Marco Beretta
721aba4bb2
🪟 fix: Stop the Sidebar Close Toggle Throwing on Click (#17893)
* fix: Stop Sidebar Toggle Buttons Forwarding the Click Event as afterSlide

The desktop toggle and the mobile close button passed their onClick handlers
straight through to handleCollapse(afterSlide), so React's click event reached
setSidebarOpen as the afterSlide callback and threw when invoked (directly, or
via requestAnimationFrame on the animated mobile drawer).

Related to #17861

* test: Cover Closing the Sidebar Without a Runtime Error
2026-11-08 14:59:32 +01:00
Marco Beretta
ea4d7c7e36
🪟 feat: Add Welcome Footer and Response Author Options and Tidy the Chat Chrome (#17879)
* fix: Keep the Projects Section Expanded by Default

* fix: Label the Streaming Dot With a Tooltip and an Accessible Name

* fix: Move the Welcome Screen Footer Directly Under the Composer

* fix: Drop the Agent Name From Responses When the Selector Already Shows It

* fix: Align the Sidebar Section Headings With the Date Labels

* feat: Make the Welcome Footer Placement and Response Author Configurable

* fix: Hide the Memories Panel on the Agents Route

* test: Cover the Launch QA Chat Chrome in E2E Scenarios

* test: Assert the Section Heading Padding Merge Without Mocking App Internals

* fix: Read the Response Author Setting Through the Messages Host

* test: Give the Consumer Spec's Messages Host the Author Setting
2026-11-08 14:57:59 +01:00
Marco Beretta
7bb115319f
🚏 refactor: Move the Queued Follow-Up Row Into the Chat Package (#17868)
Some checks are pending
Backend Unit Tests / Tests: api (shard 1/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: api (shard 2/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: api (shard 3/3) (push) Blocked by required conditions
Backend Unit Tests / Tests: data-provider (push) Blocked by required conditions
Backend Unit Tests / Tests: data-schemas (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 1/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 2/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 3/4) (push) Blocked by required conditions
Backend Unit Tests / Tests: @librechat/api (shard 4/4) (push) Blocked by required conditions
Codegraph E2E Vote Gate / Gate (push) Waiting to run
Codegraph E2E Votes / vote (shard 1/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 10/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 2/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 3/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 4/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 5/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 6/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 7/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 8/10) (push) Waiting to run
Codegraph E2E Votes / vote (shard 9/10) (push) Waiting to run
Docker Dev Branch Images Build / publish (push) Waiting to run
Frontend Unit Tests / Client build recovery regression (push) Waiting to run
Frontend Unit Tests / Codegraph select (push) Waiting to run
Frontend Unit Tests / Build packages (push) Waiting to run
Frontend Unit Tests / TypeScript type checks (client) (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/chat (push) Blocked by required conditions
Frontend Unit Tests / Tests: @librechat/client (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 1/2) (push) Blocked by required conditions
Frontend Unit Tests / Tests: Ubuntu (shard 2/2) (push) Blocked by required conditions
Frontend Unit Tests / Vite build verification (push) Blocked by required conditions
* refactor: Move the Queued Follow-Up Row Into @librechat/chat

The package owns which queued turn is drawn, when it follows the reader to the end of the thread, and where the composer's queued actions attach. The app keeps who sent it, their icon and how the text reads, passed in as props.

* test: Tag the Queued Follow-Up Row Scenario

The spec already drives the queued turn through its reveal and handoff in the browser; the tag lets the gate record it as evidence for the row the package now draws.

* chore: Retest Against Current Dev

* test: Keep Jotai's Real Exports in the Search Route Spec

PendingTurn now ships from the package components entry, which loads the steer rows and the pane submission atom at import. The spec replaced the whole jotai module with useAtomValue alone, so atom() was undefined and the suite failed to load.
2026-11-08 00:37:37 +01:00
Marco Beretta
3aea181547
🌱 refactor: Move Conversation Starters Into the Chat Package With a Starter Button Variant (#17805)
* refactor: Move Conversation Starters Into @librechat/chat With a Starter Button Variant

The welcome screen's suggested first messages render through a package component built on a new starter Button variant instead of a raw button. The app keeps resolving which starters apply (agent, spec, assistant) and sends the chosen text.

* test: Pin the Starter Variant Under the ClickHouse Reference Theme

A starter takes its fill and ink from the theme roles in light and dark, so a theme that repaints the surface repaints the chip.

* fix: Cap the Starter Width at the Call Site, Not in the Button Variant

The Button primitive spec rejects fixed sizes in the variant recipe, so the 16rem cap moves to the package component that lays the chips out.

* fix: Keep the Starter Stagger Ahead of the Unlayered Fade Rule

The unlayered fade-in rule sets the animation shorthand, which resets the delay and fill mode a layered utility sets, so every chip animated at once. The variant now declares the whole animation in one utility, and the cap scenario asserts the computed delay and fill mode.

* fix: Ship the Starter Fade From the Shared Tailwind Preset

The starter variant referenced a keyframe that only the app stylesheet defines, so a host using the published preset would get no entrance. The keyframe and its staggered animation now live in the preset next to the loading dots, and the variant uses the animate-starter-in utility.

* chore: Retest Against Current Dev
2026-11-08 00:37:23 +01:00
Marco Beretta
aa69629466
📎 refactor: Move the Attachment Row Into @librechat/chat Behind the Files Host (#17801)
* refactor: Move the Attachment Row Into @librechat/chat Behind the Files Host

* test: Cover the Attachment Row Against a Fake Files Host

* test: Run the Files Host Deletion Against the Real Hooks and Mock Only the Service Call

* test: Drive the Fallback Deletion Through the Real File Card

* test: Run the Row's Host Cases Against the Real Thumbnail and File Card

* test: Read the Host Preview From the Thumbnail Image Source

* chore: Retest Against Current Dev
2026-11-08 00:37:16 +01:00
Marco Beretta
692b60049c
📜 refactor: Make the Package Scroll Button the Message List Default (#17761)
* refactor: Move the Scroll Button Into @librechat/chat

* refactor: Make the Package Scroll Button the Message List Default

* test: Pin the Scroll Control Fade and Its Reduced-Motion Path

* fix: Drop the Scroll Control's IntersectionObserver Guard

The observer starts in an effect, which never runs in a server render, and every browser has the API. The guard existed only for jsdom, which now gets an inert observer from the package's jest setup.

* chore: Retest Against Current Dev
2026-11-08 00:37:09 +01:00
Marco Beretta
80067777cf
🧯 refactor: Retire Host Tool Outcome, Sibling, Branch Tail and Approval Members (#17867)
* refactor: Retire Host Tool Outcome, Sibling and Approval Members

The package now owns the tool outcome rules and the attachment merge they
read, selects the visible sibling through its own atom, and derives the steer
path's code approval mode from raw inputs. ChatHost loses getMappingOptions and
useSetSiblingIdx; SteerHost.useCodeApprovalMode becomes useCodeApprovalInputs.

* refactor: Select the Branch Tail Inside @librechat/chat

The tail of the branch on screen becomes package logic, read through
useBranchTail. ChatHost loses useLatestMessage and useLatestMessageId;
SteerHost.useLatestMessage becomes the useRouteConversationId adapter.

* test: Exercise Steering Against a Real Message Cache

The steering spec mocked React Query to return one message list for every key, so
it could not notice a read of another conversation's cache or a tail that stops
following the cache. It now provides a real QueryClient, seeds each conversation
key, and covers the route and another chat holding different tails and a cache
that hydrates after mount.
2026-11-08 00:36:46 +01:00
Marco Beretta
99a7ded295
🏷️ fix: Show MCP Server Titles in the Tool Library (#17883)
* fix: Show MCP Server Titles in the Tool Library and Search by Them

Tool Library cards and agent tool rows showed the MCP server's config key because buildCatalog named each item after it, and search could only match that key. Name items from the resolved title in server.metadata, falling back to the key. Search also matches the key through the item id, as the MCP Servers panel does, so existing key searches keep working.

* test: Cover MCP Server Titles in the Tool Library and Agent Tool Rows

* test: Find the E2E Memory Card and Row by Title in MCP Specs
2026-11-08 00:34:03 +01:00
Marco Beretta
ce35dc25e1
🚚 refactor: Move the Subagent Thread Panel Into @librechat/chat (#17781)
* refactor: Read the Thread Panel's Jotai State Through the Chat Surface

* refactor: Move the Subagent Thread Panel Into @librechat/chat

* test: Spec the Subagent Thread Panel Against Fake Hosts

* test: Cover the App Subagents Host Adapters the Panel Move Relies On

* fix: Style the Moved Subagent Panel With Shared Variants

* test: Pin the Shared Variants the Panel Draws Its Picker and Inline Actions With

* perf: Keep the Subagent Thread Panel Out of the Boot Bundle
2026-11-08 00:29:26 +01:00
Marco Beretta
6476ec47ff
🛰️ refactor: Read the Subagent Thread Panel's App Capabilities Through the Subagents Host (#17759)
* refactor: Add the Thread Panel's Reads, Writes and Layout to the Subagents Host

* refactor: Read the Subagent Thread Panel's App Capabilities Through the Subagents Host

* fix: Hand the Thread Panel the Query's Own Stable Refetch
2026-11-07 23:27:14 +01:00