feat: hide advanced fields in InspectionPanel for File and SplitText components (#12473)

* feat: hide advanced fields in InspectionPanel for File and SplitText components

- Add hidden-fields.ts to suppress advanced/deprecated fields from the
  InspectionPanel UI without removing backend functionality
- Hide silent_errors, delete_server_file_after_processing,
  ignore_unsupported_extensions, ignore_unspecified_files, pipeline,
  md_image_placeholder, md_page_break_placeholder, doc_key, and
  use_multithreading for the File (Read File) component
- Hide keep_separator for the SplitText component
- Replace deprecated use_multithreading branch with
  max(1, self.concurrency_multithreading) to preserve default behaviour

* feat: wire HIDDEN_FIELDS into InspectionPanelFields filter logic

Import HIDDEN_FIELDS map and apply it in both the edit-mode and
normal-mode field filters. Also suppress the APIRequest body field
when method is GET.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* feat: hide tool_placeholder input in Prompt Template component

Set show=False on the tool_placeholder input so it does not appear
in the UI while retaining tool mode functionality.

* [autofix.ci] apply automated fixes

* feat: hide include_metadata field for DynamicCreateData in InspectionPanel

* [autofix.ci] apply automated fixes

* fix: add trailing newline to component_index.json

The build_component_index.py script was generating component_index.json
without a trailing newline, causing CI failures when autofix.ci tried to
add the missing newline. This fix ensures the generated JSON file always
ends with a newline character, following POSIX text file standards.

Fixes the 'No newline at end of file' error in the update-component-index
workflow job.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* fix: add trailing newline to component_index.json

The build_component_index.py script was generating component_index.json
without a trailing newline, causing CI failures when autofix.ci tried to
add the missing newline. This fix ensures the generated JSON file always
ends with a newline character, following POSIX text file standards.

Fixes the 'No newline at end of file' error in the update-component-index
workflow job.

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: vijay kumar katuri <vijay.katuri@ibm.com>
This commit is contained in:
Ram Gopal Srikar Katakam
2026-04-08 11:52:20 -04:00
committed by GitHub
parent b905ea1c4a
commit b3666fe554
27 changed files with 141 additions and 79 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -152,6 +152,9 @@ export const BotMessage = memo(
)}
<div className="flex w-full flex-col min-w-0">
<span className="text-sm font-medium text-foreground mb-1">
{chat.sender_name ?? "AI"}
</span>
<div className="flex items-center gap-2 text-sm text-muted-foreground">
{!thinkingActive && displayTime > 0 && (
<ForwardedIconComponent

View File

@ -139,6 +139,9 @@ export const UserMessage = memo(
{/* Content */}
<div className="flex w-[94%] flex-col gap-2">
<span className="text-sm font-medium text-foreground">
{chat.sender_name ?? "User"}
</span>
<div className="form-modal-chat-text-position flex-grow">
<div className="flex w-full flex-col">
{editMessage ? (

View File

@ -14,6 +14,7 @@ import type { NodeDataType, targetHandleType } from "@/types/flow";
import { scapeJSONParse } from "@/utils/reactflowUtils";
import InspectionPanelEditField from "./InspectionPanelEditField";
import InspectionPanelField from "./InspectionPanelField";
import { HIDDEN_FIELDS } from "./hidden-fields";
interface InspectionPanelFieldsProps {
data: NodeDataType;
@ -50,6 +51,13 @@ export default function InspectionPanelFields({
.filter((templateField) => {
const template = data.node?.template[templateField];
if (isInternalField(templateField)) return false;
if (HIDDEN_FIELDS[data.type]?.includes(templateField)) return false;
if (
data.type === "APIRequest" &&
templateField === "body" &&
data.node?.template?.method?.value === "GET"
)
return false;
if (!template?.show) return false;
if (isCodeField(templateField, template)) return false;
if (isToolModeEnabled(template) && isToolMode) return false;
@ -77,6 +85,13 @@ export default function InspectionPanelFields({
return Object.keys(data.node?.template || {})
.filter((templateField) => {
const template = data.node?.template[templateField];
if (HIDDEN_FIELDS[data.type]?.includes(templateField)) return false;
if (
data.type === "APIRequest" &&
templateField === "body" &&
data.node?.template?.method?.value === "GET"
)
return false;
return shouldRenderInspectionPanelField(
templateField,
template,

View File

@ -0,0 +1,40 @@
// Fields to hide per component type in the InspectionPanel.
// Add entries here to hide fields without removing backend functionality.
export const HIDDEN_FIELDS: Record<string, string[]> = {
ChatInput: ["should_store_message", "sender"],
ChatOutput: ["should_store_message", "sender", "data_template", "clean_data"],
APIRequest: ["follow_redirects", "save_to_file", "include_httpx_metadata"],
SQLComponent: ["include_columns", "add_error"],
URLComponent: [
"prevent_outside",
"use_async",
"filter_text_html",
"continue_on_failure",
"check_response_status",
"autoset_encoding",
],
UnifiedWebSearch: ["ceid"],
Agent: ["api_key", "format_instructions", "output_schema", "verbose"],
EmbeddingModel: ["show_progress_bar", "chunk_size", "api_key"],
LanguageModelComponent: ["api_key"],
Memory: ["sender_type"],
BatchRunComponent: ["api_key"],
GuardrailValidator: ["api_key"],
SmartRouter: ["api_key"],
"Smart Transform": ["api_key"],
StructuredOutput: ["api_key", "system_prompt", "schema_name"],
KnowledgeBase: ["api_key", "include_embeddings"],
DynamicCreateData: ["include_metadata"],
SplitText: ["keep_separator"],
File: [
"silent_errors",
"delete_server_file_after_processing",
"ignore_unsupported_extensions",
"ignore_unspecified_files",
"pipeline",
"md_image_placeholder",
"md_page_break_placeholder",
"doc_key",
"use_multithreading",
],
};

File diff suppressed because one or more lines are too long

View File

@ -1254,7 +1254,7 @@ class FileComponent(BaseFileComponent):
return final_return
# Standard multi-file (or single non-advanced) path
concurrency = 1 if not self.use_multithreading else max(1, self.concurrency_multithreading)
concurrency = max(1, self.concurrency_multithreading)
file_paths = [str(f.path) for f in file_list]
self.log(f"Starting parallel processing of {len(file_paths)} files with concurrency: {concurrency}.")

View File

@ -35,6 +35,7 @@ class PromptComponent(Component):
display_name="Tool Placeholder",
tool_mode=True,
advanced=True,
show=False,
info="A placeholder input for tool mode.",
),
]