Skip to content

Instantly share code, notes, and snippets.

View w2jmoe's full-sized avatar
🤭
lf you feel it, Follow it!✨(>◡❛)

Jay Wu | 武文杰 ✨ w2jmoe

🤭
lf you feel it, Follow it!✨(>◡❛)
View GitHub Profile

MCP Route Decision — Langfuse Observation Contract

Observation name: mcp.route_decision
Observation type: SPAN
Metadata schema: mcp.route_decision.v1 (value of metadata.schema_version)

This document defines the metadata object only for the mcp.route_decision span. Span-level fields (id, traceId, type, name, startTime, endTime, parentObservationId, version, input, output, level, statusMessage) follow your Langfuse / export pipeline conventions and are not duplicated here except where noted.


@w2jmoe
w2jmoe / gist:e7d7cbe2c4fbd962d9c3933fb3c6d616
Created May 16, 2026 01:11
03.failed_path_trace.json
[
{
"id": "obs_parent_turn_failed_9e7d6c5b4a302918f7e6d5c4b3a29180",
"traceId": "a9f81d4e2c7b5036f8e1a4d9c2b7e6f5a",
"type": "SPAN",
"name": "hermes.agent.turn",
"startTime": "2026-05-15T14:22:03.420000Z",
"endTime": "2026-05-15T14:22:03.900000Z",
"parentObservationId": null,
"level": "DEFAULT",
[
{
"id": "obs_parent_turn_happy_01k9m4x7w2p3q8r5n6t1v0z3x",
"traceId": "7c4e2a1f9b8d6035e7a2c4f1b9d8e7a6",
"type": "SPAN",
"name": "hermes.agent.turn",
"startTime": "2026-05-15T08:42:17.100000Z",
"endTime": "2026-05-15T08:42:17.500000Z",
"parentObservationId": null,
"level": "DEFAULT",
# MCP Route Decision — Langfuse Observation Contract
**Observation name:** `mcp.route_decision`
**Observation `type`:** `SPAN`
**Metadata schema:** `mcp.route_decision.v1` (value of `metadata.schema_version`)
This document defines the **metadata object only** for the `mcp.route_decision` span. Span-level fields (`id`, `traceId`, `type`, `name`, `startTime`, `endTime`, `parentObservationId`, `version`, `input`, `output`, `level`, `statusMessage`) follow your Langfuse / export pipeline conventions and are not duplicated here except where noted.
---
[
{
"id": "obs_c3b8a1f2e9d0471b8c6e5a4f3029187d",
"traceId": "a9f81d4e2c7b5036f8e1a4d9c2b7e6f5a",
"type": "SPAN",
"name": "mcp.route_decision",
"startTime": "2026-05-15T14:22:03.456000Z",
"endTime": "2026-05-15T14:22:03.457000Z",
"parentObservationId": "obs_9e7d6c5b4a302918f7e6d5c4b3a29180",
"level": "DEFAULT",
[
{
"id": "obs_fa16d658fa704d8aae90e6fb",
"traceId": "eeda44058d30dcbbb99aac800f12e7d9",
"type": "SPAN",
"name": "mcp.route_decision",
"startTime": "2026-05-15T08:42:17.128000Z",
"endTime": "2026-05-15T08:42:17.129000Z",
"parentObservationId": "obs_2fd5a057ef554f668048904a",
"level": "DEFAULT",
{
"name": "mcp.route_decision",
"trace_id": "4f3a9c2e8b1d7056a4c8e3f192b6d7e4",
"span_id": "a1b2c3d4e5f67890",
"metadata": {
"router_name": "WisePick-Decision-Engine",
"router_version": "v0.1.6",
"capability_id": "k8s_log_analysis",
"selected_tool": "query_controlplane_logs",
"confidence": 0.98,