@agimon-ai/doompi-telemetry 0.0.1-alpha.21 → 0.0.1-alpha.23

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.
Files changed (2) hide show
  1. package/README.md +47 -15
  2. package/package.json +9 -7
package/README.md CHANGED
@@ -1,14 +1,16 @@
1
1
  # @agimon-ai/doompi-telemetry
2
2
 
3
- **Measure the harness without recording the work.**
3
+ Host-neutral telemetry helpers and Log Sink adapters shared by DoomPi packages.
4
4
 
5
- This is the shared telemetry library for Doompi runtimes. It emits metadata-only counters
6
- and spans: never prompt text, file contents, or the material the agent is working on. One
7
- library keeps event names and attributes consistent across extensions, which makes the
8
- result useful for debugging instead of merely plentiful.
5
+ Part of the [DoomPi distribution](https://www.npmjs.com/package/@agimon-ai/doompi).
9
6
 
10
- This is part of [Doompi](https://www.npmjs.com/package/@agimon-ai/doompi). It is usually a
11
- transitive dependency rather than something users install on its own.
7
+ This is a library, not a Pi extension. It has no Pi manifest or Pi peer dependency and should not be added to a DoomPi layer.
8
+
9
+ > **Alpha:** telemetry attributes and sink contracts may change between releases.
10
+
11
+ ## Requirements
12
+
13
+ - Node.js 22.19.0 or newer
12
14
 
13
15
  ## Install
14
16
 
@@ -16,17 +18,47 @@ transitive dependency rather than something users install on its own.
16
18
  npm install @agimon-ai/doompi-telemetry
17
19
  ```
18
20
 
19
- ## How it loads
21
+ ## Use
22
+
23
+ ```ts
24
+ import { createDoomTelemetry } from '@agimon-ai/doompi-telemetry';
25
+
26
+ const telemetry = createDoomTelemetry({
27
+ serviceName: 'review-extension',
28
+ packageName: '@example/review-extension',
29
+ cwd: process.cwd(),
30
+ env: process.env,
31
+ enableLogs: true,
32
+ enableTraces: true,
33
+ });
34
+
35
+ await telemetry.recordEvent('review.started', { 'review.file_count': 3 });
36
+ await telemetry.flush();
37
+ await telemetry.shutdown();
38
+ ```
39
+
40
+ The root and `/telemetry` subpath expose `createDoomTelemetry`, attribute sanitization, header creation, record subscriptions, and related types.
20
41
 
21
- This is a library, not a Pi extension. Doompi packages import it directly; there is no
22
- extension entry and nothing to add to `.doom/modes.yaml`.
42
+ ## Data and failure behavior
23
43
 
24
- ## Entry points
44
+ The adapter sanitizes attribute shapes and hashes selected identifiers before export. It is designed for operational metadata, but callers remain responsible for the values they pass. Do not attach prompt text, file contents, credentials, or unreviewed user data.
45
+
46
+ Exception export is optional and can include error names, messages, and stack context. Those fields may disclose code paths or values even when ordinary attributes are metadata-only.
47
+
48
+ When no endpoint is configured, telemetry export becomes a no-op rather than breaking the host. Explicit file fallback must be enabled by the caller; it is not silently selected. Sink initialization, record, flush, and shutdown behavior is surfaced through status/diagnostic callbacks.
49
+
50
+ Common controls used by DoomPi hosts include `AGENT_TELEMETRY_DISABLED`, `OTEL_SDK_DISABLED`, and `AGENT_OTEL_TRACES`. Hosts must decide whether these variables, endpoint configuration, or explicit options have precedence in their integration.
51
+
52
+ ## Development
53
+
54
+ ```bash
55
+ pnpm build
56
+ pnpm typecheck
57
+ pnpm test
58
+ pnpm lint
59
+ ```
25
60
 
26
- | Import | Purpose |
27
- | --------------------------------------- | ------------------ |
28
- | `@agimon-ai/doompi-telemetry` | Shared library API |
29
- | `@agimon-ai/doompi-telemetry/telemetry` | Telemetry helpers |
61
+ Maintained by [Agimon](https://agimon.ai/about).
30
62
 
31
63
  ## License
32
64
 
package/package.json CHANGED
@@ -1,13 +1,15 @@
1
1
  {
2
2
  "name": "@agimon-ai/doompi-telemetry",
3
- "version": "0.0.1-alpha.21",
4
- "description": "Metadata-only LogSink telemetry for Doompi runtimes",
3
+ "version": "0.0.1-alpha.23",
4
+ "description": "Host-neutral telemetry, OpenTelemetry controls, and Log Sink adapters for DoomPi sessions.",
5
5
  "keywords": [
6
- "ai",
7
- "coding-agent",
8
- "developer-tools",
6
+ "agent-observability",
9
7
  "doompi",
10
- "pi-package"
8
+ "log-sink",
9
+ "metrics",
10
+ "opentelemetry",
11
+ "telemetry",
12
+ "tracing"
11
13
  ],
12
14
  "homepage": "https://agimon.ai",
13
15
  "license": "MIT",
@@ -37,7 +39,7 @@
37
39
  "registry": "https://registry.npmjs.org/"
38
40
  },
39
41
  "dependencies": {
40
- "@agimon-ai/log-sink-mcp": "0.29.11"
42
+ "@agimon-ai/log-sink-mcp": "0.29.13"
41
43
  },
42
44
  "devDependencies": {
43
45
  "@types/node": "26.1.1",