-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
548 lines (475 loc) · 19.6 KB
/
index.html
File metadata and controls
548 lines (475 loc) · 19.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Autonomous Multi-Agent Coding Assistant</title>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css">
<style>
:root {
--primary: #3a6cf4;
--secondary: #27ae60;
--dark: #2c3e50;
--light: #f8f9fa;
--gray: #f5f5f5;
--gradient: linear-gradient(135deg, #3a6cf4, #00c6ff);
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}
body {
line-height: 1.7;
color: #333;
background-color: #fafafa;
}
.container {
max-width: 1200px;
margin: 0 auto;
padding: 0 20px;
}
/* Header */
header {
background: var(--gradient);
color: white;
padding: 80px 0 40px;
text-align: center;
border-radius: 0 0 20px 20px;
margin-bottom: 40px;
box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}
header h1 {
font-size: 3rem;
margin-bottom: 15px;
letter-spacing: -1px;
}
header p {
font-size: 1.3rem;
max-width: 700px;
margin: 0 auto 30px;
opacity: 0.9;
}
/* Sections */
section {
margin-bottom: 60px;
}
h2 {
color: var(--dark);
font-size: 2.2rem;
margin-bottom: 25px;
position: relative;
padding-bottom: 10px;
}
h2::after {
content: '';
position: absolute;
left: 0;
bottom: 0;
height: 4px;
width: 60px;
background: var(--primary);
border-radius: 2px;
}
h3 {
color: var(--dark);
font-size: 1.6rem;
margin: 25px 0 15px;
}
p {
margin-bottom: 15px;
font-size: 1.05rem;
}
/* Agent Cards */
.agents-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
gap: 25px;
margin: 30px 0;
}
.agent-card {
background: white;
border-radius: 12px;
padding: 25px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
transition: all 0.3s ease;
position: relative;
overflow: hidden;
}
.agent-card:hover {
transform: translateY(-5px);
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}
.agent-card::before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 5px;
height: 100%;
background: var(--primary);
}
.agent-card h3 {
margin-top: 0;
display: flex;
align-items: center;
gap: 10px;
}
.agent-card i {
color: var(--primary);
}
/* Code Blocks */
.code-container {
margin: 30px 0;
background: #1e1e1e;
border-radius: 12px;
padding: 25px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
position: relative;
overflow: hidden;
}
.code-container h3 {
color: white;
margin-top: 0;
margin-bottom: 15px;
font-family: 'Courier New', monospace;
}
pre {
overflow-x: auto;
background: transparent;
padding: 0;
margin: 0;
}
code {
font-family: 'Courier New', monospace;
color: #f8f8f2;
font-size: 0.95rem;
line-height: 1.5;
}
/* Workflow */
.workflow {
margin: 30px 0;
}
.workflow-step {
display: flex;
margin-bottom: 30px;
position: relative;
}
.step-number {
flex-shrink: 0;
width: 50px;
height: 50px;
background: var(--gradient);
border-radius: 50%;
display: flex;
align-items: center;
justify-content: center;
font-weight: bold;
color: white;
margin-right: 20px;
box-shadow: 0 5px 15px rgba(58, 108, 244, 0.2);
}
.step-content {
flex-grow: 1;
background: white;
border-radius: 12px;
padding: 20px 25px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}
.step-content h4 {
margin-top: 0;
color: var(--primary);
font-size: 1.3rem;
}
/* Features & Benefits */
.list-container {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
gap: 30px;
margin: 30px 0;
}
.feature-list, .benefit-list {
background: white;
border-radius: 12px;
padding: 30px;
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}
.feature-list h3, .benefit-list h3 {
margin-top: 0;
color: var(--primary);
display: flex;
align-items: center;
gap: 10px;
}
ul {
list-style-type: none;
}
ul li {
margin-bottom: 10px;
position: relative;
padding-left: 28px;
}
ul li::before {
content: '\f00c';
font-family: 'Font Awesome 6 Free';
font-weight: 900;
color: var(--secondary);
position: absolute;
left: 0;
}
/* Footer */
footer {
background: var(--dark);
color: white;
padding: 40px 0;
text-align: center;
margin-top: 60px;
}
footer p {
opacity: 0.8;
}
/* Code syntax highlighting */
.keyword { color: #ff79c6; }
.function { color: #50fa7b; }
.string { color: #f1fa8c; }
.comment { color: #6272a4; }
.class { color: #8be9fd; }
.variable { color: #f8f8f2; }
/* Responsive */
@media (max-width: 768px) {
.agents-grid {
grid-template-columns: 1fr;
}
.list-container {
grid-template-columns: 1fr;
}
header h1 {
font-size: 2.2rem;
}
header p {
font-size: 1.1rem;
}
}
img {
max-width: 100%;
height: auto;
display: block;
margin: 0 auto;
}
iframe {
max-width: 100%;
height: 450px;
}
@media (max-width: 768px) {
iframe {
width: 100%;
height: 200px; /* Adjust height for smaller screens */
}
}
</style>
</head>
<body>
<header>
<div class="container">
<h1>Autonomous Multi-Agent Coding Assistant</h1>
<p>A collaborative system of specialized AI agents that work together to design, code, and debug software projects autonomously.</p>
</div>
</header>
<main class="container">
<div style="text-align: center; margin-bottom: 20px;">
<iframe width="1000" height="500" src="https://www.youtube.com/embed/YKB0TU1-OTo"></iframe>
</div>
<section id="how-it-works">
<h2>How It Works</h2>
<p>The system uses multiple AI agents with specialized skills that coordinate through a central orchestrator to solve complex programming tasks. Each agent has a specific role in the workflow:</p>
<img src="image.png" alt="alt text" width="1200" height="400">
<div class="agents-grid">
<div class="agent-card">
<h3><i class="fas fa-sitemap"></i> Architect Agent</h3>
<p>Designs system architecture and component relationships. It analyzes the task requirements and creates a detailed design specification, including components, interfaces, and data flow.</p>
</div>
<div class="agent-card">
<h3><i class="fas fa-code"></i> Coder Agent</h3>
<p>Transforms specifications into working code. It takes the design created by the Architect Agent and generates functional code for each component.</p>
</div>
<div class="agent-card">
<h3><i class="fas fa-vial"></i> Tester Agent</h3>
<p>Creates test cases and validates functionality. It ensures that the generated code meets the requirements and works as expected by running automated tests.</p>
</div>
<div class="agent-card">
<h3><i class="fas fa-bug"></i> Debugger Agent</h3>
<p>Identifies and fixes issues in code. If the Tester Agent finds any issues, the Debugger Agent analyzes the test results and applies fixes to the code.</p>
</div>
<div class="agent-card">
<h3><i class="fas fa-project-diagram"></i> Orchestrator</h3>
<p>Coordinates agent activities and manages workflow. It ensures that all agents work together in a seamless and efficient manner.</p>
</div>
</div>
</section>
<section id="code-architecture">
<h2>Code Architecture</h2>
<h3>Orchestrator Implementation</h3>
<p>The Orchestrator is the central component of the system. It initializes all agents, manages the shared memory, and coordinates the workflow. Below is an example of its implementation:</p>
<div class="code-container">
<h3>Orchestrator.py</h3>
<pre><code><span class="keyword">class</span> <span class="class">Orchestrator</span>:
<span class="keyword">def</span> <span class="function">__init__</span>(self):
self.agents = {
<span class="string">"architect"</span>: ArchitectAgent(),
<span class="string">"coder"</span>: CoderAgent(),
<span class="string">"tester"</span>: TesterAgent(),
<span class="string">"debugger"</span>: DebuggerAgent()
}
self.shared_memory = SharedMemory()
<span class="keyword">def</span> <span class="function">process_task</span>(self, task):
<span class="comment"># 1. Architect creates design</span>
design = self.agents[<span class="string">"architect"</span>].design(task)
self.shared_memory.save(<span class="string">"design"</span>, design)
<span class="comment"># 2. Coder implements design</span>
code = self.agents[<span class="string">"coder"</span>].implement(self.shared_memory.get(<span class="string">"design"</span>))
self.shared_memory.save(<span class="string">"code"</span>, code)
<span class="comment"># 3. Tester verifies implementation</span>
test_results = self.agents[<span class="string">"tester"</span>].test(self.shared_memory.get(<span class="string">"code"</span>))
self.shared_memory.save(<span class="string">"test_results"</span>, test_results)
<span class="comment"># 4. Debugger fixes issues if tests fail</span>
<span class="keyword">if</span> <span class="keyword">not</span> test_results[<span class="string">"passed"</span>]:
fixes = self.agents[<span class="string">"debugger"</span>].debug(
self.shared_memory.get(<span class="string">"code"</span>),
self.shared_memory.get(<span class="string">"test_results"</span>)
)
self.shared_memory.save(<span class="string">"code"</span>, fixes)
<span class="keyword">return</span> self.shared_memory.get(<span class="string">"code"</span>)</code></pre>
</div>
<h3>Agent Implementations</h3>
<p>Each agent has a specific role and is implemented as a separate class. Below are examples of their implementations:</p>
<div class="code-container">
<h3>ArchitectAgent.py</h3>
<pre><code><span class="keyword">class</span> <span class="class">ArchitectAgent</span>:
<span class="keyword">def</span> <span class="function">design</span>(self, task_description):
<span class="string">"""
Analyze task requirements and create system design.
"""</span>
requirements = self._extract_requirements(task_description)
patterns = self._identify_patterns(requirements)
components = self._design_components(requirements, patterns)
interfaces = self._define_interfaces(components)
<span class="keyword">return</span> {
<span class="string">"requirements"</span>: requirements,
<span class="string">"patterns"</span>: patterns,
<span class="string">"components"</span>: components,
<span class="string">"interfaces"</span>: interfaces
}</code></pre>
</div>
<div class="code-container">
<h3>CoderAgent.py</h3>
<pre><code><span class="keyword">class</span> <span class="class">CoderAgent</span>:
<span class="keyword">def</span> <span class="function">implement</span>(self, design):
<span class="string">"""
Convert design specifications to code implementation.
"""</span>
implementation_plan = self._create_implementation_plan(design)
code_files = {}
<span class="keyword">for</span> component <span class="keyword">in</span> design[<span class="string">"components"</span>]:
code_files[component[<span class="string">"name"</span>]] = self._implement_component(
component, design[<span class="string">"interfaces"</span>]
)
<span class="keyword">return</span> code_files</code></pre>
</div>
<div class="code-container">
<h3>TesterAgent.py</h3>
<pre><code><span class="keyword">class</span> <span class="class">TesterAgent</span>:
<span class="keyword">def</span> <span class="function">test</span>(self, code):
<span class="string">"""
Validate the code by running test cases.
"""</span>
test_results = self._run_tests(code)
<span class="keyword">return</span> test_results</code></pre>
</div>
<div class="code-container">
<h3>DebuggerAgent.py</h3>
<pre><code><span class="keyword">class</span> <span class="class">DebuggerAgent</span>:
<span class="keyword">def</span> <span class="function">debug</span>(self, code, test_results):
<span class="string">"""
Fix issues in the code based on test results.
"""</span>
fixed_code = self._apply_fixes(code, test_results)
<span class="keyword">return</span> fixed_code</code></pre>
</div>
</section>
<section id="workflow">
<h2>Workflow Steps</h2>
<p>The workflow of the system is divided into the following steps:</p>
<div class="workflow">
<div class="workflow-step">
<div class="step-number">1</div>
<div class="step-content">
<h4>Architecture Design</h4>
<p>The Architect Agent analyzes the task requirements and creates a system design specification.</p>
</div>
</div>
<div class="workflow-step">
<div class="step-number">2</div>
<div class="step-content">
<h4>Code Implementation</h4>
<p>The Coder Agent translates the design into functional code.</p>
</div>
</div>
<div class="workflow-step">
<div class="step-number">3</div>
<div class="step-content">
<h4>Testing</h4>
<p>The Tester Agent creates test cases and validates the implementation.</p>
</div>
</div>
<div class="workflow-step">
<div class="step-number">4</div>
<div class="step-content">
<h4>Debugging</h4>
<p>The Debugger Agent fixes issues identified during testing.</p>
</div>
</div>
<div class="workflow-step">
<div class="step-number">5</div>
<div class="step-content">
<h4>Final Output</h4>
<p>The final, tested, and debugged code is returned as the output of the entire process.</p>
</div>
</div>
</div>
</section>
<section id="features-benefits">
<h2>Features & Benefits</h2>
<div class="list-container">
<div class="feature-list">
<h3><i class="fas fa-star"></i> Key Features</h3>
<ul>
<li>Specialized agents with distinct capabilities.</li>
<li>Shared memory system for collaboration.</li>
<li>Iterative refinement process.</li>
<li>Autonomous workflow management.</li>
<li>Modular design for easy extension.</li>
<li>Fault-tolerant through automatic debugging.</li>
</ul>
</div>
<div class="benefit-list">
<h3><i class="fas fa-award"></i> System Benefits</h3>
<ul>
<li>Reduces development time by automating repetitive tasks.</li>
<li>Ensures consistent code quality through systematic testing.</li>
<li>Leverages specialized expertise for each development phase.</li>
<li>Provides comprehensive documentation of the development process.</li>
<li>Scales across different project sizes and complexity levels.</li>
<li>Adapts to various programming languages and frameworks.</li>
</ul>
</div>
</div>
</section>
</main>
<footer>
<div class="container">
<p>Autonomous Multi-Agent Coding Assistant </p>
</div>
</footer>
</body>
</html>