Skip to content

Self-improving AI Employees for everyone

refactor(client): remove INodeTypeDescription.outputSchema field

trohitg5866821b3921
diff --git a/client/src/components/parameterPanel/InputSection.tsx b/client/src/components/parameterPanel/InputSection.tsx
index 4ba5456d..f06fac01 100644
--- a/client/src/components/parameterPanel/InputSection.tsx
+++ b/client/src/components/parameterPanel/InputSection.tsx
@@ -175,11 +175,11 @@ const InputSection: React.FC<InputSectionProps> = ({ nodeId, visible = true }) =
} else {
hasExecutionData = false;
- // Schema-driven first: if the node definition declares an
- // outputSchema, use it directly. The `start` node's runtime
- // shape is data-driven from the user's initialData JSON, so
- // it keeps the legacy parsing path for now.
- const declaredSchema = nodeDef?.outputSchema;
+ // No real run data yet. The start node derives its shape from the
+ // user's initialData JSON (genuinely UI-owned). Every other node
+ // falls through to the legacy sampleSchemas map below as a bridge
+ // until the backend schema endpoint ships. See
+ // docs-internal/schema_source_of_truth_rfc.md.
if (nodeType === 'start') {
try {
const initialData = sourceNode?.data?.initialData || '{}';
@@ -187,8 +187,6 @@ const InputSection: React.FC<InputSectionProps> = ({ nodeId, visible = true }) =
} catch (e) {
outputSchema = {};
}
- } else if (declaredSchema) {
- outputSchema = declaredSchema;
} else {
const sampleSchemas: Record<string, Record<string, any>> = {
location: { latitude: 'number', longitude: 'number', accuracy: 'number', provider: 'string', altitude: 'number' },
diff --git a/client/src/nodeDefinitions/aiAgentNodes.ts b/client/src/nodeDefinitions/aiAgentNodes.ts
index 7db8344d..bd32f58b 100644
--- a/client/src/nodeDefinitions/aiAgentNodes.ts
+++ b/client/src/nodeDefinitions/aiAgentNodes.ts
@@ -314,13 +314,6 @@ export const aiAgentNodes: Record<string, INodeTypeDescription> = {
description: 'Markdown-based conversation memory with optional vector DB for long-term retrieval',
defaults: { name: 'Memory', color: '#8b5cf6' },
uiHints: { isMemoryPanel: true, hasCodeEditor: true, hideRunButton: true },
- outputSchema: {
- session_id: 'string',
- messages: 'array',
- message_count: 'number',
- memory_type: 'string',
- window_size: 'number',
- },
inputs: [], // No input - memory node is passive
outputs: [{
name: 'memory',
diff --git a/client/src/nodeDefinitions/codeNodes.ts b/client/src/nodeDefinitions/codeNodes.ts
index 6564c74f..ed26bb9c 100644
--- a/client/src/nodeDefinitions/codeNodes.ts
+++ b/client/src/nodeDefinitions/codeNodes.ts
@@ -12,7 +12,6 @@ export const codeNodes: Record<string, INodeTypeDescription> = {
description: 'Execute Python code with input data access',
defaults: { name: 'Python Executor', color: '#3776AB' },
uiHints: { hasCodeEditor: true },
- outputSchema: { output: 'any' },
inputs: [{ name: 'main', displayName: 'Input', type: 'main' as NodeConnectionType, description: 'Input data as input_data variable' }],
outputs: [{ name: 'main', displayName: 'Output', type: 'main' as NodeConnectionType, description: 'Python execution result' }],
properties: [
@@ -38,7 +37,6 @@ export const codeNodes: Record<string, INodeTypeDescription> = {
description: 'Execute JavaScript code with input data access',
defaults: { name: 'JavaScript Executor', color: '#F7DF1E' },
uiHints: { hasCodeEditor: true },
- outputSchema: { output: 'any' },
inputs: [{ name: 'main', displayName: 'Input', type: 'main' as NodeConnectionType, description: 'Input data as input_data variable' }],
outputs: [{ name: 'main', displayName: 'Output', type: 'main' as NodeConnectionType, description: 'JavaScript execution result' }],
properties: [
@@ -64,7 +62,6 @@ export const codeNodes: Record<string, INodeTypeDescription> = {
description: 'Execute TypeScript code with input data access and type safety',
defaults: { name: 'TypeScript Executor', color: '#3178C6' },
uiHints: { hasCodeEditor: true },
- outputSchema: { output: 'any' },
inputs: [{ name: 'main', displayName: 'Input', type: 'main' as NodeConnectionType, description: 'Input data as input_data variable' }],
outputs: [{ name: 'main', displayName: 'Output', type: 'main' as NodeConnectionType, description: 'TypeScript execution result' }],
properties: [
diff --git a/client/src/nodeDefinitions/utilityNodes.ts b/client/src/nodeDefinitions/utilityNodes.ts
index cabbbe25..73c27569 100644
--- a/client/src/nodeDefinitions/utilityNodes.ts
+++ b/client/src/nodeDefinitions/utilityNodes.ts
@@ -227,11 +227,6 @@ export const utilityNodes: Record<string, INodeTypeDescription> = {
description: 'Trigger workflow when user sends a chat message from the console input',
defaults: { name: 'Chat Trigger', color: '#10b981' },
uiHints: { isChatTrigger: true },
- outputSchema: {
- message: 'string',
- timestamp: 'string',
- session_id: 'string',
- },
inputs: [],
outputs: [{
name: 'main',
diff --git a/client/src/nodeDefinitions/workflowNodes.ts b/client/src/nodeDefinitions/workflowNodes.ts
index 076e6a79..19b823c0 100644
--- a/client/src/nodeDefinitions/workflowNodes.ts
+++ b/client/src/nodeDefinitions/workflowNodes.ts
@@ -16,10 +16,6 @@ export const workflowNodes: Record<string, INodeTypeDescription> = {
description: 'Starting point for workflow execution. Provides initial data to connected nodes.',
defaults: { name: 'Start', color: '#8be9fd' },
uiHints: { hideInputSection: true, hideOutputSection: true },
- outputSchema: {
- timestamp: 'string',
- data: 'any',
- },
inputs: [],
outputs: [{
name: 'main',
@@ -52,16 +48,6 @@ export const workflowNodes: Record<string, INodeTypeDescription> = {
subtitle: 'Child Agent Completed',
description: 'Triggers when a delegated child agent completes its task (success or error)',
defaults: { name: 'Task Completed', color: '#bd93f9' },
- outputSchema: {
- task_id: 'string',
- status: 'string', // 'completed' | 'error'
- agent_name: 'string',
- agent_node_id: 'string',
- parent_node_id: 'string',
- result: 'string', // present when status === 'completed'
- error: 'string', // present when status === 'error'
- workflow_id: 'string',
- },
inputs: [],
outputs: [{
name: 'main',
diff --git a/client/src/types/INodeProperties.ts b/client/src/types/INodeProperties.ts
index 9c4ea810..7e265e4e 100644
--- a/client/src/types/INodeProperties.ts
+++ b/client/src/types/INodeProperties.ts
@@ -232,14 +232,10 @@ export interface INodeTypeDescription {
};
/** Per-node UI hints; see INodeUIHints for each flag. */
uiHints?: INodeUIHints;
- /**
- * JSON-Schema-shaped descriptor of this node's runtime output. Used by
- * InputSection to populate the draggable variable list for downstream
- * nodes; if absent, falls back to the legacy `sampleSchemas` map.
- * Use plain primitive type names ('string' | 'number' | 'boolean' |
- * 'array' | 'object' | 'any') for leaves, or nested objects.
- */
- outputSchema?: Record<string, any>;
+ // NOTE: runtime output shape is no longer declared on the frontend. It is
+ // served lazy by the backend at GET /api/schemas/nodes/{nodeType}.json and
+ // consumed by InputSection via useNodeOutputSchemaQuery. See
+ // docs-internal/schema_source_of_truth_rfc.md.
}
// Node type interface that nodes must implement