Skip to main content

Local preflight checks for LLM provider keys, endpoints, and model configuration

Project description

Terminal report screenshot

llm-preflight-check

llm-preflight-check is a local CLI for checking whether your LLM provider configuration is ready before a demo, batch job, support workflow, or agent run.

It checks:

  • required environment variables for OpenAI, Anthropic, DeepSeek, and Ollama
  • default or configured provider endpoints
  • optional live model-list requests
  • required model names such as openai:gpt-4.1 or ollama:qwen2.5-coder
  • table, JSON, Markdown, and HTML reports for local use or CI artifacts

No runtime dependencies are required.

Install

pip install llm-preflight-check

For local development:

python3 -m pip install -e .

Quick Start

Check local configuration without making network calls:

llm-preflight-check

Check only OpenAI and Ollama:

llm-preflight-check --provider openai --provider ollama

Run live endpoint checks and require specific models:

llm-preflight-check --live \
  --require-model openai:gpt-4.1 \
  --require-model ollama:qwen2.5-coder

Write a Markdown handoff report:

llm-preflight-check --format markdown --output llm-preflight.md

Use strict warnings in CI:

llm-preflight-check --require-model openai:gpt-4.1 --strict-warnings

Exit codes:

  • 0: all selected checks passed
  • 1: a required cloud provider key is missing, or warnings are strict
  • 2: a live check failed or a required live model is missing

Providers

Provider Env var Default endpoint
OpenAI OPENAI_API_KEY https://api.openai.com/v1/models
Anthropic ANTHROPIC_API_KEY https://api.anthropic.com/v1/models
DeepSeek DEEPSEEK_API_KEY https://api.deepseek.com/models
Ollama OLLAMA_HOST http://localhost:11434/api/tags

Ollama does not require an API key. If OLLAMA_HOST is not set, the CLI assumes http://localhost:11434.

Report Formats

llm-preflight-check --format table
llm-preflight-check --format json
llm-preflight-check --format markdown
llm-preflight-check --format html --output report.html

Development

python3 -m pytest
PYTHONPATH=src python3 -m llm_preflight_check.cli --provider ollama
python3 -m build --no-isolation
python3 -m twine check dist/*

License

MIT

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_preflight_check-0.1.0.tar.gz (10.5 kB view details)

Uploaded Source

Built Distribution

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

llm_preflight_check-0.1.0-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: llm_preflight_check-0.1.0.tar.gz
  • Upload date:
  • Size: 10.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for llm_preflight_check-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ab00cd009f076f2ec80106c98587c43dd9f739f79cd9c9a5df5b4c13e1edc623
MD5 7fe81fae1cd1e70ba36dd360dbf117a3
BLAKE2b-256 634fe9821cc1338b6d73b9c85f5cb446a65eb204c72c4f1dc92780d951987cac

See more details on using hashes here.

File details

Details for the file llm_preflight_check-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for llm_preflight_check-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b5b86ac045dbfc3b4ce87c1cccec917dc6c7698f110a43cf6efead999abf352c
MD5 9df8946ac2a664c72f2c749409c735db
BLAKE2b-256 e020abe3632e199b19a0794361c7017a8a2372e898643c78feb7af5d778c9ddf

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