# AI use cases for Claude DB (Avijit07x/claude-db)

Repo: [Avijit07x/claude-db](https://github.com/Avijit07x/claude-db) | Use cases: 4 | Page: https://dedupedai.com/use-cases/avijit07x-claude-db/

claude-db is a free, open-source memory layer for Claude Code that stores decisions, dead ends, rules and a map of your code in your own database.

This file holds every use case of this repo. Each one starts with a "## " heading and ends with its URL.

- Pick up a Claude Code project where you stopped: https://dedupedai.com/use-cases/avijit07x-claude-db/resume-claude-code-project-after-break/
- Map a codebase so Claude finds callers in one call: https://dedupedai.com/use-cases/avijit07x-claude-db/map-codebase-for-symbol-lookup/
- Leave a short handoff note for the next chat: https://dedupedai.com/use-cases/avijit07x-claude-db/hand-off-work-to-next-chat/
- Share Claude Code memory across machines on Postgres: https://dedupedai.com/use-cases/avijit07x-claude-db/share-memory-across-machines-with-postgres/

## How to pick up a Claude Code project where you stopped with Claude DB

Repo: [Avijit07x/claude-db](https://github.com/Avijit07x/claude-db) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Get Claude to recap your last decisions and open threads when you return to a repo.

**Who it is for:** A developer who works on a repo in short sessions and loses the thread between chats.

**The problem:** Each new Claude Code chat starts from zero, so you re-explain past decisions, dead ends and rules before any work can start.

**The outcome:** At the start of a new chat, /catchup tells you where you stopped, using memory saved from earlier chats.

### Steps

1. `npm install -g claude-db`
2. `cd your-project`
3. `claude-db install --project`
4. Restart Claude Code, then run `claude-db flush` and `claude-db scan` to load existing material.
5. Start a new chat in the project and run `/catchup`.

### Prompt to paste into your agent

```text
In the repo <repo-path> with claude-db installed, run /catchup in Claude Code and report the decisions, dead ends and open items it lists. Verify that each item matches a real earlier discussion or commit in the project before you rely on it.
```

### Caveat

Memory only builds up from chats and scans after install, so the first chat in a new project will know little until you use it for a while.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/avijit07x-claude-db/resume-claude-code-project-after-break/

## How to map a codebase so Claude finds callers in one call with Claude DB

Repo: [Avijit07x/claude-db](https://github.com/Avijit07x/claude-db) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Index an existing project so Claude can see what defines, calls or imports a symbol.

**Who it is for:** A developer or reviewer who inherits a TypeScript, Python, Go, Rust, Java, Kotlin or JavaScript codebase and needs to trace where a function is used.

**The problem:** Without a map, Claude runs grep and reads many files to work out what calls what, which is slow and often incomplete.

**The outcome:** Claude answers who defines, calls or imports a symbol in a single lookup, with the map built from your existing code.

### Steps

1. `npm install -g claude-db`
2. `cd your-project`
3. `claude-db install --project`
4. Run `claude-db scan` to map the existing code into memory.
5. In Claude Code, run `/cdb-scan` if you want to map the codebase from inside a chat, then ask who calls a function you choose.

### Prompt to paste into your agent

```text
In the repo <repo-path>, after running claude-db scan, ask Claude Code who defines, calls and imports the symbol <symbol-name>. Expected output is a list of definition and call sites. Verify at least one listed site with grep before trusting the result.
```

### Caveat

The README notes that plain grep wins in some cases, so check Claude DB results against grep when precision matters.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/avijit07x-claude-db/map-codebase-for-symbol-lookup/

## How to leave a short handoff note for the next chat with Claude DB

Repo: [Avijit07x/claude-db](https://github.com/Avijit07x/claude-db) | Difficulty: Intermediate | Time: 15 minutes | Basis: From the README

Save a brief status note so the next Claude Code chat or a teammate can continue.

**Who it is for:** A developer who stops mid-task and wants a teammate or a fresh chat to pick up the work without a long recap.

**The problem:** Work in progress lives in one chat, so the next person or session has to rebuild the context by hand.

**The outcome:** A short note saved through /handoff that the next chat or teammate can read at the start of their session.

### Steps

1. `npm install -g claude-db`
2. `cd your-project`
3. `claude-db install --project`
4. Restart Claude Code.
5. At the end of your session, run `/handoff` and write a short note on what is done and what is next.

### Prompt to paste into your agent

```text
In the repo <repo-path>, run /handoff in Claude Code at the end of the session and then start a new chat in the same project. Expected output is a short summary of the open work in the new chat. Verify that it names the same open task you wrote in the handoff.
```

### Caveat

The note reaches a teammate only if they use the same Claude DB database, so a local SQLite store does not share it by default.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/avijit07x-claude-db/hand-off-work-to-next-chat/

## How to share Claude Code memory across machines on Postgres with Claude DB

Repo: [Avijit07x/claude-db](https://github.com/Avijit07x/claude-db) | Difficulty: Advanced | Time: 30 minutes | Basis: From the README

Move Claude DB from local SQLite to a shared Postgres or MongoDB database.

**Who it is for:** A developer or small team who uses Claude Code on more than one machine and wants one memory store.

**The problem:** The default SQLite store lives on one machine, so decisions and maps made on a laptop are missing on a desktop.

**The outcome:** Memory is kept in a Postgres or MongoDB database you run, so every machine using Claude DB reads the same store.

### Steps

1. `npm install -g claude-db`
2. `cd your-project`
3. `claude-db install --project`
4. Run `claude-db use pg` or `claude-db use mongodb` and follow the prompts to point Claude DB at your database. (inferred, check the README)
5. Run `claude-db doctor` to check the setup, then `claude-db status` to confirm what is recorded.

### Prompt to paste into your agent

```text
In the repo <repo-path>, switch claude-db to the database <pg-or-mongodb> and run claude-db doctor. Expected output is a passing setup check and a status line showing the chosen database. Verify that claude-db status reports the same memory count on a second machine after one chat is recorded.
```

### Caveat

The README gives the command only as a table entry, so the exact connection steps are in the documentation site and you should confirm them there.

Risk, credentials: A shared Postgres or MongoDB connection needs database credentials, so store them outside the repo and never commit them.

Disclaimer: Third-party repos we don't own or vouch for. AI-generated use cases can be wrong: review everything and run at your own risk. Full text: https://dedupedai.com/disclaimer/

URL: https://dedupedai.com/use-cases/avijit07x-claude-db/share-memory-across-machines-with-postgres/
