# Leann Search

> Semantic search across codebase using LEANN vector index

- **Type:** Skill
- **Install:** `agentstack add skill-parcadei-continuous-claude-v3-leann-search`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [parcadei](https://agentstack.voostack.com/s/parcadei)
- **Installs:** 0
- **Category:** [Search](https://agentstack.voostack.com/c/search)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [parcadei](https://github.com/parcadei)
- **Source:** https://github.com/parcadei/Continuous-Claude-v3/tree/main/.claude/skills/archive/leann-search

## Install

```sh
agentstack add skill-parcadei-continuous-claude-v3-leann-search
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# LEANN Semantic Search

Use LEANN for meaning-based code search instead of grep.

## When to Use

- **Conceptual queries**: "how does authentication work", "where are errors handled"
- **Understanding patterns**: "streaming implementation", "provider architecture"
- **Finding related code**: code that's semantically similar but uses different terms

## When NOT to Use

- **Exact matches**: Use Grep for `class Foo`, `def bar`, specific identifiers
- **Regex patterns**: Use Grep for `error.*handling`, `import.*from`
- **File paths**: Use Glob for `*.test.ts`, `src/**/*.py`

## Commands

```bash
# Search the current project's index
leann search  "" --top-k 5

# List available indexes
leann list

# Example
leann search rigg "how do providers handle streaming" --top-k 5
```

## MCP Tool (in Claude Code)

```
leann_search(index_name="rigg", query="your semantic query", top_k=5)
```

## Rebuilding the Index

When codebase changes significantly:

```bash
cd /path/to/project
leann build  --docs src tests scripts \
  --file-types '.ts,.py,.md,.json' \
  --no-recompute --no-compact \
  --embedding-mode sentence-transformers \
  --embedding-model all-MiniLM-L6-v2
```

## How It Works

1. LEANN uses sentence embeddings to understand *meaning*
2. Searches find conceptually similar code, not just text matches
3. Results ranked by semantic similarity score (0-1)

## Grep vs LEANN Decision

| Query Type | Tool | Example |
|------------|------|---------|
| Natural language | LEANN | "how does caching work" |
| Class/function name | Grep | "class CacheManager" |
| Pattern matching | Grep | `error\|warning` |
| Find implementations | LEANN | "rate limiting logic" |

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [parcadei](https://github.com/parcadei)
- **Source:** [parcadei/Continuous-Claude-v3](https://github.com/parcadei/Continuous-Claude-v3)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-parcadei-continuous-claude-v3-leann-search
- Seller: https://agentstack.voostack.com/s/parcadei
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
