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

# Hermes Integration

> Configure ByteRover as long-term memory for Hermes agents

Give your [Hermes](https://hermes-agent.nousresearch.com/) agents persistent memory with ByteRover. The ByteRover memory provider automatically native retrieves relevant knowledge before each response, curates new insights after each turn, and preserves context before compression — so your agents remember decisions, patterns, and fixes across sessions.

## Prerequisites

Ensure the following are installed and available in your `PATH`:

| Requirement                 | How to install                                                           |
| --------------------------- | ------------------------------------------------------------------------ |
| **ByteRover CLI** (`brv`)   | [ByteRover installtion guide](/index)                                    |
| **Hermes Agent** (`hermes`) | [Hermes installtion guide](https://github.com/NousResearch/hermes-agent) |

## ByteRover CLI initialization

ByteRover CLI needs an LLM provider to power its curation and query features.

Supported list: ByteRover, OpenRouter, Anthropic, OpenAI, Google Gemini, xAI, Groq, Mistral, DeepInfra, Cohere, Together AI, Perplexity, Cerebras, Vercel, MiniMax, GLM, Moonshot AI, and OpenAI Compatible.

To see all available providers:

```bash theme={null}
brv providers list
```

Run one of the following to get started:

```bash theme={null}
brv providers connect byterover                                                          # Free, requires login with ByteRover account
brv providers connect anthropic --api-key sk-ant-... --model claude-sonnet-4-5-20250929  # Use your own API key: OpenAI, Anthropic, etc.
```

## Hermes integration guide

**Option 1 — Interactive setup (recommended):**

```bash theme={null}
hermes memory setup
```

When prompted, select `byterover` from the list of available memory providers.

**Option 2 — Manual configuration:**

```bash theme={null}
hermes config set memory.provider byterover
```

**After memory configuration, restart your Hermes gateway:**

```bash theme={null}
hermes gateway restart
```

If you get stuck on the gateway restart command, reinstall the gateway:

```bash theme={null}
hermes gateway install
```

Then start the Hermes gateway:

```bash theme={null}
hermes gateway start
```

Then restart the Hermes gateway:

```bash theme={null}
hermes gateway restart
```

## Features

### Context Retrieval

Before each LLM call, the provider runs `brv query` with the user's message and injects the results as additional context. Your agent automatically has relevant memories, past decisions, and patterns available without any manual prompting.

### Automatic Curation

After each conversation turn, the provider runs `brv curate` in the background to extract and store valuable knowledge — architectural decisions, bug fixes, recurring patterns, and more. This happens asynchronously and does not add latency to responses.

### Pre-Compression Flush

When the agent's context window approaches compression, the provider extracts and stores insights before the conversation history is summarized. Nothing valuable is lost when the context is compacted.

## Hermes Agent Tools

ByteRover integration exposes three tools that your agent can call directly:

| Tool         | Description                                                                                          |
| ------------ | ---------------------------------------------------------------------------------------------------- |
| `brv_query`  | Search the persistent knowledge tree for memories, decisions, and patterns from previous sessions    |
| `brv_curate` | Store a fact, decision, or pattern into the knowledge tree — automatically categorized and organized |
| `brv_status` | Check the ByteRover CLI version, tree stats, and cloud sync state                                    |

**Context-tree directory:** `$HERMES_HOME/byterover/.brv` (profile-scoped, created automatically on first use)

<CardGroup cols={2}>
  <Card title="LLM Providers" icon="cpu" href="/external-llm-providers/overview">
    Connect an external provider or use the built-in LLM
  </Card>

  <Card title="Onboard Context" icon="lightbulb" href="/common-workflows/onboard-context">
    Learn how to seed your context tree with existing knowledge
  </Card>
</CardGroup>

<CardGroup cols={2}>
  <Card title="Reference" icon="book" href="/autonomous-agents/hermes-reference">
    Troubleshooting, error
  </Card>

  <Card title="Local & Cloud" icon="book" href="/local-vs-cloud">
    Exploring local & cloud options
  </Card>
</CardGroup>
