@barivia/barsom-mcp 0.22.1 → 0.22.4
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/README.md +6 -3
- package/dist/index.js +1 -1
- package/dist/job_status_format.js +23 -0
- package/dist/prepare_training_prompt.js +15 -5
- package/dist/shared.js +62 -7
- package/dist/tools/account.js +16 -77
- package/dist/tools/datasets.js +20 -8
- package/dist/tools/explore_map.js +37 -18
- package/dist/tools/results.js +7 -1
- package/dist/tools/train.js +11 -4
- package/dist/tools/training_core.js +6 -1
- package/dist/tools/training_monitor.js +80 -37
- package/dist/train_submit_message.js +5 -7
- package/dist/training_monitor_curve.js +32 -0
- package/dist/ui-delivery.js +185 -0
- package/dist/views/src/views/results-explorer/index.html +16 -13
- package/dist/views/src/views/training-monitor/index.html +30 -18
- package/dist/viz_links.js +25 -0
- package/package.json +1 -1
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { getVizPort } from "./shared.js";
|
|
2
|
+
import { isFullyComplete, isTerminalJobStatus, shouldKeepPollingJob } from "./training_monitor_curve.js";
|
|
3
|
+
export { isFullyComplete, isTerminalJobStatus, shouldKeepPollingJob };
|
|
4
|
+
export function buildVizStandaloneUrl(view, jobId) {
|
|
5
|
+
const port = getVizPort();
|
|
6
|
+
if (!port)
|
|
7
|
+
return undefined;
|
|
8
|
+
return `http://localhost:${port}/viz/${view}?mode=standalone&job_id=${encodeURIComponent(jobId)}`;
|
|
9
|
+
}
|
|
10
|
+
export function monitorStandaloneLinkText(jobId) {
|
|
11
|
+
const url = buildVizStandaloneUrl("training-monitor", jobId);
|
|
12
|
+
if (!url)
|
|
13
|
+
return undefined;
|
|
14
|
+
return (`Live training monitor: [Open training monitor](${url})\n` +
|
|
15
|
+
`AGENT: surface this to the user as a clickable markdown link in your reply — do not leave it buried in tool output.\n` +
|
|
16
|
+
`This localhost port is per MCP session and goes stale if the proxy restarts — re-run training_monitor for a fresh URL, or set BARIVIA_VIZ_PORT for a persistent port. Health check: http://localhost:${getVizPort()}/api/health?job_id=${encodeURIComponent(jobId)}`);
|
|
17
|
+
}
|
|
18
|
+
export function resultsExplorerStandaloneLinkText(jobId) {
|
|
19
|
+
const url = buildVizStandaloneUrl("results-explorer", jobId);
|
|
20
|
+
if (!url)
|
|
21
|
+
return undefined;
|
|
22
|
+
return (`Interactive results explorer: [Open results explorer](${url})\n` +
|
|
23
|
+
`AGENT: surface this to the user as a clickable markdown link in your reply — do not leave it buried in tool output.\n` +
|
|
24
|
+
`This localhost port is per MCP session and goes stale if the proxy restarts — re-run results_explorer for a fresh URL, or set BARIVIA_VIZ_PORT for a persistent port.`);
|
|
25
|
+
}
|