---
url: https://docs.mochiexec.io/reference/cli/mochi_ai_config_set_usage.md
description: Set how long local AI usage is kept
---

# mochi ai config set usage

Set how long local AI usage is kept

## Synopsis

Sets how long, and how much, AI usage `mochi ai usage local` keeps before removing the oldest entries.

```shell
mochi ai config set usage [flags]
```

## Options

| Flag | Type | Description |
|------|------|-------------|
| `-h, --help` |  | help for usage |
| `--max-age` | `string` | Keep entries this long (e.g. 30d, 720h) |
| `--max-size` | `string` | Keep at most this much (e.g. 10MB, 500KB) |
| `-o, --output` | `string` | Output format: text or json (default "text") |

## Options inherited from parent commands

| Flag | Type | Description |
|------|------|-------------|
| `-L, --log-level` | `string` | Log verbosity level (debug, info, fatal) (default "info") |
| `--sync` |  | Sync flow cache and workspaces |

## See also

* [mochi ai config set](mochi_ai_config_set.md) — Change AI settings
