getcompetitive 4.2.0 → 4.3.0

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
@@ -18,6 +18,7 @@ Smogon-tier and archetype surface that used to sit alongside it is gone.
18
18
  ## What it provides
19
19
 
20
20
  - **26 tools** across six domains: data, team analysis, team workflows (paste in, diagnose, prepare matchups), meta (usage-derived), battle mechanics, and official regulation sets
21
+ - **Six workflow prompts** — `/team-doctor`, `/matchup-prep`, `/build-around`, `/tournament-prep`, `/learn-my-team`, `/meta-report` — server-provided templates that chain the deterministic tools, so compound workflows stay discoverable without a 40-tool surface
21
22
  - **Structured, agent-first definitions** — every tool declares MCP annotations and an output schema, returns `structuredContent` alongside JSON text, and documents all of its parameters; the deterministic half of the [TDQS](https://tdqs.dev) checklist is linted in CI
22
23
  - Full **Pokémon Showdown** dataset — species, alternate forms, stats, moves, items, abilities, natures, learnsets, types
23
24
  - **Battle math** from Smogon's calculator — stat calculation and full damage calculation (weather, terrain, boosts, items)
@@ -137,10 +138,39 @@ With Docker (after `docker build -t getcompetitive .`):
137
138
  For Claude Desktop, add one of the same entries under `mcpServers` in
138
139
  `claude_desktop_config.json`.
139
140
 
141
+ ## Remote endpoint
142
+
143
+ The same surface runs over Streamable HTTP — the stateless remote mode, one
144
+ request per transport, safe behind a load balancer:
145
+
146
+ ```bash
147
+ node dist/http-server.js # http://127.0.0.1:3000/mcp
148
+ PORT=8080 node dist/http-server.js
149
+ ```
150
+
151
+ Connect a client with the URL `http://<host>:<port>/mcp`. TLS, auth and rate
152
+ limiting are the deployer's concern: the server itself remains a pure offline
153
+ read.
154
+
155
+ ## Workflow prompts
156
+
157
+ Six server-provided prompts make the compound workflows discoverable without
158
+ adding a tool per workflow — each chains the deterministic tools, and each
159
+ follows the same doctrine: the model explains, getcompetitive proves.
160
+
161
+ | Prompt | What it chains |
162
+ | --- | --- |
163
+ | `/team-doctor` | `parse_team` → `diagnose_team` → `format_team` ("fix my team") |
164
+ | `/matchup-prep` | `parse_team` → `prepare_matchup` ("here is my opponent") |
165
+ | `/build-around` | `get_set` → `analyze_team` → `diagnose_team` → `check_legality` → `format_team` |
166
+ | `/tournament-prep` | `get_regulation` → `list_threats` → `get_set` (a pre-event briefing) |
167
+ | `/learn-my-team` | `parse_team` → `analyze_team` → `diagnose_team` → `get_set` (a team guide) |
168
+ | `/meta-report` | `list_threats` → `get_set` on the top five (a data-dated meta report) |
169
+
140
170
  ## Verify
141
171
 
142
172
  ```bash
143
- npm test # builds and drives every tool over real MCP stdio
173
+ npm test # builds and drives every tool over real MCP stdio, plus the HTTP entrypoint
144
174
  ```
145
175
 
146
176
  ## Example queries
@@ -0,0 +1,47 @@
1
+ #!/usr/bin/env node
2
+ /**
3
+ * getcompetitive — MCP server over Streamable HTTP: the remote-endpoint mode.
4
+ *
5
+ * node dist/http-server.js # defaults to port 3000, host 127.0.0.1
6
+ * PORT=8080 node dist/http-server.js
7
+ *
8
+ * Connect any MCP client to http://<host>:<port>/mcp. This is the same
9
+ * transport-agnostic server as the stdio entrypoint — identical tools and
10
+ * prompts. It runs in stateless mode, the shape the SDK recommends for remote
11
+ * deployments: each request gets a fresh transport (stateless transports are
12
+ * single-request by design, so reusing one would collide on message ids), no
13
+ * session state is kept, and the whole thing can sit behind a load balancer.
14
+ * Deployment concerns — TLS, auth, rate limits, hosting — are deliberately left
15
+ * to whoever runs it: the server itself stays a pure offline read.
16
+ */
17
+ import http from 'node:http';
18
+ import { StreamableHTTPServerTransport } from '@modelcontextprotocol/sdk/server/streamableHttp.js';
19
+ import { buildServer } from './server.js';
20
+ const port = Number(process.env.PORT ?? 3000);
21
+ const host = process.env.HOST ?? '127.0.0.1';
22
+ const httpServer = http.createServer((req, res) => {
23
+ void (async () => {
24
+ // Stateless: a fresh server+transport per request, per the SDK's contract
25
+ // that a stateless transport handles exactly one request.
26
+ const server = buildServer();
27
+ const transport = new StreamableHTTPServerTransport({ sessionIdGenerator: undefined });
28
+ await server.connect(transport);
29
+ await transport.handleRequest(req, res);
30
+ })().catch((e) => {
31
+ console.error('MCP request failed:', e instanceof Error ? e.message : e);
32
+ if (!res.headersSent) {
33
+ res.writeHead(500, { 'content-type': 'application/json' });
34
+ res.end(JSON.stringify({ jsonrpc: '2.0', error: { code: -32603, message: 'Internal error' } }));
35
+ }
36
+ });
37
+ });
38
+ httpServer.listen(port, host, () => {
39
+ console.error(`getcompetitive MCP server listening on http://${host}:${port}/mcp (stateless)`);
40
+ });
41
+ process.on('SIGINT', () => {
42
+ httpServer.close(() => process.exit(0));
43
+ });
44
+ process.on('SIGTERM', () => {
45
+ httpServer.close(() => process.exit(0));
46
+ });
47
+ //# sourceMappingURL=http-server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"http-server.js","sourceRoot":"","sources":["../src/http-server.ts"],"names":[],"mappings":";AACA;;;;;;;;;;;;;;GAcG;AACH,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,6BAA6B,EAAE,MAAM,oDAAoD,CAAC;AACnG,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,IAAI,GAAG,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC;AAC9C,MAAM,IAAI,GAAG,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,WAAW,CAAC;AAE7C,MAAM,UAAU,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,EAAE;IAChD,KAAK,CAAC,KAAK,IAAI,EAAE;QACf,0EAA0E;QAC1E,0DAA0D;QAC1D,MAAM,MAAM,GAAG,WAAW,EAAE,CAAC;QAC7B,MAAM,SAAS,GAAG,IAAI,6BAA6B,CAAC,EAAE,kBAAkB,EAAE,SAAS,EAAE,CAAC,CAAC;QACvF,MAAM,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC;QAChC,MAAM,SAAS,CAAC,aAAa,CAAC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
+ * getcompetitive — MCP server for the Pokémon Champions meta, over stdio.
4
4
  *
5
5
  * Champions is the only game here, so the surface is scoped to it: the official
6
6
  * regulation sets, the usage-derived threat list, and the data lookups and
7
7
  * battle math a team needs — all in the game's own terms (doubles, level 50,
8
8
  * 66 stat points, no Terastallization).
9
9
  */
10
- import { readFileSync } from 'node:fs';
11
- import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
12
10
  import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';
13
- import { registerDataTools } from './tools/data.js';
14
- import { registerCalcTools } from './tools/calc.js';
15
- import { registerRegulationTools } from './tools/regulations.js';
16
- import { registerAnalyzeTools } from './tools/analyze.js';
17
- import { registerMetaTools } from './tools/meta.js';
18
- import { registerTeamTools } from './tools/team.js';
19
- import { registerDoctorTool } from './tools/doctor.js';
20
- import { registerMatchupTool } from './tools/matchup.js';
21
- import { registerSpritesTool } from './tools/sprites.js';
22
- const { version } = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8'));
23
- const server = new McpServer({
24
- name: 'getcompetitive',
25
- version,
26
- });
27
- registerDataTools(server);
28
- registerCalcTools(server);
29
- registerRegulationTools(server);
30
- registerAnalyzeTools(server);
31
- registerMetaTools(server);
32
- registerTeamTools(server);
33
- registerDoctorTool(server);
34
- registerMatchupTool(server);
35
- registerSpritesTool(server);
11
+ import { buildServer } from './server.js';
12
+ const server = buildServer();
36
13
  await server.connect(new StdioServerTransport());
37
14
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AACA;;;;;;;GAOG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,iBAAiB,EAAE,MAAM,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BAAoB,EAAE,MAAM,2CAA2C,CAAC;AACjF,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,MAAM,GAAG,WAAW,EAAE,CAAC;AAC7B,MAAM,MAAM,CAAC,OAAO,CAAC,IAAI,oBAAoB,EAAE,CAAC,CAAC"}
@@ -0,0 +1,175 @@
1
+ /**
2
+ * Server-provided workflow prompts: discoverable recipes that chain the
3
+ * deterministic tools, instead of a tool per workflow (which would push the
4
+ * surface toward forty names). Prompts are static text templates — no I/O, the
5
+ * same purity as the tools — and they all follow one doctrine: the model
6
+ * explains, getcompetitive proves, so every number in an answer must come from
7
+ * a tool's output.
8
+ */
9
+ import { z } from 'zod';
10
+ const regulationArg = z
11
+ .string()
12
+ .optional()
13
+ .describe('Regulation id to work under, e.g. "m-c"; omitted, the workflow uses the current set.');
14
+ const teamArg = z
15
+ .string()
16
+ .optional()
17
+ .describe('The team as paste text (Showdown format, or plain lines); omitted, the workflow asks for it.');
18
+ const goalArg = z.string().optional().describe('What the player wants out of the change, carried into diagnose_team.');
19
+ export function registerPrompts(server) {
20
+ server.registerPrompt('team-doctor', {
21
+ title: 'Team Doctor',
22
+ description: 'Diagnose a team against the meta and prescribe evidence-backed changes. "Here is my team — fix it."',
23
+ argsSchema: { team: teamArg, regulation: regulationArg, goal: goalArg },
24
+ }, async (args) => ({
25
+ messages: [
26
+ {
27
+ role: 'user',
28
+ content: {
29
+ type: 'text',
30
+ text: `Act as a Pokémon Champions team coach. The user wants their team diagnosed and improved under ${args.regulation ?? 'the current regulation set'}${args.goal ? `, with the goal: ${args.goal}` : ''}.
31
+
32
+ ${args.team ? `Their team (paste text):\n\n${args.team}\n` : 'Ask the user to paste their team first.'}
33
+
34
+ Then, in order:
35
+ 1. Run parse_team on the paste (with the regulation) and surface every warning it returns — a name that did not resolve is a fixable typo, not a dead end.
36
+ 2. Run diagnose_team on the parsed team, passing the goal and any members the user wants kept.
37
+ 3. Walk through the problems with their evidence, then the candidate changes with their math. Say plainly which changes are exact (spread, move) and which are typing-only heuristics (member swaps) — diagnose_team labels the confidence, repeat it.
38
+ 4. If you propose a changed team, run format_team on it so the user can copy the paste straight into the game.
39
+
40
+ Every claim must come from the tools\u2019 output. You explain; getcompetitive proves.`,
41
+ },
42
+ },
43
+ ],
44
+ }));
45
+ server.registerPrompt('matchup-prep', {
46
+ title: 'Matchup Preparation',
47
+ description: 'Prepare a match against a known opponent: their likely sets, speed races, key rolls, bring-four, leads. "Here is my opponent — prepare me."',
48
+ argsSchema: {
49
+ team: teamArg,
50
+ opponent: z
51
+ .string()
52
+ .optional()
53
+ .describe('The opponent\u2019s team: paste text, or just species names if that is all the player knows.'),
54
+ regulation: regulationArg,
55
+ },
56
+ }, async (args) => ({
57
+ messages: [
58
+ {
59
+ role: 'user',
60
+ content: {
61
+ type: 'text',
62
+ text: `Act as a Pokémon Champions match analyst. The user has a matchup coming up.
63
+ ${args.team ? `Their team:\n\n${args.team}\n` : 'Ask the user for their team first.'}
64
+ ${args.opponent ? `What they know about the opponent:\n\n${args.opponent}\n` : 'Ask the user what they know about the opponent (species at minimum).'}
65
+
66
+ Then, in order:
67
+ 1. parse_team on any paste text. If the opponent is just species names, that is fine — pass them to prepare_matchup as the opponent array; it estimates what it cannot know and says so.
68
+ 2. Run prepare_matchup with the team, the opponent, and ${args.regulation ?? 'the current regulation'}.
69
+ 3. Deliver the dossier in plain language: their likely sets ordered by usage, the speed races that matter, the key damage rolls (quote the description lines), the recommended bring-four and why, leads to open with and watch for, win/loss conditions, and which of the user\u2019s members to preserve.
70
+ 4. End with the matchupConfidence read and what it can and cannot see.
71
+
72
+ Every number comes from prepare_matchup\u2019s output — you explain; getcompetitive proves.`,
73
+ },
74
+ },
75
+ ],
76
+ }));
77
+ server.registerPrompt('build-around', {
78
+ title: 'Build Around',
79
+ description: 'Build a legal team around one or two core species: coverage gaps, candidate partners, legality, paste. "Build around Mega Salamence + Rillaboom."',
80
+ argsSchema: {
81
+ core: z
82
+ .string()
83
+ .optional()
84
+ .describe('The species to build around, e.g. "Salamence-Mega", or two species separated by +.'),
85
+ regulation: regulationArg,
86
+ },
87
+ }, async (args) => ({
88
+ messages: [
89
+ {
90
+ role: 'user',
91
+ content: {
92
+ type: 'text',
93
+ text: `Act as a Pokémon Champions teambuilder. Build a team around ${args.core ?? 'the species the user names (ask them first)'} for ${args.regulation ?? 'the current regulation set'}.
94
+
95
+ Workflow:
96
+ 1. get_set on the core species (batched if several) so the core is built from what the meta actually plays.
97
+ 2. Run analyze_team on the partial team to see the defensive weaknesses and the types nothing hits super-effectively — those are the gaps the remaining slots must fill.
98
+ 3. Run diagnose_team on the partial team and mine its candidate changes (member swaps and move changes) for gap-filling partners; prefer partners the meta has usage data for (list_threats), and say when a pick is typing-only.
99
+ 4. Assemble six members, run check_legality against the regulation, then format_team the finished squad so the user can paste it.
100
+
101
+ Explain each pick with its evidence (coverage, speed, or usage). You design; getcompetitive proves the picks.`,
102
+ },
103
+ },
104
+ ],
105
+ }));
106
+ server.registerPrompt('tournament-prep', {
107
+ title: 'Tournament Preparation',
108
+ description: 'A pre-tournament walkthrough: the rules, the meta, the threats, and a preparation checklist.',
109
+ argsSchema: { regulation: regulationArg },
110
+ }, async (args) => ({
111
+ messages: [
112
+ {
113
+ role: 'user',
114
+ content: {
115
+ type: 'text',
116
+ text: `Act as a Pokémon Champions tournament coach. Prepare the user for an event under ${args.regulation ?? 'the current regulation set'}.
117
+
118
+ Workflow:
119
+ 1. get_regulation for the rules that shape the format: clauses, timers, bring 4 of 6, Mega rules. (Skip includeRoster unless a full legal list is actually wanted.)
120
+ 2. list_threats for the regulation and get_set (batched) on the top threats so their real sets are in front of you.
121
+ 3. Produce a tournament-prep briefing: the meta snapshot (top threats with usage, tier bands), what each top threat does, and a preparation checklist — answers for the top threats, a speed plan, and a bring-four habit.
122
+
123
+ Numbers only from the tools; the sample size and sourceAsOf from list_threats are part of the briefing, not an afterthought.`,
124
+ },
125
+ },
126
+ ],
127
+ }));
128
+ server.registerPrompt('learn-my-team', {
129
+ title: 'Learn My Team',
130
+ description: 'A plain-language guide to the user\u2019s own team: roles, synergies, holes, and how it is meant to play.',
131
+ argsSchema: { team: teamArg, regulation: regulationArg },
132
+ }, async (args) => ({
133
+ messages: [
134
+ {
135
+ role: 'user',
136
+ content: {
137
+ type: 'text',
138
+ text: `Act as a Pokémon Champions tutor. The user wants to understand the team they already play.
139
+ ${args.team ? `Their team:\n\n${args.team}\n` : 'Ask the user to paste their team first.'}
140
+
141
+ Workflow:
142
+ 1. parse_team on the paste.
143
+ 2. analyze_team for the synergy read: stacked weaknesses, coverage gaps, speed placement, and the score.
144
+ 3. diagnose_team for what it would change, so the guide includes the holes.
145
+ 4. For each member: get_set if the species is ranked (batched across the team), else get_pokemon plus get_learnset highlights.
146
+
147
+ Deliver a team guide: each member\u2019s role, the pairs and synergies between them, the holes a future change should fill, and a one-paragraph game plan. Every factual claim cites a tool\u2019s output.`,
148
+ },
149
+ },
150
+ ],
151
+ }));
152
+ server.registerPrompt('meta-report', {
153
+ title: 'Meta Report',
154
+ description: 'The current meta in one report: usage tiers, the top sets, and a data-dated read of what is good.',
155
+ argsSchema: { regulation: regulationArg },
156
+ }, async (args) => ({
157
+ messages: [
158
+ {
159
+ role: 'user',
160
+ content: {
161
+ type: 'text',
162
+ text: `Act as a Pokémon Champions metagame reporter. Produce the meta report for ${args.regulation ?? 'the current regulation set'}.
163
+
164
+ Workflow:
165
+ 1. list_threats for the usage ranking, tiers and the sample behind it.
166
+ 2. get_set (batched) on the top five threats for their real sets.
167
+ 3. Write the report: the tier bands with usage shares, each top threat\u2019s standard set and what it does, and a closing read of what the meta rewards. State the list\u2019s sourceAsOf and sample size so the reader knows how current the numbers are.
168
+
169
+ The report is data journalism: every figure quoted comes from the tools, and the data date travels with it.`,
170
+ },
171
+ },
172
+ ],
173
+ }));
174
+ }
175
+ //# sourceMappingURL=prompts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"prompts.js","sourceRoot":"","sources":["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, transport-agnostic: every entrypoint (stdio for local
3
+ * clients, HTTP for a remote endpoint) builds the same surface from here, so
4
+ * the tools, prompts and version can never drift between them.
5
+ */
6
+ import { readFileSync } from 'node:fs';
7
+ import { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
8
+ import { registerDataTools } from './tools/data.js';
9
+ import { registerCalcTools } from './tools/calc.js';
10
+ import { registerRegulationTools } from './tools/regulations.js';
11
+ import { registerAnalyzeTools } from './tools/analyze.js';
12
+ import { registerMetaTools } from './tools/meta.js';
13
+ import { registerTeamTools } from './tools/team.js';
14
+ import { registerDoctorTool } from './tools/doctor.js';
15
+ import { registerMatchupTool } from './tools/matchup.js';
16
+ import { registerSpritesTool } from './tools/sprites.js';
17
+ import { registerPrompts } from './prompts.js';
18
+ export const VERSION = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8')).version;
19
+ export function buildServer() {
20
+ const server = new McpServer({
21
+ name: 'getcompetitive',
22
+ version: VERSION,
23
+ });
24
+ registerDataTools(server);
25
+ registerCalcTools(server);
26
+ registerRegulationTools(server);
27
+ registerAnalyzeTools(server);
28
+ registerMetaTools(server);
29
+ registerTeamTools(server);
30
+ registerDoctorTool(server);
31
+ registerMatchupTool(server);
32
+ registerSpritesTool(server);
33
+ registerPrompts(server);
34
+ return server;
35
+ }
36
+ //# sourceMappingURL=server.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server.js","sourceRoot":"","sources":["../src/server.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,SAAS,EAAE,MAAM,yCAAyC,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,uBAAuB,EAAE,MAAM,wBAAwB,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,EAAE,mBAAmB,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC;AAE/C,MAAM,CAAC,MAAM,OAAO,GAClB,IAAI,CAAC,KAAK,CAAC,YAAY,CAAC,IAAI,GAAG,CAAC,iBAAiB,EAAE,OAAO,IAAI,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,CAC7E,CAAC,OAAO,CAAC;AAEV,MAAM,UAAU,WAAW;IACzB,MAAM,MAAM,GAAG,IAAI,SAAS,CAAC;QAC3B,IAAI,EAAE,gBAAgB;QACtB,OAAO,EAAE,OAAO;KACjB,CAAC,CAAC;IAEH,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAC1B,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAC1B,uBAAuB,CAAC,MAAM,CAAC,CAAC;IAChC,oBAAoB,CAAC,MAAM,CAAC,CAAC;IAC7B,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAC1B,iBAAiB,CAAC,MAAM,CAAC,CAAC;IAC1B,kBAAkB,CAAC,MAAM,CAAC,CAAC;IAC3B,mBAAmB,CAAC,MAAM,CAAC,CAAC;IAC5B,mBAAmB,CAAC,MAAM,CAAC,CAAC;IAC5B,eAAe,CAAC,MAAM,CAAC,CAAC;IAExB,OAAO,MAAM,CAAC;AAChB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "getcompetitive",
3
- "version": "4.2.0",
3
+ "version": "4.3.0",
4
4
  "description": "MCP server exposing competitive Pokemon data and battle mechanics for team building and decision making",
5
5
  "type": "module",
6
6
  "bin": {