diff --git a/interface/web/src/Settings.jsx b/interface/web/src/Settings.jsx index 94bc4c9..03c21c7 100644 --- a/interface/web/src/Settings.jsx +++ b/interface/web/src/Settings.jsx @@ -6,6 +6,8 @@ const DEFAULTS = { think: false, // Qwen3-style reasoning; off = much faster chat/memory temperature: 0.7, num_ctx: 0, // context window in tokens; 0 = model default + rag_top_k: 3, // document chunks injected into chat + rag_min_score: 0.6, // min cosine similarity for a chunk to count system_prompt: "", timeout: 120, gpu_offload: -1, // -1 = Auto; 0–100 = percent of layers forced onto the GPU @@ -209,6 +211,36 @@ export function Settings() { +
+
+ + update("rag_top_k", Math.max(0, parseInt(e.target.value) || 0))} + style={{ width: "100%", padding: "0.6rem", background: "#222", color: "#eee", border: "1px solid #333", borderRadius: "8px", boxSizing: "border-box" }} + /> +
+
+ + update("rag_min_score", parseFloat(e.target.value))} + style={{ width: "100%", accentColor: "#007acc" }} + /> +
+
+
+ How many uploaded-document chunks to pull into chat, and the minimum cosine + similarity each must clear. Higher relevance = fewer, tighter matches. +
+