Skip to main content

Centralized reference of LLM capabilities.

Project description

🦜🪪 langchain-model-profiles

PyPI - Version PyPI - License PyPI - Downloads Twitter

[!WARNING] This package is currently in development and the API is subject to change.

Centralized reference of LLM capabilities for LangChain chat models.

Overview

langchain-model-profiles enables programmatic access to model capabilities through a .profile property on LangChain chat models.

This allows you to query model-specific features such as context window sizes, supported input/output modalities, structured output support, tool calling capabilities, and more.

Data sources

This package is built on top of the excellent work by the models.dev project, an open source initiative that provides model capability data.

This package augments the data from models.dev with some additional fields. We intend to keep this aligned with the upstream project as it evolves.

Installation

pip install "langchain[model-profiles]"

Or with uv:

uv add "langchain[model-profiles]"

Usage

Access model capabilities through the .profile property on any LangChain chat model:

# pip install "langchain[openai]"

from langchain.chat_models import init_chat_model

model = init_chat_model("openai:gpt-5")
profile = model.profile

# Check specific capabilities
if profile.get("structured_output"):
    print(f"This model supports a dedicated structured output feature.")

if profile.get("max_input_tokens"):
    print(f"Max input tokens: {profile.get('max_input_tokens')}")

if profile.get("..."):
    ...

Available fields

See ModelProfile in model_profile.py for the full list of available fields and their descriptions.

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

langchain_model_profiles-0.0.3.tar.gz (145.5 kB view details)

Uploaded Source

Built Distribution

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

langchain_model_profiles-0.0.3-py3-none-any.whl (30.0 kB view details)

Uploaded Python 3

File details

Details for the file langchain_model_profiles-0.0.3.tar.gz.

File metadata

  • Download URL: langchain_model_profiles-0.0.3.tar.gz
  • Upload date:
  • Size: 145.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for langchain_model_profiles-0.0.3.tar.gz
Algorithm Hash digest
SHA256 36d2363953fa13a6f217096ef413f1ebe287161ad5c6d2f728911bc9cd7724c9
MD5 08f897847fce169fff2cc270f4c3b297
BLAKE2b-256 e8be2567ef4954fdfd2c14793cc4b59b008ee558eeba7d0dea9faadbaeca7a6b

See more details on using hashes here.

File details

Details for the file langchain_model_profiles-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for langchain_model_profiles-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 76f588327c917df425b004d19d81db634c4b0008ed6497aa3f81b788950d9fc2
MD5 e60bc48fdfe8cba3121f12b63d3284c4
BLAKE2b-256 c1a1cf7b1c5a4294e7a7b9f0b2e31ecbde3d9bbe672bab893a4e8b95fc8838bc

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