Kolena Agents Client
Project description
Kolena Agents
Python client for interacting with Kolena Agents.
Initialization
An API Key is required to use the python client. Generate a key from your user profile within the Kolena web UI.
Copy the created key and store in a KOLENA_API_KEY environment variable:
export KOLENA_API_KEY="your-api-key"
Usage
Here's an example of how to use the client to add, download, list, and delete agent runs:
from kolena_agents import Client
client = Client()
# add new agent run
new_run = client.agent_run.add(agent_id=1, files=["path/to/file1", "path/to/file2"])
# download agent run
run = client.agent_run.get(agent_id=1, run_id=2)
# alternatively, list all agent runs
all_runs = client.agent_run.list(agent_id=1)
# delete agent run
client.agent_run.delete(agent_id=1, run_id=2)
# list all agents
all_agents = client.agent.list()
# get an agent
agent = client.agent.get(agent_id=1)
# update Agent metadata
updated_agent = client.agent.update_metadata(
agent_id=1,
metadata={
"environment": "production",
"version": 2,
"tags": ["nlp", "extraction"]
}
)
Webhook
Kolena provides a helper function to handle signature verification and parsing. See Webhook Integration for more information.
from kolena_agents import webhook
result = webhook.construct_event(request_body, secret, request_headers)
Supported Python Versions
Python versions 3.8 and later are supported.
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 kolena_agents-0.11.1.tar.gz.
File metadata
- Download URL: kolena_agents-0.11.1.tar.gz
- Upload date:
- Size: 56.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
99776587e1fedd11665e8a6fceaac50f9fe080e1d507984c1dd872bd498f0492
|
|
| MD5 |
1a402d4185be33982cbbf819b4783ad1
|
|
| BLAKE2b-256 |
f7d33d4184c424e2f19428ba34a795f6823ac61bde93e1b0943ab956c7d4ba88
|
File details
Details for the file kolena_agents-0.11.1-py3-none-any.whl.
File metadata
- Download URL: kolena_agents-0.11.1-py3-none-any.whl
- Upload date:
- Size: 118.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
548411327b73bddb7c9735ea8ffc666a5227ebccbf2749d9841ac54476cd1420
|
|
| MD5 |
c4da40f4a774f8bfcd26bde7eaf9f04c
|
|
| BLAKE2b-256 |
43b1df14e86272a3ba572c4344d1de7d3b72fb95e6b779c4da77aedc6b5403db
|