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

# AI Assistant Chat: Talk to Your Agents in Real Time

> Use the Layest AI Assistant to chat with your agents in real time. Ask questions, trigger workflows, and retrieve data without leaving the platform.

The AI Assistant chat is a conversational interface built directly into Layest, giving you a live channel to interact with any agent your workspace has configured. Whether you need a quick answer, want to kick off a multi-step workflow, or are iterating on a prompt in real time, the chat panel keeps everything in one place — no context switching required.

## Opening the Chat Panel

The chat panel is accessible from anywhere inside Layest. Click the **Assistant** icon in the left navigation bar, or press `Cmd+K` (Mac) / `Ctrl+K` (Windows/Linux) to open it as an overlay. The panel slides in from the right and stays docked until you close it, so you can chat while viewing dashboards, agent configs, or logs at the same time.

To expand the chat to full-screen mode, click the **Expand** icon in the top-right corner of the panel. Press `Esc` or click **Collapse** to return to the docked view.

## Starting a New Conversation

Each conversation is an independent session with a single agent. To begin:

<Steps>
  <Step title="Open the chat panel">
    Click the **Assistant** icon in the left nav or press `Cmd+K` / `Ctrl+K`.
  </Step>

  <Step title="Select an agent">
    Use the agent picker at the top of the panel to choose which agent you want to talk to. Your pinned agents appear first.
  </Step>

  <Step title="Type your first message">
    Click the input field at the bottom of the panel, type your message, and press `Enter` to send. Press `Shift+Enter` to add a line break without sending.
  </Step>
</Steps>

Each new session is saved automatically to your [conversation history](/ai-assistant/conversations) so you can revisit it later.

## Chat Features

The chat input supports rich formatting, attachments, and structured output — making it easy to work with complex information without leaving the conversation.

<CardGroup cols={2}>
  <Card title="Message Formatting" icon="text">
    Use Markdown in your messages: **bold**, *italic*, `inline code`, and bulleted lists are all rendered in the response pane. This is especially useful when asking the agent to produce structured output.
  </Card>

  <Card title="Code Blocks" icon="code">
    Wrap code in triple backticks (\`\`\`) with a language tag for syntax highlighting. Agents recognise fenced code and will respond with properly formatted code blocks of their own.
  </Card>

  <Card title="File Attachments" icon="paperclip">
    Click the **Attach** icon (paperclip) or drag and drop a file into the input area to upload documents, CSVs, or images. The agent uses the attached file as context for its response.
  </Card>

  <Card title="Citations" icon="quote-left">
    When an agent draws from a connected knowledge source, it appends inline citation markers to its response. Hover over a citation to preview the source, or click it to open the full document.
  </Card>
</CardGroup>

### Supported Attachment Types

| File type             | Max size | Notes                         |
| --------------------- | -------- | ----------------------------- |
| PDF                   | 50 MB    | Text extracted automatically  |
| CSV / XLSX            | 20 MB    | Parsed into tabular context   |
| PNG / JPG / WEBP      | 10 MB    | Sent to vision-capable agents |
| Plain text / Markdown | 10 MB    | Passed as-is                  |

## Switching Between Agents

You can change the active agent mid-session without losing your current conversation thread. Click the agent name in the header of the chat panel to open the agent picker, then select a different agent. Layest creates a new conversation branch with the selected agent while keeping the original session intact in your history.

<Info>
  Switching agents does not carry over the conversation context automatically. If you want the new agent to have context from your previous messages, copy and paste the relevant excerpts into your first message to the new agent.
</Info>

## @-Mentions and Slash Commands

You can invoke specific behaviours without navigating away from the chat using @-mentions and slash commands.

**@-mentions** reference a named agent, integration, or data source inline:

```text theme={null}
@SalesAgent what were last quarter's closed-won deals over $50k?
```

**Slash commands** trigger built-in actions in the current conversation:

| Command      | What it does                                                           |
| ------------ | ---------------------------------------------------------------------- |
| `/new`       | Starts a fresh conversation with the current agent                     |
| `/clear`     | Clears the visible message history (session is still saved)            |
| `/export`    | Downloads the current conversation as a Markdown file                  |
| `/prompt`    | Opens the [Prompt Library](/ai-assistant/prompt-library) picker inline |
| `/summarise` | Asks the agent to summarise the conversation so far                    |

Type `/` in the input field to see the full list of available commands for the active agent.

## Keyboard Shortcuts

Work faster without reaching for the mouse:

| Shortcut           | Action                               |
| ------------------ | ------------------------------------ |
| `Cmd+K` / `Ctrl+K` | Open or close the chat panel         |
| `Enter`            | Send message                         |
| `Shift+Enter`      | Insert line break                    |
| `↑`                | Edit last sent message               |
| `Cmd+/` / `Ctrl+/` | Open slash command palette           |
| `Cmd+E` / `Ctrl+E` | Toggle full-screen mode              |
| `Esc`              | Close full-screen or dismiss overlay |

<Tip>
  Pin your most-used agents for instant access. Open the agent picker, hover over any agent, and click the **Pin** icon (📌). Pinned agents appear at the top of the picker and in the quick-launch bar at the bottom of the chat panel — saving you several clicks every session.
</Tip>
