Tool-Ahead-of-Time (TAoT): Because Why Wait? 🕒
Ever found yourself staring at a shiny new LLM through LangChain's window, but can't use tool calling because it's "not supported yet"?
Sad agent noises 😢
Well, hold my JSON parser, because this repo says "NOT TODAY!" 🦾
What is this sorcery? 🧙♂️
This is a Python package that enables tool calling for any model available through Langchain's ChatOpenAI library (and by extension, any model available through OpenAI's library) and Langchain's AzureAIChatCompletionsModel library, even before LangChain and LangGraph officially supports it!
Yes, you read that right. We're living in the age of AI and things move fast 🏎️💨
It essentially works by reformatting the output response of the model into a JSON parser and passing this on to the relevant tools.
This repo showcases an example with DeepSeek-R1 671B, which isn't currently supported with tool calling by LangChain and LangGraph (as of 16th Feb 2025).
Features 🌟
- Tool calling support for OpenAI and non-OpenAI models available on:
- Langchain's ChatOpenAI library (and by extension, OpenAI and non-OpenAI models available on the base OpenAI's library).
- Langchain's AzureAIChatCompletionsModel library.
- This package follows a similar method to LangChain's and LangGraph's
create_react_agentmethod for tool calling, so makes it easy for you to read the syntax. 😊 - Zero waiting for official support required.
- More robust than a caffeinated developer at 3 AM. ☕
Quick Start 🚀
Follow the notebook tutorials in the "tutorial" folder in this repo for a fast and practical guide:
- "taot_tutorial_ChatOpenAI.ipynb" file for Langchain's ChatOpenAI library.
- "taot_tutorial_AzureAIChatCompletionsModel.ipynb" file for Langchain's AzureAIChatCompletionsModel library.
Change Log 📖
20th Feb 2025:
- Package now available on PyPI! Just "pip install taot" and you're ready to go.
- Completely redesigned to follow LangChain's and LangGraph's intuitive
create_react_agenttool calling methods. - Produces natural language responses when tool calling is performed.
1st Mar 2025:
- Package now available in TypeScript on npm! Just "npm install taot-ts" and you're ready to go. (https://github.com/leockl/tool-ahead-of-time-ts)
8th Mar 2025:
- Updated package to include implementation support for Microsoft Azure via Langchain's AzureAIChatCompletionsModel library.
Contributions 🤝
Feel free to contribute! Whether it's adding features, fixing bugs, adding comments in the code or any suggestions to improve this repo, all are welcomed 😄
Disclaimer ⚠️
This package is like that friend who shows up to the party early - technically not invited yet, but hopes to bring such good vibes that everyone's glad they came.
License 📜
MIT License - Because sharing is caring, and we care about you having tool calling RIGHT NOW.
Made with ❤️ and a healthy dose of impatience.
Metadata
Release files for taot 0.2.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| taot-0.2.4.tar.gz | 7.9 kB | Without provenance | Details for taot-0.2.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| taot-0.2.4-py3-none-any.whl | Python 3 | none | any | Details for taot-0.2.4-py3-none-any.whl |
Total release size: 14.8 kB
Release files / taot-0.2.4.tar.gz
| Download URL | taot-0.2.4.tar.gz |
|---|---|
| Size | 7.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2afce922e0697961b083797d805b9d18a90786c8090198b9457edb83eea4aba0
|
|
BLAKE2b-256 checksum How to use checksums |
2876d6f526f8db9ea58b340ce49ef73948407ad4b43b06563e116ab7ccdc370e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|
Release files / taot-0.2.4-py3-none-any.whl
| Download URL | taot-0.2.4-py3-none-any.whl |
|---|---|
| Size | 6.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6a243021c80f69c793a040f25c6adbcd8200f79f4bf50770f22826e3254e01ee
|
|
BLAKE2b-256 checksum How to use checksums |
7bb05f2c991a3c057ced286806ff3ff65515d80f144f2013f6500b8c50bd0f5e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.11
|
Security for taot 0.2.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.