All Guides
Project Guide

Spreadsheet Agent Use Cases

See where LLM agents fit well around wb and where a direct script is still the better choice.

LLM Use with AI

Spreadsheet Agent Use Cases

LLM agents work best when the job mixes workbook operations with interpretation, policy, or human-facing summaries. Let wb do the spreadsheet work. Let the model decide what to inspect, how to explain it, and which patch to propose.

Good Fits

Budget and Forecast Review

Read a summary range, trace a few key formulas, and explain why totals moved.

Typical command loop:

  • wb info
  • wb read --headers --range ...
  • wb dep --cell ...
  • wb calc --range ...

This works well when a finance user wants both a spreadsheet change and a written explanation of the change.

Workbook Cleanup and Normalization

Normalize sheet names, clear bad cells, set column widths, and fix obviously broken formulas.

Typical command loop:

  • wb info
  • wb read --headers
  • wb edit --validate-only --plan
  • wb edit

This is a good fit when the cleanup rules are partly mechanical and partly contextual.

Analyst Copilot for Existing Models

Answer questions like “where does this KPI come from?” or “what breaks if we change this assumption?”

Typical command loop:

  • wb read --range ...
  • wb dep --cell ... --direction both
  • wb calc --range ...

This is where an agent can add real value by turning dependency output into a human explanation with exact references.

Creating New Workbooks from Structured Inputs

Turn extracted facts, API payloads, or a planning brief into a workbook spec and then build the file.

Typical command loop:

  • wb create --spec ...
  • wb edit --patch ...
  • wb calc

This works best when the model is generating structure from semi-structured inputs and wb is responsible for the actual file.

Batch QA and Regression Triage

Open many generated workbooks, recalculate formulas, and surface the cells that need human review.

Typical command loop:

  • wb info
  • wb read --range ... --format json
  • wb calc --format json

This is useful in CI, fixture auditing, and migration work where the model is summarizing failures rather than inventing spreadsheet logic from scratch.

When Not to Use an Agent

Skip the agent layer when the task is fully deterministic:

  • fixed ETL pipelines that already know every target cell
  • large batch rewrites where a direct script is cheaper and easier to test
  • high-stakes financial closes where no human will review the patch

In those cases, use the Go library or a plain wb script directly.

Practical Guardrails

  • Read only the range the model needs.
  • Keep the workbook as the source of truth, not screenshots or copied tables.
  • Validate patches before saving.
  • Recalculate after edits that can affect formulas.
  • Return exact sheet and cell references in every summary.