Skip to main content

Examples

These patterns are starting points—swap table names, thresholds, Slack channels, and connection IDs for your workspace. Each example lists the intent, trigger, and shape of the graph; paste fragments into the canvas or provide them to an assistant following Vibe coding.

Build with AI

Natural-language version: “Build me the Incremental ETL pattern from the docs using dataset processed_tickets.” Point the assistant at this page plus the flow authoring guide.

1. Account health alert (schedule + Slack)

Intent: Every weekday morning, find accounts whose health score is below a threshold and post a compact list to Slack.

Trigger: schedule (cron) with timezone.

Graph sketch:

  1. CALL semantic.query@.at_risk
  2. CONDITION on len(results) > 0 (derive boolean in a small TRANSFORM if needed)
  3. CALL slack.send_message with interpolated summary text

MCP-style prompt: “Create a scheduled agent weekdays 9am PT. Query accounts with health_score < 40 and churned = 0, limit 50. Post account_id, name, health_score as bullets to Slack channel C0123 using connection <slack_connection_id>.”

2. Ticket analysis pipeline (conversation trigger)

Intent: When a ticket conversation is ingested, classify sentiment and topics, then store JSON in a dataset for dashboards.

Trigger: conversation with types: ["ticket"].

The conversation trigger payload provides key, metadata, and timestamp — not the full ticket text. To load the full content, use a semantic.query step early in the flow.

Graph sketch:

  1. CALL semantic.query to fetch the full ticket using identifiers from $.trigger.conversation.key (e.g. join tickets on the id found in the key object).
  2. AGENT small with JSON-only system prompt → @.classification
  3. CALL dataset.record.upsert keyed by ticket id.

3. Renewal risk summary (query trigger + email)

Intent: Once per UTC day, select accounts renewing in N days with risk signals, summarize with a large model, email the owning CSM list.

Trigger: query SQL returning account_id, csm_email, name, … with LIMIT.

Graph sketch:

  1. CALL semantic.query for core renewal rows → @.renewals
  2. Optional second CALL for needle movers / metrics.
  3. AGENT large to craft per-account or batched summaries depending on volume.
  4. CALL email.send with both body and optional html.

Remember query-trigger cadence and idempotency (Triggers).

4. CRM sync (interval + update)

Intent: Every few hours, select accounts whose derived fields changed in FunnelStory and push properties to HubSpot or Salesforce.

Trigger: interval such as "6h".

Graph sketch:

  1. CALL semantic.query for the change set.
  2. LOOP over rows calling hubspot.update_record or salesforce.update_record with mapped fields, or salesforce.create_record when you need a new Salesforce record (for example a Task or Note on an Account).

Respect API rate limits—keep SQL selective and batches small.

5. Chat agent (manual + tools)

Intent: A user opens Chat, asks questions, and the LLM may call semantic.query or create tasks.

Trigger: manual (plus chat entrypoint).

Graph sketch:

  • Final AGENT must write user-visible text to @.response.
  • Attach tools for semantic.query and tasks.create as needed.

6. Incremental ETL (query + dataset dedupe)

Intent: Process only rows not yet present in a dataset of finished keys.

Trigger: query SQL using LEFT JOIN dataset_records('processed') pattern (see flow authoring guide).

Graph sketch:

  1. CALL semantic.query returning pending rows.
  2. LOOP with inner AGENT or CALL processing.
  3. CALL dataset.record.upsert marking completion keys.

7. Parallel notify (BRANCH + JOIN)

Intent: When a condition hits, notify Slack and email in parallel, then continue cleanup only after both succeed.

Graph sketch:

  1. CONDITION on severity predicate.
  2. BRANCH into path_slack and path_email, each ending at JOIN.
  3. After JOIN, mark a dataset row or call tasks.create.

This pattern avoids serial delays when integrations are independent.