@agentium/observability 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +42 -0
- package/dist/index.cjs +1370 -0
- package/dist/index.d.cts +279 -0
- package/dist/index.d.ts +279 -0
- package/dist/index.js +1333 -0
- package/package.json +48 -0
package/README.md
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# @agentium/observability
|
|
2
|
+
|
|
3
|
+
Opt-in tracing, metrics, and structured logging for Agentium agents.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @agentium/observability
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Quick Start
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { Agent, openai } from "@agentium/core";
|
|
15
|
+
import { instrument } from "@agentium/observability";
|
|
16
|
+
|
|
17
|
+
const agent = new Agent({ name: "assistant", model: openai("gpt-4o") });
|
|
18
|
+
|
|
19
|
+
const obs = instrument(agent, {
|
|
20
|
+
exporters: ["console"], // or "langfuse", "otel", "json-file"
|
|
21
|
+
});
|
|
22
|
+
|
|
23
|
+
await agent.run("Hello!");
|
|
24
|
+
await obs.tracer.flush();
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Exporters
|
|
28
|
+
|
|
29
|
+
| Shorthand | Env Vars | Description |
|
|
30
|
+
|-----------|----------|-------------|
|
|
31
|
+
| `"console"` | — | Pretty-print trace tree |
|
|
32
|
+
| `"langfuse"` | `LANGFUSE_PUBLIC_KEY`, `LANGFUSE_SECRET_KEY` | Langfuse cloud |
|
|
33
|
+
| `"otel"` | `OTEL_EXPORTER_OTLP_ENDPOINT` | OpenTelemetry collector |
|
|
34
|
+
| `"json-file"` | — | Local JSON file |
|
|
35
|
+
|
|
36
|
+
## Documentation
|
|
37
|
+
|
|
38
|
+
Full docs at [agentium.mintlify.dev](https://agentium.mintlify.dev)
|
|
39
|
+
|
|
40
|
+
## License
|
|
41
|
+
|
|
42
|
+
MIT
|