Documentation Index
Fetch the complete documentation index at: https://langwatch.ai/docs/llms.txt
Use this file to discover all available pages before exploring further.
Pairs with: AI Gateway → Anthropic provider. Direct Anthropic API traffic flows through the gateway data plane; Cowork tool-use telemetry is a separate OTLP feed routed through this ingestion source.
tool_use taxonomy into precise governance KPI fields is the next step on the adapter roadmap.
Currently implemented
- Receiver:
POST /api/ingest/otel/:sourceId, same endpoint asotel_generic. - Auth:
Authorization: Bearer lw_is_<secret>. - Body: OTLP/HTTP JSON envelope (also accepts protobuf + gzip, deflate, brotli per the shared parser).
- OTLP shape: Spans (lands in
recorded_spanswith origin metadata stamped). Same handoff path asotel_generic. - Pipeline: Receiver lazy-ensures the hidden Governance Project, stamps
langwatch.origin.*+langwatch.governance.retention_classon every span, hands off to the existing trace pipeline. Cowork tool-call spans land as the OCSF “Action = tool_call”; model-call spans land as “Action = chat” via the governance fold’s heuristic. - Status flip: receiver calls
recordEventReceived(sourceId)after any successful 202; source flips fromawaiting_first_event→active.
What the admin configures upstream
The composer collects:| Field | Required | Stored |
|---|---|---|
Anthropic workspace ID (wsp_...) | yes | IngestionSource.payloadConfig.workspaceId, used for correlation with Anthropic’s admin console; the receiver itself doesn’t enforce it today |
| Field | Value |
|---|---|
| OTLP URL | https://<your-langwatch>/api/ingest/otel/<sourceId> |
| Bearer secret | lw_is_<base64url> |
What event shape we accept today
Whatever OTLP body Cowork emits,resource_spans are walked, each span turns into one governance KPI. Cowork’s tool-call spans land as eventType: tool.invocation (the heuristic catches tool in the span name); model-call spans land as eventType: api.call (the heuristic catches chat/messages/completion).
What is still envelope-only, follow-up work
- Cowork tool taxonomy. Cowork attaches a richer
tool_useattribute set than the generic OTel heuristic looks for (e.g.anthropic.cowork.tool.intent,anthropic.cowork.tool.outcome). These attributes are kept inrawPayloadbut aren’t promoted to top-level governance KPI fields. A Cowork-specific overlay normaliser will pick them up. - Workspace ID enforcement. The
workspaceIdconfig field is currently informational. A future change will reject events whose Cowork-emitted workspace attribute doesn’t match the configured one (defence-in-depth against secret leaks). - Cowork-specific cost normalisation. Anthropic’s spans don’t carry
gen_ai.usage.cost_usddirectly; cost is derived later by the cost-enrichment pipeline. Until then,costUsdwill be0on the CLI tail output.
Verify with CLI + web
tool.invocation and api.call. If everything shows agent.action, the heuristic isn’t matching Cowork’s span names, file an issue with a sample span name and the Cowork adapter heuristic will be tightened.