@bicharts/chart-mcp 0.5.106 → 0.5.108

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 CHANGED
@@ -54,6 +54,7 @@ only render text); `structuredContent` is for code, so nothing has to string-par
54
54
  | `geo` / `geoPoint` | region/basemap wiring, and how many points actually placed |
55
55
  | `data` **or** `files` | the render payload inline, **or** the paths written — never both |
56
56
  | `hostContract`, `build` | the contract the code targets, and the bundle that served the call |
57
+ | `recoveredAfterMs` | present only when the response stream was cut and the chart was fetched back by its correlation: milliseconds from the start of the call to delivery. `creditCost` is null then |
57
58
 
58
59
  `data` carries the appended `__geoIso__` / `__geoLat__` / `__geoLon__` columns, which a caller
59
60
  cannot reconstruct from the source data — so a geo chart needs either it or `files.data`.
@@ -134,6 +135,7 @@ Two ways to supply them — env wins over the file:
134
135
  | `BIC_URL` | override backend (default `https://bizintelligencechampions.com`) |
135
136
  | `BIC_MCP_REASONING` | OPTIONAL override of the default reasoning mode (else `""` = leave-to-visual, same as the PBI visual) |
136
137
  | `BIC_MCP_MODEL` | OPTIONAL override of the default model (else `""` = the account's IsDefault model, same as the visual) |
138
+ | `BIC_MCP_TIMEOUT_MS` | OPTIONAL: how long one `generate_chart` call waits, recovery included (default `900000`, 15 minutes) |
137
139
 
138
140
  **Defaults match the Power BI visual.** Unset, the MCP sends `model=""` (server
139
141
  resolves the `IsDefault` model), `reasoning_mode=""` (leave-to-visual heuristic), and
@@ -156,8 +158,13 @@ needs**:
156
158
  - Fallback for hosts that don't reset on progress: raise the host's per-tool
157
159
  timeout (Claude Code: `MCP_TOOL_TIMEOUT` in ms, set in the environment Claude
158
160
  Code itself runs in — e.g. the `env` block of `settings.json`).
159
- - (Planned) retrieve an already-generated result by `correlationId` so a dropped
160
- connection recovers the billed code instead of re-generating.
161
+ - **Built in:** when the response stream is cut *after* the server accepted the
162
+ request, the MCP does not give up or re-generate. Inside the same tool call it
163
+ checks for the finished chart by its `correlationId` (a fetch that can never call a
164
+ model), backing off between checks, until the chart arrives or the recovery window
165
+ or `BIC_MCP_TIMEOUT_MS` runs out, whichever is sooner. A recovered chart carries
166
+ `recoveredAfterMs`; when nothing arrives, the error keeps the `correlationId` to
167
+ quote to support.
161
168
 
162
169
  `BIC_MCP_REASONING=CP`/`1P` *would* finish faster, but that trades away visual parity
163
170
  (no validator) — prefer raising the timeout.