agentgui 1.0.63 → 1.0.64

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/acp-launcher.js CHANGED
@@ -8,16 +8,56 @@ import { query } from '@anthropic-ai/claude-code';
8
8
  * - Actual filesystem operations
9
9
  * - Streaming responses with onUpdate callbacks
10
10
  * - No subprocess spawning needed (SDK handles it)
11
+ * - Integrated glootie-cc MCP servers for full capabilities
11
12
  */
12
13
  export default class ACPConnection {
13
14
  constructor() {
14
15
  this.sessionId = null;
15
16
  this.onUpdate = null;
16
17
  this.cwd = process.cwd();
18
+ this.mcpServers = this.buildMcpServers();
19
+ }
20
+
21
+ buildMcpServers() {
22
+ const mcpServers = {};
23
+
24
+ // Add glootie-cc MCP servers for full execution capabilities
25
+ if (process.env.CLAUDE_PLUGIN_ROOT) {
26
+ const pluginRoot = process.env.CLAUDE_PLUGIN_ROOT;
27
+ mcpServers['dev'] = {
28
+ type: 'stdio',
29
+ command: 'bunx',
30
+ args: ['mcp-glootie@latest'],
31
+ timeout: 360000
32
+ };
33
+ mcpServers['code-search'] = {
34
+ type: 'stdio',
35
+ command: 'bunx',
36
+ args: ['codebasesearch@latest'],
37
+ timeout: 360000
38
+ };
39
+ } else {
40
+ // Fallback to standard MCP configuration
41
+ mcpServers['dev'] = {
42
+ type: 'stdio',
43
+ command: 'bunx',
44
+ args: ['mcp-glootie@latest'],
45
+ timeout: 360000
46
+ };
47
+ mcpServers['code-search'] = {
48
+ type: 'stdio',
49
+ command: 'bunx',
50
+ args: ['codebasesearch@latest'],
51
+ timeout: 360000
52
+ };
53
+ }
54
+
55
+ return mcpServers;
17
56
  }
18
57
 
19
58
  async connect(agentType, cwd) {
20
59
  console.log(`[ACP] Using @anthropic-ai/claude-code SDK (${agentType})`);
60
+ console.log(`[ACP] MCP servers configured: ${Object.keys(this.mcpServers).join(', ')}`);
21
61
  if (cwd) {
22
62
  this.cwd = cwd;
23
63
  }
@@ -46,7 +86,7 @@ export default class ACPConnection {
46
86
  }
47
87
 
48
88
  async injectSystemContext() {
49
- return { context: 'Using Claude Code SDK with real plugins' };
89
+ return { context: 'Using Claude Code SDK with glootie-cc MCP integration' };
50
90
  }
51
91
 
52
92
  async sendPrompt(prompt) {
@@ -55,12 +95,42 @@ export default class ACPConnection {
55
95
  try {
56
96
  console.log(`[ACP] Sending prompt (${promptText.length} chars) in ${this.cwd}`);
57
97
 
98
+ // Build environment with proper permissions and working directory setup
99
+ const env = {
100
+ ...process.env,
101
+ HOME: process.env.HOME || '/config',
102
+ USER: process.env.USER || 'abc',
103
+ PATH: process.env.PATH || '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
104
+ // Ensure file operations are fully enabled
105
+ CLAUDE_CODE_ALLOW_ALL: 'true',
106
+ CLAUDE_CODE_BYPASS_PERMISSIONS: 'true'
107
+ };
108
+
109
+ // Build permission updates to allow directory access
110
+ const permissionUpdates = [
111
+ {
112
+ type: 'addDirectories',
113
+ directories: ['/tmp/test-projects', this.cwd, '/tmp', '/config'],
114
+ destination: 'session'
115
+ },
116
+ {
117
+ type: 'addRules',
118
+ rules: ['*'],
119
+ behavior: 'allow',
120
+ destination: 'session'
121
+ }
122
+ ];
123
+
58
124
  // Use the SDK directly to execute the prompt
59
125
  // The SDK handles plugins, system prompt, and all real execution
60
126
  const session = await query({
61
127
  prompt: promptText,
62
128
  options: {
63
- cwd: this.cwd
129
+ cwd: this.cwd,
130
+ env: env,
131
+ mcpServers: this.mcpServers,
132
+ permissionMode: 'acceptEdits',
133
+ additionalDirectories: ['/tmp/test-projects', this.cwd, '/tmp', '/config']
64
134
  }
65
135
  });
66
136
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agentgui",
3
- "version": "1.0.63",
3
+ "version": "1.0.64",
4
4
  "description": "Multi-agent ACP client with real-time communication",
5
5
  "type": "module",
6
6
  "main": "server.js",
package/static/app.js CHANGED
@@ -1354,7 +1354,7 @@ class GMGUIApp {
1354
1354
  if (this.pollingInterval) clearInterval(this.pollingInterval);
1355
1355
 
1356
1356
  let pollCount = 0;
1357
- const maxNoResponsePolls = 60;
1357
+ const maxNoResponsePolls = 240;
1358
1358
  let lastKnownIds = new Set(
1359
1359
  Array.from(document.querySelectorAll('#chatMessages [data-message-id]'))
1360
1360
  .map(el => el.dataset.messageId)