@appoly/multiagent-chat 1.0.3 → 1.0.6
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 +8 -18
- package/config.yaml +58 -1
- package/index.html +66 -110
- package/main.js +850 -370
- package/package.json +2 -2
- package/preload.js +10 -5
- package/renderer.js +627 -838
- package/styles.css +547 -760
package/README.md
CHANGED
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
<p align="center">
|
|
2
|
-
<a href="https://appoly.co.uk"><img src="appoly-logo-white-bg.png" alt="Appoly" height="
|
|
2
|
+
<a href="https://appoly.co.uk"><img src="appoly-logo-white-bg.png" alt="Appoly" height="70"></a>
|
|
3
3
|
|
|
4
4
|
<img src="robot.png" alt="Multi-Agent Chat" height="80">
|
|
5
5
|
</p>
|
|
6
6
|
|
|
7
7
|
# Multi-Agent Chat
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
Collaborate with multiple AI agents (Claude, Codex, etc.) in a shared chat interface. Uses your local CLI installations—bring your own API keys.
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
## Demo
|
|
12
|
+
|
|
13
|
+
<p align="center">
|
|
14
|
+
<img src="multiagent-chat.gif" alt="Demo" height="600">
|
|
15
|
+
</p>
|
|
12
16
|
|
|
13
17
|
## Installation
|
|
14
18
|
|
|
@@ -24,20 +28,6 @@ Run in your project directory:
|
|
|
24
28
|
multiagent-chat
|
|
25
29
|
```
|
|
26
30
|
|
|
27
|
-
### Advanced
|
|
28
|
-
|
|
29
|
-
```bash
|
|
30
|
-
# Specify workspace explicitly
|
|
31
|
-
multiagent-chat /path/to/project
|
|
32
|
-
multiagent-chat --workspace /path/to/project
|
|
33
|
-
|
|
34
|
-
# With custom config file
|
|
35
|
-
multiagent-chat --config /path/to/config.yaml
|
|
36
|
-
|
|
37
|
-
# Environment variables also work
|
|
38
|
-
WORKSPACE=/path/to/project multiagent-chat
|
|
39
|
-
```
|
|
40
|
-
|
|
41
31
|
## Configuration
|
|
42
32
|
|
|
43
33
|
On first run, a default config is created at `~/.multiagent-chat/config.yaml`.
|
|
@@ -74,7 +64,7 @@ You can override with a project-local config using `--config /path/to/config.yam
|
|
|
74
64
|
## Requirements
|
|
75
65
|
|
|
76
66
|
- **Node.js**: v18.x - v22.x (Node 23+ not yet supported due to native module compatibility)
|
|
77
|
-
- **AI CLI tools**: Claude Code, Codex, or other compatible agents installed
|
|
67
|
+
- **AI CLI tools**: Claude Code, Codex, or other compatible agents installed and authenticated (they should work in your terminal before using this app)
|
|
78
68
|
|
|
79
69
|
## Contributing
|
|
80
70
|
|
package/config.yaml
CHANGED
|
@@ -26,7 +26,7 @@ agents:
|
|
|
26
26
|
|
|
27
27
|
- name: "Codex"
|
|
28
28
|
command: "codex"
|
|
29
|
-
args: []
|
|
29
|
+
args: ['--full-auto']
|
|
30
30
|
use_pty: true
|
|
31
31
|
color: "#22c55e" # Green for Codex
|
|
32
32
|
|
|
@@ -77,6 +77,63 @@ prompts:
|
|
|
77
77
|
|
|
78
78
|
**{other_agents}**: Wait for {selected_agent} to confirm they have completed the implementation. Then review the changes and provide feedback. Iterate together until everyone is satisfied with the result.
|
|
79
79
|
|
|
80
|
+
# Resume template - used when restoring a past session
|
|
81
|
+
# Placeholders: {agent_name}, {agent_names}, {chat_summary}, {existing_plan}, {new_message}, {outbox_file}, {plan_file}
|
|
82
|
+
resume_template: |
|
|
83
|
+
## Multi-Agent Collaboration Session (Resumed)
|
|
84
|
+
|
|
85
|
+
**You are: {agent_name}**
|
|
86
|
+
You are collaborating with: {agent_names}
|
|
87
|
+
|
|
88
|
+
This is a RESUMED session. A previous discussion happened (summarised below). The user has sent a new message to continue.
|
|
89
|
+
|
|
90
|
+
### CRITICAL: How to Communicate
|
|
91
|
+
|
|
92
|
+
**You MUST send all responses through your outbox file.** Do NOT just reply in your terminal - other agents and the user cannot see your terminal output. The ONLY way to communicate is by writing to your outbox file.
|
|
93
|
+
|
|
94
|
+
Use this exact bash command (do NOT use file editing tools - they are slower):
|
|
95
|
+
|
|
96
|
+
```bash
|
|
97
|
+
cat << 'EOF' > {outbox_file}
|
|
98
|
+
Your message here.
|
|
99
|
+
Can be multiple lines.
|
|
100
|
+
EOF
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
**IMPORTANT:**
|
|
104
|
+
- For writing to your outbox, do NOT use built-in file write/edit tools (e.g. Write, Edit, write_file). Use `cat` with a heredoc as shown above - it is MUCH faster. You should still use your built-in tools for all other legitimate purposes (reading code, editing files, etc.).
|
|
105
|
+
- Do NOT just think or respond in your terminal. That is invisible to everyone else.
|
|
106
|
+
- Every response you want others to see MUST go through: `cat << 'EOF' > {outbox_file}`
|
|
107
|
+
|
|
108
|
+
### Previous Discussion Summary
|
|
109
|
+
{chat_summary}
|
|
110
|
+
|
|
111
|
+
### Existing Plan
|
|
112
|
+
{existing_plan}
|
|
113
|
+
|
|
114
|
+
### Guidelines
|
|
115
|
+
- **Sign your messages** - Start or end with your name (e.g., "— {agent_name}")
|
|
116
|
+
- Messages from other agents will appear in your terminal automatically
|
|
117
|
+
- Wait for responses before sending multiple messages
|
|
118
|
+
- When done, one agent should write the final agreed solution to `{plan_file}`
|
|
119
|
+
- Resume in **discussion-first mode** by default: discuss the user's message with other agents before making code changes
|
|
120
|
+
- Do NOT implement, edit files, or run write operations unless the user's newest message explicitly asks to implement/fix/change code now
|
|
121
|
+
- If the user intent is unclear, ask a brief clarification question in the chat before doing any implementation work
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
## New Message from User
|
|
126
|
+
{new_message}
|
|
127
|
+
|
|
128
|
+
---
|
|
129
|
+
|
|
130
|
+
**Respond NOW by writing to your outbox. Use this exact command:**
|
|
131
|
+
```bash
|
|
132
|
+
cat << 'EOF' > {outbox_file}
|
|
133
|
+
Your response here.
|
|
134
|
+
EOF
|
|
135
|
+
```
|
|
136
|
+
|
|
80
137
|
# Prompt template for agents
|
|
81
138
|
# This is sent via PTY when the session starts
|
|
82
139
|
prompt_template: |
|
package/index.html
CHANGED
|
@@ -12,93 +12,84 @@
|
|
|
12
12
|
<script src="node_modules/marked/lib/marked.umd.js"></script>
|
|
13
13
|
</head>
|
|
14
14
|
<body>
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
<div class="
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
<div class="workspace-sidebar-
|
|
21
|
-
<h3>Workspace</h3>
|
|
22
|
-
</div>
|
|
23
|
-
<div class="workspace-list-container">
|
|
24
|
-
<ul id="recent-workspaces" class="workspace-list">
|
|
25
|
-
<li class="workspace-empty">Loading...</li>
|
|
26
|
-
</ul>
|
|
27
|
-
</div>
|
|
28
|
-
<div class="workspace-actions">
|
|
29
|
-
<button id="browse-workspace-button" class="workspace-action-button">
|
|
30
|
-
<span class="action-icon">📁</span>
|
|
31
|
-
Browse...
|
|
32
|
-
</button>
|
|
33
|
-
<button id="use-cwd-button" class="workspace-action-button" style="display: none;">
|
|
34
|
-
<span class="action-icon">📍</span>
|
|
35
|
-
Use Current Directory
|
|
36
|
-
</button>
|
|
37
|
-
</div>
|
|
38
|
-
<div class="workspace-footer">
|
|
39
|
-
<button id="edit-config-button" class="config-link-button">
|
|
40
|
-
Edit configuration →
|
|
41
|
-
</button>
|
|
42
|
-
</div>
|
|
15
|
+
<div class="app-layout">
|
|
16
|
+
<!-- Sidebar -->
|
|
17
|
+
<div class="sidebar">
|
|
18
|
+
<div class="sidebar-header">
|
|
19
|
+
<div class="sidebar-workspace-name" id="sidebar-workspace-name">Loading...</div>
|
|
20
|
+
<div class="sidebar-workspace-path" id="sidebar-workspace-path"></div>
|
|
43
21
|
</div>
|
|
44
22
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
<p class="subtitle">Autonomous collaboration for complex challenges</p>
|
|
23
|
+
<div class="sidebar-new-session">
|
|
24
|
+
<button id="new-session-button" class="new-session-btn">+ New Session</button>
|
|
25
|
+
</div>
|
|
49
26
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
<
|
|
27
|
+
<div class="sidebar-section-label">Sessions</div>
|
|
28
|
+
<div class="session-list-container">
|
|
29
|
+
<div id="session-list" class="session-list">
|
|
30
|
+
<div class="session-list-empty">No sessions yet</div>
|
|
54
31
|
</div>
|
|
32
|
+
</div>
|
|
55
33
|
|
|
56
|
-
|
|
34
|
+
<div class="sidebar-footer">
|
|
35
|
+
<button id="change-workspace-button" class="sidebar-footer-btn">Change Workspace</button>
|
|
36
|
+
<button id="settings-button" class="sidebar-footer-btn">Settings</button>
|
|
37
|
+
</div>
|
|
38
|
+
</div>
|
|
39
|
+
|
|
40
|
+
<!-- Main Area -->
|
|
41
|
+
<div class="main-area">
|
|
42
|
+
<div class="drag-bar"></div>
|
|
43
|
+
<!-- Welcome View (shown when no session) -->
|
|
44
|
+
<div id="welcome-view" class="welcome-view">
|
|
45
|
+
<div class="welcome-content">
|
|
46
|
+
<img src="robot.png" alt="Robot" class="welcome-icon">
|
|
47
|
+
<h1 class="welcome-title">Let's build</h1>
|
|
48
|
+
<p class="welcome-subtitle">Start a multi-agent collaboration session</p>
|
|
49
|
+
<div id="config-info" class="welcome-config-info">
|
|
50
|
+
<div id="config-details">Loading agents...</div>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
<div class="prompt-input-bar">
|
|
57
54
|
<textarea
|
|
58
|
-
id="
|
|
59
|
-
|
|
60
|
-
|
|
55
|
+
id="prompt-input"
|
|
56
|
+
class="prompt-textarea"
|
|
57
|
+
placeholder="Describe your challenge... (Enter to send)"
|
|
58
|
+
rows="3"
|
|
61
59
|
></textarea>
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
<button id="start-button" class="primary-button" disabled>Select a Workspace</button>
|
|
65
|
-
|
|
66
|
-
<div id="config-info" class="config-info">
|
|
67
|
-
<h3>Current Environment</h3>
|
|
68
|
-
<div id="config-details">Loading...</div>
|
|
60
|
+
<button id="prompt-send-btn" class="prompt-send-btn" aria-label="Send" title="Send">↑</button>
|
|
69
61
|
</div>
|
|
70
62
|
</div>
|
|
71
|
-
</div>
|
|
72
|
-
</div>
|
|
73
63
|
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
64
|
+
<!-- Session View (shown when session loaded/active) -->
|
|
65
|
+
<div id="session-view" class="session-view" style="display: none;">
|
|
66
|
+
<div class="chat-area">
|
|
67
|
+
<div id="chat-viewer" class="chat-viewer"></div>
|
|
68
|
+
<div id="chat-new-messages" class="chat-new-messages" aria-hidden="true">
|
|
69
|
+
<button id="chat-new-messages-button" class="small-button">New messages ↓</button>
|
|
70
|
+
</div>
|
|
71
|
+
</div>
|
|
72
|
+
<div class="prompt-input-bar">
|
|
73
|
+
<textarea
|
|
74
|
+
id="user-message-input"
|
|
75
|
+
class="prompt-textarea"
|
|
76
|
+
placeholder="Send a message to all agents... (Enter to send)"
|
|
77
|
+
rows="2"
|
|
78
|
+
></textarea>
|
|
79
|
+
<button id="send-message-button" class="prompt-send-btn" aria-label="Send" title="Send">↑</button>
|
|
89
80
|
</div>
|
|
90
|
-
<div id="agent-tabs" class="tabs"></div>
|
|
91
|
-
<div id="agent-outputs" class="agent-outputs"></div>
|
|
92
81
|
</div>
|
|
82
|
+
</div>
|
|
93
83
|
|
|
94
|
-
|
|
84
|
+
<!-- Right Panel (shown only when agents active) -->
|
|
85
|
+
<div id="right-panel" class="right-panel" style="display: none;">
|
|
86
|
+
<!-- Resize Handle -->
|
|
95
87
|
<div class="resize-handle resize-handle-h" data-resize="main"></div>
|
|
96
88
|
|
|
97
|
-
<!-- Right Panel
|
|
98
|
-
<div class="right-panel">
|
|
99
|
-
<!-- Top-Level Main Tabs -->
|
|
89
|
+
<!-- Right Panel Tabs -->
|
|
90
|
+
<div class="right-panel-inner">
|
|
100
91
|
<div class="main-tabs">
|
|
101
|
-
<button id="main-tab-
|
|
92
|
+
<button id="main-tab-terminal" class="main-tab active" data-tab="terminal">Terminal</button>
|
|
102
93
|
<button id="main-tab-plan" class="main-tab" data-tab="plan">Plan</button>
|
|
103
94
|
<button id="main-tab-diff" class="main-tab" data-tab="diff">
|
|
104
95
|
Diff
|
|
@@ -106,30 +97,10 @@
|
|
|
106
97
|
</button>
|
|
107
98
|
</div>
|
|
108
99
|
|
|
109
|
-
<!--
|
|
110
|
-
<div id="
|
|
111
|
-
<div
|
|
112
|
-
|
|
113
|
-
<h3>Communication Stream</h3>
|
|
114
|
-
</div>
|
|
115
|
-
<div id="chat-viewer" class="chat-viewer"></div>
|
|
116
|
-
<div id="chat-new-messages" class="chat-new-messages" aria-hidden="true">
|
|
117
|
-
<button id="chat-new-messages-button" class="small-button">New messages ↓</button>
|
|
118
|
-
</div>
|
|
119
|
-
</div>
|
|
120
|
-
<div class="message-section">
|
|
121
|
-
<div class="panel-header">
|
|
122
|
-
<h3>Direct Intervention</h3>
|
|
123
|
-
</div>
|
|
124
|
-
<div class="message-input-container">
|
|
125
|
-
<textarea
|
|
126
|
-
id="user-message-input"
|
|
127
|
-
placeholder="Send instruction to all agents..."
|
|
128
|
-
rows="2"
|
|
129
|
-
></textarea>
|
|
130
|
-
<button id="send-message-button" class="primary-button">Send</button>
|
|
131
|
-
</div>
|
|
132
|
-
</div>
|
|
100
|
+
<!-- Terminal Tab Content -->
|
|
101
|
+
<div id="terminal-tab-content" class="tab-content active">
|
|
102
|
+
<div id="agent-tabs" class="tabs"></div>
|
|
103
|
+
<div id="agent-outputs" class="agent-outputs"></div>
|
|
133
104
|
</div>
|
|
134
105
|
|
|
135
106
|
<!-- Plan Tab Content -->
|
|
@@ -161,14 +132,11 @@
|
|
|
161
132
|
</div>
|
|
162
133
|
</div>
|
|
163
134
|
<div class="diff-layout">
|
|
164
|
-
<!-- File List Pane -->
|
|
165
135
|
<div class="diff-file-list">
|
|
166
136
|
<div class="file-list-header">Changed Files</div>
|
|
167
137
|
<ul id="diff-file-list-items" class="file-list-items"></ul>
|
|
168
138
|
</div>
|
|
169
|
-
<!-- Resize Handle for Diff Panes -->
|
|
170
139
|
<div class="resize-handle resize-handle-h diff-resize" data-resize="diff"></div>
|
|
171
|
-
<!-- Diff Content Pane -->
|
|
172
140
|
<div class="diff-content-pane">
|
|
173
141
|
<div id="diff-content" class="diff-content">
|
|
174
142
|
<em>Select a file or view all changes...</em>
|
|
@@ -194,18 +162,6 @@
|
|
|
194
162
|
</div>
|
|
195
163
|
</div>
|
|
196
164
|
|
|
197
|
-
<!-- New Session Modal -->
|
|
198
|
-
<div id="new-session-modal" class="modal" style="display: none;">
|
|
199
|
-
<div class="modal-content">
|
|
200
|
-
<h3>Start New Session?</h3>
|
|
201
|
-
<p class="modal-description">Chat history and plan will be cleared. This won't undo code changes.</p>
|
|
202
|
-
<div class="modal-actions">
|
|
203
|
-
<button id="new-session-cancel" class="small-button">Cancel</button>
|
|
204
|
-
<button id="new-session-confirm" class="small-button primary">Start New Session</button>
|
|
205
|
-
</div>
|
|
206
|
-
</div>
|
|
207
|
-
</div>
|
|
208
|
-
|
|
209
165
|
<script src="renderer.js"></script>
|
|
210
166
|
</body>
|
|
211
167
|
</html>
|