polydev-ai 1.8.71 ā 1.8.73
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 +164 -52
- package/lib/cliManager.js +37 -2
- package/mcp/stdio-wrapper.js +11 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,12 +1,40 @@
|
|
|
1
|
-
# Polydev
|
|
1
|
+
# Polydev
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<p align="center">
|
|
4
|
+
<img src="https://raw.githubusercontent.com/polydev-ai/polydev/main/public/logo.png" alt="Polydev Logo" width="120" />
|
|
5
|
+
</p>
|
|
4
6
|
|
|
5
|
-
|
|
7
|
+
<p align="center">
|
|
8
|
+
<strong>Multi-model AI perspectives for your coding agents</strong><br>
|
|
9
|
+
Query GPT-5, Claude, Gemini, and Grok simultaneously through one MCP server
|
|
10
|
+
</p>
|
|
6
11
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="https://www.npmjs.com/package/polydev-ai"><img src="https://img.shields.io/npm/v/polydev-ai.svg" alt="npm version"></a>
|
|
14
|
+
<a href="https://polydev.ai/articles/swe-bench-paper"><img src="https://img.shields.io/badge/SWE--bench-74.6%25-brightgreen" alt="SWE-bench Verified"></a>
|
|
15
|
+
<a href="https://opensource.org/licenses/MIT"><img src="https://img.shields.io/badge/License-MIT-blue.svg" alt="License: MIT"></a>
|
|
16
|
+
</p>
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## š One-Command Install
|
|
21
|
+
|
|
22
|
+
### Claude Code
|
|
23
|
+
```sh
|
|
24
|
+
claude mcp add polydev -- npx -y polydev-ai@latest
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
### Cursor / Windsurf / Cline
|
|
28
|
+
```sh
|
|
29
|
+
npx polydev-ai@latest
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
### OpenAI Codex CLI
|
|
33
|
+
```sh
|
|
34
|
+
npx polydev-ai@latest
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
> Get your token at **[polydev.ai/dashboard/mcp-tokens](https://polydev.ai/dashboard/mcp-tokens)**
|
|
10
38
|
|
|
11
39
|
---
|
|
12
40
|
|
|
@@ -24,60 +52,64 @@ Get insights from GPT 5.2, Claude Opus 4.5, Gemini 3, and Grok 4.1 ā all throu
|
|
|
24
52
|
|
|
25
53
|
---
|
|
26
54
|
|
|
27
|
-
##
|
|
28
|
-
|
|
29
|
-
**Already paying for ChatGPT Plus, Claude Pro, or Gemini Advanced?** Use those subscriptions directly through your CLI tools ā no API keys needed.
|
|
30
|
-
|
|
31
|
-
| Subscription | CLI Tool | How to Use |
|
|
32
|
-
|--------------|----------|------------|
|
|
33
|
-
| Claude Pro ($20/mo) | Claude Code | `claude login` with your Anthropic account |
|
|
34
|
-
| ChatGPT Plus ($20/mo) | Codex CLI | `codex login` with your OpenAI account |
|
|
35
|
-
| Gemini Advanced ($20/mo) | Gemini CLI | `gemini login` with your Google account |
|
|
55
|
+
## How It Works
|
|
36
56
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
3. Polydev queries models through your authenticated CLI sessions
|
|
41
|
-
4. Your subscription quota is used ā no extra costs
|
|
57
|
+
```
|
|
58
|
+
Your Agent ā Polydev MCP ā [GPT-5, Claude, Gemini, Grok] ā Synthesized Answer
|
|
59
|
+
```
|
|
42
60
|
|
|
43
|
-
|
|
61
|
+
When your AI agent gets stuck, Polydev consults multiple frontier models simultaneously and returns their combined perspectives. One request, four expert opinions.
|
|
44
62
|
|
|
45
63
|
---
|
|
46
64
|
|
|
47
65
|
## Quick Start
|
|
48
66
|
|
|
49
|
-
### 1
|
|
67
|
+
### Option 1: Use Hosted Service (Recommended)
|
|
50
68
|
|
|
51
|
-
**[polydev.ai
|
|
69
|
+
Get started instantly at **[polydev.ai](https://polydev.ai)**
|
|
52
70
|
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
71
|
+
**Step 1:** Install the MCP server
|
|
72
|
+
```sh
|
|
73
|
+
npx polydev-ai@latest
|
|
74
|
+
```
|
|
57
75
|
|
|
58
|
-
|
|
76
|
+
**Step 2:** Set your token (get it from [polydev.ai/dashboard/mcp-tokens](https://polydev.ai/dashboard/mcp-tokens))
|
|
77
|
+
```sh
|
|
78
|
+
export POLYDEV_USER_TOKEN="pd_your_token_here"
|
|
79
|
+
```
|
|
59
80
|
|
|
60
|
-
|
|
61
|
-
|
|
81
|
+
### Option 2: Self-Host with Your Own API Keys
|
|
82
|
+
|
|
83
|
+
**Step 1:** Clone and install
|
|
84
|
+
```sh
|
|
85
|
+
git clone https://github.com/polydev-ai/polydev.git
|
|
86
|
+
```
|
|
87
|
+
```sh
|
|
88
|
+
cd polydev && npm install
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
**Step 2:** Configure environment
|
|
92
|
+
```sh
|
|
93
|
+
cp .env.example .env.local
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
**Step 3:** Add your API keys to `.env.local` and run
|
|
97
|
+
```sh
|
|
98
|
+
npm run dev
|
|
62
99
|
```
|
|
63
100
|
|
|
64
101
|
---
|
|
65
102
|
|
|
66
|
-
##
|
|
103
|
+
## IDE Configuration
|
|
67
104
|
|
|
68
105
|
### Claude Code
|
|
69
106
|
|
|
70
|
-
|
|
107
|
+
**One command:**
|
|
108
|
+
```sh
|
|
71
109
|
claude mcp add polydev -- npx -y polydev-ai@latest
|
|
72
110
|
```
|
|
73
111
|
|
|
74
|
-
|
|
75
|
-
```bash
|
|
76
|
-
export POLYDEV_USER_TOKEN="pd_your_token_here"
|
|
77
|
-
```
|
|
78
|
-
|
|
79
|
-
Or add to `~/.claude.json`:
|
|
80
|
-
|
|
112
|
+
**Or add to `~/.claude.json`:**
|
|
81
113
|
```json
|
|
82
114
|
{
|
|
83
115
|
"mcpServers": {
|
|
@@ -94,8 +126,7 @@ Or add to `~/.claude.json`:
|
|
|
94
126
|
|
|
95
127
|
### Cursor / Windsurf / Cline
|
|
96
128
|
|
|
97
|
-
Add to your MCP config
|
|
98
|
-
|
|
129
|
+
**Add to your MCP config (usually `~/.cursor/mcp.json` or similar):**
|
|
99
130
|
```json
|
|
100
131
|
{
|
|
101
132
|
"mcpServers": {
|
|
@@ -112,8 +143,7 @@ Add to your MCP config:
|
|
|
112
143
|
|
|
113
144
|
### OpenAI Codex CLI
|
|
114
145
|
|
|
115
|
-
Add to `~/.codex/config.toml
|
|
116
|
-
|
|
146
|
+
**Add to `~/.codex/config.toml`:**
|
|
117
147
|
```toml
|
|
118
148
|
[mcp_servers.polydev]
|
|
119
149
|
command = "npx"
|
|
@@ -133,12 +163,11 @@ session_timeout = 600
|
|
|
133
163
|
|
|
134
164
|
Once connected, your agent can call:
|
|
135
165
|
|
|
136
|
-
```
|
|
166
|
+
```json
|
|
137
167
|
{
|
|
138
168
|
"tool": "get_perspectives",
|
|
139
169
|
"arguments": {
|
|
140
|
-
"prompt": "How should I refactor this authentication flow?"
|
|
141
|
-
"user_token": "pd_your_token_here"
|
|
170
|
+
"prompt": "How should I refactor this authentication flow?"
|
|
142
171
|
}
|
|
143
172
|
}
|
|
144
173
|
```
|
|
@@ -150,17 +179,58 @@ Or just mention "polydev" or "perspectives" in your prompt:
|
|
|
150
179
|
"Get perspectives on: Should I use Redis or PostgreSQL for caching?"
|
|
151
180
|
```
|
|
152
181
|
|
|
153
|
-
|
|
182
|
+
---
|
|
183
|
+
|
|
184
|
+
## Use Your Existing CLI Subscriptions
|
|
185
|
+
|
|
186
|
+
**Already paying for ChatGPT Plus, Claude Pro, or Gemini Advanced?** Use those subscriptions directly through your CLI tools.
|
|
187
|
+
|
|
188
|
+
| Subscription | CLI Tool | Setup |
|
|
189
|
+
|--------------|----------|-------|
|
|
190
|
+
| Claude Pro ($20/mo) | Claude Code | `claude login` |
|
|
191
|
+
| ChatGPT Plus ($20/mo) | Codex CLI | `codex login` |
|
|
192
|
+
| Gemini Advanced ($20/mo) | Gemini CLI | `gemini login` |
|
|
193
|
+
|
|
194
|
+
Polydev can route requests through your authenticated CLI sessions ā your subscription quota is used, no extra API costs.
|
|
154
195
|
|
|
155
196
|
---
|
|
156
197
|
|
|
157
|
-
##
|
|
198
|
+
## Self-Hosting
|
|
199
|
+
|
|
200
|
+
### Requirements
|
|
201
|
+
|
|
202
|
+
- Node.js 18+
|
|
203
|
+
- PostgreSQL (or Supabase)
|
|
204
|
+
- API keys for the models you want to use
|
|
205
|
+
|
|
206
|
+
### Environment Variables
|
|
158
207
|
|
|
208
|
+
Create a `.env.local` file:
|
|
209
|
+
|
|
210
|
+
```sh
|
|
211
|
+
# Database
|
|
212
|
+
NEXT_PUBLIC_SUPABASE_URL=your_supabase_url
|
|
213
|
+
NEXT_PUBLIC_SUPABASE_ANON_KEY=your_anon_key
|
|
214
|
+
SUPABASE_SERVICE_ROLE_KEY=your_service_role_key
|
|
215
|
+
|
|
216
|
+
# AI Providers (add the ones you want)
|
|
217
|
+
OPENAI_API_KEY=sk-...
|
|
218
|
+
ANTHROPIC_API_KEY=sk-ant-...
|
|
219
|
+
GOOGLE_API_KEY=...
|
|
220
|
+
XAI_API_KEY=...
|
|
159
221
|
```
|
|
160
|
-
|
|
222
|
+
|
|
223
|
+
### Database Setup
|
|
224
|
+
|
|
225
|
+
```sh
|
|
226
|
+
cd supabase && supabase db push
|
|
161
227
|
```
|
|
162
228
|
|
|
163
|
-
|
|
229
|
+
### Run
|
|
230
|
+
|
|
231
|
+
```sh
|
|
232
|
+
npm run dev
|
|
233
|
+
```
|
|
164
234
|
|
|
165
235
|
---
|
|
166
236
|
|
|
@@ -179,10 +249,52 @@ Our approach achieves **74.6% on SWE-bench Verified** (Resolve@2), matching Clau
|
|
|
179
249
|
|
|
180
250
|
---
|
|
181
251
|
|
|
252
|
+
## Project Structure
|
|
253
|
+
|
|
254
|
+
```
|
|
255
|
+
polydev/
|
|
256
|
+
āāā src/ # Next.js application
|
|
257
|
+
ā āāā app/ # App router pages & API routes
|
|
258
|
+
ā āāā components/ # React components
|
|
259
|
+
ā āāā hooks/ # Custom React hooks
|
|
260
|
+
ā āāā lib/ # Utilities and services
|
|
261
|
+
āāā mcp/ # MCP server implementation
|
|
262
|
+
āāā supabase/ # Database migrations
|
|
263
|
+
āāā docs/ # Documentation
|
|
264
|
+
āāā public/ # Static assets
|
|
265
|
+
```
|
|
266
|
+
|
|
267
|
+
---
|
|
268
|
+
|
|
269
|
+
## Contributing
|
|
270
|
+
|
|
271
|
+
Contributions are welcome! Please read our contributing guidelines before submitting PRs.
|
|
272
|
+
|
|
273
|
+
```sh
|
|
274
|
+
# Fork the repository, then:
|
|
275
|
+
git clone https://github.com/YOUR_USERNAME/polydev.git
|
|
276
|
+
```
|
|
277
|
+
```sh
|
|
278
|
+
cd polydev && npm install
|
|
279
|
+
```
|
|
280
|
+
```sh
|
|
281
|
+
git checkout -b feature/amazing-feature
|
|
282
|
+
```
|
|
283
|
+
```sh
|
|
284
|
+
git commit -m 'Add amazing feature'
|
|
285
|
+
```
|
|
286
|
+
```sh
|
|
287
|
+
git push origin feature/amazing-feature
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
Then open a Pull Request.
|
|
291
|
+
|
|
292
|
+
---
|
|
293
|
+
|
|
182
294
|
## Links
|
|
183
295
|
|
|
184
296
|
- **Website:** [polydev.ai](https://polydev.ai)
|
|
185
|
-
- **
|
|
297
|
+
- **Documentation:** [polydev.ai/docs](https://polydev.ai/docs)
|
|
186
298
|
- **npm:** [npmjs.com/package/polydev-ai](https://www.npmjs.com/package/polydev-ai)
|
|
187
299
|
- **Research:** [SWE-bench Paper](https://polydev.ai/articles/swe-bench-paper)
|
|
188
300
|
|
|
@@ -196,5 +308,5 @@ MIT License - see [LICENSE](LICENSE) for details.
|
|
|
196
308
|
|
|
197
309
|
<p align="center">
|
|
198
310
|
<b>Built by <a href="https://polydev.ai">Polydev AI</a></b><br>
|
|
199
|
-
<
|
|
311
|
+
<sub>Multi-model consultation for better code</sub>
|
|
200
312
|
</p>
|
package/lib/cliManager.js
CHANGED
|
@@ -781,9 +781,28 @@ This is a known issue with @google/gemini-cli@0.3.4 and older Node.js versions.`
|
|
|
781
781
|
timeout: timeoutMs,
|
|
782
782
|
// Explicitly pass environment to ensure HOME is available for CLI tools
|
|
783
783
|
// that read config from ~/.config or similar paths (e.g., Gemini CLI)
|
|
784
|
+
// Also include flags to suppress update prompts and browser opening
|
|
784
785
|
env: {
|
|
785
786
|
...process.env,
|
|
786
|
-
HOME: process.env.HOME || os.homedir()
|
|
787
|
+
HOME: process.env.HOME || os.homedir(),
|
|
788
|
+
// Suppress interactive prompts and update checks
|
|
789
|
+
CI: '1',
|
|
790
|
+
NO_COLOR: '1',
|
|
791
|
+
TERM: 'dumb',
|
|
792
|
+
NONINTERACTIVE: '1',
|
|
793
|
+
// Prevent browser opening (OAuth, updates, etc.)
|
|
794
|
+
NO_BROWSER: '1',
|
|
795
|
+
BROWSER: 'echo', // Redirect browser opening to no-op
|
|
796
|
+
DISPLAY: '', // Prevent X11 browser opening
|
|
797
|
+
HEADLESS: '1',
|
|
798
|
+
// CLI-specific flags to suppress updates
|
|
799
|
+
CODEX_DISABLE_UPDATE_CHECK: '1',
|
|
800
|
+
CLAUDE_CODE_DISABLE_UPDATE_CHECK: '1',
|
|
801
|
+
GEMINI_NO_BROWSER: '1',
|
|
802
|
+
GOOGLE_NO_BROWSER: '1',
|
|
803
|
+
// Prevent package manager update prompts
|
|
804
|
+
npm_config_update_notifier: 'false',
|
|
805
|
+
NO_UPDATE_NOTIFIER: '1'
|
|
787
806
|
}
|
|
788
807
|
});
|
|
789
808
|
|
|
@@ -1070,7 +1089,23 @@ This is a known issue with @google/gemini-cli@0.3.4 and older Node.js versions.`
|
|
|
1070
1089
|
...process.env,
|
|
1071
1090
|
TMPDIR: tmpDir,
|
|
1072
1091
|
TEMP: tmpDir,
|
|
1073
|
-
TMP: tmpDir
|
|
1092
|
+
TMP: tmpDir,
|
|
1093
|
+
HOME: process.env.HOME || os.homedir(),
|
|
1094
|
+
// Suppress interactive prompts and update checks
|
|
1095
|
+
CI: '1',
|
|
1096
|
+
NO_COLOR: '1',
|
|
1097
|
+
TERM: 'dumb',
|
|
1098
|
+
NONINTERACTIVE: '1',
|
|
1099
|
+
// Prevent browser opening (OAuth, updates, etc.)
|
|
1100
|
+
NO_BROWSER: '1',
|
|
1101
|
+
BROWSER: 'echo',
|
|
1102
|
+
DISPLAY: '',
|
|
1103
|
+
HEADLESS: '1',
|
|
1104
|
+
// CLI-specific flags to suppress updates
|
|
1105
|
+
CODEX_DISABLE_UPDATE_CHECK: '1',
|
|
1106
|
+
// Prevent package manager update prompts
|
|
1107
|
+
npm_config_update_notifier: 'false',
|
|
1108
|
+
NO_UPDATE_NOTIFIER: '1'
|
|
1074
1109
|
}
|
|
1075
1110
|
});
|
|
1076
1111
|
|
package/mcp/stdio-wrapper.js
CHANGED
|
@@ -249,7 +249,17 @@ class StdioMCPWrapper {
|
|
|
249
249
|
constructor() {
|
|
250
250
|
this.userToken = process.env.POLYDEV_USER_TOKEN;
|
|
251
251
|
if (!this.userToken) {
|
|
252
|
-
console.error('
|
|
252
|
+
console.error('\nāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā');
|
|
253
|
+
console.error('ā POLYDEV_USER_TOKEN is not set ā');
|
|
254
|
+
console.error('ā āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā£');
|
|
255
|
+
console.error('ā Get your free token at: ā');
|
|
256
|
+
console.error('ā š https://polydev.ai/dashboard/mcp-tokens ā');
|
|
257
|
+
console.error('ā ā');
|
|
258
|
+
console.error('ā Then add to ~/.zshrc or ~/.bashrc: ā');
|
|
259
|
+
console.error('ā export POLYDEV_USER_TOKEN="pd_your_token_here" ā');
|
|
260
|
+
console.error('ā ā');
|
|
261
|
+
console.error('ā Restart your terminal and Claude Code after adding the token ā');
|
|
262
|
+
console.error('āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā\n');
|
|
253
263
|
process.exit(1);
|
|
254
264
|
}
|
|
255
265
|
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "polydev-ai",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.73",
|
|
4
4
|
"engines": {
|
|
5
5
|
"node": ">=20.x <=22.x"
|
|
6
6
|
},
|
|
7
|
-
"mcpName": "io.github.
|
|
8
|
-
"description": "Multi-model AI perspectives for coding agents - query GPT
|
|
7
|
+
"mcpName": "io.github.polydev-ai/polydev",
|
|
8
|
+
"description": "Multi-model AI perspectives for coding agents - query GPT-5, Claude, Gemini, and Grok simultaneously through one MCP server",
|
|
9
9
|
"keywords": [
|
|
10
10
|
"mcp",
|
|
11
11
|
"model-context-protocol",
|