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

# ai:chat:create

> Generate a new AI chat class.

Scaffold a new AI chat class and its matching test file under a module's `ai/chats` directory. The `@ooneex/ai` dependency is installed if it is not already present.

## Usage

```bash theme={null}
ooneex ai:chat:create [options]
```

## Examples

```bash theme={null}
# Interactive: prompts for the chat name
ooneex ai:chat:create

# Provide the name as a flag
ooneex ai:chat:create --name=Support

# Target a specific module
ooneex ai:chat:create --name=Support --module=help
```

## Options

| Option       | Description                                               | Default             |
| ------------ | --------------------------------------------------------- | ------------------- |
| `--name`     | Chat name. Normalized to PascalCase with a `Chat` suffix. | Prompted if omitted |
| `--module`   | Target module the chat is created in.                     | `shared`            |
| `--override` | Overwrite the files if they already exist.                | `false`             |

## AI Skill

This command ships a matching `ai:chat:create` skill. It generates the chat class and test file, then guides your AI agent through completing a chat that extends the `Chat` base class from `@ooneex/ai`, including its model, system prompts, tools, and middlewares.

<Tabs>
  <Tab title="Claude">
    ```bash theme={null}
    ooneex claude:init
    ```
  </Tab>

  <Tab title="Codex">
    ```bash theme={null}
    ooneex codex:init
    ```
  </Tab>
</Tabs>
