Skip to main content

A Python package to list and monitor available LLM models from various providers

Project description

LLM List

PyPI Python Version License: MIT Code style: black

A Python package to list and monitor available LLM models from various providers including Ollama and Hugging Face.

Features

  • List available LLM models from multiple providers
  • Monitor model updates and changes
  • Simple and intuitive API
  • Caching support for offline usage
  • Command-line interface
  • Docker support

Installation

Using pip

pip install llm-list

From source

git clone https://github.com/softreck/llm-list.git
cd llm-list
pip install -e .

Using Docker

docker build -t llm-list .
docker run --rm -it llm-list --help

Usage

Command Line Interface

# List all available models
llm-list list

# List models from a specific provider
llm-list list --provider ollama
llm-list list --provider huggingface

# Save output to a file
llm-list list --output models.json

#### Get help
```bash
llm-list --help

Python API

Get Ollama models

from llm_list.scrapers import OllamaScraper

# Create a scraper instance
scraper = OllamaScraper(output_dir="./data")

# Scrape models
models = scraper.scrape_models()
print(f"Found {len(models)} models")

# Monitor for changes
scraper.monitor(interval=3600)  # Check every hour

Get Hugging Face models

from llm_list.scrapers import HuggingFaceScraper

# Create a scraper instance
scraper = HuggingFaceScraper(output_dir="./data")

# Scrape models with search filter
models = scraper.scrape_models(search_term="code")
print(f"Found {len(models)} models")

# Get default models (works offline)
default_models = scraper._load_cached_models()

Development

  1. Clone the repository:

    git clone https://github.com/yourusername/llm-list.git
    cd llm-list
    
  2. Install the package in development mode with all dependencies:

    pip install -e ".[dev]"
    
  3. Run tests:

    make test
    
  4. Run linters and type checking:

    make lint
    
  5. Format code:

    make format
    

Available Make Commands

  • make install - Install the package in development mode
  • make dev - Install development dependencies
  • make test - Run tests
  • make coverage - Generate and view test coverage report
  • make lint - Check code style with black, isort, and mypy
  • make format - Format code with black and isort
  • make typecheck - Run type checking with mypy
  • make clean - Remove build artifacts
  • make build - Build the package
  • make check - Check the package
  • make publish-test - Upload to TestPyPI
  • make publish - Upload to PyPI
  • make pre-commit - Run all checks before committing
  • make help - Show available commands

Publishing to PyPI

  1. Update the version number in setup.py
  2. Update the changelog in CHANGELOG.md
  3. Build the package:
    make build
    
  4. Test the package:
    make check
    
  5. Publish to TestPyPI (optional):
    make publish-test
    
  6. Publish to PyPI:
    make publish
    

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llm_list-0.1.0.tar.gz (24.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llm_list-0.1.0-py2.py3-none-any.whl (23.2 kB view details)

Uploaded Python 2Python 3

File details

Details for the file llm_list-0.1.0.tar.gz.

File metadata

  • Download URL: llm_list-0.1.0.tar.gz
  • Upload date:
  • Size: 24.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.4

File hashes

Hashes for llm_list-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ab5b1d2fdfbac1b5430bf017c2c4057fb627ab58c6224d15c2fae3bb7402b8a3
MD5 a49045380952945c63e5302e3fb624c4
BLAKE2b-256 c754e67f85d74c8a6aef4574910f23eda2675526e5e78e3f89f0c02f2a470a3e

See more details on using hashes here.

File details

Details for the file llm_list-0.1.0-py2.py3-none-any.whl.

File metadata

  • Download URL: llm_list-0.1.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 23.2 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.4

File hashes

Hashes for llm_list-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 679ab93a4ebe2d8c8ade33a5fffda61b7696a6fb8a76c21a72cc11e19ebcb08e
MD5 70178d3a67394087b132d0701d28c01e
BLAKE2b-256 1a44e60c94f2c83d23bfd59607ca3e740d7819085d758b2d2128ba455d221006

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page