> ## Documentation Index
> Fetch the complete documentation index at: https://oculon.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Modeling with AI

> Use the AI assistant to build, extend, and explain models, with example prompts for common modeling tasks.

The AI assistant can set up model structure, write formulas, and explain how an existing model works. Use it to get to a first draft faster, then review the logic yourself. For the full list of what it can do, see [What the assistant can do](https://oculon.mintlify.site/concepts/ai-and-agents/ai-assistant/what-the-assistant-can-do.md).

<video autoPlay muted loop playsInline src="https://mintcdn.com/oculon/NI9gTKI_lkWb5XlY/videos/ai-and-agents/modeling-with-ai.mp4?fit=max&auto=format&n=NI9gTKI_lkWb5XlY&q=85&s=3f24b54c6e1ed930af33f244e5f34501" aria-label="A user asks the AI assistant, open beside the SaaS P&L model, to add Gross margin as Revenue minus COGS and Gross margin % as Gross margin divided by Revenue. The assistant reads the model, updates the gross margin variables, and shows a summary with a Changed 1 model card." />

## Before you start

Open the model you want to work on, or `@` mention it in the composer. Check which scenario is active, because the assistant works in the scenario you're viewing.

Use Agent mode to make changes, or Ask mode to explore without changes. For larger builds, start in [Plan mode](https://oculon.mintlify.site/concepts/ai-and-agents/ai-assistant/plan-mode.md) so you can review the approach first.

## Build a new model

Describe the business question, the time range, and the main drivers. For example, `Create a SaaS revenue model for FY27, monthly, driven by new customers, churn rate, and ARPA` gives the assistant all three. See [What is a model](https://oculon.mintlify.site/concepts/modeling/models/overview.md) for how models are structured.

## Add variables and formulas

Tell the assistant what the variable represents and how it should calculate, such as `Add Gross margin as Revenue minus COGS, and Gross margin % as Gross margin divided by Revenue`. You can also ask it to `Break down Bookings by the Region dimension`.

The assistant uses actual formula and planned formula logic relative to the model's [Last actual date](https://oculon.mintlify.site/concepts/data-and-structure/time/last-actual-date.md). A prompt like `Make Marketing spend 12% of Revenue in the planned formula, and keep actuals from the GL` changes only the planned side. Ask the assistant to explain which side of the cutoff it changed. For formula syntax, see [Formula basics](https://oculon.mintlify.site/concepts/modeling/formulas/overview.md).

## Understand an existing model

Ask the assistant to trace logic you didn't build. `Explain how Net revenue is calculated, step by step` walks through a calculation, and `Why did Opex jump in March?` investigates a change. You can also ask it to `List any variables with formula errors`.

## Explore scenarios

The assistant can create and compare scenarios. Try `Create a scenario called Downside with 15% fewer new customers from Q2`, then `Compare Base and Downside for EBITDA in FY27`.

## Review before you rely on it

After the assistant makes changes, open the changes card and review each new or edited variable. Check the first periods before and after the Last actual date, and confirm aggregation and formats for new variables.

If something is wrong, use **Undo** or **Restore Checkpoint**. See [Approvals and checkpoints](https://oculon.mintlify.site/concepts/ai-and-agents/ai-assistant/approvals-and-checkpoints.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.