Langtrace
Monitoring Agents and Swarms with Langtrace
Last updated
Monitoring Agents and Swarms with Langtrace
Last updated
© 2024 SwarmZero Technology Solutions Inc. All rights reserved.
Langtrace is an open source observability and evaluations platform for AI Agents. You can use it to track vital LLM metrics, store & version control your prompts, compare the performance of your prompts across different models and much more.
First, signup on Langtrace.
Create a new project.
Give it a name and description.
Set the project type to Default.
Install the Python SDK for Langtrace in your existing SwarmZero project.
Import and initialize Langtrace before you import the SwarmZero SDK.
Generate a Langtrace API Key from the Langtrace app dashboard.
Select the Setup Project button on the newly created project card.
Click Generate API Key and follow the on-screen instructions.
Copy the API key.
In the .env file of your SwarmZero project, add this:
Restart the agent server if you are using the agent.run()
method.
If not, just call agent.chat(...)
again from your Python script.
Examples of Langtrace integration can be found in the examples repository.