unsloth/studio/frontend
Roland Tannous ca83bea538 Studio: app-level RAG defaults for new KBs
Power users can now set their preferred chunking strategy / mode /
embedder once in Settings → Knowledge Bases and have new KBs use those
values by default, instead of toggling on every create.

Backend
- routes/rag.py:
  - GET /api/rag/defaults returns the stored RagDefaults (or sensible
    fallbacks when nothing is set: standard / text / null embedder).
  - PUT /api/rag/defaults is PATCH-style — only fields present in the
    body overwrite. The (multimodal, late) constraint is enforced
    here too, so users can't poison the defaults with a combination
    the create path would reject.
- Persistence reuses the existing chat_settings store via
  upsert_chat_settings_merge; the values live under a single
  rag.defaults key as a nested JSON dict.

Frontend
- rag-api.ts: getRagDefaults / setRagDefaults wrappers + RagDefaults
  + UpdateRagDefaultsRequest types.
- rag-store.ts: defaults state, loadDefaults / updateDefaults
  actions. loadDefaults swallows errors so a missing endpoint just
  leaves defaults null.
- rag-defaults-section.tsx (new): self-contained mode + strategy +
  embedding-model controls, persists on change. Used in the Settings
  KB tab below the ThreadIndexList section.
- knowledge-bases-tab.tsx: mounts RagDefaultsSection below thread
  indexes with a separator.
- kb-create-dialog.tsx: loads defaults on open and prefills the form
  with them (falls back to hard-coded standard / text when defaults
  haven't loaded yet). reset() returns to the latest defaults rather
  than the hard-coded ones.
2026-05-24 12:47:16 +04:00
..
public Polish/cloud to providers (#5450) 2026-05-15 19:29:21 +04:00
src Studio: app-level RAG defaults for new KBs 2026-05-24 12:47:16 +04: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 security: NOT affected by Mini Shai-Hulud (May-12 wave) -- forward-looking hardening only (#5397) 2026-05-13 04:58:12 -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 Final cleanup 2026-03-12 18:28:04 +00:00
package-lock.json Add OpenDocument chat attachments (#5510) 2026-05-18 03:41:24 -07:00
package.json Add OpenDocument chat attachments (#5510) 2026-05-18 03:41:24 -07:00
tsconfig.app.json Relax frontend unused local check (#4388) 2026-03-17 16:04:11 -07:00
tsconfig.json cleanup 2026-02-04 13:28:39 +01:00
tsconfig.node.json cleanup 2026-02-04 13:28:39 +01:00
vite.config.ts Fix Install commands for Windows + 1 line installs (#4447) 2026-03-19 02:09:09 -07:00