Skip to content

DeepTutor: Lifelong Personalized Tutoring. https://deeptutor.info/.

fix(web): clarify LightRAG base model guidance and effective settings

NoxsMediad39f5e8e85b1
diff --git a/web/components/knowledge/IndexingModelSelector.tsx b/web/components/knowledge/IndexingModelSelector.tsx
index 4eb2dc769..ab0f504c2 100644
--- a/web/components/knowledge/IndexingModelSelector.tsx
+++ b/web/components/knowledge/IndexingModelSelector.tsx
@@ -61,6 +61,8 @@ export function selectionFromLightRagDefault(
interface IndexingModelSelectorProps {
label?: string;
labelClassName?: string;
+ description?: string;
+ showReasoningHint?: boolean;
defaultSelection?: IndexingLLMSelection | null;
defaultLabel?: string;
lockModel?: boolean;
@@ -79,6 +81,8 @@ interface IndexingModelSelectorProps {
export default function IndexingModelSelector({
label = "Indexing model",
labelClassName = "text-[11px] font-medium uppercase tracking-wide text-[var(--muted-foreground)]",
+ description,
+ showReasoningHint = true,
defaultSelection,
defaultLabel,
lockModel = false,
@@ -157,7 +161,13 @@ export default function IndexingModelSelector({
<span className={`mb-1.5 block ${labelClassName}`}>
{t(label)}
</span>
+ {description && (
+ <span className="mb-1.5 block text-[11px] leading-relaxed text-[var(--muted-foreground)]">
+ {t(description)}
+ </span>
+ )}
<select
+ aria-label={t(label)}
value={
usesDefault
? "__engine_default__"
@@ -255,13 +265,15 @@ export default function IndexingModelSelector({
</option>
))}
</select>
- <p className="mt-1 text-[11px] text-[var(--muted-foreground)]">
- {inheritBaseReasoning !== undefined
- ? t("With no role override, reasoning follows the LightRAG base.")
- : t(
- "Sets this model's default reasoning depth. Auto leaves the choice to the provider.",
- )}
- </p>
+ {showReasoningHint && (
+ <p className="mt-1 text-[11px] text-[var(--muted-foreground)]">
+ {inheritBaseReasoning !== undefined
+ ? t("With no role override, reasoning follows the LightRAG base.")
+ : t(
+ "Sets this model's default reasoning depth. Auto leaves the choice to the provider.",
+ )}
+ </p>
+ )}
</label>
)}
</div>
diff --git a/web/components/knowledge/LightRagRoleModelsEditor.tsx b/web/components/knowledge/LightRagRoleModelsEditor.tsx
index 2ecac84e0..0c054dccf 100644
--- a/web/components/knowledge/LightRagRoleModelsEditor.tsx
+++ b/web/components/knowledge/LightRagRoleModelsEditor.tsx
@@ -129,11 +129,17 @@ export default function LightRagRoleModelsEditor({
onChange: (value: LightRagRoleModels) => void;
}) {
const { t } = useTranslation();
+ const baseOption = options.find(
+ (option) =>
+ option.profile_id === models?.base.profile_id &&
+ option.model_id === models?.base.model_id,
+ );
return (
<div className="space-y-4">
<div className="space-y-1.5">
<IndexingModelSelector
label="LightRAG base model"
+ description="The default model when no role model is specified. Role models can inherit its model and reasoning setting."
labelClassName="text-[12px] font-medium text-[var(--foreground)]"
options={options}
selection={models?.base ?? null}
@@ -149,11 +155,13 @@ export default function LightRagRoleModelsEditor({
);
}}
/>
- <p className="text-[11px] leading-relaxed text-[var(--muted-foreground)]">
- {t(
- "The default model when no role model is specified. Role models can inherit its model and reasoning setting.",
- )}
- </p>
+ {baseOption && (
+ <p className="text-[11px] text-[var(--muted-foreground)]">
+ {t("Currently effective")}: {baseOption.provider_label || baseOption.profile_name} ·{" "}
+ {baseOption.model_name} ·{" "}
+ {models?.base.reasoning_effort || t("Auto")}
+ </p>
+ )}
</div>
{models &&
(["extract", "keyword", "query", "vlm"] as const).map((role) => {
@@ -168,11 +176,6 @@ export default function LightRagRoleModelsEditor({
option.profile_id === effective?.profile_id &&
option.model_id === effective?.model_id,
);
- const baseOption = options.find(
- (option) =>
- option.profile_id === models.base.profile_id &&
- option.model_id === models.base.model_id,
- );
const selectionKey =
value.mode === "model" && value.selection
? `${value.selection.profile_id}:${value.selection.model_id}`
@@ -266,6 +269,7 @@ export default function LightRagRoleModelsEditor({
{value.mode !== "disabled" && (
<IndexingModelSelector
reasoningOnly
+ showReasoningHint={false}
options={roleOptions}
selection={
effective