You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The final assistant response must include the printed URL.
154
154
155
-
If the SDK-generated URL is not available, fall back to the generic MCP permalink workflow described in the agent task (Step 5).
155
+
If the SDK-generated URL is not available, construct the permalink manually using the URL format documented in `braintrust-url-formats.md` as described in the agent task (Step 5).
- Confirm the app still runs if `BRAINTRUST_API_KEY` is unset.
92
94
93
-
If you do not know how to run the app, ask the user.
95
+
If you do not know how to run the app, ask the user and wait for the response before proceeding.
94
96
95
97
---
96
98
97
99
### 5. Verify in Braintrust (CRITICAL)
98
100
99
-
Using the Braintrust MCP (preferred):
101
+
The permalink must be included in the final output. This confirms the full installation succeeded.
100
102
101
-
1. Query for the emitted logs/traces.
102
-
2. Generate a **permalink to the data**.
103
-
3. Print the permalink clearly.
103
+
The project must be set in code during installation — do not guess the project name from context.
104
104
105
-
The permalink must be included in the final output.
106
-
This confirms the full installation succeeded.
105
+
**How to obtain the permalink:**
107
106
108
-
Notes:
107
+
Most language SDKs print a direct URL to the emitted trace after the app runs. Capture that URL and print it.
109
108
110
-
- The agent must not "guess" the project from Braintrust UI. The project must be set in code during installation.
111
-
- If a language SDK provides a deterministic URL to the emitted trace/log (e.g. a `/logs?r=<traceId>&s=<spanId>` link), it is acceptable to print that as the permalink, but it still must point to the specific emitted data.
109
+
If the SDK does not print a URL, construct one manually using the URL format documented in `{SDK_INSTALL_DIR}/braintrust-url-formats.md`:
112
110
113
-
Minimal MCP workflow to generate a permalink (use this if the SDK does not provide a deterministic URL):
1. Resolve the project ID using the project name that was configured in code:
116
-
- Call `resolve_object` with `object_type="project_logs"` and `project_name=<your project name>`
117
-
2. Find the newest emitted row in that project:
118
-
- Call `sql_query` with `object_type="project_logs"`, `object_ids=[<project id>]`, and a time filter, e.g. `created > now() - interval 1 hour`, ordered by `created DESC`, `limit 1`
119
-
3. Generate a permalink to that row:
120
-
- Call `generate_permalink` with `object_type="project_logs"`, `object_id=<project id>`, `row_id=<row id from sql_query>`
115
+
-`org`: your Braintrust organization slug
116
+
-`project_name`: the project name set in code
117
+
-`root_span_id`: the trace/span ID returned or logged by the SDK
0 commit comments