Topic Research Summarizer: A Workflow Script Tutorial
Learn how to build a Workflow Script that searches Google and returns a plain-language summary on any topic. The ideal first tutorial for MindStudio Workflow Scripts.
User enters a topic, the script searches Google and returns a plain-language summary. This is the ideal first Workflow Script to build — it introduces the core pattern you’ll use again and again.
Why build this
If you’re new to Workflow Scripts, start here. You’ll learn the foundational pattern that most scripts follow: take a user input, perform a search, and return a generated response. By the end, you’ll have a working script and a clear understanding of how Workflow Scripts fit into the Automations Canvas.
Blocks you’ll use
- User Input — Collects the topic the user wants to research.
- Run Script — Houses the Workflow Script. Inside the script, a Search Google action fetches the top results and a Generate Text action summarizes them.
- Display Content — Shows the generated summary to the user.
Canvas flow
Start → User Input → Run Script → Display Content → End
The Run Script block is where your Workflow Script lives. It takes the topic as input, searches Google for the top results, and uses a Generate Text action to produce a plain-language summary returned under the key summary.
How to build it
-
Open the Automations Canvas — Open MindStudio. The Automations Canvas is displayed by default. You’ll see a Start block and an End block already in place.
-
Add a User Input block — Click + to add a block and select User Input. In the block settings on the right, click + to add a user input, then click Create New. Set the Type to Short Text and enter
topicin the Variable field — this is the name you’ll use to reference this input in the Run Script block. Set the Label to a short name — for example, “Topic”. Then set the Help Text to a description the user will see — for example, “What topic should I research?”Once you’ve set up the user input, click the Main.flow tab at the top of the editor to return to the workflow.
-
Add a Run Script block — Click + in the workflow, then select View All Blocks. From the Blocks screen, search for Run Script and select it. In the block settings, click Edit Script to open the script editor. Paste the prompt below to generate the script automatically.
Generate a script that takes a topic as user input, searches Google for that topic, then uses a Generate Text action to summarize the top results into a plain-language overview. Return the summary under a key named summary.- Return to the workflow — Once the script is generated, click the Main.flow tab to return to the workflow. The Input Variables and Output Variables settings will appear in the block settings on the right.
- Configure Input Variables — For the
topicparameter, set the Variable to{{topic}}. - Configure Output Variables — Confirm that
summaryis mapped to the variable{{summary}}.
-
Add a Display Content block — Click + and select Display Content. Connect it after the Run Script block. In the block settings, set the Message field to
{{summary}}— the variable you mapped in the Run Script block’s Output Variables. This displays the summary generated by your script. -
Name your AI agent — Click Untitled Agent at the top of the interface, then update the Agent Name field — for example, “Topic Research Summarizer.”
-
Preview your AI agent — Click the Preview button, then select Open Draft Agent to run the AI agent and test your workflow.
Try it in MindStudio
Open MindStudio and follow along with this tutorial. No coding required.