NeuroAgent AI

Observability & Cost

Every run is traced and costed automatically — no setup.

from neuroagent import Agent

agent = Agent(provider="openai")
agent.run("Summarize the news.")
agent.run("Draft a reply.")

print(agent.stats())
# {'runs': 2, 'tokens': 1423, 'cost': 0.0042, 'cost_str': '$0.0042',
#  'by_model': {...}, 'by_provider': {...}, ...}

# Inspect the last run as a tree of spans:
from neuroagent.observability import ConsoleExporter
print(ConsoleExporter().export(agent.last_trace))

# Ship traces to any OpenTelemetry collector (OTLP/HTTP, no SDK required):
from neuroagent.observability import OTelExporter
OTelExporter().send(agent.last_trace, "http://localhost:4318/v1/traces")

Pricing tables

Data-driven and overridable — useful for new models or self-hosted endpoints:

from neuroagent.cost import register_pricing
register_pricing("my-model", input_per_million=1.0, output_per_million=2.0)