SDK Installation
Installing the Invariant SDK for Python
The Invariant SDK enables you to share, analyze and collaborate on AI agent runtime traces. This documentation will guide you through the process of setting up the SDK, capturing traces, and uploading them to the Invariant Explorer. The SDK currently only supports Python.
Install via pip directly
Include via requirements.txt
You can include the Invariant SDK in your requirements.txt
file by adding invariant-sdk
.
Include via pyproject.toml
To include the Invariant SDK in your pyproject.toml
file, follow these steps:
Using poetry
-
Add
invariant-sdk
under the[tool.poetry.dependencies]
section inpyproject.toml
. -
Run the following command to install the dependencies:
Using hatch
-
Add
invariant-sdk
under thedependencies
section inpyproject.toml
. -
Run the following command to install the dependencies: