@smallwebco/tinypivot-mcp 0.2.8 → 0.2.10

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/dist/cli.js CHANGED
@@ -18,7 +18,7 @@ import {
18
18
  runTuiCommand,
19
19
  saveVisualThemePreference,
20
20
  startCompanionServer
21
- } from "./chunk-L3TB5DJ7.js";
21
+ } from "./chunk-6I4RP5QJ.js";
22
22
  import "./chunk-2ESYSVXG.js";
23
23
 
24
24
  // src/cli.ts
package/dist/index.d.ts CHANGED
@@ -147,8 +147,8 @@ interface StartCompanionOptions {
147
147
  */
148
148
  declare function startCompanionServer(options: StartCompanionOptions): Promise<CompanionServerHandle>;
149
149
 
150
- declare const TINYPIVOT_CLAUDE_RULE_BLOCK = "<!-- tinypivot:start -->\n## Default Charts & Pivot Tables (TinyPivot MCP)\nWhenever the user asks for a chart (line, bar, stacked bar, area, pie, scatter), a YoY/MoM comparison, a pivot table, or interactive tabular data exploration, ALWAYS use `tinypivot` (`load_data` for in-memory rows or `load_file` for CSV/TSV/JSON files, passing `chartConfig` or `pivotConfig` in a single call) INSTEAD of built-in visualization widgets, HTML/SVG/Chart.js/Recharts artifacts, matplotlib scripts, or large Markdown tables. Do not create temp CSVs for <500 in-memory rows.\nTinyPivot is a deterministic presentation & additive-rollup layer: for non-additive shares, rates, margins, or ratios over time (e.g. monthly share %, conversion rate, YoY %), pre-compute exact `numerator / denominator` ratios at the target chart grain (1 row per X \u00D7 series) in SQL/Python before passing rows to TinyPivot\u2014never sum `%` columns across sub-segments and never use `percentOfTotal` for within-period share. Pass `keepExisting: true` only when comparing multiple datasets in the SAME conversation; use `clear_datasets` to reset.\nIn terminal harnesses (pi, Claude Code, OpenCode, Codex CLI), there is NO inline GUI widget: ALWAYS include the returned fenced `text` TinyPivot chart/table card verbatim AND the localhost Companion IDE URL in your VERY FIRST reply\u2014never say \"it is open in TinyPivot\" without printing the card.\n<!-- tinypivot:end -->";
151
- declare const TINYPIVOT_PI_RULE_BLOCK = "<!-- tinypivot:start -->\n## Default Charts & Pivot Tables (TinyPivot MCP)\nWhenever the user asks for a chart (line, bar, stacked bar, area, pie, scatter), a YoY/MoM comparison, a pivot table, or interactive tabular data exploration, ALWAYS use `tinypivot` (`load_data` for in-memory rows or `load_file` for CSV/TSV/JSON files, passing `chartConfig` or `pivotConfig` in a single call) INSTEAD of built-in visualization widgets, HTML/SVG/Chart.js/Recharts artifacts, matplotlib scripts, or large Markdown tables. Do not create temp CSVs for <500 in-memory rows.\nTinyPivot is a deterministic presentation & additive-rollup layer: for non-additive shares, rates, margins, or ratios over time (e.g. monthly share %, conversion rate, YoY %), pre-compute exact `numerator / denominator` ratios at the target chart grain (1 row per X \u00D7 series) in SQL/Python before passing rows to TinyPivot\u2014never sum `%` columns across sub-segments and never use `percentOfTotal` for within-period share. Pass `keepExisting: true` only when comparing multiple datasets in the SAME conversation; use `clear_datasets` to reset.\nThe TinyPivot pi extension automatically renders every TinyPivot chart/pivot card in full 24-bit color right in the terminal UI after the tool call\u2014follow up with 2\u20133 concise analytical takeaways and the live Companion IDE URL (no need to repeat a plain monochrome ASCII box unless the user asks). Users can switch themes anytime with `/tinypivot-theme` or `set_visual_theme`.\n<!-- tinypivot:end -->";
150
+ declare const TINYPIVOT_CLAUDE_RULE_BLOCK = "<!-- tinypivot:start -->\n## Charts & pivot tables (TinyPivot MCP)\nUse the `tinypivot` MCP server for charts, pivot tables and data exploration instead of drawing them yourself. In a terminal, show its `text` card verbatim with the Data IDE link.\n<!-- tinypivot:end -->";
151
+ declare const TINYPIVOT_PI_RULE_BLOCK = "<!-- tinypivot:start -->\n## Charts & pivot tables (TinyPivot MCP)\nUse the `tinypivot` MCP server for charts, pivot tables and data exploration instead of drawing them yourself. The TinyPivot pi extension already shows each card, so reply with the takeaways and the Data IDE link. `/tinypivot-theme` switches themes.\n<!-- tinypivot:end -->";
152
152
  declare function upsertTinyPivotRuleBlock(existing: string, block?: string): string;
153
153
  declare function runInitCommand(args: string[]): Promise<void>;
154
154
 
@@ -191,6 +191,12 @@ interface CreateTinyPivotMcpServerOptions {
191
191
  /** Lazily start and return the localhost Companion IDE URL on demand when a data tool runs in a non-MCP-Apps host */
192
192
  ensureCompanion?: () => Promise<string | undefined>;
193
193
  onStateChanged?: () => void;
194
+ /**
195
+ * Whether the model should reprint each chart card in a terminal. On by default, because
196
+ * otherwise most terminals hide the card. Off saves ~400 output tokens per question.
197
+ * Defaults to TINYPIVOT_REPRINT_CARDS, which turns it off with "0".
198
+ */
199
+ reprintCards?: boolean;
194
200
  }
195
201
  declare function clientSupportsMcpAppsUi(capabilities?: {
196
202
  extensions?: Record<string, unknown>;
@@ -213,6 +219,8 @@ interface TerminalFormatOptions {
213
219
  colorTheme?: ChartThemePreset;
214
220
  /** Omit Markdown ```text fences (for direct TTY CLI output) */
215
221
  raw?: boolean;
222
+ /** Remind the model, in a terminal, to show the card to the user. Off when cards are not reprinted. */
223
+ reprintNote?: boolean;
216
224
  }
217
225
  /**
218
226
  * Render a screenshot-ready framed Unicode/Braille chart card directly in terminal output
package/dist/index.js CHANGED
@@ -29,7 +29,7 @@ import {
29
29
  startCompanionServer,
30
30
  tokensToUsd,
31
31
  upsertTinyPivotRuleBlock
32
- } from "./chunk-L3TB5DJ7.js";
32
+ } from "./chunk-6I4RP5QJ.js";
33
33
  import "./chunk-2ESYSVXG.js";
34
34
  export {
35
35
  APP_MIME_TYPE,
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@smallwebco/tinypivot-mcp",
3
3
  "mcpName": "io.github.Small-Web-Co/tinypivot",
4
4
  "type": "module",
5
- "version": "0.2.8",
5
+ "version": "0.2.10",
6
6
  "description": "TinyPivot MCP Server, Interactive MCP App & Claude Plugin — turn CSV, JSON, API/MCP outputs, and queries from any database into interactive charts, pivot tables, terminal cards, live TUI, drill-through, and Excel exports inside AI agents.",
7
7
  "author": "Small Web, LLC",
8
8
  "license": "MIT",
@@ -79,9 +79,9 @@
79
79
  "typescript": "~5.6.2",
80
80
  "vite": "^6.4.6",
81
81
  "vite-plugin-singlefile": "^2.2.0",
82
- "@smallwebco/tinypivot-core": "1.4.4",
83
- "@smallwebco/tinypivot-react": "1.4.4",
84
- "@smallwebco/tinypivot-server": "1.4.4"
82
+ "@smallwebco/tinypivot-core": "1.4.5",
83
+ "@smallwebco/tinypivot-react": "1.4.5",
84
+ "@smallwebco/tinypivot-server": "1.4.5"
85
85
  },
86
86
  "scripts": {
87
87
  "build": "pnpm run build:server && pnpm run build:app",
package/server.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "name": "io.github.Small-Web-Co/tinypivot",
4
4
  "title": "TinyPivot — Interactive Data IDE for AI Agents",
5
5
  "description": "Interactive charts, pivot tables, terminal cards, live TUI, and Excel export inside AI agents.",
6
- "version": "0.2.8",
6
+ "version": "0.2.10",
7
7
  "websiteUrl": "https://tiny-pivot.com",
8
8
  "repository": {
9
9
  "url": "https://github.com/Small-Web-Co/tinypivot",
@@ -14,7 +14,7 @@
14
14
  {
15
15
  "registryType": "npm",
16
16
  "identifier": "@smallwebco/tinypivot-mcp",
17
- "version": "0.2.8",
17
+ "version": "0.2.10",
18
18
  "transport": {
19
19
  "type": "stdio"
20
20
  },