Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions website/src/hooks/useRestorePipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,22 @@ export const useRestorePipeline = ({
}
}

// If the operation type is 'split', preserve the method_kwargs object
if (type === "split") {
if (op.method_kwargs) {
stringifiedKwargs.method_kwargs = op.method_kwargs;
} else if (stringifiedKwargs.method_kwargs) {
// Handle case where method_kwargs might have been stringified
try {
if (typeof stringifiedKwargs.method_kwargs === "string") {
stringifiedKwargs.method_kwargs = JSON.parse(stringifiedKwargs.method_kwargs);
}
} catch (e) {
console.error("Error parsing stringified method_kwargs:", e);
}
}
}

return {
id: id || uuidv4(),
llmType:
Expand Down
Loading