Chat with LangChain LLM models, with tool calling and multimodal support
Project description
ChainChat - Chat with LangChain
CLI to chat with any LangChain model, also supports tool calling and multimodality.
Chat Models
ChainChat will introspect any installed langchain_* packages and make any BaseChatModel subclasses
available as commands with the models attributes as options - chainchat <model-command> --<option> <value>.
Just pip install any model packages you want to use, and they will be available as model commands to chat with:
$ chainchat chat
...
Commands:
preset Load a preset model from YAML.
$ pip install langchain_openai langchain_anthropic
$ chainchat chat
...
Commands:
preset Load a preset model from YAML.
anthropic See...
anthropic-messages See...
azure-open-ai See...
...
API Keys
API keys are accessed via environment variables.
By default they are loaded from a .env file located in the current directory.
You can specify a different file using the chainchat --dotenv option.
OpenAI Compatible Models
You can use any OpenAI compatible model with ChainChat.
For example to use xAI Grok put your XAI_API_KEY in your .env file
and alias it to OPENAI_API_KEY:
$ chainchat --alias-env OPENAI_API_KEY XAI_API_KEY chat --tool read_file --prompt "Read and summarize the file ./LICENSE.txt" open-ai --model-name grok-beta --openai-api-base https://api.x.ai/v1
I am reading the file ./LICENSE.txt to summarize its contents.
...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chainchat-0.1a2.tar.gz.
File metadata
- Download URL: chainchat-0.1a2.tar.gz
- Upload date:
- Size: 109.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
636150ba738720d46218813059a734d3ecb758c372a005f9c3f2112f73847847
|
|
| MD5 |
4b9ce37f1bab0f7ddf128e5c0a62a0f1
|
|
| BLAKE2b-256 |
7fda003b8a56c9343d91588ead2aa89a8e60495a26ed4aa9f535b02392d0cd5f
|
Provenance
The following attestation bundles were made for chainchat-0.1a2.tar.gz:
Publisher:
publish.yml on rectalogic/chainchat
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
chainchat-0.1a2.tar.gz -
Subject digest:
636150ba738720d46218813059a734d3ecb758c372a005f9c3f2112f73847847 - Sigstore transparency entry: 151459768
- Sigstore integration time:
-
Permalink:
rectalogic/chainchat@07a2e8e0eb3f48313d8a489bf69b8558f0445662 -
Branch / Tag:
refs/tags/0.1.a2 - Owner: https://github.com/rectalogic
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@07a2e8e0eb3f48313d8a489bf69b8558f0445662 -
Trigger Event:
release
-
Statement type:
File details
Details for the file chainchat-0.1a2-py3-none-any.whl.
File metadata
- Download URL: chainchat-0.1a2-py3-none-any.whl
- Upload date:
- Size: 29.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
63830b2e2c22eb1aac69aff83cebaca2c5033685c3043271161e730c62a8b4f8
|
|
| MD5 |
ca999c2d49050bdf2577351f5afb78b9
|
|
| BLAKE2b-256 |
1009316d6d9355b41edf6b1e48bd6321bad589ccd0228ba0a4d7e414b755f854
|
Provenance
The following attestation bundles were made for chainchat-0.1a2-py3-none-any.whl:
Publisher:
publish.yml on rectalogic/chainchat
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
chainchat-0.1a2-py3-none-any.whl -
Subject digest:
63830b2e2c22eb1aac69aff83cebaca2c5033685c3043271161e730c62a8b4f8 - Sigstore transparency entry: 151459769
- Sigstore integration time:
-
Permalink:
rectalogic/chainchat@07a2e8e0eb3f48313d8a489bf69b8558f0445662 -
Branch / Tag:
refs/tags/0.1.a2 - Owner: https://github.com/rectalogic
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@07a2e8e0eb3f48313d8a489bf69b8558f0445662 -
Trigger Event:
release
-
Statement type: