Metadata-Version: 2.4
Name: openrouter-models-browser
Version: 0.1.0
Summary: CLI for browsing and comparing AI models from the OpenRouter API
Project-URL: Homepage, https://github.com/janwychowaniak/openrouter-models-browser
Project-URL: Issues, https://github.com/janwychowaniak/openrouter-models-browser/issues
Project-URL: Source, https://github.com/janwychowaniak/openrouter-models-browser
Author: Jan Wychowaniak
License-Expression: MIT
License-File: LICENSE
Keywords: ai,cli,llm,models,openrouter
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Console
Classifier: Intended Audience :: Developers
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Topic :: Utilities
Requires-Python: >=3.11
Requires-Dist: pyyaml>=6.0
Requires-Dist: requests>=2.31
Requires-Dist: tabulate>=0.9
Description-Content-Type: text/markdown

# ormodels

A CLI for browsing and comparing AI models from the [OpenRouter](https://openrouter.ai/) API.

## Installation

The command is `ormodels`; the PyPI distribution name is `openrouter-models-browser`.

```sh
# Recommended: isolated tool install
uv tool install openrouter-models-browser
# or
pipx install openrouter-models-browser

# Or as a regular dependency
pip install openrouter-models-browser
```

Requires Python 3.11+.

## Usage

```sh
# Show help
ormodels -h

# Search for models by name, ID, or modality
ormodels claude
ormodels gpt
ormodels "text->text"

# Combine multiple searches (results deduplicated)
ormodels claude gemini

# Get full details for an exact ID match
ormodels anthropic/claude-3.5-sonnet

# Equivalent module form
python -m ormodels claude
```

## Output

### Search results (table)

Comparison table with columns:
`ID`, `NAME`, `CREATED`, `CONTEXT_LENGTH`, `MODALITY`, `TOKENIZER`, `PROMPT`, `COMPLETION`, `MAX_COMPL_TOKENS`.

Pricing is shown in dollars per 1M tokens. Token counts use a dual format (e.g. `256000 | 256k`).

### Exact match (YAML)

When the query exactly matches a model ID, the full model entry is printed in YAML format with the description first, followed by prominent fields, then remaining details.

## Development

```sh
# Set up dev environment
uv sync --all-groups

# Run quality gates
uv run ruff format --check .
uv run ruff check .
uv run mypy
uv run pytest

# Run the CLI from source
uv run ormodels claude

# Build distribution artifacts
uv build
```

Publishing is automated via the `Publish` GitHub Actions workflow on a `v*` tag, using PyPI Trusted Publishing (no API token required).

## License

MIT
