quiet robot

Agent Playground

Recipe: Analyze my spreadsheet

Reads a messy sales sheet, writes an analysis, and when it crashes reads the error and fixes itself until the numbers come out. What it does, when to use it, how to make it yours, and what a run costs.

View as Markdown

Reads a messy sales spreadsheet, writes an analysis, and when the analysis crashes on a messy cell, reads the error and fixes itself, until the totals come out. It ends with sales by region and a bar chart.

At a glanceNotes
CategoryData
ShapeA loop that reads its own errors
PlanFree and up
Needs a Claude keyNo
Limits it comes with4 loops, 180 seconds, $0.05
Analyze my spreadsheet, as it is on the canvas.Load the spreadsheet (Run command), Look at the data (Run code), Write the analysis (Run command), Run the analysis (Run command), Read the error, fix it (Run code), Show the summary (Run command). Arrows: Load the spreadsheet to Look at the data; Look at the data to Write the analysis; Write the analysis to Run the analysis; Run the analysis to Read the error, fix it on Failed; Read the error, fix it to Run the analysis; Run the analysis to Show the summary on Passed.FailedPassed>_ RUN COMMANDLoad the spreadsheet{ } RUN CODELook at the data>_ RUN COMMANDWrite the analysisgo back here>_ RUN COMMANDRun the analysisno internet{ } RUN CODERead the error, fix it>_ RUN COMMANDShow the summary
Analyze my spreadsheet, as it is on the canvas.
The Analyze my spreadsheet recipe in the builder after a run, with each step's result on the canvas and the run's steps listed on the right.
A real run of the recipe. The panel on the right lists every step with what it printed.

When to use it

  • You have a spreadsheet export with messy cells (commas in numbers, n/a, blanks) and want totals and a chart.
  • A weekly report from the same export, without fixing it by hand each time.
  • Any script that should learn from its own errors.

Run it

  1. Open Agent Playground in the dashboard and find Analyze my spreadsheet under Start from a recipe. In the builder, Recipes in the toolbar lists them too.
  2. Choose Use this recipe. It becomes a flow of your own, so changing it never changes the recipe.
  3. Choose Simulate to see the forecast, then Run.

What you'll see: The first try crashes on 1,200.50, the second on n/a, and the third skips what it can't read and finishes: sales by region, the top region, and how many rows were left out. The summary is in summary.md and the chart in chart.svg.

Make it yours

  1. Change Load the spreadsheet to load your own sheet: download it from a link, or start the flow from a webhook that sends it.
  2. Change Write the analysis to the totals you want: by month, by product, by customer.
  3. Replace Read the error, fix it with an Agent whose goal is The analysis crashed with this error. Fix analysis.py., with the output of Run the analysis added through Insert….
  4. Have the last step send the summary somewhere useful, after an approval if it goes outside your team.

What a run costs

These are the builder's own forecast for the recipe as it comes, with its limits, rounded. Simulate shows the same numbers for your version, and they change as you change the flow.

NotesTypical1 in 10 runsAt most
Sandbox time$0.0002$0.0003$0.0023
How long it takes17 seconds21 seconds180 seconds

A typical run uses $0.0002 of sandbox time, so about 4,700 runs cost $1, and every plan includes $5 of usage a month. At most is the most a run could cost with these limits: it stops at $0.05 or 180 seconds, whichever comes first.

  • Agent PlaygroundQuickstart: build and run your first flow
  • Agent PlaygroundBlocks
  • Agent PlaygroundRecipes
  • SandboxesQuickstart: your first sandbox
  • SandboxesMCP server
  • SandboxesAPI reference