Skip to content
Keboola Docs

Ask a question and get an answer

Put the question to your own data: Kai reads the table you built and answers it in plain words, then answers the follow-up, and the same pipeline can be asked for as one prompt.

Tutorial Getting Started about 5 minutes

You built the table to answer something. Nobody has said the answer out loud yet. This page does, out of your own project rather than out of a page.

Where you are: staffing_outlook is in Storage. When you finish: the guide’s question answered from your data, and a second answer you did not have to build anything new to get.

Before you start

  • A Keboola project. Get a project covers creating or joining one — the Free Plan covers this guide.
  • The Kai Agent button in the top bar. An organization admin switches the feature on; see Get started with Kai.
  • The staffing_outlook table in Storage, from Transform data.

Three ways to do this, one page — they are alternatives, not steps. Prompt is what you paste into Kai; UI is the same task click by click, for when you want to see where each setting lives; CLI / API is the same task from a terminal, with the raw request beside it. Pick one tab and carry on — your choice follows you to the next page.

If a step builds something other than what this page describes, say so in the same chat — it edits what it made. Nothing here is one-way.

Everywhere else in this guide Kai stood in for your clicking. Here it reads what you built. Querying a table and calculating a metric is Data Exploration, and it needs nothing set up. Nothing on this page changes the project either: reading is what Kai’s read-only tools do, and those are allowed without asking by default. Expect an answer rather than an approval dialog, unless this project’s tool permissions have been set to ask.

This is the whole interaction, the pointer marking where the reasoning lands:

The answer changes with the forecast. On the day this page was written, two cafés were flagged on the same two days, both at the start of the week, and Kai put it as “a thin start-of-week roster colliding with warm, dry weather”. In a wet week Kai will tell you nobody is short-handed, and that is the table being right.

An answer is a place to start, not to stop:

Prompt
Using staffing_outlook: if one extra person joined the roster on every short-handed day, which
of those days would still be over 67 expected units per person, and what would each day's
figure become?

Check: Kai recomputes the per-person figure for every flagged row with one more person and lists the before and after. On the day this was written the answer was none of them: one extra person brought every flagged day well under the line. That is the kind of thing nobody can see in five separate files, and it took one question because the pipeline had already put the roster next to the demand.

If the numbers come out different, Kai wrote its own SQL and may have drawn the lines somewhere else: rounded before dividing, or read short_handed as text. The definitions this guide uses are the columns your transformation already wrote, so point Kai at those (expected_units, rostered_staff, expected_units_per_person) rather than re-prompting blind.

You built this one step at a time so every result stayed checkable. Once you have seen the pieces, the loading, the forecast and the joining are one request rather than three:

Prompt
Load the five CSV files at https://help.keboola.com/getting-started/boolabean/ (stores,
products, sales, staffing, weather_daily) into Storage as one HTTP data source configuration.
Add a second HTTP configuration for the open-meteo forecast CSV for the six cafés. Then build a
transformation that joins them into staffing_outlook, one row per café per forecast day with
expected units per rostered person and a short_handed flag over 67, and tell me which café and
day come out most stretched.

Two things to know before you paste it. Kai still asks you to approve each object it creates, so a prompt this size is a dozen approvals rather than one. And on a request with several parts Kai tends to answer “I’ll tackle this in stages”, do the first stage, and stop until you say continue; in our runs the same work as four separate prompts in one chat needed no nudging at all. The one-prompt version works. It is a shortcut for the second time, not a replacement for having seen the pieces once.

The part of the question still open is who else needs to see this. A chat answer reaches the person who asked. The next page turns the table into a grid anyone can open.

Ask Kai

Hi, I'm Kai — Keboola's AI assistant for the docs. Ask me anything and I'll answer from the documentation and cite the pages I use.

Kai is an AI and can make mistakes. Check the sources it links.