@tonyclaw/llm-inspector 1.7.2 → 1.7.3

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.
@@ -1,5 +1,5 @@
1
1
  {
2
- "date": "2026-06-03T09:30:25.048Z",
2
+ "date": "2026-06-03T09:45:59.559Z",
3
3
  "preset": "node-server",
4
4
  "framework": {
5
5
  "name": "nitro",
@@ -1,5 +1,5 @@
1
1
  import { r as reactExports, j as jsxRuntimeExports, a as React } from "../_libs/react.mjs";
2
- import { C as CapturedLogSchema, a as parseRequest, p as parseOpenAIResponse, I as InspectorResponseSchema } from "./router-D7g2K6y6.mjs";
2
+ import { C as CapturedLogSchema, a as parseRequest, p as parseOpenAIResponse, I as InspectorResponseSchema } from "./router-BWDeDWmr.mjs";
3
3
  import { u as useVirtualizer } from "../_libs/tanstack__react-virtual.mjs";
4
4
  import { J as JSZip } from "../_libs/jszip.mjs";
5
5
  import { c as clsx } from "../_libs/clsx.mjs";
@@ -766,7 +766,7 @@ let entriesPromise;
766
766
  let baseManifestPromise;
767
767
  let cachedFinalManifestPromise;
768
768
  async function loadEntries() {
769
- const routerEntry = await import("./router-D7g2K6y6.mjs").then((n) => n.r);
769
+ const routerEntry = await import("./router-BWDeDWmr.mjs").then((n) => n.r);
770
770
  const startEntry = await import("./start-HYkvq4Ni.mjs");
771
771
  return { startEntry, routerEntry };
772
772
  }
@@ -65,7 +65,7 @@ function RootDocument({ children }) {
65
65
  ] })
66
66
  ] });
67
67
  }
68
- const $$splitComponentImporter = () => import("./index-BZkxgx8f.mjs");
68
+ const $$splitComponentImporter = () => import("./index-D0iGQ1Zd.mjs");
69
69
  const Route$d = createFileRoute("/")({
70
70
  component: lazyRouteComponent($$splitComponentImporter, "component")
71
71
  });
@@ -1417,11 +1417,13 @@ function migrateProviders() {
1417
1417
  }
1418
1418
  const oldAnthropicBaseUrl = getOldUrl(p, "anthropicBaseUrl");
1419
1419
  const oldOpenaiBaseUrl = getOldUrl(p, "openaiBaseUrl");
1420
- if (p.format !== void 0 && oldAnthropicBaseUrl === "" && oldOpenaiBaseUrl === "") {
1420
+ const currentAnthropicUrl = p.anthropicBaseUrl ?? "";
1421
+ const currentOpenaiUrl = p.openaiBaseUrl ?? "";
1422
+ if (p.format !== void 0 && (currentAnthropicUrl !== "" || currentOpenaiUrl !== "")) {
1421
1423
  return p;
1422
1424
  }
1423
- const newAnthropicUrl = oldAnthropicBaseUrl !== "" ? oldAnthropicBaseUrl : p.anthropicBaseUrl ?? "";
1424
- const newOpenaiUrl = oldOpenaiBaseUrl !== "" ? oldOpenaiBaseUrl : p.openaiBaseUrl ?? "";
1425
+ const newAnthropicUrl = oldAnthropicBaseUrl !== "" ? oldAnthropicBaseUrl : currentAnthropicUrl;
1426
+ const newOpenaiUrl = oldOpenaiBaseUrl !== "" ? oldOpenaiBaseUrl : currentOpenaiUrl;
1425
1427
  let format;
1426
1428
  let baseUrl;
1427
1429
  if (newAnthropicUrl !== "" && newOpenaiUrl !== "") {
@@ -1433,6 +1435,14 @@ function migrateProviders() {
1433
1435
  } else if (newAnthropicUrl !== "") {
1434
1436
  format = "anthropic";
1435
1437
  baseUrl = newAnthropicUrl;
1438
+ } else if (p.format !== void 0 && p.baseUrl !== void 0 && p.baseUrl !== "") {
1439
+ format = p.format;
1440
+ baseUrl = p.baseUrl;
1441
+ if (format === "openai") {
1442
+ return { ...p, format, baseUrl, anthropicBaseUrl: "", openaiBaseUrl: p.baseUrl };
1443
+ } else {
1444
+ return { ...p, format, baseUrl, anthropicBaseUrl: p.baseUrl, openaiBaseUrl: "" };
1445
+ }
1436
1446
  }
1437
1447
  migrated = true;
1438
1448
  return {
@@ -100,49 +100,49 @@ const assets = {
100
100
  "/assets/alibaba-TTwafVwX.svg": {
101
101
  "type": "image/svg+xml",
102
102
  "etag": '"171b-6dyV5K8QjiaY35sN9qNprh9zDIs"',
103
- "mtime": "2026-06-03T09:30:18.865Z",
103
+ "mtime": "2026-06-03T09:45:53.063Z",
104
104
  "size": 5915,
105
105
  "path": "../public/assets/alibaba-TTwafVwX.svg"
106
106
  },
107
- "/assets/index-B3RwBPLW.css": {
108
- "type": "text/css; charset=utf-8",
109
- "etag": '"10c74-aXacU4DRFVsUwcC5jHnjoPRSlTA"',
110
- "mtime": "2026-06-03T09:30:18.865Z",
111
- "size": 68724,
112
- "path": "../public/assets/index-B3RwBPLW.css"
113
- },
114
107
  "/assets/minimax-BPMzvuL-.jpeg": {
115
108
  "type": "image/jpeg",
116
109
  "etag": '"1b06-IwivU89ko5UTMUM1/t7hn4sQK9A"',
117
- "mtime": "2026-06-03T09:30:18.865Z",
110
+ "mtime": "2026-06-03T09:45:53.065Z",
118
111
  "size": 6918,
119
112
  "path": "../public/assets/minimax-BPMzvuL-.jpeg"
120
113
  },
114
+ "/assets/index-B3RwBPLW.css": {
115
+ "type": "text/css; charset=utf-8",
116
+ "etag": '"10c74-aXacU4DRFVsUwcC5jHnjoPRSlTA"',
117
+ "mtime": "2026-06-03T09:45:53.063Z",
118
+ "size": 68724,
119
+ "path": "../public/assets/index-B3RwBPLW.css"
120
+ },
121
121
  "/assets/zhipuai-BPNAnxo-.svg": {
122
122
  "type": "image/svg+xml",
123
123
  "etag": '"2bf8-hNaLCTi89nOFCsIIfWpP/jrfo0s"',
124
- "mtime": "2026-06-03T09:30:18.862Z",
124
+ "mtime": "2026-06-03T09:45:53.063Z",
125
125
  "size": 11256,
126
126
  "path": "../public/assets/zhipuai-BPNAnxo-.svg"
127
127
  },
128
- "/assets/main-CpIX1ZHy.js": {
129
- "type": "text/javascript; charset=utf-8",
130
- "etag": '"4db57-PIyiLXQGvlFJuizUFXRhGOYXJwY"',
131
- "mtime": "2026-06-03T09:30:18.865Z",
132
- "size": 318295,
133
- "path": "../public/assets/main-CpIX1ZHy.js"
134
- },
135
128
  "/assets/qwen-CONDcHqt.png": {
136
129
  "type": "image/png",
137
130
  "etag": '"572c3-cdJAPaHdOvFCGzuaQjagdgOu6XE"',
138
- "mtime": "2026-06-03T09:30:18.865Z",
131
+ "mtime": "2026-06-03T09:45:53.065Z",
139
132
  "size": 357059,
140
133
  "path": "../public/assets/qwen-CONDcHqt.png"
141
134
  },
135
+ "/assets/main-CpIX1ZHy.js": {
136
+ "type": "text/javascript; charset=utf-8",
137
+ "etag": '"4db57-PIyiLXQGvlFJuizUFXRhGOYXJwY"',
138
+ "mtime": "2026-06-03T09:45:53.065Z",
139
+ "size": 318295,
140
+ "path": "../public/assets/main-CpIX1ZHy.js"
141
+ },
142
142
  "/assets/index-Bf_WGooQ.js": {
143
143
  "type": "text/javascript; charset=utf-8",
144
144
  "etag": '"831df-gmdpd1CCnM4IdaxHIs9uyMgWFaY"',
145
- "mtime": "2026-06-03T09:30:18.865Z",
145
+ "mtime": "2026-06-03T09:45:53.065Z",
146
146
  "size": 537055,
147
147
  "path": "../public/assets/index-Bf_WGooQ.js"
148
148
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tonyclaw/llm-inspector",
3
- "version": "1.7.2",
3
+ "version": "1.7.3",
4
4
  "type": "module",
5
5
  "description": "LLM API proxy inspector — captures and displays requests/responses from AI coding tools in a web UI",
6
6
  "license": "MIT",
@@ -7,7 +7,6 @@ import {
7
7
  Trash2,
8
8
  RotateCw,
9
9
  CheckCircle,
10
- XCircle,
11
10
  Minus,
12
11
  ExternalLink,
13
12
  AlertCircle,
@@ -60,16 +60,17 @@ function migrateProviders(): void {
60
60
 
61
61
  const oldAnthropicBaseUrl = getOldUrl(p, "anthropicBaseUrl");
62
62
  const oldOpenaiBaseUrl = getOldUrl(p, "openaiBaseUrl");
63
+ const currentAnthropicUrl = p.anthropicBaseUrl ?? "";
64
+ const currentOpenaiUrl = p.openaiBaseUrl ?? "";
63
65
 
64
- // If already migrated (has format field and both URLs), skip
65
- if (p.format !== undefined && oldAnthropicBaseUrl === "" && oldOpenaiBaseUrl === "") {
66
+ // If already migrated (has format field and at least one URL), skip
67
+ if (p.format !== undefined && (currentAnthropicUrl !== "" || currentOpenaiUrl !== "")) {
66
68
  return p;
67
69
  }
68
70
 
69
71
  // Preserve both URLs
70
- const newAnthropicUrl =
71
- oldAnthropicBaseUrl !== "" ? oldAnthropicBaseUrl : (p.anthropicBaseUrl ?? "");
72
- const newOpenaiUrl = oldOpenaiBaseUrl !== "" ? oldOpenaiBaseUrl : (p.openaiBaseUrl ?? "");
72
+ const newAnthropicUrl = oldAnthropicBaseUrl !== "" ? oldAnthropicBaseUrl : currentAnthropicUrl;
73
+ const newOpenaiUrl = oldOpenaiBaseUrl !== "" ? oldOpenaiBaseUrl : currentOpenaiUrl;
73
74
 
74
75
  // Determine primary format based on which URL is set
75
76
  let format: "anthropic" | "openai" | undefined;
@@ -85,6 +86,15 @@ function migrateProviders(): void {
85
86
  } else if (newAnthropicUrl !== "") {
86
87
  format = "anthropic";
87
88
  baseUrl = newAnthropicUrl;
89
+ } else if (p.format !== undefined && p.baseUrl !== undefined && p.baseUrl !== "") {
90
+ // Only baseUrl is set (legacy config) - migrate based on format
91
+ format = p.format;
92
+ baseUrl = p.baseUrl;
93
+ if (format === "openai") {
94
+ return { ...p, format, baseUrl, anthropicBaseUrl: "", openaiBaseUrl: p.baseUrl };
95
+ } else {
96
+ return { ...p, format, baseUrl, anthropicBaseUrl: p.baseUrl, openaiBaseUrl: "" };
97
+ }
88
98
  }
89
99
 
90
100
  migrated = true;