unsloth/studio/frontend
Daniel Han f3991ac416
Chat search: search all messages, user messages first (#6350)
* Chat search: match across all messages, not just title and preview

The Cmd/Ctrl+K chat search only matched the thread title and a 120
character preview of the newest message, so keywords anywhere else in a
conversation were unfindable. Build a per-thread haystack from the title
plus every message's text and match against that.

The haystack is lowercased once at index build time, so the keystroke
filter only normalizes the short query instead of re-lowercasing the
whole conversation per item.

* Chat search: search user messages first, expand to all only if no hit

User messages are short while assistant replies can be very long, so
matching the whole conversation on every keystroke scales with the
assistant text. Store a separate userSearchText (title plus user
messages) and match it first, expanding to the full per thread
searchText only when nothing matches user text anywhere. Row filtering
moves into selectVisibleChats with cmdk shouldFilter disabled so the
tier choice is deterministic.

* Chat search: include tool calls and sources in the full-text tier

extractText now also pulls reasoning/thinking, tool call name/args/result
and cited source title/url, so the expanded full-conversation tier finds
keywords that only appear in tool activity. Drop the now-unused preview
field since search no longer matches on it.

* Chat search: drop base64 image/audio payloads from the index

extractText stringified tool-call results wholesale, so an
image_generation result (image_b64) or audio payload would pour megabytes
of base64 into searchText and get lowercased on every rebuild. Add
searchableText, which keeps readable tool args/results (tool name, prompt,
text) but skips binary keys and strips data URLs, long base64 runs and the
__IMAGES__ suffix.
2026-06-15 23:48:37 -07:00
..
public chore(studio/frontend): normalize line endings to LF (#6012) 2026-06-12 03:51:59 -07:00
src Chat search: search all messages, user messages first (#6350) 2026-06-15 23:48:37 -07:00
.gitignore perf(studio): upgrade to Vite 8 + auto-install bun for faster frontend builds (#4522) 2026-03-25 04:27:41 -07:00
.gitkeep add studio root folder 2026-02-02 09:14:35 +00:00
.npmrc Studio: npm v12 readiness for install-script gating (#6128) 2026-06-10 02:20:27 -07:00
biome.json feat: add seed dataset support with configuration, preview, and builder utilities 2026-02-14 18:44:38 +01:00
components.json add studio root folder 2026-02-02 09:14:35 +00:00
data-designer.openapi (1).yaml save and import, and fixes 2026-02-04 14:32:49 +01:00
eslint.config.js Final cleanup 2026-03-12 18:28:04 +00:00
index.html chore(studio/frontend): normalize line endings to LF (#6012) 2026-06-12 03:51:59 -07:00
package-lock.json Bump hono to 4.12.21, fixes CVE-2026-47676 (#6014) 2026-06-11 16:45:10 +02:00
package.json Bump hono to 4.12.21, fixes CVE-2026-47676 (#6014) 2026-06-11 16:45:10 +02:00
tsconfig.app.json chore(studio/frontend): normalize line endings to LF (#6012) 2026-06-12 03:51:59 -07:00
tsconfig.json chore(studio/frontend): normalize line endings to LF (#6012) 2026-06-12 03:51:59 -07:00
tsconfig.node.json chore(studio/frontend): normalize line endings to LF (#6012) 2026-06-12 03:51:59 -07:00
vite.config.ts Fix Install commands for Windows + 1 line installs (#4447) 2026-03-19 02:09:09 -07:00