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

# AI Assistant

> Contextually-aware AI that adapts to your current workflow and mode

## Overview

The AI Assistant is an intelligent helper that understands what you're working on and adapts its suggestions accordingly. Rather than offering generic help, it provides relevant guidance based on your current mode, the model you're viewing, and your recent actions.

## Context-Aware Behavior

The assistant automatically adjusts based on where you are in the platform:

| Mode             | Assistant Focus                                                                      |
| ---------------- | ------------------------------------------------------------------------------------ |
| **Design**       | Suggests structural improvements, equation syntax help, parameter naming conventions |
| **Experiment**   | Proposes scenarios to test, explains variable relationships, interprets results      |
| **Calibrate**    | Helps fit parameters to data, suggests calibration strategies                        |
| **Presentation** | Offers quick quizzes, summarizes model insights, explains concepts                   |
| **Decide**       | Compares scenario trade-offs, highlights key differences                             |
| **Activity**     | Provides hints about the objective, suggests strategies                              |

When you switch modes, the assistant uses the new mode on your very next message, even if you stay in the same chat session.

### Experiment Mode Context

In **Experiment** mode, the assistant receives a richer state snapshot so it can reason about the exact run you are looking at:

* Active parameter IDs and their current overridden values
* Number of modified parameters
* Compare mode status and visible chart context
* Latest run summary (for example baseline/scenario final values and series lengths)
* Current UI state metadata (mode + whether output is available)

This is why experiment responses can reference your current slider changes and chart comparison state more precisely.

### Fast Responses for Simple Prompts

For short, lightweight requests, the assistant uses a direct-response path instead of running the full orchestration flow.

* If your request is clear, it gives a concise answer immediately.
* If your request is ambiguous, it asks one focused clarifying question.

Examples:

* "Can you help?"
* "Thanks"
* "What can you do in this mode?"

## Quick Actions

Each mode surfaces relevant quick-action prompts:

<CardGroup cols={2}>
  <Card title="Presentation Mode" icon="play">
    * "Summarize this model"
    * "Take a quick quiz"
    * "Explain this concept"
  </Card>

  <Card title="Experiment Mode" icon="flask">
    * "What happens if I increase X?"
    * "Compare these scenarios"
    * "Why is this variable changing?"
  </Card>
</CardGroup>

## Using the Assistant

1. Click the **chat icon** in the bottom-right corner
2. Type a question or select a suggested prompt
3. The assistant responds with context-aware guidance

<Tip>
  The assistant knows which model you're viewing and can reference specific variables, parameters, and relationships in its responses.
</Tip>

## Capabilities

* **Model explanation** — Describe what the model does and how components interact
* **Equation help** — Debug syntax errors and suggest improvements
* **Scenario analysis** — Interpret results and suggest next experiments
* **Learning support** — Answer questions about system dynamics concepts

## Transparency

Below the input field, a small status bar shows the current **mode**, **AI model**, and a **Context** link.

* **Mode** — Click to see all available modes and switch between them.
* **AI Model** — Click to choose which LLM powers the assistant (e.g. Gemini Flash Latest, Gemini 2.5 Flash, Gemini 3 Flash Preview).
* **Context** — Click to inspect exactly what is sent to the AI: the system prompt, files, chat history, selected elements, and parameter state.

In Experiment mode, the Context view also shows the active parameter overrides and UI snapshot used for that message.
