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

# Storing

> Store, edit, and delete CLI chunks in vector databases.

CLI storage commands manage embedded chunks in Qdrant, Pinecone, or Weaviate.

## Store

`store` reads embedded chunk JSON from `--input-dir` and upserts it.

```bash theme={null}
ragrails store \
  --input-dir files/output/embedded/ \
  --vector-db qdrant \
  --collection support \
  --url http://localhost:6333 \
  --batch-size 64
```

Output:

```text theme={null}
Inputs     : 12
Stored     : 12
Failed     : 0
Provider   : qdrant
Collection : support
```

## Edit

`edit` re-embeds and replaces stored chunks by exact ID.

```bash theme={null}
ragrails edit \
  --input-dir files/updated-chunks/ \
  --vector-db qdrant \
  --collection support \
  --url http://localhost:6333 \
  --provider voyage \
  --model voyage-3
```

## Delete

`delete` removes chunks by exact ID.

```bash theme={null}
ragrails delete \
  --id refund-policy-0 \
  --id refund-policy-1 \
  --vector-db qdrant \
  --collection support \
  --url http://localhost:6333
```

## Options

### `store`

| Option         | Default        | Description                                          |
| -------------- | -------------- | ---------------------------------------------------- |
| `--input-dir`  | required       | Folder of embedded chunk JSON files.                 |
| `--vector-db`  | `qdrant`       | `qdrant`, `qdrant_cloud`, `pinecone`, or `weaviate`. |
| `--collection` | config or none | Collection, index, or class name.                    |
| `--url`        | config or none | Vector DB URL.                                       |
| `--batch-size` | `64`           | Chunks per upsert batch.                             |

### `edit`

| Option                   | Default               | Description                                |
| ------------------------ | --------------------- | ------------------------------------------ |
| `--input-dir`            | required              | Folder of edited chunk JSON files.         |
| `--provider` / `--model` | `voyage` / `voyage-3` | Embedding provider/model for re-embedding. |
| `--batch-size`           | `64`                  | Chunks per edit batch.                     |

### `delete`

| Option | Default  | Description                     |
| ------ | -------- | ------------------------------- |
| `--id` | required | Chunk ID to delete. Repeatable. |

<CardGroup cols={2}>
  <Card title="Embedding" icon="binary" href="/usage/cli/embedding">Create embedded JSON.</Card>
  <Card title="Maintenance" icon="refresh-cw" href="/usage/cli/knowledge-base-maintenance">Refresh stale chunks.</Card>
</CardGroup>
