mirror of
https://github.com/Mintplex-Labs/anything-llm.git
synced 2025-04-17 18:18:11 +00:00
ui adjustments for order flow
back nav on order flow fix bad schema ref
This commit is contained in:
parent
a7010fd48d
commit
6bab8b5bd4
3 changed files with 15 additions and 6 deletions
|
@ -8,7 +8,7 @@ export default function OrderDetails({ setSettings, setStep }) {
|
|||
useEffect(() => {
|
||||
FineTuning.info()
|
||||
.then((res) => {
|
||||
setInfo(res);
|
||||
setInfo(res ?? {});
|
||||
setSettings((prev) => {
|
||||
return { ...prev, tuningInfo: res };
|
||||
});
|
||||
|
|
|
@ -3,7 +3,7 @@ import FineTuningSteps, { FineTuningCreationLayout } from "./Steps";
|
|||
import { CheckCircle, Circle, Sparkle } from "@phosphor-icons/react";
|
||||
import { isMobile } from "react-device-detect";
|
||||
|
||||
function SideBarSelection({ currentStep }) {
|
||||
function SideBarSelection({ setStep, currentStep }) {
|
||||
const currentIndex = Object.keys(FineTuningSteps).indexOf(currentStep);
|
||||
return (
|
||||
<div
|
||||
|
@ -26,7 +26,16 @@ function SideBarSelection({ currentStep }) {
|
|||
isLast ? "" : "border-b border-white/10",
|
||||
].join(" ")}
|
||||
>
|
||||
<div className="text-sm font-light">{props.name}</div>
|
||||
{isDone ? (
|
||||
<button
|
||||
onClick={() => setStep(stepKey)}
|
||||
className="border-none hover:underline text-white/40 text-sm font-light"
|
||||
>
|
||||
{props.name}
|
||||
</button>
|
||||
) : (
|
||||
<div className="text-sm font-light">{props.name}</div>
|
||||
)}
|
||||
<div className="flex items-center gap-x-2">
|
||||
{isDone ? (
|
||||
<CheckCircle className={`text-green-300`} />
|
||||
|
@ -60,7 +69,7 @@ export default function FineTuningFlow() {
|
|||
<Sparkle size={24} />
|
||||
<p className="text-lg font-medium">Custom Fine-Tuned Model</p>
|
||||
</div>
|
||||
<SideBarSelection currentStep={step} />
|
||||
<SideBarSelection setStep={setStep} currentStep={step} />
|
||||
</div>
|
||||
{StepPage.component({ settings, setSettings, setStep })}
|
||||
</div>
|
||||
|
|
|
@ -72,7 +72,7 @@ const FineTuning = {
|
|||
workspaceId: {
|
||||
in: workspaceIds,
|
||||
},
|
||||
...(feedback === true ? { feedback: 1 } : {}),
|
||||
...(feedback === true ? { feedbackScore: true } : {}),
|
||||
});
|
||||
return count;
|
||||
},
|
||||
|
@ -141,7 +141,7 @@ const FineTuning = {
|
|||
workspaceId: {
|
||||
in: workspaces.map((ws) => ws.id),
|
||||
},
|
||||
...(feedback === true ? { feedback: 1 } : {}),
|
||||
...(feedback === true ? { feedbackScore: true } : {}),
|
||||
});
|
||||
const preparedData = chats.map((chat) => {
|
||||
const responseJson = safeJsonParse(chat.response);
|
||||
|
|
Loading…
Add table
Reference in a new issue