@inferevents/mcp 0.5.3 → 1.0.2

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 (110) hide show
  1. package/dist/api-client.d.ts +141 -59
  2. package/dist/api-client.d.ts.map +1 -1
  3. package/dist/api-client.js +59 -69
  4. package/dist/api-client.js.map +1 -1
  5. package/dist/config.d.ts +2 -0
  6. package/dist/config.d.ts.map +1 -1
  7. package/dist/config.js +19 -0
  8. package/dist/config.js.map +1 -1
  9. package/dist/index.js +0 -0
  10. package/dist/remote.d.ts +1 -1
  11. package/dist/remote.d.ts.map +1 -1
  12. package/dist/remote.js +5 -0
  13. package/dist/remote.js.map +1 -1
  14. package/dist/server.d.ts.map +1 -1
  15. package/dist/server.js +90 -186
  16. package/dist/server.js.map +1 -1
  17. package/dist/tool-result.d.ts +34 -0
  18. package/dist/tool-result.d.ts.map +1 -0
  19. package/dist/tool-result.js +30 -0
  20. package/dist/tool-result.js.map +1 -0
  21. package/dist/tools/annotate-span.d.ts +7 -0
  22. package/dist/tools/annotate-span.d.ts.map +1 -0
  23. package/dist/tools/annotate-span.js +16 -0
  24. package/dist/tools/annotate-span.js.map +1 -0
  25. package/dist/tools/annotate-trace.d.ts +7 -0
  26. package/dist/tools/annotate-trace.d.ts.map +1 -0
  27. package/dist/tools/annotate-trace.js +16 -0
  28. package/dist/tools/annotate-trace.js.map +1 -0
  29. package/dist/tools/create-project.d.ts.map +1 -1
  30. package/dist/tools/create-project.js +39 -7
  31. package/dist/tools/create-project.js.map +1 -1
  32. package/dist/tools/deprecated-tools.d.ts +16 -0
  33. package/dist/tools/deprecated-tools.d.ts.map +1 -0
  34. package/dist/tools/deprecated-tools.js +78 -0
  35. package/dist/tools/deprecated-tools.js.map +1 -0
  36. package/dist/tools/deprecated.d.ts +25 -0
  37. package/dist/tools/deprecated.d.ts.map +1 -0
  38. package/dist/tools/deprecated.js +42 -0
  39. package/dist/tools/deprecated.js.map +1 -0
  40. package/dist/tools/get-cost-stats.d.ts +18 -0
  41. package/dist/tools/get-cost-stats.d.ts.map +1 -0
  42. package/dist/tools/get-cost-stats.js +88 -0
  43. package/dist/tools/get-cost-stats.js.map +1 -0
  44. package/dist/tools/get-error-spans.d.ts +8 -0
  45. package/dist/tools/get-error-spans.d.ts.map +1 -0
  46. package/dist/tools/get-error-spans.js +25 -0
  47. package/dist/tools/get-error-spans.js.map +1 -0
  48. package/dist/tools/get-insights.d.ts.map +1 -1
  49. package/dist/tools/get-insights.js +74 -109
  50. package/dist/tools/get-insights.js.map +1 -1
  51. package/dist/tools/get-latency-stats.d.ts +7 -0
  52. package/dist/tools/get-latency-stats.d.ts.map +1 -0
  53. package/dist/tools/get-latency-stats.js +28 -0
  54. package/dist/tools/get-latency-stats.js.map +1 -0
  55. package/dist/tools/get-project-summary.d.ts +0 -39
  56. package/dist/tools/get-project-summary.d.ts.map +1 -1
  57. package/dist/tools/get-project-summary.js +101 -79
  58. package/dist/tools/get-project-summary.js.map +1 -1
  59. package/dist/tools/get-span.d.ts +6 -0
  60. package/dist/tools/get-span.d.ts.map +1 -0
  61. package/dist/tools/get-span.js +30 -0
  62. package/dist/tools/get-span.js.map +1 -0
  63. package/dist/tools/get-token-usage.d.ts +7 -0
  64. package/dist/tools/get-token-usage.d.ts.map +1 -0
  65. package/dist/tools/get-token-usage.js +25 -0
  66. package/dist/tools/get-token-usage.js.map +1 -0
  67. package/dist/tools/get-trace.d.ts +6 -0
  68. package/dist/tools/get-trace.d.ts.map +1 -0
  69. package/dist/tools/get-trace.js +28 -0
  70. package/dist/tools/get-trace.js.map +1 -0
  71. package/dist/tools/list-spans.d.ts +15 -0
  72. package/dist/tools/list-spans.d.ts.map +1 -0
  73. package/dist/tools/list-spans.js +19 -0
  74. package/dist/tools/list-spans.js.map +1 -0
  75. package/dist/tools/schemas.d.ts +45 -0
  76. package/dist/tools/schemas.d.ts.map +1 -0
  77. package/dist/tools/schemas.js +86 -0
  78. package/dist/tools/schemas.js.map +1 -0
  79. package/dist/tools/switch-project.d.ts.map +1 -1
  80. package/dist/tools/switch-project.js +56 -5
  81. package/dist/tools/switch-project.js.map +1 -1
  82. package/package.json +2 -2
  83. package/dist/tools/annotate-thread.d.ts +0 -11
  84. package/dist/tools/annotate-thread.d.ts.map +0 -1
  85. package/dist/tools/annotate-thread.js +0 -23
  86. package/dist/tools/annotate-thread.js.map +0 -1
  87. package/dist/tools/get-event-counts.d.ts +0 -23
  88. package/dist/tools/get-event-counts.d.ts.map +0 -1
  89. package/dist/tools/get-event-counts.js +0 -50
  90. package/dist/tools/get-event-counts.js.map +0 -1
  91. package/dist/tools/get-ontology.d.ts +0 -9
  92. package/dist/tools/get-ontology.d.ts.map +0 -1
  93. package/dist/tools/get-ontology.js +0 -62
  94. package/dist/tools/get-ontology.js.map +0 -1
  95. package/dist/tools/get-retention.d.ts +0 -11
  96. package/dist/tools/get-retention.d.ts.map +0 -1
  97. package/dist/tools/get-retention.js +0 -87
  98. package/dist/tools/get-retention.js.map +0 -1
  99. package/dist/tools/get-top-events.d.ts +0 -11
  100. package/dist/tools/get-top-events.d.ts.map +0 -1
  101. package/dist/tools/get-top-events.js +0 -74
  102. package/dist/tools/get-top-events.js.map +0 -1
  103. package/dist/tools/get-user-journey.d.ts +0 -10
  104. package/dist/tools/get-user-journey.d.ts.map +0 -1
  105. package/dist/tools/get-user-journey.js +0 -143
  106. package/dist/tools/get-user-journey.js.map +0 -1
  107. package/dist/tools/update-ontology.d.ts +0 -37
  108. package/dist/tools/update-ontology.d.ts.map +0 -1
  109. package/dist/tools/update-ontology.js +0 -51
  110. package/dist/tools/update-ontology.js.map +0 -1
package/dist/server.js CHANGED
@@ -1,20 +1,27 @@
1
1
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
2
- // Skills are separate (@inferevents/skills). MCP server = tools only.
3
2
  import { ApiClient, ApiError } from "./api-client.js";
4
3
  import { loadConfig } from "./config.js";
5
- import { getEventCountsSchema, handleGetEventCounts, } from "./tools/get-event-counts.js";
6
- import { getRetentionSchema, handleGetRetention, } from "./tools/get-retention.js";
7
- import { getUserJourneySchema, handleGetUserJourney, } from "./tools/get-user-journey.js";
8
- import { getTopEventsSchema, handleGetTopEvents, } from "./tools/get-top-events.js";
9
- import { getInsightsSchema, handleGetInsights, } from "./tools/get-insights.js";
10
- import { getOntologySchema, handleGetOntology, } from "./tools/get-ontology.js";
11
- import { updateOntologySchema, handleUpdateOntology, } from "./tools/update-ontology.js";
12
- import { annotateThreadSchema, handleAnnotateThread, } from "./tools/annotate-thread.js";
13
- import { switchProjectSchema, handleSwitchProject, } from "./tools/switch-project.js";
14
- import { createProjectSchema, handleCreateProject, } from "./tools/create-project.js";
15
- import { getProjectSummarySchema, handleGetProjectSummary, } from "./tools/get-project-summary.js";
4
+ // Active tool schemas
5
+ import { listSpansInputSchema, getTraceInputSchema, getSpanInputSchema, getLatencyStatsInputSchema, getTokenUsageInputSchema, getCostStatsInputSchema, getErrorSpansInputSchema, annotateSpanInputSchema, annotateTraceInputSchema, } from "./tools/schemas.js";
6
+ // Active tool handlers
7
+ import { handleListSpans } from "./tools/list-spans.js";
8
+ import { handleGetTrace } from "./tools/get-trace.js";
9
+ import { handleGetSpan } from "./tools/get-span.js";
10
+ import { handleGetLatencyStats } from "./tools/get-latency-stats.js";
11
+ import { handleGetTokenUsage } from "./tools/get-token-usage.js";
12
+ import { handleGetCostStats } from "./tools/get-cost-stats.js";
13
+ import { handleGetErrorSpans } from "./tools/get-error-spans.js";
14
+ import { handleAnnotateSpan } from "./tools/annotate-span.js";
15
+ import { handleAnnotateTrace } from "./tools/annotate-trace.js";
16
+ // Adapted tools (kept)
17
+ import { getInsightsSchema, handleGetInsights } from "./tools/get-insights.js";
18
+ import { getProjectSummarySchema, handleGetProjectSummary } from "./tools/get-project-summary.js";
19
+ // Config helpers (kept)
20
+ import { createProjectSchema, handleCreateProject } from "./tools/create-project.js";
21
+ import { switchProjectSchema, handleSwitchProject } from "./tools/switch-project.js";
22
+ // Deprecation shims (7)
23
+ import { RETIRED_TOOL_SHIMS } from "./tools/deprecated-tools.js";
16
24
  export function createServer(config) {
17
- // Re-reads config from disk on each call so switch_project takes effect immediately
18
25
  async function getClient() {
19
26
  try {
20
27
  const freshConfig = await loadConfig();
@@ -25,188 +32,85 @@ export function createServer(config) {
25
32
  }
26
33
  }
27
34
  const server = new McpServer({
28
- name: "infer-analytics",
29
- version: "0.1.0",
35
+ name: "infer-llm-obs",
36
+ version: "1.0.0",
30
37
  });
31
- // Skills are now in a separate package (@inferevents/skills)
32
- // installed via: npx skills add infer-events/skills
33
- // The MCP server only provides tools, not skill resources.
34
- // --- Tools ---
35
- server.tool("get_event_counts", "Count events over a time range, optionally grouped by a property. " +
36
- "Use this for questions like 'how many signups this week', " +
37
- "'page views by country last 30 days', or 'purchase count trend'.", getEventCountsSchema, async (params) => {
38
- try {
39
- const text = await handleGetEventCounts(await getClient(), params);
40
- return { content: [{ type: "text", text }] };
41
- }
42
- catch (error) {
43
- return {
44
- content: [{ type: "text", text: formatError(error) }],
45
- isError: true,
46
- };
47
- }
48
- });
49
- server.tool("get_retention", "Cohort-based retention analysis. Shows what percentage of users who performed " +
50
- "a start event came back to perform a return event. " +
51
- "Use for questions like 'what is our week-over-week retention', " +
52
- "'do users come back after signing up', or 'retention by monthly cohort'.", getRetentionSchema, async (params) => {
53
- try {
54
- const text = await handleGetRetention(await getClient(), params);
55
- return { content: [{ type: "text", text }] };
56
- }
57
- catch (error) {
58
- return {
59
- content: [{ type: "text", text: formatError(error) }],
60
- isError: true,
61
- };
62
- }
63
- });
64
- server.tool("get_user_journey", "Get the ordered sequence of events for a specific user. " +
65
- "Use for questions like 'what did user X do', 'show me this user's activity', " +
66
- "or 'trace a user's path through the app'. " +
67
- "To find user IDs: first call get_event_counts with group_by='anonymous_id' " +
68
- "to list anonymous user IDs, then pass one to this tool as user_id.", getUserJourneySchema, async (params) => {
69
- try {
70
- const text = await handleGetUserJourney(await getClient(), params);
71
- return { content: [{ type: "text", text }] };
72
- }
73
- catch (error) {
74
- return {
75
- content: [{ type: "text", text: formatError(error) }],
76
- isError: true,
77
- };
78
- }
79
- });
80
- server.tool("get_top_events", "List the most frequent events in a time range with counts and unique users. " +
81
- "Use for questions like 'what events are being tracked', 'what are users doing', " +
82
- "'show me all event types', or 'what's the most common action'.", getTopEventsSchema, async (params) => {
83
- try {
84
- const text = await handleGetTopEvents(await getClient(), params);
85
- return { content: [{ type: "text", text }] };
86
- }
87
- catch (error) {
88
- return {
89
- content: [{ type: "text", text: formatError(error) }],
90
- isError: true,
91
- };
92
- }
93
- });
94
- server.tool("get_insights", "Get automatically detected anomalies and notable patterns. " +
95
- "Call get_project_summary first for full context, then call this for specific alerts. " +
96
- "Returns pre-computed insights like volume drops, error spikes, milestones, " +
97
- "and new events with thread context. Insights are auto-detected hourly — no query needed.", getInsightsSchema, async (params) => {
98
- try {
99
- const text = await handleGetInsights(await getClient(), params);
100
- return { content: [{ type: "text", text }] };
101
- }
102
- catch (error) {
103
- return {
104
- content: [{ type: "text", text: formatError(error) }],
105
- isError: true,
106
- };
107
- }
108
- });
109
- server.tool("get_ontology", "View the event ontology — how events are classified into product categories " +
110
- "(activation, engagement, monetization, referral, noise) and funnel stages. " +
111
- "Use this to understand what events mean in the context of the product. " +
112
- "If empty, suggest classifying events with update_ontology.", getOntologySchema, async (params) => {
113
- try {
114
- const text = await handleGetOntology(await getClient(), params);
115
- return { content: [{ type: "text", text }] };
116
- }
117
- catch (error) {
118
- return {
119
- content: [{ type: "text", text: formatError(error) }],
120
- isError: true,
121
- };
122
- }
123
- });
124
- server.tool("update_ontology", "Classify events into product categories and funnel stages. " +
125
- "Use 'proposed' status when suggesting to the developer for confirmation, " +
126
- "'confirmed' when the developer has agreed. " +
127
- "Categories: activation (first value moment), engagement (ongoing usage), " +
128
- "monetization (revenue), referral (invites/shares), noise (high volume, low signal). " +
129
- "SDK-declared categories are automatically confirmed.", updateOntologySchema, async (params) => {
130
- try {
131
- const text = await handleUpdateOntology(await getClient(), params);
132
- return { content: [{ type: "text", text }] };
133
- }
134
- catch (error) {
135
- return {
136
- content: [{ type: "text", text: formatError(error) }],
137
- isError: true,
138
- };
139
- }
140
- });
141
- server.tool("annotate_thread", "REQUIRED after investigating any insight from get_insights. " +
142
- "Records your finding (root cause, contributing factors, resolution) into the thread. " +
143
- "This is what makes Infer compound — your annotation appears in every future session's " +
144
- "briefing and project summary. The thread_id and exact call are shown in get_insights output. " +
145
- "Skip only if the thread already has an annotation covering your finding.", annotateThreadSchema, async (params) => {
146
- try {
147
- const text = await handleAnnotateThread(await getClient(), params);
148
- return { content: [{ type: "text", text }] };
149
- }
150
- catch (error) {
151
- return {
152
- content: [{ type: "text", text: formatError(error) }],
153
- isError: true,
154
- };
155
- }
156
- });
157
- server.tool("switch_project", "Switch between Infer projects or list all configured projects. " +
158
- "Use when the user says 'switch to project X' or 'list my projects' or " +
159
- "wants to query data from a different project.", switchProjectSchema, async (params) => {
160
- try {
161
- const text = await handleSwitchProject(params);
162
- return { content: [{ type: "text", text }] };
163
- }
164
- catch (error) {
165
- return {
166
- content: [{ type: "text", text: formatError(error) }],
167
- isError: true,
168
- };
169
- }
170
- });
171
- server.tool("create_project", "Create a new Infer project from the CLI. " +
172
- "Use when the user wants to add analytics to a new codebase. " +
173
- "Requires an active session from prior signup.", createProjectSchema, async (params) => {
174
- try {
175
- const freshConfig = await loadConfig().catch(() => config);
176
- const text = await handleCreateProject(params, freshConfig.endpoint);
177
- return { content: [{ type: "text", text }] };
178
- }
179
- catch (error) {
38
+ // ─── Span inspection (3 tools) ───────────────────────────────────────────
39
+ server.tool("list_spans", "List LLM calls (spans) captured by the Infer gateway. Filter by model, user, session, " +
40
+ "tags, time window, duration, or HTTP status. Returns a paginated list with a cursor " +
41
+ "for continuation. Use this to explore recent activity or find spans matching a specific filter.", listSpansInputSchema, async (params) => wrapMcp(async () => handleListSpans(await getClient(), params)));
42
+ server.tool("get_trace", "Return all spans sharing a trace_id as a hierarchical tree (walks parent_span_id edges). " +
43
+ "Use this when an agent made multiple LLM calls in one turn and you want to see the whole turn — " +
44
+ "e.g., a multi-iteration agent that called a tool, saw the result, and called the model again.", getTraceInputSchema, async (params) => wrapMcp(async () => handleGetTrace(await getClient(), params)));
45
+ server.tool("get_span", "Return full detail for a single span — messages, tool calls, attributes, annotations. " +
46
+ "Use this after list_spans or get_trace to drill into a specific call.", getSpanInputSchema, async (params) => wrapMcp(async () => handleGetSpan(await getClient(), params)));
47
+ // ─── Aggregations (4 tools) ──────────────────────────────────────────────
48
+ server.tool("get_latency_stats", "p50/p95/p99 latency by dimension (model, user, session, or feature) over a time window. " +
49
+ "Groups with fewer than 10 samples are surfaced as warnings. Use this to diagnose slowness or " +
50
+ "compare models.", getLatencyStatsInputSchema, async (params) => wrapMcp(async () => handleGetLatencyStats(await getClient(), params)));
51
+ server.tool("get_token_usage", "Sum input/output tokens by dimension (model, user, session, feature) over a time window. " +
52
+ "Warns when any rows used tiktoken-estimated counts rather than upstream-authoritative counts.", getTokenUsageInputSchema, async (params) => wrapMcp(async () => handleGetTokenUsage(await getClient(), params)));
53
+ server.tool("get_cost_stats", "Compute cost (USD) by dimension at query time from the @inferevents/shared pricing table. " +
54
+ "Models missing from the pricing table surface as warnings with their (provider, model) name; their " +
55
+ "cost is reported as null rather than silently zero. Ollama models return $0 legitimately.", getCostStatsInputSchema, async (params) => wrapMcp(async () => handleGetCostStats(await getClient(), params)));
56
+ server.tool("get_error_spans", "List recent failures (status_code >= 400 OR stream_truncated) with aggregated error_type counts. " +
57
+ "Warns on retry storms (attempt_count > 1). Use this to diagnose an error spike.", getErrorSpansInputSchema, async (params) => wrapMcp(async () => handleGetErrorSpans(await getClient(), params)));
58
+ // ─── Annotations (2 tools) ───────────────────────────────────────────────
59
+ server.tool("annotate_span", "Attach a finding to a specific span. Use after diagnosing a single LLM call e.g., " +
60
+ "'root cause: prompt was 3x longer than baseline'. The annotation surfaces in future get_span calls.", annotateSpanInputSchema, async (params) => wrapMcp(async () => handleAnnotateSpan(await getClient(), params)));
61
+ server.tool("annotate_trace", "Attach a finding to a whole trace (multi-span agent turn). Use after diagnosing a multi-iteration " +
62
+ "turn e.g., 'upstream timeout triggered 3 retries, last attempt succeeded'. Surfaces in future " +
63
+ "get_trace calls and in the insight-threads briefing.", annotateTraceInputSchema, async (params) => wrapMcp(async () => handleAnnotateTrace(await getClient(), params)));
64
+ // ─── Insights + summary (2 adapted tools) ────────────────────────────────
65
+ server.tool("get_insights", "Auto-detected anomalies and notable patterns — latency regressions, error-rate spikes, " +
66
+ "token-consumption outliers, new models, new error types. Call get_project_summary first for full " +
67
+ "context, then this for specific alerts. Each insight includes a correlation_hint for git-log lookups.", getInsightsSchema, async (params) => wrapMcp(async () => handleGetInsights(await getClient(), params)));
68
+ server.tool("get_project_summary", "Project-level overview — model distribution, weekly spend, error rate, active anomaly threads. " +
69
+ "Compiled hourly. Call this first when starting an investigation.", getProjectSummarySchema, async () => wrapMcp(async () => handleGetProjectSummary(await getClient())));
70
+ // ─── Config helpers (2 tools) ────────────────────────────────────────────
71
+ server.tool("switch_project", "Switch between Infer projects or list available ones. Operates on the local config file, " +
72
+ "not the server.", switchProjectSchema, async (params) => wrapMcp(async () => handleSwitchProject(params)));
73
+ server.tool("create_project", "Create a new Infer project from the CLI. Requires an active auth session from `npx @inferevents/skills run infer-setup`.", createProjectSchema, async (params) => wrapMcp(async () => {
74
+ const freshConfig = await loadConfig().catch(() => config);
75
+ return handleCreateProject(params, freshConfig.endpoint);
76
+ }));
77
+ // ─── Deprecation shims (7 — retire on 2026-06-17) ────────────────────────
78
+ for (const [toolName, entry] of Object.entries(RETIRED_TOOL_SHIMS)) {
79
+ server.tool(toolName, entry.description, {}, async () => {
80
+ const out = await entry.handler();
180
81
  return {
181
- content: [{ type: "text", text: formatError(error) }],
182
- isError: true,
82
+ content: out.content.map((c) => ({ type: "text", text: c.text })),
83
+ isError: out.isError,
183
84
  };
184
- }
185
- });
186
- server.tool("get_project_summary", "Get a compiled overview of the project — health score, key metrics, event catalog, " +
187
- "funnel performance, and active insight threads. This is the analytics wiki — " +
188
- "always up to date, compiled hourly. " +
189
- "Call this first for full context, then get_insights for specific alerts.", getProjectSummarySchema, async () => {
190
- try {
191
- const text = await handleGetProjectSummary(await getClient());
192
- return { content: [{ type: "text", text }] };
193
- }
194
- catch (error) {
195
- return {
196
- content: [{ type: "text", text: formatError(error) }],
197
- isError: true,
198
- };
199
- }
200
- });
85
+ });
86
+ }
201
87
  return server;
202
88
  }
89
+ /**
90
+ * Wrap an async tool handler so a thrown error becomes a structured
91
+ * `{ content, isError: true }` MCP response rather than a transport
92
+ * fault. All active tools return a `string` (JSON-in-text) from their
93
+ * handler; we forward that as `content[0].text`.
94
+ */
95
+ async function wrapMcp(run) {
96
+ try {
97
+ const text = await run();
98
+ return { content: [{ type: "text", text }] };
99
+ }
100
+ catch (error) {
101
+ return {
102
+ content: [{ type: "text", text: formatError(error) }],
103
+ isError: true,
104
+ };
105
+ }
106
+ }
203
107
  function formatError(error) {
204
108
  if (error instanceof ApiError) {
205
- return `API Error: ${error.message}`;
109
+ return JSON.stringify({ error: "api_error", status_code: error.statusCode, message: error.message }, null, 2);
206
110
  }
207
111
  if (error instanceof Error) {
208
- return `Error: ${error.message}`;
112
+ return JSON.stringify({ error: "internal_error", message: error.message }, null, 2);
209
113
  }
210
- return `Unknown error occurred`;
114
+ return JSON.stringify({ error: "unknown_error" }, null, 2);
211
115
  }
212
116
  //# sourceMappingURL=server.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"server.js","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,sEAAsE;AACtE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,UAAU,EAAoB,MAAM,aAAa,CAAC;AAC3D,OAAO,EACL,oBAAoB,EACpB,oBAAoB,GACrB,MAAM,6BAA6B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C;YACrD,OAAO,EAAE,IAAI;SACd,CAAC;IACJ,CAAC;AACH,CAAC;AAED,SAAS,WAAW,CAAC,KAAc;IACjC,IAAI,KAAK,YAAY,QAAQ,EAAE,CAAC;QAC9B,OAAO,IAAI,CAAC,SAAS,CACnB,EAAE,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,KAAK,CAAC,UAAU,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,EAC7E,IAAI,EACJ,CAAC,CACF,CAAC;IACJ,CAAC;IACD,IAAI,KAAK,YAAY,KAAK,EAAE,CAAC;QAC3B,OAAO,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,gBAAgB,EAAE,OAAO,EAAE,KAAK,CAAC,OAAO,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;IACtF,CAAC;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,EAAE,KAAK,EAAE,eAAe,EAAE,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;AAC7D,CAAC"}
@@ -0,0 +1,34 @@
1
+ /**
2
+ * Shared result envelope for every active MCP tool. Spec §7.2.
3
+ *
4
+ * Rules:
5
+ * - `primary` is the tool-specific payload — each tool defines its own type.
6
+ * - `warnings[]` flag data-quality concerns the agent should surface (small
7
+ * sample sizes, estimated tokens, missing pricing entries, truncated streams).
8
+ * - `caveats[]` note methodology (p95 computed on N=…; 7-day baseline, etc).
9
+ * - `as_of` is the wall-clock of this query — stable anchor for agent recall.
10
+ * - `source` tells the agent where the data came from so it can reason about
11
+ * freshness and trustworthiness.
12
+ */
13
+ export type ToolResultSource = "spans" | "insights" | "annotations" | "project_summary" | "config" | "pricing_table";
14
+ export interface ToolResult<T> {
15
+ primary: T;
16
+ warnings: string[];
17
+ caveats: string[];
18
+ as_of: string;
19
+ source: ToolResultSource;
20
+ }
21
+ export declare function wrapResult<T>(input: {
22
+ primary: T;
23
+ source: ToolResultSource;
24
+ warnings?: string[];
25
+ caveats?: string[];
26
+ asOf?: string;
27
+ }): ToolResult<T>;
28
+ /**
29
+ * Serialize a result envelope as a single JSON-in-text MCP response body.
30
+ * The MCP SDK's `content[].text` is the user-visible channel; embedding
31
+ * JSON lets the agent parse structured fields deterministically.
32
+ */
33
+ export declare function toolResponseText<T>(envelope: ToolResult<T>): string;
34
+ //# sourceMappingURL=tool-result.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool-result.d.ts","sourceRoot":"","sources":["../src/tool-result.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,MAAM,MAAM,gBAAgB,GACxB,OAAO,GACP,UAAU,GACV,aAAa,GACb,iBAAiB,GACjB,QAAQ,GACR,eAAe,CAAC;AAEpB,MAAM,WAAW,UAAU,CAAC,CAAC;IAC3B,OAAO,EAAE,CAAC,CAAC;IACX,QAAQ,EAAE,MAAM,EAAE,CAAC;IACnB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,gBAAgB,CAAC;CAC1B;AAED,wBAAgB,UAAU,CAAC,CAAC,EAAE,KAAK,EAAE;IACnC,OAAO,EAAE,CAAC,CAAC;IACX,MAAM,EAAE,gBAAgB,CAAC;IACzB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,GAAG,UAAU,CAAC,CAAC,CAAC,CAQhB;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,EAAE,QAAQ,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,MAAM,CAEnE"}
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Shared result envelope for every active MCP tool. Spec §7.2.
3
+ *
4
+ * Rules:
5
+ * - `primary` is the tool-specific payload — each tool defines its own type.
6
+ * - `warnings[]` flag data-quality concerns the agent should surface (small
7
+ * sample sizes, estimated tokens, missing pricing entries, truncated streams).
8
+ * - `caveats[]` note methodology (p95 computed on N=…; 7-day baseline, etc).
9
+ * - `as_of` is the wall-clock of this query — stable anchor for agent recall.
10
+ * - `source` tells the agent where the data came from so it can reason about
11
+ * freshness and trustworthiness.
12
+ */
13
+ export function wrapResult(input) {
14
+ return {
15
+ primary: input.primary,
16
+ warnings: input.warnings ? [...input.warnings] : [],
17
+ caveats: input.caveats ? [...input.caveats] : [],
18
+ as_of: input.asOf ?? new Date().toISOString(),
19
+ source: input.source,
20
+ };
21
+ }
22
+ /**
23
+ * Serialize a result envelope as a single JSON-in-text MCP response body.
24
+ * The MCP SDK's `content[].text` is the user-visible channel; embedding
25
+ * JSON lets the agent parse structured fields deterministically.
26
+ */
27
+ export function toolResponseText(envelope) {
28
+ return JSON.stringify(envelope, null, 2);
29
+ }
30
+ //# sourceMappingURL=tool-result.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tool-result.js","sourceRoot":"","sources":["../src/tool-result.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAkBH,MAAM,UAAU,UAAU,CAAI,KAM7B;IACC,OAAO;QACL,OAAO,EAAE,KAAK,CAAC,OAAO;QACtB,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE;QACnD,OAAO,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,EAAE;QAChD,KAAK,EAAE,KAAK,CAAC,IAAI,IAAI,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE;QAC7C,MAAM,EAAE,KAAK,CAAC,MAAM;KACrB,CAAC;AACJ,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,gBAAgB,CAAI,QAAuB;IACzD,OAAO,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC;AAC3C,CAAC"}
@@ -0,0 +1,7 @@
1
+ import type { ApiClient } from "../api-client.js";
2
+ export interface AnnotateSpanParams {
3
+ span_id: string;
4
+ content: string;
5
+ }
6
+ export declare function handleAnnotateSpan(client: ApiClient, params: AnnotateSpanParams): Promise<string>;
7
+ //# sourceMappingURL=annotate-span.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"annotate-span.d.ts","sourceRoot":"","sources":["../../src/tools/annotate-span.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAGlD,MAAM,WAAW,kBAAkB;IACjC,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,kBAAkB,GACzB,OAAO,CAAC,MAAM,CAAC,CAejB"}
@@ -0,0 +1,16 @@
1
+ import { wrapResult, toolResponseText } from "../tool-result.js";
2
+ export async function handleAnnotateSpan(client, params) {
3
+ const result = await client.annotateSpan(params);
4
+ return toolResponseText(wrapResult({
5
+ primary: {
6
+ annotation_id: result.annotation_id,
7
+ span_id: params.span_id,
8
+ content: params.content,
9
+ },
10
+ source: "annotations",
11
+ caveats: [
12
+ `Annotation is scoped to the authenticated project. Future calls to get_span("${params.span_id}") will surface it.`,
13
+ ],
14
+ }));
15
+ }
16
+ //# sourceMappingURL=annotate-span.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"annotate-span.js","sourceRoot":"","sources":["../../src/tools/annotate-span.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAOjE,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,MAAiB,EACjB,MAA0B;IAE1B,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC;IACjD,OAAO,gBAAgB,CACrB,UAAU,CAAC;QACT,OAAO,EAAE;YACP,aAAa,EAAE,MAAM,CAAC,aAAa;YACnC,OAAO,EAAE,MAAM,CAAC,OAAO;YACvB,OAAO,EAAE,MAAM,CAAC,OAAO;SACxB;QACD,MAAM,EAAE,aAAa;QACrB,OAAO,EAAE;YACP,gFAAgF,MAAM,CAAC,OAAO,qBAAqB;SACpH;KACF,CAAC,CACH,CAAC;AACJ,CAAC"}
@@ -0,0 +1,7 @@
1
+ import type { ApiClient } from "../api-client.js";
2
+ export interface AnnotateTraceParams {
3
+ trace_id: string;
4
+ content: string;
5
+ }
6
+ export declare function handleAnnotateTrace(client: ApiClient, params: AnnotateTraceParams): Promise<string>;
7
+ //# sourceMappingURL=annotate-trace.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"annotate-trace.d.ts","sourceRoot":"","sources":["../../src/tools/annotate-trace.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAGlD,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,wBAAsB,mBAAmB,CACvC,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,mBAAmB,GAC1B,OAAO,CAAC,MAAM,CAAC,CAejB"}
@@ -0,0 +1,16 @@
1
+ import { wrapResult, toolResponseText } from "../tool-result.js";
2
+ export async function handleAnnotateTrace(client, params) {
3
+ const result = await client.annotateTrace(params);
4
+ return toolResponseText(wrapResult({
5
+ primary: {
6
+ annotation_id: result.annotation_id,
7
+ trace_id: params.trace_id,
8
+ content: params.content,
9
+ },
10
+ source: "annotations",
11
+ caveats: [
12
+ "Trace-level annotation — applies to the whole multi-span turn, not a single span.",
13
+ ],
14
+ }));
15
+ }
16
+ //# sourceMappingURL=annotate-trace.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"annotate-trace.js","sourceRoot":"","sources":["../../src/tools/annotate-trace.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AAOjE,MAAM,CAAC,KAAK,UAAU,mBAAmB,CACvC,MAAiB,EACjB,MAA2B;IAE3B,MAAM,MAAM,GAAG,MAAM,MAAM,CAAC,aAAa,CAAC,MAAM,CAAC,CAAC;IAClD,OAAO,gBAAgB,CACrB,UAAU,CAAC;QACT,OAAO,EAAE;YACP,aAAa,EAAE,MAAM,CAAC,aAAa;YACnC,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,OAAO,EAAE,MAAM,CAAC,OAAO;SACxB;QACD,MAAM,EAAE,aAAa;QACrB,OAAO,EAAE;YACP,mFAAmF;SACpF;KACF,CAAC,CACH,CAAC;AACJ,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"create-project.d.ts","sourceRoot":"","sources":["../../src/tools/create-project.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,mBAAmB;;;CAQ/B,CAAC;AAEF,wBAAsB,mBAAmB,CACvC,MAAM,EAAE;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,EAClD,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,MAAM,CAAC,CAoDjB"}
1
+ {"version":3,"file":"create-project.d.ts","sourceRoot":"","sources":["../../src/tools/create-project.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,mBAAmB;;;CAQ/B,CAAC;AAEF,wBAAsB,mBAAmB,CACvC,MAAM,EAAE;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAA;CAAE,EAClD,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,MAAM,CAAC,CA0FjB"}
@@ -1,5 +1,6 @@
1
1
  import { z } from "zod";
2
2
  import { addProject, readConfigFile, getSession } from "../config.js";
3
+ import { wrapResult, toolResponseText } from "../tool-result.js";
3
4
  export const createProjectSchema = {
4
5
  project_name: z
5
6
  .string()
@@ -17,7 +18,14 @@ export async function handleCreateProject(params, endpoint) {
17
18
  session = await getSession();
18
19
  }
19
20
  if (!session) {
20
- return "No session found. Sign up at https://infer.events/signup first, then run /infer-setup.";
21
+ return toolResponseText(wrapResult({
22
+ primary: {
23
+ status: "error",
24
+ error: "no_session",
25
+ message: "No session found. Sign up at https://infer.events/signup first, then run /infer-setup.",
26
+ },
27
+ source: "config",
28
+ }));
21
29
  }
22
30
  const baseUrl = config.endpoint ?? endpoint;
23
31
  // Call the API to create the project
@@ -28,13 +36,21 @@ export async function handleCreateProject(params, endpoint) {
28
36
  });
29
37
  if (!response.ok) {
30
38
  const body = await response.json().catch(() => ({}));
31
- return `Failed to create project: ${body.error ?? response.statusText}`;
39
+ return toolResponseText(wrapResult({
40
+ primary: {
41
+ status: "error",
42
+ error: "create_failed",
43
+ status_code: response.status,
44
+ message: `Failed to create project: ${body.error ?? response.statusText}`,
45
+ },
46
+ source: "config",
47
+ }));
32
48
  }
33
49
  const result = await response.json();
34
50
  // Save to config
35
51
  const slug = params.project_name.toLowerCase().replace(/[^a-z0-9]+/g, "-");
36
52
  await addProject(slug, result.read_key, result.project_id, result.write_key, true);
37
- const lines = [
53
+ const setupInstructions = [
38
54
  `Project "${result.project_name}" created and set as active.`,
39
55
  "",
40
56
  `Project ID: ${result.project_id}`,
@@ -43,9 +59,25 @@ export async function handleCreateProject(params, endpoint) {
43
59
  "",
44
60
  `Saved to ~/.infer/config.json as "${slug}" (now active).`,
45
61
  "",
46
- "Next: Install the SDK in your project with npm install @inferevents/sdk",
47
- `Then init with: init({ projectId: "${result.write_key}" })`,
48
- ];
49
- return lines.join("\n");
62
+ "Next: route your LLM traffic through the Infer gateway using the write key " +
63
+ "(pk_write_*) as your provider's API key. The read key (pk_read_*) is for MCP access.",
64
+ ].join("\n");
65
+ return toolResponseText(wrapResult({
66
+ primary: {
67
+ status: "created",
68
+ project_id: result.project_id,
69
+ project_name: result.project_name,
70
+ project_slug: slug,
71
+ read_key: result.read_key,
72
+ write_key: result.write_key,
73
+ endpoint: result.endpoint,
74
+ active: true,
75
+ setup_instructions_text: setupInstructions,
76
+ },
77
+ source: "config",
78
+ caveats: [
79
+ "Save the read_key (pk_read_*) for MCP access and the write_key (pk_write_*) for gateway BYOK calls. These are shown ONCE.",
80
+ ],
81
+ }));
50
82
  }
51
83
  //# sourceMappingURL=create-project.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"create-project.js","sourceRoot":"","sources":["../../src/tools/create-project.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAEtE,MAAM,CAAC,MAAM,mBAAmB,GAAG;IACjC,YAAY,EAAE,CAAC;SACZ,MAAM,EAAE;SACR,QAAQ,CAAC,8DAA8D,CAAC;IAC3E,OAAO,EAAE,CAAC;SACP,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,sGAAsG,CAAC;CACpH,CAAC;AAEF,MAAM,CAAC,KAAK,UAAU,mBAAmB,CACvC,MAAkD,EAClD,QAAgB;IAEhB,MAAM,MAAM,GAAG,MAAM,cAAc,EAAE,CAAC;IAEtC,+DAA+D;IAC/D,IAAI,OAAO,GAAG,MAAM,CAAC,OAAO,CAAC;IAC7B,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,OAAO,GAAG,MAAM,UAAU,EAAE,CAAC;IAC/B,CAAC;IACD,IAAI,CAAC,OAAO,EAAE,CAAC;QACb,OAAO,wFAAwF,CAAC;IAClG,CAAC;IAED,MAAM,OAAO,GAAG,MAAM,CAAC,QAAQ,IAAI,QAAQ,CAAC;IAE5C,qCAAqC;IACrC,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,GAAG,OAAO,yBAAyB,EA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AM,CAAC,YAAY;YACjC,YAAY,EAAE,IAAI;YAClB,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,SAAS,EAAE,MAAM,CAAC,SAAS;YAC3B,QAAQ,EAAE,MAAM,CAAC,QAAQ;YACzB,MAAM,EAAE,IAAI;YACZ,uBAAuB,EAAE,iBAAiB;SAC3C;QACD,MAAM,EAAE,QAAQ;QAChB,OAAO,EAAE;YACP,2HAA2H;SAC5H;KACF,CAAC,CACH,CAAC;AACJ,CAAC"}
@@ -0,0 +1,16 @@
1
+ import { type ToolHandlerResponse } from "./deprecated.js";
2
+ interface RetiredEntry {
3
+ description: string;
4
+ handler: () => Promise<ToolHandlerResponse>;
5
+ }
6
+ /**
7
+ * The 6 retired web-analytics tools. Their old registrations in server.ts
8
+ * become handlers that emit the deprecation envelope from
9
+ * `buildDeprecationShim`. After 2026-06-17 these registrations should be
10
+ * deleted outright and callers will see "unknown tool" from the MCP SDK.
11
+ *
12
+ * Spec §7.1 retired list + §8.4 60-day shim window.
13
+ */
14
+ export declare const RETIRED_TOOL_SHIMS: Record<string, RetiredEntry>;
15
+ export {};
16
+ //# sourceMappingURL=deprecated-tools.d.ts.map