k-cli-for-devs 1.0.0__py3-none-any.whl
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.
- k_cli/__init__.py +77 -0
- k_cli/agents/__init__.py +0 -0
- k_cli/agents/adversarial_swarm.py +338 -0
- k_cli/agents/agent_core.py +255 -0
- k_cli/agents/background_daemon.py +141 -0
- k_cli/agents/orchestrator.py +376 -0
- k_cli/agents/persona.py +649 -0
- k_cli/agents/scaffold_engine.py +121 -0
- k_cli/agents/strands_agent.py +832 -0
- k_cli/agents/subagents.py +1496 -0
- k_cli/cli.py +3297 -0
- k_cli/core/__init__.py +0 -0
- k_cli/core/airgap.py +95 -0
- k_cli/core/credentials.py +548 -0
- k_cli/core/intent_sensor.py +177 -0
- k_cli/core/llm_driver.py +1028 -0
- k_cli/core/model_manager.py +1109 -0
- k_cli/core/models_hub.py +913 -0
- k_cli/core/prompting.py +41 -0
- k_cli/core/sdk.py +322 -0
- k_cli/core/session.py +826 -0
- k_cli/core/smart_router.py +230 -0
- k_cli/core/storage_manager.py +176 -0
- k_cli/core/viewport_engine.py +117 -0
- k_cli/demo/demo_runner.py +579 -0
- k_cli/git/__init__.py +0 -0
- k_cli/git/ai_bisect.py +208 -0
- k_cli/git/conflict_resolver.py +1039 -0
- k_cli/git/git_guard.py +417 -0
- k_cli/git/patcher.py +1175 -0
- k_cli/git/repo_map.py +1780 -0
- k_cli/git/smart_git.py +928 -0
- k_cli/git/verifier.py +969 -0
- k_cli/github/__init__.py +0 -0
- k_cli/github/dedup_engine.py +787 -0
- k_cli/github/github_client.py +1702 -0
- k_cli/github/github_engine.py +641 -0
- k_cli/github/local_hub.py +209 -0
- k_cli/github/pr_watcher.py +129 -0
- k_cli/github/trending.py +205 -0
- k_cli/tools/__init__.py +0 -0
- k_cli/tools/audit.py +79 -0
- k_cli/tools/chaos_immunity.py +377 -0
- k_cli/tools/codebase_qa.py +106 -0
- k_cli/tools/command_runner.py +256 -0
- k_cli/tools/diagram_generator.py +547 -0
- k_cli/tools/doc_retriever.py +1332 -0
- k_cli/tools/feature.py +105 -0
- k_cli/tools/ghost_daemon.py +122 -0
- k_cli/tools/incident_triage.py +1365 -0
- k_cli/tools/mcp_client.py +1846 -0
- k_cli/tools/repo_gardener.py +142 -0
- k_cli/tools/rules.py +109 -0
- k_cli/tools/security.py +52 -0
- k_cli/tools/security_healer.py +999 -0
- k_cli/tools/synapse_graph.py +155 -0
- k_cli/tui/__init__.py +0 -0
- k_cli/tui/diff_viewer.py +223 -0
- k_cli/tui/tui.py +1145 -0
- k_cli/tui/tui_animations.py +648 -0
- k_cli/tui/tui_app.py +2788 -0
- k_cli/ui/__init__.py +10 -0
- k_cli/ui/simple_repl.py +315 -0
- k_cli/web/__init__.py +7 -0
- k_cli/web/server.py +624 -0
- k_cli/web/static/app.js +830 -0
- k_cli/web/static/index.html +495 -0
- k_cli/web/static/monitor.html +189 -0
- k_cli/web/static/style.css +838 -0
- k_cli_for_devs-1.0.0.dist-info/METADATA +461 -0
- k_cli_for_devs-1.0.0.dist-info/RECORD +75 -0
- k_cli_for_devs-1.0.0.dist-info/WHEEL +5 -0
- k_cli_for_devs-1.0.0.dist-info/entry_points.txt +2 -0
- k_cli_for_devs-1.0.0.dist-info/licenses/LICENSE +21 -0
- k_cli_for_devs-1.0.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8">
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
|
+
<title>K-CLI Live Agent Activity Monitor | Dual-Window View</title>
|
|
7
|
+
<!-- Fonts & Icons -->
|
|
8
|
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
9
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
10
|
+
<link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700;800;900&display=swap" rel="stylesheet">
|
|
11
|
+
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css">
|
|
12
|
+
<link rel="stylesheet" href="/static/style.css">
|
|
13
|
+
<style>
|
|
14
|
+
body {
|
|
15
|
+
background-color: #030712;
|
|
16
|
+
color: #f3f4f6;
|
|
17
|
+
font-family: 'Inter', sans-serif;
|
|
18
|
+
margin: 0;
|
|
19
|
+
padding: 1rem;
|
|
20
|
+
}
|
|
21
|
+
.monitor-header {
|
|
22
|
+
display: flex;
|
|
23
|
+
justify-content: space-between;
|
|
24
|
+
align-items: center;
|
|
25
|
+
padding: 0.8rem 1.2rem;
|
|
26
|
+
background: rgba(15, 23, 42, 0.7);
|
|
27
|
+
border: 1px solid rgba(56, 189, 248, 0.2);
|
|
28
|
+
border-radius: 8px;
|
|
29
|
+
margin-bottom: 1rem;
|
|
30
|
+
}
|
|
31
|
+
.monitor-grid {
|
|
32
|
+
display: grid;
|
|
33
|
+
grid-template-columns: 1fr 1fr;
|
|
34
|
+
gap: 1rem;
|
|
35
|
+
height: calc(100vh - 110px);
|
|
36
|
+
}
|
|
37
|
+
@media (max-width: 900px) {
|
|
38
|
+
.monitor-grid {
|
|
39
|
+
grid-template-columns: 1fr;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
.monitor-card {
|
|
43
|
+
background: rgba(15, 23, 42, 0.6);
|
|
44
|
+
border: 1px solid rgba(255, 255, 255, 0.1);
|
|
45
|
+
border-radius: 8px;
|
|
46
|
+
display: flex;
|
|
47
|
+
flex-direction: column;
|
|
48
|
+
overflow: hidden;
|
|
49
|
+
}
|
|
50
|
+
.monitor-card-header {
|
|
51
|
+
padding: 0.8rem 1rem;
|
|
52
|
+
background: rgba(30, 41, 59, 0.8);
|
|
53
|
+
border-bottom: 1px solid rgba(255, 255, 255, 0.08);
|
|
54
|
+
display: flex;
|
|
55
|
+
justify-content: space-between;
|
|
56
|
+
align-items: center;
|
|
57
|
+
}
|
|
58
|
+
.terminal-box {
|
|
59
|
+
flex: 1;
|
|
60
|
+
padding: 1rem;
|
|
61
|
+
font-family: 'Fira Code', monospace;
|
|
62
|
+
font-size: 0.85rem;
|
|
63
|
+
line-height: 1.5;
|
|
64
|
+
overflow-y: auto;
|
|
65
|
+
color: #38bdf8;
|
|
66
|
+
background: #050811;
|
|
67
|
+
white-space: pre-wrap;
|
|
68
|
+
word-break: break-all;
|
|
69
|
+
}
|
|
70
|
+
.status-badge {
|
|
71
|
+
display: inline-flex;
|
|
72
|
+
align-items: center;
|
|
73
|
+
gap: 6px;
|
|
74
|
+
padding: 4px 10px;
|
|
75
|
+
border-radius: 20px;
|
|
76
|
+
font-size: 0.75rem;
|
|
77
|
+
font-weight: 600;
|
|
78
|
+
background: rgba(34, 197, 94, 0.15);
|
|
79
|
+
color: #4ade80;
|
|
80
|
+
border: 1px solid rgba(34, 197, 94, 0.3);
|
|
81
|
+
}
|
|
82
|
+
.pulse-dot {
|
|
83
|
+
width: 8px;
|
|
84
|
+
height: 8px;
|
|
85
|
+
background-color: #4ade80;
|
|
86
|
+
border-radius: 50%;
|
|
87
|
+
box-shadow: 0 0 8px #4ade80;
|
|
88
|
+
animation: pulse 1.5s infinite;
|
|
89
|
+
}
|
|
90
|
+
@keyframes pulse {
|
|
91
|
+
0% { opacity: 1; transform: scale(1); }
|
|
92
|
+
50% { opacity: 0.4; transform: scale(1.2); }
|
|
93
|
+
100% { opacity: 1; transform: scale(1); }
|
|
94
|
+
}
|
|
95
|
+
</style>
|
|
96
|
+
</head>
|
|
97
|
+
<body>
|
|
98
|
+
|
|
99
|
+
<header class="monitor-header">
|
|
100
|
+
<div class="logo-group">
|
|
101
|
+
<h2 style="margin:0; font-size:1.1rem; color:#38bdf8;">
|
|
102
|
+
<i class="fa-solid fa-desktop text-cyan"></i> K-CLI Live Agent Synchronized Second Window
|
|
103
|
+
</h2>
|
|
104
|
+
</div>
|
|
105
|
+
<div class="status-badge" id="monitor-status">
|
|
106
|
+
<span class="pulse-dot"></span>
|
|
107
|
+
<span id="monitor-status-text">CONNECTED TO AGENT SWARM</span>
|
|
108
|
+
</div>
|
|
109
|
+
</header>
|
|
110
|
+
|
|
111
|
+
<div class="monitor-grid">
|
|
112
|
+
<!-- Pane 1: Token Stream -->
|
|
113
|
+
<div class="monitor-card">
|
|
114
|
+
<div class="monitor-card-header">
|
|
115
|
+
<span style="font-weight:600; font-size:0.9rem;"><i class="fa-solid fa-bolt text-cyan"></i> Live Thinking & Token Stream</span>
|
|
116
|
+
<span id="tok-stats" style="font-size:0.8rem; color:#94a3b8;">0 tokens</span>
|
|
117
|
+
</div>
|
|
118
|
+
<div class="terminal-box" id="token-stream-box">Waiting for agent execution...</div>
|
|
119
|
+
</div>
|
|
120
|
+
|
|
121
|
+
<!-- Pane 2: Telemetry & Compiler Events -->
|
|
122
|
+
<div class="monitor-card">
|
|
123
|
+
<div class="monitor-card-header">
|
|
124
|
+
<span style="font-weight:600; font-size:0.9rem;"><i class="fa-solid fa-microchip text-magenta"></i> Telemetry & AST Verification</span>
|
|
125
|
+
<span id="telemetry-stats" style="font-size:0.8rem; color:#94a3b8;">Idle</span>
|
|
126
|
+
</div>
|
|
127
|
+
<div class="terminal-box" id="telemetry-box" style="color:#a855f7;">[System] Monitor listener ready. Listening on /ws/monitor...</div>
|
|
128
|
+
</div>
|
|
129
|
+
</div>
|
|
130
|
+
|
|
131
|
+
<script>
|
|
132
|
+
document.addEventListener('DOMContentLoaded', () => {
|
|
133
|
+
const tokenBox = document.getElementById('token-stream-box');
|
|
134
|
+
const telemetryBox = document.getElementById('telemetry-box');
|
|
135
|
+
const tokStats = document.getElementById('tok-stats');
|
|
136
|
+
const telemetryStats = document.getElementById('telemetry-stats');
|
|
137
|
+
const statusText = document.getElementById('monitor-status-text');
|
|
138
|
+
|
|
139
|
+
let tokenCount = 0;
|
|
140
|
+
let currentPrompt = "";
|
|
141
|
+
|
|
142
|
+
const wsProtocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
|
|
143
|
+
const wsUrl = `${wsProtocol}//${window.location.host}/ws/monitor`;
|
|
144
|
+
|
|
145
|
+
function connectWS() {
|
|
146
|
+
const ws = new WebSocket(wsUrl);
|
|
147
|
+
|
|
148
|
+
ws.onopen = () => {
|
|
149
|
+
statusText.textContent = "CONNECTED TO AGENT SWARM";
|
|
150
|
+
};
|
|
151
|
+
|
|
152
|
+
ws.onmessage = (event) => {
|
|
153
|
+
const data = JSON.parse(event.data);
|
|
154
|
+
|
|
155
|
+
if (data.type === 'start') {
|
|
156
|
+
tokenCount = 0;
|
|
157
|
+
currentPrompt = data.prompt;
|
|
158
|
+
tokenBox.textContent = `[Task] ${data.prompt}\n[Model] ${data.model} (${data.route_reason || 'Auto'})\n\n`;
|
|
159
|
+
telemetryBox.textContent = `[${new Date().toLocaleTimeString()}] ▶ EXECUTION STARTED\nPrompt: ${data.prompt}\nModel: ${data.model}\nRoute Reason: ${data.route_reason || 'Adaptive Intent'}\n`;
|
|
160
|
+
telemetryStats.textContent = "EXECUTING";
|
|
161
|
+
} else if (data.type === 'token') {
|
|
162
|
+
tokenCount += 1;
|
|
163
|
+
tokStats.textContent = `${tokenCount} tokens`;
|
|
164
|
+
tokenBox.textContent += data.token;
|
|
165
|
+
tokenBox.scrollTop = tokenBox.scrollHeight;
|
|
166
|
+
} else if (data.type === 'complete') {
|
|
167
|
+
telemetryBox.textContent += `\n[${new Date().toLocaleTimeString()}] ✔ COMPLETED SUCCESSFULLY\nAttempts: ${data.attempts}\nRAM RSS: ${data.ram_usage_mb} MB\n`;
|
|
168
|
+
telemetryStats.textContent = "VERIFIED";
|
|
169
|
+
} else if (data.type === 'error') {
|
|
170
|
+
telemetryBox.textContent += `\n[${new Date().toLocaleTimeString()}] ✘ ERROR: ${data.message}\n`;
|
|
171
|
+
telemetryStats.textContent = "ERROR";
|
|
172
|
+
}
|
|
173
|
+
};
|
|
174
|
+
|
|
175
|
+
ws.onclose = () => {
|
|
176
|
+
statusText.textContent = "DISCONNECTED - RETRYING...";
|
|
177
|
+
setTimeout(connectWS, 3000);
|
|
178
|
+
};
|
|
179
|
+
|
|
180
|
+
ws.onerror = () => {
|
|
181
|
+
statusText.textContent = "CONNECTION ERROR";
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
connectWS();
|
|
186
|
+
});
|
|
187
|
+
</script>
|
|
188
|
+
</body>
|
|
189
|
+
</html>
|