AI summary on create

When a row is added to the table you choose, the app's AI reads its text and writes a neutral one-sentence summary into a new ai_summary field. Point it at a choice field such as category and it also files the row: it picks one of that field's values, but only when the row still has no value or the default one, so nobody's choice is overwritten. When AI isn't available the run logs why and leaves the row as it is.

AI summary on create: its trigger and steps

What it adds to your app

Field ai_summary on your table. One workflow: on create, summarise (and optionally categorise) with ctx.ai.

Fields added to your tables

  • ‹entity›.ai_summary

How its workflows run

Each one is a server workflow in your project: it runs on its trigger, with retries, and its runs show in the builder's log.

  1. Summarise each new ‹entity› with AI

    When a row changes: ‹entity› created. Then: Update ‹entity›.

Set it up

It merges into the contract of an app you already have. Nothing is overwritten: a name you already use is refused until you pass a prefix.

  1. Pick the project

    Use the button above, or ask your coding agent with the Appbricx MCP server connected (quickstart).

  2. Point it at your tables and roles

    Leave out the ones with defaults; a wrong one is refused with the options your app has.

    ParamWhat it isExample
    entityNew rows of this table get a summary.ticket
    text_fieldThe field with the text to summarise (a body, a description, a message). Optional.body
    extra_fieldOptional: a second text field it reads first, such as the subject or title. Optional.subject
    classify_fieldOptional: a choice field the AI fills when the row has no value yet (or the default one), such as category. Optional.category
  3. Preview, then apply to dev

    A dry run shows the diff and the check report; applying it changes your dev environment only.

  4. Deploy

    When dev looks right, deploy. Production gets a snapshot first, so you can roll back.

Use it with your coding agent

The agent reads the template, runs a dry run, shows you the diff and applies it.

Prompt
Add the AI summary on create template (slug "ai-summary-on-create") to my Appbricx project. Read it with get_template, run use_template with dry_run first and show me the diff, then apply it. Ask me where it attaches if you can't tell from my contract (entity: table to summarise; text_field: text to read; extra_field: also read (optional); classify_field: file into (optional)).
MCP call
{
  "tool": "use_template",
  "arguments": {
    "slug": "ai-summary-on-create",
    "project_id": "<your project id>",
    "params": {
      "entity": "ticket",
      "text_field": "body",
      "extra_field": "subject",
      "classify_field": "category"
    },
    "dry_run": true
  }
}
CLI
appbricx templates use ai-summary-on-create --param entity=ticket --param text_field=body --param extra_field=subject --param classify_field=category --dry-run

Your agent adds it. Appbricx runs it.