workflow/Inputs & Outputs

5.7 Workflow Inputs & Outputs

In Pop’s workflow system, inputs and outputs define how a workflow receives data and returns results. Whether you're building:

  • an AI content generator
  • an automated chart analysis tool
  • a knowledge‑base Q&A flow
  • a PDF report generator
  • a data processing pipeline
  • or a complete mini‑app

You must understand how Inputs and Outputs function.


🧩 1. What Are Input Parameters (Inputs)?

Input parameters represent the data passed into a workflow at runtime.

They usually come from:

  • user input (text / forms)
  • files (PDF, Excel, images, JSON)
  • runtime parameters (filters, date ranges)
  • front‑end application dynamic parameters
  • external API payloads

All inputs are received by the Entry Node.

Example (entered in the run window):

{
  "title": "2024 Annual Summary",
  "keywords": ["AI", "Automation", "Efficiency"],
  "pdf": <file>
}

🔢 2. Types of Input Parameters

Pop supports multiple input types, including:

Type Example Use Case
text string text AI Q&A, summary, rewriting
json JSON object / array data processing / charts
file PDF, Excel, images document parsing / reporting
number numeric value calculation / loops
boolean true / false conditional branching
array list batch processing / loops
any any type flexible scenarios

The input type determines how nodes parse the data.


🛠 3. Defining Input Parameters

In the right‑side panel, click Workflow Settings → Input Parameters to define inputs.

Fields include:

Field Description
Name Variable name used inside nodes/scripts
Label Display name in UI forms
Type text / number / file / json / boolean
Default Default value if none is provided
Required Whether this input must be provided
Description Explanation of the parameter

Example — defining a date range parameter:

name: date_range
type: text
required: true
default: ""
label: Date Range

📥 4. Using Input Parameters in Nodes

All inputs are collected in the Entry Node and can be accessed anywhere.

In PSL:

const title = input.value.title;
const keywords = input.value.keywords;

In AI Prompt:

Title: {{input.title}}
Keywords: {{input.keywords}}

In HTTP Request Node:

GET /api/report?date={{input.date_range}}

Inputs flow through the entire workflow and act as the core of data‑driven automation.


📤 5. What Are Output Parameters (Outputs)?

Output parameters represent the final data returned by the workflow.

Typical examples:

  • AI‑generated text
  • downloadable PPT / PDF link
  • JSON analysis results
  • chart rendering data
  • table data for the layout manager

Outputs are defined by ResultView (Sink) nodes.

Example:

{
  "summary": "This is the summary...",
  "charts": [...],
  "pdf_url": "https://..."
}

📦 6. Defining Output Parameters

In workflow settings, you can define:

Field Description
Name Key used to reference the output
Type text / json / file, etc.
Default empty text/object/array
Description Explanation of the output's purpose

Outputs are used in layout pages:

{{workflow.outputs.summary}}
{{workflow.outputs.chart_data}}
{{workflow.outputs.report_file}}

🔄 7. Entry Node & Result/Sink Node

During workflow execution:

  • Entry Node triggers the flow and passes inputs
  • ResultView / Sink Node determines what to return

Example:

[Entry] → [AI Summary] → [Generate Chart] → [ResultView]

Or writing a file:

[Entry] → [Excel Generator] → [Sink (write path)]

🧠 8. Role of Inputs & Outputs in Published Apps

When you publish a workflow as an app:

  • Inputs become form fields automatically
  • Outputs bind to layout components (charts, tables, text)
  • The workflow becomes a no‑code application

Example — report generator:

User UI = Input parameters + Layout components
Logic = Workflow
Result = Outputs bound to UI


📝 9. Common Input/Output Patterns

Pattern 1: Text → AI → Text

input.text → llm → result-view

Pattern 2: File → Parser → AI → File

input.file → pdf-toolbox → llm → ppt-generator → result-view

Pattern 3: JSON → Script → Chart

input.json → script → chart → layout

Pattern 4: Multi‑Input → Merge → AI → Object Output

input.multiple → transformer → llm → dictionary → result

🎯 10. Summary

Inputs and outputs are the "entry" and "exit" of every workflow. They determine:

  • how the workflow receives external data
  • what results the workflow returns
  • how app forms and UI elements bind to workflow logic
  • how nodes pass and transform data

Mastering inputs and outputs enables you to build flexible, scalable, and reusable workflows.