Database size and shape note
Starting pointBuilds on the shipped template “postgresql data analysis” (7 nodes), which you can find in the template library.
Give a platform team a short plain-English note on which tables are largest and what that suggests.
- List the tables in the public schema.
- Run the fixed size query.
- A code node formats the result as a short summary.
- An OpenAI chat call returns two or three observations, and an owner reads them in a human-input step.
Where the approval sits. The shipped template sends its summary to the model and moves on. The reader’s step and a read-only role are the additions.
Approved ad hoc query
DesignedLet an analyst ask a question in words and run the SQL only after seeing it.
- An agent turns the question into a SQL statement.
- A policy check denies statements that are not plain selects.
- A human-input step shows the analyst the exact SQL, with approve and reject branches.
- On approval, the query action runs it under the read-only role, and the rows go back as output.
Where the approval sits. The approval is on the SQL and not on the question, which is what makes it meaningful. The read-only role is the backstop if the check misses something.
Schema documentation draft
DesignedDraft a description of each table for a data catalogue, for the owner to review.
- List the tables in a schema.
- An LLM node drafts a one-line description of each from its name and the owner’s notes.
- A human-input step sends the draft to the data owner.
- The approved text is passed on as output, to be filed in the catalogue by a person.
Where the approval sits. Table names alone can mislead a model, so the owner’s review is where mistakes are caught. Nothing is written to the database.
- Shipped template
- A governed template with its approval step already in it ships in the platform.
- Starting point
- A shipped template runs the same actions. It is an integration test with no approval step, so you add the gate.
- Designed
- Design intent. It uses the actions listed above plus generic nodes, and nothing has been built as a template.