Metadata-Version: 2.4
Name: uv-add-complete
Version: 0.1.6
Summary: Fast dependency suggestions and shell completion for uv add
Project-URL: Homepage, https://github.com/kavangajera/uv-aide
Project-URL: Repository, https://github.com/kavangajera/uv-aide
Project-URL: Issues, https://github.com/kavangajera/uv-aide/issues
Keywords: cli,completion,dependencies,pypi,uv
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Software Development :: Build Tools
Classifier: Topic :: Utilities
Requires-Python: >=3.10
Description-Content-Type: text/markdown

# uv-add-complete

[![PyPI](https://img.shields.io/pypi/v/uv-add-complete.svg)](https://pypi.org/project/uv-add-complete/)
[![Python](https://img.shields.io/pypi/pyversions/uv-add-complete.svg)](https://pypi.org/project/uv-add-complete/)
[![Smoke](https://github.com/kavangajera/uv-aide/actions/workflows/smoke.yml/badge.svg)](https://github.com/kavangajera/uv-aide/actions/workflows/smoke.yml)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](#license)

Smart dependency completion for `uv add`.

`uv-add-complete` helps you discover and add Python packages while you type. It
adds shell completions for `uv add`, shows package suggestions from an offline
lookup catalog, and includes useful metadata such as category and description.

![uv-add-complete package completion UI](docs/assets/completion-ui.png)

## Why

`uv` is fast, but remembering exact package names is still friction:

```console
uv add fast<Tab> py<Tab>
```

`uv-add-complete` turns that moment into a guided package search. It is designed
for modern Python projects: web apps, CLIs, data tooling, AI agents, LangChain
integrations, ML libraries, vector databases, testing tools, and more.

## Features

- Completion support for `uv add` and `uvpy add`.
- Offline package lookup catalog bundled with the package.
- 1,500+ curated package records generated from PyPI metadata.
- Includes modern AI/ML packages such as `openai`, `anthropic`,
  `pydantic-ai`, `langchain`, `langgraph`, `langsmith`, `manim`, and many
  `langchain-*` integrations.
- Category and description metadata for richer terminal suggestions.
- Auto-detects PowerShell, Bash, Zsh, and Fish during setup.
- Optional PowerShell Tab UI with a table-style package picker.

## Install

### Global tool setup

Use this when you want completion available across projects:

```console
uv tool install "uv-add-complete>=0.1.6"
uvpy init --yes
```

Restart your shell, then try:

```console
uv add fast<Tab> py<Tab>
```

### Project-local setup

Use this when you only want it inside one project:

```console
uv add "uv-add-complete>=0.1.6"
uv run uvpy init --yes
```

When installed locally, run commands through `uv run`:

```console
uv run uvpy --version
uv run uvpy add py --list
```

## Shell setup

`uvpy init` auto-detects your shell:

```console
uvpy init --yes
```

If detection is wrong, pass the shell explicitly:

```console
uvpy init --shell powershell --yes
uvpy init --shell pwsh --yes
uvpy init --shell zsh --yes
uvpy init --shell bash --yes
uvpy init --shell fish --yes
```

PowerShell users can opt into the experimental table-style Tab picker:

```console
uvpy init --yes --tab-ui
```

## Usage

Show matching packages with metadata:

```console
uvpy add py --list
```

Return package names for shell integrations:

```console
uvpy _complete add fast --format names
```

Return structured JSON:

```console
uvpy _complete add fast --format json
```

List the bundled catalog:

```console
uv-aide packages
```

## Catalog

The bundled catalog is stored at:

```text
src/uv_aide/data/packages.json
```

Each record uses this schema:

```json
{
  "name": "fastapi",
  "summary": "FastAPI framework, high performance, easy to learn, fast to code, ready for production",
  "category": "web",
  "project_url": "https://pypi.org/project/fastapi/"
}
```

The catalog is built from PyPI project metadata and curated categories. It keeps
completion fast because shell completion can use local data instead of making a
network request on every Tab press.

## Development

```console
uv sync
uv run pytest
uv run ruff check .
```

Useful local smoke checks:

```console
uv run uvpy add lang --list
uv run uvpy init --shell powershell --dry-run
uv run uvpy init --shell zsh --dry-run
uv run uvpy _complete add langchain-open --format names
```

## Release

This project publishes to PyPI through GitHub Actions and PyPI Trusted
Publishing. PyPI versions are immutable, so every release must use a fresh
version number.

For `0.1.6`:

```console
uv version 0.1.6
git add .
git commit -m "feat(catalog): expand package lookup database"
git push
gh release create v0.1.6 --title "v0.1.6" --notes "Expand package lookup database"
```

## Links

- [PyPI package](https://pypi.org/project/uv-add-complete/)
- [GitHub repository](https://github.com/kavangajera/uv-aide)
- [Issues](https://github.com/kavangajera/uv-aide/issues)

## License

MIT
