Skip to Content
BlocksAI

AI Assistant

A chat panel docked beside a page, a conversation with code and feedback, questions about token usage that can ask for your approval, a failed reply with retry, a copilot that leads with its tools' data, menus for the model and tools, and the chats by day and projects that keep chats, files and instructions together.

A chat assistant that takes the Vercel AI SDK's useChat as it is, or any function that streams, built on shadcn's chat components, with the chats and projects around it. Replies show the model's thinking, tool calls, Markdown, files and sources; the previews stream canned replies.

Side Panel

An assistant docked beside the page, with suggested prompts, the page as context, and New conversation and Close buttons.

npx shadcn add @dashboardblocks/ai-assistant-01

Assistant

Answers from your revenue data

Assistant

Answers from your revenue data

Revenue, last 30 days

Press Enter to send and Shift+Enter for a new line.

Conversation

A conversation with a table and a SQL query, where you can attach a file, copy, rate or regenerate a reply, or pick a follow-up question.

npx shadcn add @dashboardblocks/ai-assistant-02

Analytics assistant

Answers from your product analytics, with the query behind each one.

You:

Why did checkout conversion drop last week?

Assistant:

Checkout conversion fell from 3.8% to 3.1% between Sep 15 and Sep 21. Three things changed that week:

  • Safari 17 payment errors. 41% of failed checkouts were on Safari 17, starting with the Sep 15 release.
  • Longer shipping estimates. Standard delivery showed 5–7 days instead of 3–5 for EU addresses.
  • More paid social traffic. Sessions from paid social doubled, and they convert at 1.2%.

The Safari errors explain most of the drop. Fixing them should win back about half a point.

You:

Can you give me the SQL to check the Safari errors?

Assistant:

This counts started and failed checkouts by browser for that week, from the events table:

sql
selectbrowser,count(*) filter (where name = 'checkout_started') as started,count(*) filter (where name = 'checkout_failed') as failed,round(100.0 * count(*) filter (where name = 'checkout_failed')  / nullif(count(*) filter (where name = 'checkout_started'), 0), 1) as failure_ratefrom eventswhere occurred_at >= '2026-09-15' and occurred_at < '2026-09-22'group by browserorder by failed desc;

If Safari's failure_rate is well above the other browsers, the release is the likely cause.

Press Enter to send and Shift+Enter for a new line. Paste or drop files to attach them.

Ask About Data

Questions about this month's AI Usage numbers, with the tokens and cost of each answer and a change that waits for your approval.

npx shadcn add @dashboardblocks/ai-assistant-03

Token usage

All models this month. Output is 8% of the tokens and 38% of the cost.

Tokens
305.5M
Cost
$998.40
From the cache
30%
  • Input197M
  • Cached83M
  • Output25.5M

Ask about this data

You:

What drove the cost this month?

Assistant:

Output tokens: they're 8% of the tokens but 38% of the cost, at five times the input price. Most come from support summaries, which write about 900 tokens per ticket.

Capping summaries at 400 tokens would save roughly $150 a month.

2K in  96 out$0.0037

Press Enter to send and Shift+Enter for a new line.

Retry

A reply that failed, kept in the conversation with a button to try again.

npx shadcn add @dashboardblocks/ai-assistant-04

Ops assistant

Answers from incidents, deploys and runbooks.

You:

Is checkout healthy right now?

Assistant:

Yes. The checkout error rate is 0.3% over the last hour, under the 1% alert threshold, and p95 latency is 420 ms. The last deploy, web@4.18.2, went out at 09:12 UTC with no new errors.

You:
  • payments-api.logLOG

Summarise last night’s incidents

Press Enter to send and Shift+Enter for a new line. Paste or drop files to attach them.

Copilot Panel: Tool Calls, Pro

Asked why MRR dropped, it looks up MRR by plan and the largest movements, counts MRR down to this week, grows each plan's bar to its value and cites the accounts behind the drop.

Pro

Copilot

Ask about your data. Answers cite the records they use.

You:

Why did MRR drop this week?

Press Enter to send and Shift+Enter for a new line.

Copilot Panel: Stored Conversation, Pro

A saved conversation that opens on its answer, where one tool call failed and the answer says what it couldn't check.

Pro

Copilot

Ask about your data. Answers cite the records they use.

You:

Which accounts are at risk?

Copilot:

Lowest health score

Last month
  • Oakridge Dental Group31

    Down 46.6% vs last month

  • Lumen Studios36

    Down 18.2% vs last month

Two accounts are at risk, worth $3,550 of MRRSource 1: accounts.health_scores. Oakridge Dental Group removed 12 seatsSource 2: Oakridge Dental Group, and Lumen Studios hasn’t signed in for 19 daysSource 3: Lumen Studios.

I couldn’t count their open support tickets, so ask again once the support desk is back.

Press Enter to send and Shift+Enter for a new line.

Composer Menus, Pro

A message box with a Tools button that turns web search on as a chip and the connected apps on or off, and one pill for the model and how hard it thinks.

Pro

Press Enter to send and Shift+Enter for a new line. Paste or drop files to attach them.

Usage Limit, Pro

A message box at its limit that says when it resets, with a smaller model to keep going on and Upgrade.

Pro

You’ve reached your limit. It resets at 4:00 PM.

Press Enter to send and Shift+Enter for a new line.

Share Chat, Pro

A chat shared with the workspace that has changed since, with Update link, who can open the link and Copy link.

Pro

Share “Explain the October orders CSV”

A link shows the chat as it is now. What you add after stays private.

Anyone at Acme with the link can read the chat as it was when you shared it.

You’ve added to the chat since you shared it. The link still shows the older copy.

https://app.acme.co/share/7f3c1a9e

Every chat you shared, with who can open each link and when, to open, copy or stop sharing with Undo.

Pro

Shared links

3 chats shared. Each link shows the chat as it was when you shared it.

    Canvas, Pro

    A letter beside the chat at its third version, with what it changed marked, an earlier version to restore, and editing in place saved as a new version.

    Pro

    2027 prices letter

    By Orion  

    Version 3 of 3

    Dear Rosa,

    removed Thank you for another year of Briar coffee at Northside Kitchen. Our wholesale prices change on January 1, 2027, and we wanted you to hear it from us first. added Your delivery days, payment terms and grinder servicing stay the same in 2027, and so does the 6% break on orders over 20 kilos. Our prices change on January 1.

    Green coffee from Kenya and Colombia cost us about 18% more removed at origin this year, and shipping rose again in the spring. We added this year, and we held our prices through removed 2026 and have kept the rise as small as we can. added 2026.

    Coffee, a kiloNowFrom January 1
    House blend£18.20£19.40
    Kenya Kiambu£19.30£21.40
    Colombia Huila£18.90£20.10
    Decaf£17.60£17.60

    removed Your delivery days, payment terms and grinder servicing stay the same.

    If you’d like to talk it through, reply to this email or call me on 0113 496 0721.

    Best wishes,
    Nadia Rahman
    Operations lead, Briar

    Press Enter to edit.

    Model Chart, Pro

    Three charts Claude wrote as specs instead of chart code: weekly takings against a break-even line, a cost breakdown stacked across, and orders by city with York picked out.

    Pro
    Expected weekly takings vs break-evenTakings climb from £2,400 to £6,000 a week and pass the £4,800 break-even in week 8.

    Research Run, Pro

    A research run as Orion’s reply, 41 seconds in: each search with the sites it found, the thoughts between them and the page it’s reading now, with the time and Stop.

    Pro
    Researching6 searches  1 page read
    1. Searched US tariffs Brazil coffee 2026 price outlook
    2. I’m going to pull up the Primexbt forecast page and a USDA source, and run a UK search on café wholesale pricing and GBP exchange rates. That’s one more search round, then a fetch.
    3. Searched UK café wholesale coffee price per kg roasters 2026 increase cost of green coffee share
    4. Searched pound dollar exchange rate forecast 2027
    5. Read Coffee Price Forecast 2026, 2027, 2028–2030 | PrimeXBT (opens in a new tab)
    6. Reading stonex.com…

    Keeps going if you leave. The report opens beside the chat when it’s written.

    Chat History, Pro

    The sidebar's chats by day, pinned first, each with a menu to pin, rename in place or delete with Undo.

    Chat History: All Chats, Pro

    Every chat with its project, searchable, with boxes to pick several and delete them at once.

    Pro

    Chats

    16 chats, the newest first. Pick several to delete them at once.

    Chats: 16 chats, the newest first. Pick several to delete them at once.
    ChatUpdated
    Pinned
    Pricing rules for wholesaleWholesale prices 2027Oct 22
    Supplier email templatesSupplier contractsOct 19
    Today
    Price list from the costs sheetWholesale prices 20272:14 PM
    Café fit-out checklistLeeds café opening11:02 AM
    Explain the October orders CSV9:40 AM
    Yesterday
    Why did October orders dip?Oct 30
    Roast schedule for LeedsLeeds café openingOct 30
    Previous 7 days
    Shop discount scriptWebsite rewriteOct 28
    Reply to Bean & LeafOct 28
    Allergen labels wordingWebsite rewriteOct 27
    Notes from the Kenya callOct 25
    Previous 30 days
    Grinder service quoteOct 20
    Holiday opening hours postWebsite rewriteOct 17
    Compare two milk suppliersSupplier contractsOct 12
    September
    Christmas blend tasting notesSep 24
    Lease questions for the landlordLeeds café openingSep 11

      Project Grid, Pro

      Every project as a card with what it's for, its chats and files, when it changed and who it's shared with, and New project.

      Project Workspace, Pro

      One project's chats with a message box that starts a new one, beside its instructions, edited in place, its files, added and removed with Undo, and the documents written in its chats.

      Pro

      Wholesale prices 2027

      Next year’s café prices, the letters about them and the rules behind them.

      Instructions and 4 files

      Press Enter to send and Shift+Enter for a new line.

      Chats

      6

        On this page