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

# Session search

> Full-text search over every conversation you've ever had — find past discussions, decisions, and solutions in seconds.

# Session search

Session search lets you search across all past conversations — all profiles, all time. It's a full-text search engine over every conversation you've ever had with the agent.

***

## Session search vs. memory

These two features complement each other:

| Feature          | Session search                                | Memory                                                            |
| ---------------- | --------------------------------------------- | ----------------------------------------------------------------- |
| What it stores   | Full conversation transcripts                 | Distilled facts                                                   |
| How it's created | Automatically — every conversation is indexed | Agent-curated — the agent decides what to remember                |
| How to search    | FTS5 full-text query                          | Browse the memory page or ask the agent                           |
| Size             | Grows with every conversation                 | Bounded (\~2,200 chars for agent notes, \~1,375 for user profile) |
| In system prompt | No — searched on demand                       | Yes — injected into every turn                                    |
| Best for         | "What did we say about X?"                    | "What do you know about me?"                                      |

Memory gives the agent quick context in every conversation. Session search lets the agent dig into the full history when memory isn't enough.

***

## When to use it

* "What did we discuss about the database migration three weeks ago?"
* "Find the conversation where we debugged the WebSocket reconnect issue."
* "Show me every time I mentioned the staging server."
* "What was the solution to the white screen bug?"

Memory might have a fact like "Migrated DB from MySQL to PostgreSQL on 2026-01-15." Session search finds the full 40-message conversation where you discussed the migration, planned the approach, hit errors, and fixed them.

***

## How to search

<Tabs>
  <Tab title="From the sidebar">
    Type in the **search bar** at the top of the sidebar.

    The search:

    1. First matches conversation titles — if any title contains your query, it shows at the top.
    2. Then searches conversation contents — full-text search across all messages in all sessions.
    3. Results are ranked by relevance.

    Click any result to open that conversation. The matching text is highlighted.
  </Tab>

  <Tab title="From chat">
    Ask the agent directly:

    ```
    What did we discuss about the database migration?
    ```

    The agent uses the `session_search` tool to find matching conversations and incorporates the findings into its response.
  </Tab>

  <Tab title="Advanced (FTS5 syntax)">
    Session search supports FTS5 query syntax:

    | Operator         | Example                | Effect                                      |
    | ---------------- | ---------------------- | ------------------------------------------- |
    | `AND` (default)  | `python error`         | Both terms must appear                      |
    | `OR`             | `alpha OR beta`        | Either term matches                         |
    | `"..."` (phrase) | `"database migration"` | Exact phrase match                          |
    | `NOT`            | `python NOT java`      | Exclude a term                              |
    | `*` (prefix)     | `deploy*`              | Matches "deploy", "deployment", "deploying" |
  </Tab>
</Tabs>

***

## Search result fields

Each result shows:

| Field              | What it is                                  |
| ------------------ | ------------------------------------------- |
| **Session title**  | The conversation title                      |
| **Date**           | When the conversation happened              |
| **Snippet**        | The matching text, highlighted              |
| **Profile**        | Which profile the conversation belongs to   |
| **Match position** | Where in the conversation the match appears |

Click a result to open the full conversation — the matching text is scrolled into view and highlighted.

***

## Browsing without searching

If you don't have a specific query, you can browse:

* **Recent sessions** — the sidebar shows recent conversations chronologically.
* **By profile** — switch profiles to see that profile's conversations.
* **By date** — conversations are grouped by Today, Yesterday, This Week, Earlier.

***

<CardGroup cols={2}>
  <Card title="Memory" icon="brain" href="/memory">
    Curated facts the agent keeps across all conversations.
  </Card>

  <Card title="Conversations" icon="message" href="/conversations">
    How conversations are stored and organized.
  </Card>
</CardGroup>
