Flow.Documentation

Step: Search knowledge base

4 steps± 3 minVideoVerified 22 Oct 2026
  1. Step 1 · Open your development environment
  2. Step 2 · Create a workflow with a question
  3. Step 3 · Add the step Search knowledge base
  4. Step 4 · Align, save and run

With the step Search knowledge base a workflow fetches the best matching chunks from a knowledge base, by meaning and by words. The query may come from earlier steps, for example a customer's question. Later steps get a list of results: the text, the score and the document.

Watch the whole guide as a video4 steps in one film
Step 1 / 4

Open your development environment

In the portal, under Environments, click Development, and there Open. Flow opens in a new tab and you are signed in straight away.

  1. Click Development
Open your development environment · Click Development
  1. Click Open ↗
Open your development environment · Click Open ↗
Step 2 / 4

Create a workflow with a question

Create a new workflow and put a question in the trigger's sample data. That is how the question will come in later too, for example through an API or a chat.

  1. Click Add to General
Create a workflow with a question · Click Add to General
  1. Click New workflow
Create a workflow with a question · Click New workflow
  1. In Workflow name, type Look up a maintenance question
Create a workflow with a question · In Workflow name, type Look up a maintenance question
  1. Click the trigger
Create a workflow with a question · Click the trigger
  1. Click Code
Create a workflow with a question · Click Code
  1. In Sample data, type `{
Create a workflow with a question · In Sample data, type `{; ;
Step 3 / 4

Add the step Search knowledge base

Choose the knowledge base and write the query. {{question}} takes the question from the trigger. Under Search by you choose whether Flow searches by meaning, by words or both; both usually works best.

  1. Click Add node
Add the step Search knowledge base · Click Add node
  1. Click Search knowledge base
Add the step Search knowledge base · Click Search knowledge base
  1. In Knowledge base, choose Bike maintenance · 2 documents
  2. In Query Use variables, for example {{order.description}}., type {{question}}
  3. In Number of results, type 2
Add the step Search knowledge base · In Knowledge base, choose Bike maintenance · 2 documents; In Query Use variables, for example {{order.description}}., type {{question}}; In Number of results, type 2
  1. Click the dot of ‘Event trigger’
Add the step Search knowledge base · Click the dot of ‘Event trigger’
  1. Click the dot of ‘Bike maintenance’
Add the step Search knowledge base · Click the dot of ‘Bike maintenance’
Step 4 / 4

Align, save and run

Select all steps (Ctrl+A), align them horizontally and save. Run the workflow: at the bottom under Output you see how many chunks the step found, and in the step's output the results themselves.

  1. Click Align horizontally
Align, save and run · Click Align horizontally
  1. Click Save
Align, save and run · Click Save
  1. Click Run
Align, save and run · Click Run
Align, save and run · ‘… results from knowledge base Bike maintenance’: how many chunks matched well enough (at most 2).
Align, save and run · The best result comes from the document on the chain.

This guide was carried out step by step on 22 Oct 2026 by an automated test on Flow (version 3e563176).