# Main agent

MAIA's main agent takes a research objective and returns layers on the map and in the table, with a written answer. It answers from the data first, researches only what the data cannot answer, and checks the result before it reports.

Updated: 2026-09-30. Source: https://maia-analytics.com/docs/capabilities/main-agent

## What it is for

The main agent answers your question from the project's data first, and researches only what the data cannot answer. When the answer is a set of places, they land on the map and in the table. The chat holds the summary, not the rows.

![The chat after a run. MAIA's answer reads: Created Top 10 Owner-User ESG Solar Sites. Validation confirms: 10 owner-occupied sites, 10 verified single-tenant buildings, 10 operators with documented public ESG obligations, 10 satellite-inspected roofs rated Good or Excellent, combined estimated capacity 5,591 kW, and 8 of 10 within designated incentive areas. Below it, the skill's plan and View activity.](https://maia-analytics.com/product-shots/docs/chat-answer@2x.png)

The main agent's answer at the end of a run: what it built, what it checked, and what it found.

## One run, step by step

1. **Read.** It reads the project's state: the layers, their columns, the current view, and your selection.
2. **Explore.** It checks what the data holds before it commits to a route.
3. **Act.** It queries, builds layers, and defines columns. Actions that do not depend on each other run in parallel.
4. **Verify.** It checks its own result against the data. See [How it verifies](https://maia-analytics.com/docs/capabilities/main-agent#verify).
5. **Answer.** It reports what it built, what it assumed, and what it could not confirm.

## Records first, research last

The main agent reads what the project holds and MAIA's own data before it researches anything, and it never searches the web for a fact the data holds. Research, through [sub-agents](https://maia-analytics.com/docs/capabilities/sub-agents), is the slowest route and the one that spends the most credits.

When the data holds no answer, it defines a column that asks for one, tests it on a few rows, and runs the rest. That column is an [enrichment](https://maia-analytics.com/docs/enrichments/overview). Every row spends credits, and a run above your row limit stops on an approval card first. You can run the same enrichment yourself, on the rows you pick. See [Run an enrichment](https://maia-analytics.com/docs/enrichments/run-an-enrichment).

## The rules it keeps

These hold however a request is phrased.

| Rule | What it means |
| --- | --- |
| Null means unknown | A missing value is not zero, not false, and not vacant |
| Requirements filter, preferences rank | A preference orders the list. It never removes a place |
| Check the records before filtering on them | It reads what a county's records contain before it uses a field as a test |
| Zoning is a district name, not an entitlement | What a code permits comes from the ordinance, not the data |
| Done means stop | Once the objective is met, it adds no extra layers or columns |
| Source data is read-only | It writes to the project's own layers, never to the data beneath them |
| Rows are set aside, not deleted | A removal is an exclusion you can reverse |
| Some uses are declined | See [Restricted uses](https://maia-analytics.com/docs/reference/restricted-uses) |

## How it verifies

After it changes the data, the main agent checks its result against the data before it answers, and it reports what it could not confirm. When a check fails for a reason it can fix, it corrects the work and tries again. It does not quote a value from a run still in progress.

## Questions and approvals

It asks only when a choice would change the result, spend credits you have not agreed to, or set rows aside on a judgment call. Some actions always wait for your approval. Both are covered on [Dispatch](https://maia-analytics.com/docs/using-maia/dispatch).

## Long conversations

In a long conversation, MAIA keeps what matters: what you asked for, the decisions made, and the state of the data. Details from early in the chat can fade, so restate the objective if the run has drifted, or save the method as a [skill](https://maia-analytics.com/docs/capabilities/skills) first. Now and then MAIA asks you to start a new chat. The project's data is untouched either way.

## Limits

- **A run keeps going when you leave.** It runs on MAIA's servers. Closing the project or the browser does not stop it.
- **One run per project at a time.** Several projects can run at once.
- **A run has a time limit.** Send a long job as several short requests.
- **A stop keeps what MAIA finished.**
- **A large result goes to a layer**, where you see all of it. The chat holds the summary.

Every limit is on [Limits](https://maia-analytics.com/docs/reference/limits).
