Group customer feedback into themes with quotes, using AI

An agent reads survey responses and returns the main themes with counts and word-for-word quotes.

  • Files
  • Budget cap

Watch a real run

A real run on Oct 7, 2026, replayed. Model: openai/gpt-6-luna.

Succeededrun_16e8f6ea0b96505dd4d2615be299a35b$0.002898 of $0.03
  1. Queuedbudget $0.03 reserved
  2. MicroVMmicroVM ready
  3. MicroVMworker started · shell off · web off
  4. Fileread feedback.txt
  5. MicroVMmicroVM destroyed
  6. Succeeded2 model calls, 2,542 tokensRecorded output (English)
    json
    {
      "themes": [
        {
          "name": "Dashboard and report speed",
          "sentiment": "positive",
          "count": 3,
          "response_numbers": [
            1,
            9,
            19
          ],
          "quote": "Love the new dashboard, much faster than before."
        },
        {
          "name": "Pricing and plan details",
          "sentiment": "negative",
          "count": 3,
          "response_numbers": [
            4,
            13,
            20
          ],
          "quote": "Pricing is confusing, I cannot tell which plan includes API access."
        },
        {
          "name": "Dark mode",
          "sentiment": "request",
          "count": 3,
          "response_numbers": [
            6,
            10,
            18
          ],
          "quote": "Please add dark mode."
        },
        {
          "name": "Support experience",
          "sentiment": "positive",
          "count": 2,
          "response_numbers": [
            3,
            12
          ],
          "quote": "Support answered in 10 minutes, great experience."
        },
        {
          "name": "CSV export failures",
          "sentiment": "negative",
          "count": 2,
          "response_numbers": [
            2,
            11
          ],
          "quote": "Export to CSV keeps timing out on big reports."
        },
        {
          "name": "Mobile app crashes",
          "sentiment": "negative",
          "count": 2,
          "response_numbers": [
            5,
            14
          ],
          "quote": "The mobile app crashes when I open reports."
        },
        {
          "name": "Excel import failures",
          "sentiment": "negative",
          "count": 2,
          "response_numbers": [
            7,
            17
          ],
          "quote": "Importing contacts from Excel failed twice with no error message."
        },
        {
          "name": "Finding and downloading invoices",
          "sentiment": "negative",
          "count": 2,
          "response_numbers": [
            8,
            16
          ],
          "quote": "Billing page is hard to find, I could not get my invoice."
        },
        {
          "name": "Easy onboarding",
          "sentiment": "positive",
          "count": 1,
          "response_numbers": [
            15
          ],
          "quote": "Onboarding was easy, I was running in 10 minutes."
        }
      ],
      "unthemed": []
    }
  7. Worker destroyed$0.002898 charged, $0.027102 released
Model $0.000498 · Web $0.00 · Compute $0.0024

Run it yourself

Open the sample in the playground with the whole request filled in. It runs on your own account, within the budget shown, against the same read-only sample systems.

Budget for this sample: $0.03

How it works

Each theme has a count and at least one verbatim quote, so every claim can be checked against the source file. Praise and complaints are separated, and a response is counted under one theme only.

What the agent can and cannot do

The permissions are part of the request. Anything not listed here is not available to the run.

SettingAllowed
ConnectionsNone
WebOff
ShellOff
Filesfeedback.txt (read-only)
Zero data retentionOff: the record is kept for 30 days
Budget$0.03, a hard cap
Timeout60 seconds

Credentials never enter the machine: a broker adds them to each call and enforces the methods above.

The code

This is the exact request the sample sends. Set EPHEMERAL_API_KEY to a member key of your organization.

curl -X POST $EPHEMERAL_URL/v1/runs \
  -H "Authorization: Bearer $EPHEMERAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d @request.json

Files in the request

Passed inline, so nothing is uploaded first. The agent sees each one as a read-only file.

feedback.txt
feedback.txt
1. Love the new dashboard, much faster than before.
2. Export to CSV keeps timing out on big reports.
3. Support answered in 10 minutes, great experience.
4. Pricing is confusing, I cannot tell which plan includes API access.
5. The mobile app crashes when I open reports.
6. Please add dark mode.
7. Importing contacts from Excel failed twice with no error message.
8. Billing page is hard to find, I could not get my invoice.
9. The dashboard loads quickly now, nice work.
10. I would pay more for a dark theme, my eyes hurt at night.
11. CSV export is broken for anything over a few thousand rows.
12. Great support team, they fixed my issue same day.
13. Why does the Team plan cost so much more than Pro? The page does not explain it.
14. The app crashed on my phone again after the update.
15. Onboarding was easy, I was running in 10 minutes.
16. Could not find where to download invoices. Had to ask support.
17. Import from Excel silently drops rows with dates.
18. Dark mode please! The white background is too bright.
19. Reports are much faster, thank you.
20. Pricing page does not list the API limits for each plan.
Full request body request.json

The same body, with the files inline.

request.json
{
  "prompt": "feedback.txt holds 20 numbered customer comments. Group them into themes. Reply with one JSON object and nothing else: {\"themes\": [{\"name\": string, \"sentiment\": \"positive\"|\"negative\"|\"request\", \"count\": number, \"response_numbers\": number[], \"quote\": string}], \"unthemed\": number[]}. Every comment belongs to exactly one theme, so the counts add up to 20 together with unthemed. quote must be copied word for word from one of the theme's comments. Order themes by count, highest first.",
  "files": [
    {
      "path": "feedback.txt",
      "content": "1. Love the new dashboard, much faster than before.\n2. Export to CSV keeps timing out on big reports.\n3. Support answered in 10 minutes, great experience.\n4. Pricing is confusing, I cannot tell which plan includes API access.\n5. The mobile app crashes when I open reports.\n6. Please add dark mode.\n7. Importing contacts from Excel failed twice with no error message.\n8. Billing page is hard to find, I could not get my invoice.\n9. The dashboard loads quickly now, nice work.\n10. I would pay more for a dark theme, my eyes hurt at night.\n11. CSV export is broken for anything over a few thousand rows.\n12. Great support team, they fixed my issue same day.\n13. Why does the Team plan cost so much more than Pro? The page does not explain it.\n14. The app crashed on my phone again after the update.\n15. Onboarding was easy, I was running in 10 minutes.\n16. Could not find where to download invoices. Had to ask support.\n17. Import from Excel silently drops rows with dates.\n18. Dark mode please! The white background is too bright.\n19. Reports are much faster, thank you.\n20. Pricing page does not list the API limits for each plan.\n"
    }
  ],
  "shell": false,
  "timeout_seconds": 60,
  "max_cost_micros": 30000
}

Read more

Related samples

esc

Nothing matches “”.