amdb 0.3.1

Turn your codebase into AI context. A high-performance context generator for LLMs (Cursor, Claude) using Tree-sitter and Vector Search.
# amdb: AI Context Generator

![Rust](https://img.shields.io/badge/built_with-Rust-dca282.svg)
![Version](https://img.shields.io/badge/version-0.3.1-blue.svg)

## [korean]readmekr.md
---
## [benchmark]benchmark/benchmark.md

## ⚡ The Context Problem
AI coding assistants (Cursor, Windsurf, Claude) are powerful, **but they are blind**. They only see the files you open. They lack the deep, structural understanding of your entire codebase that you have.

**`amdb` (Agent Memory Database) solves this.** It scans your local project, builds a vector index of your code, and generates a **single, highly-optimized Markdown context file**. Feed this file to your AI, and watch it understand your project like never before.

---

## 📦 Installation

### Option 1: One-line Installer (Recommended)
You don't need Rust installed. Just run this script to install the latest binary automatically.
Works on **macOS** (Intel/Apple Silicon) and **Linux** (including WSL).

```bash
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/BETAER-08/amdb/releases/latest/download/amdb-installer.sh | sh
```

### Option 2: Manual Download
Prefer to download the file yourself? Go to the Releases Page and download the version for your OS.

### Option 3: Install via Cargo
If you have the Rust toolchain installed:

```bash
cargo install amdb
```

## 🚀 Quick Start

### 1. Initialize Project
Run this in your project root. `amdb` will scan your code (Rust, Python, JS/TS), extract symbols, and build a vector database in a hidden `.database/` folder.

```bash
amdb init
```

You can also specify a target directory:

```bash
amdb init ./my-project
```

### 2. Generate Context
Create a full project summary. This generates `.amdb/context.md`, which contains a compressed map of your entire codebase.

```bash
amdb generate
```

**🔥 Pro Tip:** Drag and drop `.amdb/context.md` into your AI chat (Cursor/Claude) to give it "God Mode" understanding of your project.

---

## 🧠 Advanced Usage: Focus Mode

For large projects, a full context might be too big. Use **Focus Mode** to generate a summary relevant to a specific feature or bug. `amdb` uses vector search to find the most relevant files.

```bash
# Example: generating context for authentication logic
amdb generate --focus "login authentication jwt"
```

This creates a targeted summary (e.g., in `.amdb/`) containing only the symbols and files relevant to "login authentication jwt".

---

## 🛠 Supported Languages

`amdb` uses robust Tree-sitter parsers to fully understand the syntax and structure of:

- **Rust** (`.rs`)
- **Python** (`.py`)
- **JavaScript** (`.js`, `.jsx`, `.mjs`)
- **TypeScript** (`.ts`, `.tsx`)
- **C** (`.c`, `.h`)
- **C++** (`.cpp`, `.hpp`, `.cc`, `.cxx`)
- **C#**(`.cs`)
- **Go** (`.go`)
- **Java** (`.java`)
- **Ruby** (`.rb`)
- **PHP** (.`php`)
- **HTML** (`.html`, `.htm`)
- **CSS** (`.css`)
- **JSON** (`.json`)
- **Bash** (`.sh`, `.bash`)

---

## 📝 Git Configuration
`amdb` generates local files that should usually be ignored by Git.
Add this to your `.gitignore`:

```text
.database/
.amdb/
```

<p align="center">
  Generated by amdb • The Missing Memory for AI Agents
</p>

Please email us for bug reports or inquiries.
email:try.betaer@gmail.com