fix: Add sandbox feature to workflow features mapping

This commit is contained in:
zhsama
2026-01-25 16:30:50 +08:00
parent 47835aaad9
commit 8754b321df
4 changed files with 5 additions and 0 deletions
@@ -122,6 +122,7 @@ const WorkflowMain = ({
citation: features.retriever_resource || { enabled: false },
moderation: features.sensitive_word_avoidance || { enabled: false },
annotationReply: features.annotation_reply || { enabled: false },
sandbox: features.sandbox || { enabled: false },
}
setFeatures(transformedFeatures)
@@ -67,6 +67,7 @@ export const useNodesSyncDraft = () => {
retriever_resource: features.citation,
sensitive_word_avoidance: features.moderation,
file_upload: features.file,
sandbox: features.sandbox,
}
return {
+1
View File
@@ -60,6 +60,7 @@ const Features = () => {
retriever_resource: currentFeatures.citation,
sensitive_word_avoidance: currentFeatures.moderation,
file_upload: currentFeatures.file,
sandbox: currentFeatures.sandbox,
}
await updateFeatures({
+2
View File
@@ -1,6 +1,7 @@
import type {
FileUpload,
RetrieverResource,
Runtime,
SensitiveWordAvoidance,
SpeechToText,
SuggestedQuestionsAfterAnswer,
@@ -20,6 +21,7 @@ export type WorkflowDraftFeaturesPayload = {
retriever_resource?: RetrieverResource
sensitive_word_avoidance?: SensitiveWordAvoidance
file_upload?: FileUpload
sandbox?: Runtime
}
export const workflowDraftEnvironmentVariablesContract = base