oh-my-customcode 0.118.3 → 0.119.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/dist/cli/index.js
CHANGED
package/dist/index.js
CHANGED
package/package.json
CHANGED
|
@@ -213,3 +213,102 @@ claude-inspector
|
|
|
213
213
|
```
|
|
214
214
|
|
|
215
215
|
Claude Inspector is external to oh-my-customcode and does not require any project configuration changes.
|
|
216
|
+
|
|
217
|
+
## Agent Trajectory Export Mode
|
|
218
|
+
|
|
219
|
+
Toggle: `/monitoring-setup trajectory-otel on|off`
|
|
220
|
+
|
|
221
|
+
When enabled, agent-eval-framework 4-metric data is emitted as OpenTelemetry spans for external analysis.
|
|
222
|
+
|
|
223
|
+
### trajectory-otel on
|
|
224
|
+
|
|
225
|
+
1. Read `.claude/settings.local.json` (create if not exists)
|
|
226
|
+
2. Add or update `env` field with trajectory export configuration:
|
|
227
|
+
```json
|
|
228
|
+
{
|
|
229
|
+
"env": {
|
|
230
|
+
"CLAUDE_CODE_ENABLE_TELEMETRY": "1",
|
|
231
|
+
"OTEL_METRICS_EXPORTER": "console",
|
|
232
|
+
"OTEL_LOGS_EXPORTER": "console",
|
|
233
|
+
"CLAUDE_TRAJECTORY_OTEL": "1"
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
```
|
|
237
|
+
3. If `OTEL_EXPORTER_OTLP_ENDPOINT` is set in the environment, also add:
|
|
238
|
+
```json
|
|
239
|
+
{
|
|
240
|
+
"env": {
|
|
241
|
+
"OTEL_TRACES_EXPORTER": "otlp"
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
```
|
|
245
|
+
Otherwise default to `"OTEL_TRACES_EXPORTER": "console"`.
|
|
246
|
+
4. Preserve all existing settings
|
|
247
|
+
5. Report:
|
|
248
|
+
```
|
|
249
|
+
[Done] Agent Trajectory Export enabled
|
|
250
|
+
|
|
251
|
+
Configured in: .claude/settings.local.json
|
|
252
|
+
Span exporter: console (default) | otlp (if OTEL_EXPORTER_OTLP_ENDPOINT set)
|
|
253
|
+
Metrics: correctness, step_ratio, tool_call_ratio, latency_ratio
|
|
254
|
+
Events: tool_call (tool_name, duration_ms, exit_code)
|
|
255
|
+
|
|
256
|
+
Note: Takes effect on next `claude` session restart.
|
|
257
|
+
To disable: /monitoring-setup trajectory-otel off
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
### trajectory-otel off
|
|
261
|
+
|
|
262
|
+
1. Read `.claude/settings.local.json`
|
|
263
|
+
2. Remove trajectory-related keys from `env`:
|
|
264
|
+
- `CLAUDE_TRAJECTORY_OTEL`
|
|
265
|
+
- `OTEL_TRACES_EXPORTER`
|
|
266
|
+
3. Report:
|
|
267
|
+
```
|
|
268
|
+
[Done] Agent Trajectory Export disabled
|
|
269
|
+
|
|
270
|
+
Removed from: .claude/settings.local.json
|
|
271
|
+
Takes effect on next session restart.
|
|
272
|
+
```
|
|
273
|
+
|
|
274
|
+
### Span Schema
|
|
275
|
+
|
|
276
|
+
```
|
|
277
|
+
operation: agent.invocation
|
|
278
|
+
attributes:
|
|
279
|
+
agent.type: string // e.g. "lang-golang-expert"
|
|
280
|
+
agent.model: string // e.g. "claude-sonnet-4-6"
|
|
281
|
+
task.id: string // eval task identifier
|
|
282
|
+
task.capability: string // research | implement | review | debug | manage
|
|
283
|
+
metric.correctness: bool
|
|
284
|
+
metric.step_ratio: float
|
|
285
|
+
metric.tool_call_ratio: float
|
|
286
|
+
metric.latency_ratio: float
|
|
287
|
+
events:
|
|
288
|
+
- tool_call
|
|
289
|
+
attrs: tool_name (string), duration_ms (int), exit_code (int)
|
|
290
|
+
duration: total wall clock time of agent invocation
|
|
291
|
+
```
|
|
292
|
+
|
|
293
|
+
### Activation Notes
|
|
294
|
+
|
|
295
|
+
- Independent from the existing console monitoring mode (`enable`/`disable`). Both can be active simultaneously.
|
|
296
|
+
- `trajectory-otel on` does NOT implicitly call `enable` — console metrics monitoring remains a separate toggle.
|
|
297
|
+
- Console exporter (default): prints span JSON to stdout for local dev / debugging.
|
|
298
|
+
- OTLP exporter (optional): activated when `OTEL_EXPORTER_OTLP_ENDPOINT` env var is set. Compatible with Grafana, Datadog, Honeycomb, and any OTLP-compliant collector. No LangSmith dependency.
|
|
299
|
+
- Actual OTEL SDK emission is handled by the Claude Code telemetry layer. This skill configures the env vars that activate the trajectory span pipeline.
|
|
300
|
+
|
|
301
|
+
### status (extended)
|
|
302
|
+
|
|
303
|
+
When `trajectory-otel` is active, `status` command output includes:
|
|
304
|
+
|
|
305
|
+
```
|
|
306
|
+
[Monitoring Status]
|
|
307
|
+
├── Enabled: Yes/No
|
|
308
|
+
├── Metrics exporter: console / otlp / none
|
|
309
|
+
├── Logs exporter: console / otlp / none
|
|
310
|
+
├── Trajectory export: Yes/No
|
|
311
|
+
├── Traces exporter: console / otlp / none
|
|
312
|
+
└── Config: .claude/settings.local.json
|
|
313
|
+
```
|
|
314
|
+
|
|
@@ -652,7 +652,47 @@ find .claude/outputs/eval -name "result.yaml" | \
|
|
|
652
652
|
|
|
653
653
|
**한계**: 집계가 수동이며, LangSmith Insights의 시계열 추이나 분포 시각화는 제공하지 않는다.
|
|
654
654
|
|
|
655
|
-
**향후 보강**: monitoring-setup
|
|
655
|
+
**향후 보강**: monitoring-setup의 `trajectory-otel` 모드(#1035)로 step trace를 OTEL span으로 내보내고 Grafana에서 시각화하는 경로가 열린다.
|
|
656
|
+
|
|
657
|
+
### 5.5 OpenTelemetry Trajectory Export (#1035)
|
|
658
|
+
|
|
659
|
+
`monitoring-setup` 스킬의 `trajectory-otel` 모드를 활성화하면 agent-eval-framework가 측정한 4-metric 데이터를 OTEL span/event로 내보낸다.
|
|
660
|
+
|
|
661
|
+
**활성화**: `/monitoring-setup trajectory-otel on`
|
|
662
|
+
**비활성화**: `/monitoring-setup trajectory-otel off`
|
|
663
|
+
|
|
664
|
+
#### Span 구조
|
|
665
|
+
|
|
666
|
+
```
|
|
667
|
+
operation: agent.invocation
|
|
668
|
+
attributes:
|
|
669
|
+
agent.type, agent.model, task.id, task.capability
|
|
670
|
+
metric.correctness, metric.step_ratio, metric.tool_call_ratio, metric.latency_ratio
|
|
671
|
+
events:
|
|
672
|
+
tool_call (tool_name, duration_ms, exit_code)
|
|
673
|
+
```
|
|
674
|
+
|
|
675
|
+
#### 내보내기 옵션
|
|
676
|
+
|
|
677
|
+
| 옵션 | 조건 | 대상 |
|
|
678
|
+
|------|------|------|
|
|
679
|
+
| Console exporter | 기본 (항상) | stdout — 로컬 디버깅 |
|
|
680
|
+
| OTLP exporter | `OTEL_EXPORTER_OTLP_ENDPOINT` 환경변수 설정 시 | Grafana / Datadog / Honeycomb 등 |
|
|
681
|
+
|
|
682
|
+
#### 장점
|
|
683
|
+
|
|
684
|
+
- **표준 OTEL 생태계**: LangSmith 의존 없음. 모든 OTLP 호환 collector에 연결 가능.
|
|
685
|
+
- **다른 LLM 시스템과 비교**: 동일 OTEL 인프라를 사용하는 시스템(예: LangChain) 메트릭과 직접 비교 가능.
|
|
686
|
+
- **기존 모니터링과 독립**: `enable`/`disable` 콘솔 모니터링과 별도 토글. 동시 활성화 가능.
|
|
687
|
+
|
|
688
|
+
#### 대안 매핑 테이블 업데이트
|
|
689
|
+
|
|
690
|
+
| LangChain 컴포넌트 | 역할 | oh-my-customcode 대안 |
|
|
691
|
+
|--------------------|------|----------------------|
|
|
692
|
+
| LangSmith trace | step별 실행 기록 수집 | claude-mem `save_memory` per step (5.2) |
|
|
693
|
+
| Polly (record/replay) | 결정론적 재현 | episodic-memory 검색 (5.3) |
|
|
694
|
+
| Insights dashboard | 집계 메트릭 시각화 | statusline.sh + omcustom-improve-report (5.4) |
|
|
695
|
+
| **LangSmith OTEL export** | **표준 OTEL span 수집** | **trajectory-otel mode (5.5, #1035)** |
|
|
656
696
|
|
|
657
697
|
---
|
|
658
698
|
|
package/templates/manifest.json
CHANGED