vibecore 0.2.0a1__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.
Potentially problematic release.
This version of vibecore might be problematic. Click here for more details.
- vibecore/__init__.py +0 -0
- vibecore/agents/default.py +79 -0
- vibecore/agents/prompts.py +12 -0
- vibecore/agents/task_agent.py +66 -0
- vibecore/cli.py +131 -0
- vibecore/context.py +24 -0
- vibecore/handlers/__init__.py +5 -0
- vibecore/handlers/stream_handler.py +231 -0
- vibecore/main.py +506 -0
- vibecore/main.tcss +0 -0
- vibecore/mcp/__init__.py +6 -0
- vibecore/mcp/manager.py +167 -0
- vibecore/mcp/server_wrapper.py +109 -0
- vibecore/models/__init__.py +5 -0
- vibecore/models/anthropic.py +239 -0
- vibecore/prompts/common_system_prompt.txt +64 -0
- vibecore/py.typed +0 -0
- vibecore/session/__init__.py +5 -0
- vibecore/session/file_lock.py +127 -0
- vibecore/session/jsonl_session.py +236 -0
- vibecore/session/loader.py +193 -0
- vibecore/session/path_utils.py +81 -0
- vibecore/settings.py +161 -0
- vibecore/tools/__init__.py +1 -0
- vibecore/tools/base.py +27 -0
- vibecore/tools/file/__init__.py +5 -0
- vibecore/tools/file/executor.py +282 -0
- vibecore/tools/file/tools.py +184 -0
- vibecore/tools/file/utils.py +78 -0
- vibecore/tools/python/__init__.py +1 -0
- vibecore/tools/python/backends/__init__.py +1 -0
- vibecore/tools/python/backends/terminal_backend.py +58 -0
- vibecore/tools/python/helpers.py +80 -0
- vibecore/tools/python/manager.py +208 -0
- vibecore/tools/python/tools.py +27 -0
- vibecore/tools/shell/__init__.py +5 -0
- vibecore/tools/shell/executor.py +223 -0
- vibecore/tools/shell/tools.py +156 -0
- vibecore/tools/task/__init__.py +5 -0
- vibecore/tools/task/executor.py +51 -0
- vibecore/tools/task/tools.py +51 -0
- vibecore/tools/todo/__init__.py +1 -0
- vibecore/tools/todo/manager.py +31 -0
- vibecore/tools/todo/models.py +36 -0
- vibecore/tools/todo/tools.py +111 -0
- vibecore/utils/__init__.py +5 -0
- vibecore/utils/text.py +28 -0
- vibecore/widgets/core.py +332 -0
- vibecore/widgets/core.tcss +63 -0
- vibecore/widgets/expandable.py +121 -0
- vibecore/widgets/expandable.tcss +69 -0
- vibecore/widgets/info.py +25 -0
- vibecore/widgets/info.tcss +17 -0
- vibecore/widgets/messages.py +232 -0
- vibecore/widgets/messages.tcss +85 -0
- vibecore/widgets/tool_message_factory.py +121 -0
- vibecore/widgets/tool_messages.py +483 -0
- vibecore/widgets/tool_messages.tcss +289 -0
- vibecore-0.2.0a1.dist-info/METADATA +407 -0
- vibecore-0.2.0a1.dist-info/RECORD +63 -0
- vibecore-0.2.0a1.dist-info/WHEEL +4 -0
- vibecore-0.2.0a1.dist-info/entry_points.txt +2 -0
- vibecore-0.2.0a1.dist-info/licenses/LICENSE +21 -0
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
ToolMessage {
|
|
2
|
+
Horizontal.tool-output {
|
|
3
|
+
height: auto;
|
|
4
|
+
|
|
5
|
+
&> .tool-output-prefix {
|
|
6
|
+
height: 1;
|
|
7
|
+
width: 5;
|
|
8
|
+
padding-left: 2;
|
|
9
|
+
padding-right: 1;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
&> Vertical.tool-output-content {
|
|
13
|
+
height: auto;
|
|
14
|
+
|
|
15
|
+
&> .tool-output-content {
|
|
16
|
+
# color: $text-muted;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
&> .tool-output-content-more {
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
PythonToolMessage {
|
|
26
|
+
Horizontal.python-code {
|
|
27
|
+
height: auto;
|
|
28
|
+
layers: main button;
|
|
29
|
+
|
|
30
|
+
&> .python-code-prefix {
|
|
31
|
+
height: 1;
|
|
32
|
+
width: 5;
|
|
33
|
+
padding-left: 2;
|
|
34
|
+
padding-right: 1;
|
|
35
|
+
color: $text-muted;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.copy-button {
|
|
39
|
+
layer: button;
|
|
40
|
+
dock: right;
|
|
41
|
+
height: 1;
|
|
42
|
+
width: 8;
|
|
43
|
+
min-width: 8;
|
|
44
|
+
margin: 0;
|
|
45
|
+
padding: 0;
|
|
46
|
+
background: $secondary;
|
|
47
|
+
color: $text;
|
|
48
|
+
border: none;
|
|
49
|
+
|
|
50
|
+
&:hover {
|
|
51
|
+
background: $secondary-lighten-1;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
&:focus {
|
|
55
|
+
background: $secondary-lighten-1;
|
|
56
|
+
text-style: bold;
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
&> Vertical.python-code-content {
|
|
61
|
+
height: auto;
|
|
62
|
+
width: 1fr;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
Horizontal.tool-output {
|
|
67
|
+
height: auto;
|
|
68
|
+
|
|
69
|
+
&> .tool-output-prefix {
|
|
70
|
+
height: 1;
|
|
71
|
+
width: 5;
|
|
72
|
+
padding-left: 2;
|
|
73
|
+
padding-right: 1;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
&> Vertical.tool-output-content {
|
|
77
|
+
height: auto;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
TodoWriteToolMessage {
|
|
83
|
+
Horizontal.todo-list {
|
|
84
|
+
height: auto;
|
|
85
|
+
|
|
86
|
+
&> .todo-list-prefix {
|
|
87
|
+
height: 1;
|
|
88
|
+
width: 5;
|
|
89
|
+
padding-left: 2;
|
|
90
|
+
padding-right: 1;
|
|
91
|
+
color: $text-muted;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
&> Vertical.todo-list-content {
|
|
95
|
+
height: auto;
|
|
96
|
+
width: 1fr;
|
|
97
|
+
|
|
98
|
+
.todo-item {
|
|
99
|
+
height: auto;
|
|
100
|
+
margin-left: 0;
|
|
101
|
+
padding: 0;
|
|
102
|
+
|
|
103
|
+
&.in_progress {
|
|
104
|
+
color: $success;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
&.pending {
|
|
108
|
+
color: $text;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
&.completed {
|
|
112
|
+
color: $text-muted;
|
|
113
|
+
text-style: dim;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
ReadToolMessage {
|
|
121
|
+
Horizontal.tool-output {
|
|
122
|
+
height: auto;
|
|
123
|
+
|
|
124
|
+
&> .tool-output-prefix {
|
|
125
|
+
height: 1;
|
|
126
|
+
width: 5;
|
|
127
|
+
padding-left: 2;
|
|
128
|
+
padding-right: 1;
|
|
129
|
+
color: $text-muted;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
&> Vertical.tool-output-content {
|
|
133
|
+
height: auto;
|
|
134
|
+
width: 1fr;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
TaskToolMessage {
|
|
140
|
+
Horizontal.task-prompt {
|
|
141
|
+
height: auto;
|
|
142
|
+
|
|
143
|
+
&> .task-prompt-prefix {
|
|
144
|
+
height: 1;
|
|
145
|
+
width: 5;
|
|
146
|
+
padding-left: 2;
|
|
147
|
+
padding-right: 1;
|
|
148
|
+
color: $text-muted;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
&> Vertical.task-prompt-content {
|
|
152
|
+
height: auto;
|
|
153
|
+
width: 1fr;
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
Horizontal.tool-output {
|
|
158
|
+
height: auto;
|
|
159
|
+
|
|
160
|
+
&> .tool-output-prefix {
|
|
161
|
+
height: 1;
|
|
162
|
+
width: 5;
|
|
163
|
+
padding-left: 2;
|
|
164
|
+
padding-right: 1;
|
|
165
|
+
color: $text-muted;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
&> Vertical.tool-output-content {
|
|
169
|
+
height: auto;
|
|
170
|
+
width: 1fr;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.message-content {
|
|
175
|
+
height: auto;
|
|
176
|
+
|
|
177
|
+
&> .message-content-prefix {
|
|
178
|
+
height: 1;
|
|
179
|
+
width: 5;
|
|
180
|
+
padding-left: 2;
|
|
181
|
+
padding-right: 1;
|
|
182
|
+
color: $text-muted;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
&> Vertical.message-content-body {
|
|
186
|
+
height: auto;
|
|
187
|
+
width: 1fr;
|
|
188
|
+
|
|
189
|
+
&> MainScroll#messages {
|
|
190
|
+
height: auto;
|
|
191
|
+
max-height: 10;
|
|
192
|
+
width: 1fr;
|
|
193
|
+
overflow-y: auto;
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
WriteToolMessage {
|
|
201
|
+
Horizontal.write-content {
|
|
202
|
+
height: auto;
|
|
203
|
+
|
|
204
|
+
&> .write-content-prefix {
|
|
205
|
+
height: 1;
|
|
206
|
+
width: 5;
|
|
207
|
+
padding-left: 2;
|
|
208
|
+
padding-right: 1;
|
|
209
|
+
color: $text-muted;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
&> Vertical.write-content-body {
|
|
213
|
+
height: auto;
|
|
214
|
+
width: 1fr;
|
|
215
|
+
|
|
216
|
+
.write-content-expandable {
|
|
217
|
+
height: auto;
|
|
218
|
+
width: 1fr;
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
Horizontal.tool-output {
|
|
224
|
+
height: auto;
|
|
225
|
+
|
|
226
|
+
&> .tool-output-prefix {
|
|
227
|
+
height: 1;
|
|
228
|
+
width: 5;
|
|
229
|
+
padding-left: 2;
|
|
230
|
+
padding-right: 1;
|
|
231
|
+
color: $text-muted;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
&> Vertical.tool-output-content {
|
|
235
|
+
height: auto;
|
|
236
|
+
width: 1fr;
|
|
237
|
+
|
|
238
|
+
.write-output-message {
|
|
239
|
+
color: $text-muted;
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
MCPToolMessage {
|
|
246
|
+
Horizontal.mcp-arguments {
|
|
247
|
+
height: auto;
|
|
248
|
+
|
|
249
|
+
&> .mcp-arguments-prefix {
|
|
250
|
+
height: 1;
|
|
251
|
+
width: 5;
|
|
252
|
+
padding-left: 2;
|
|
253
|
+
padding-right: 1;
|
|
254
|
+
color: $text-muted;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
&> Vertical.mcp-arguments-content {
|
|
258
|
+
height: auto;
|
|
259
|
+
width: 1fr;
|
|
260
|
+
|
|
261
|
+
.mcp-arguments-label {
|
|
262
|
+
color: $text-muted;
|
|
263
|
+
# margin-bottom: 1;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.mcp-arguments-text {
|
|
267
|
+
color: $text-muted;
|
|
268
|
+
text-overflow: ellipsis;
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
Horizontal.tool-output {
|
|
274
|
+
height: auto;
|
|
275
|
+
|
|
276
|
+
&> .tool-output-prefix {
|
|
277
|
+
height: 1;
|
|
278
|
+
width: 5;
|
|
279
|
+
padding-left: 2;
|
|
280
|
+
padding-right: 1;
|
|
281
|
+
color: $text-muted;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
&> Vertical.tool-output-content {
|
|
285
|
+
height: auto;
|
|
286
|
+
width: 1fr;
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
}
|
|
@@ -0,0 +1,407 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: vibecore
|
|
3
|
+
Version: 0.2.0a1
|
|
4
|
+
Summary: Build your own AI-powered automation tools in the terminal with this extensible agent framework
|
|
5
|
+
Project-URL: Homepage, https://github.com/serialx/vibecore
|
|
6
|
+
Project-URL: Repository, https://github.com/serialx/vibecore
|
|
7
|
+
Project-URL: Bug Tracker, https://github.com/serialx/vibecore/issues
|
|
8
|
+
Project-URL: Discussions, https://github.com/serialx/vibecore/discussions
|
|
9
|
+
Project-URL: Documentation, https://github.com/serialx/vibecore#readme
|
|
10
|
+
Author-email: Sung-jin Brian Hong <serialx@serialx.net>
|
|
11
|
+
License: MIT
|
|
12
|
+
License-File: LICENSE
|
|
13
|
+
Keywords: agents,ai,anthropic,assistant,automation,claude,cli,framework,gpt,mcp,model-context-protocol,openai,terminal,textual,tool-use,tui
|
|
14
|
+
Classifier: Development Status :: 3 - Alpha
|
|
15
|
+
Classifier: Environment :: Console
|
|
16
|
+
Classifier: Intended Audience :: Developers
|
|
17
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
18
|
+
Classifier: Operating System :: OS Independent
|
|
19
|
+
Classifier: Programming Language :: Python :: 3
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
23
|
+
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
|
|
24
|
+
Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
|
|
25
|
+
Classifier: Topic :: Software Development :: User Interfaces
|
|
26
|
+
Classifier: Topic :: Terminals
|
|
27
|
+
Classifier: Topic :: Text Processing :: Linguistic
|
|
28
|
+
Classifier: Typing :: Typed
|
|
29
|
+
Requires-Python: >=3.11
|
|
30
|
+
Requires-Dist: litellm>=1.72.4
|
|
31
|
+
Requires-Dist: openai-agents[litellm]>=0.2.2
|
|
32
|
+
Requires-Dist: pydantic-settings>=2.10.1
|
|
33
|
+
Requires-Dist: textual>=4.0.0
|
|
34
|
+
Requires-Dist: typer>=0.14.0
|
|
35
|
+
Description-Content-Type: text/markdown
|
|
36
|
+
|
|
37
|
+
# vibecore
|
|
38
|
+
|
|
39
|
+
<div align="center">
|
|
40
|
+
|
|
41
|
+
[](https://badge.fury.io/py/vibecore)
|
|
42
|
+
[](https://www.python.org/downloads/)
|
|
43
|
+
[](https://opensource.org/licenses/MIT)
|
|
44
|
+
[](https://pypistats.org/packages/vibecore)
|
|
45
|
+
[](https://github.com/astral-sh/ruff)
|
|
46
|
+
[](https://microsoft.github.io/pyright/)
|
|
47
|
+
|
|
48
|
+
**Build your own AI-powered automation tools in the terminal with this extensible agent framework**
|
|
49
|
+
|
|
50
|
+
[Features](#features) " [Installation](#installation) " [Usage](#usage) " [Development](#development) " [Contributing](#contributing)
|
|
51
|
+
|
|
52
|
+
</div>
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
<p align="center" style="max-width: 800px; margin: 0 auto;">
|
|
57
|
+
<img src="docs/images/screenshot.png" alt="vibecore terminal screenshot" style="max-width: 100%; height: auto;">
|
|
58
|
+
</p>
|
|
59
|
+
|
|
60
|
+
## Overview
|
|
61
|
+
|
|
62
|
+
vibecore is a **Do-it-yourself Agent Framework** that transforms your terminal into a powerful AI workspace. More than just a chat interface, it's a complete platform for building and orchestrating custom AI agents that can manipulate files, execute code, run shell commands, and manage complex workflows—all from the comfort of your terminal.
|
|
63
|
+
|
|
64
|
+
Built on [Textual](https://textual.textualize.io/) and the [OpenAI Agents SDK](https://github.com/openai/openai-agents-python), vibecore provides the foundation for creating your own AI-powered automation tools. Whether you're automating development workflows, building custom AI assistants, or experimenting with agent-based systems, vibecore gives you the building blocks to craft exactly what you need.
|
|
65
|
+
|
|
66
|
+
### Key Features
|
|
67
|
+
|
|
68
|
+
- **AI-Powered Chat Interface** - Interact with state-of-the-art language models through an intuitive terminal interface
|
|
69
|
+
- **Rich Tool Integration** - Built-in tools for file operations, shell commands, Python execution, and task management
|
|
70
|
+
- **MCP Support** - Connect to external tools and services via Model Context Protocol servers
|
|
71
|
+
- **Beautiful Terminal UI** - Modern, responsive interface with dark/light theme support
|
|
72
|
+
- **Real-time Streaming** - See AI responses as they're generated with smooth streaming updates
|
|
73
|
+
- **Extensible Architecture** - Easy to add new tools and capabilities
|
|
74
|
+
- **High Performance** - Async-first design for responsive interactions
|
|
75
|
+
- **Context Management** - Maintains state across tool executions for coherent workflows
|
|
76
|
+
|
|
77
|
+
## Installation
|
|
78
|
+
|
|
79
|
+
### Prerequisites
|
|
80
|
+
|
|
81
|
+
- Python 3.11 or higher
|
|
82
|
+
|
|
83
|
+
### Install from PyPI
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
# Install vibecore
|
|
87
|
+
pip install vibecore
|
|
88
|
+
|
|
89
|
+
# Configure your API key
|
|
90
|
+
export ANTHROPIC_API_KEY="your-api-key-here"
|
|
91
|
+
# or
|
|
92
|
+
export OPENAI_API_KEY="your-api-key-here"
|
|
93
|
+
|
|
94
|
+
# Run vibecore
|
|
95
|
+
vibecore
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
### Install from Source
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
# Clone the repository
|
|
102
|
+
git clone https://github.com/serialx/vibecore.git
|
|
103
|
+
cd vibecore
|
|
104
|
+
|
|
105
|
+
# Install with pip
|
|
106
|
+
pip install -e .
|
|
107
|
+
|
|
108
|
+
# Or install with uv (recommended for development)
|
|
109
|
+
uv sync
|
|
110
|
+
|
|
111
|
+
# Configure your API key
|
|
112
|
+
export ANTHROPIC_API_KEY="your-api-key-here"
|
|
113
|
+
# or
|
|
114
|
+
export OPENAI_API_KEY="your-api-key-here"
|
|
115
|
+
|
|
116
|
+
# Run vibecore
|
|
117
|
+
vibecore
|
|
118
|
+
# or with uv
|
|
119
|
+
uv run vibecore
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
## Usage
|
|
123
|
+
|
|
124
|
+
### Basic Commands
|
|
125
|
+
|
|
126
|
+
Once vibecore is running, you can:
|
|
127
|
+
|
|
128
|
+
- **Chat naturally** - Type messages and press Enter to send
|
|
129
|
+
- **Toggle theme** - Press `Ctrl+Shift+D` to toggle dark/light
|
|
130
|
+
- **Cancel agent** - Press `Esc` to cancel the current operation
|
|
131
|
+
- **Navigate history** - Use `Up/Down` arrows
|
|
132
|
+
- **Exit** - Press `Ctrl+D` twice to confirm
|
|
133
|
+
|
|
134
|
+
### Commands
|
|
135
|
+
|
|
136
|
+
- `/help` - Show help and keyboard shortcuts
|
|
137
|
+
- `/clear` - Clear the current session and start a new one
|
|
138
|
+
|
|
139
|
+
### Available Tools
|
|
140
|
+
|
|
141
|
+
vibecore comes with powerful built-in tools:
|
|
142
|
+
|
|
143
|
+
#### File Operations
|
|
144
|
+
```
|
|
145
|
+
- Read files and directories
|
|
146
|
+
- Write and edit files
|
|
147
|
+
- Multi-edit for batch file modifications
|
|
148
|
+
- Pattern matching with glob
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
#### Shell Commands
|
|
152
|
+
```
|
|
153
|
+
- Execute bash commands
|
|
154
|
+
- Search with grep
|
|
155
|
+
- List directory contents
|
|
156
|
+
- File system navigation
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
#### Python Execution
|
|
160
|
+
```
|
|
161
|
+
- Run Python code in isolated environments
|
|
162
|
+
- Persistent execution context
|
|
163
|
+
- Full standard library access
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
#### Task Management
|
|
167
|
+
```
|
|
168
|
+
- Create and manage todo lists
|
|
169
|
+
- Track task progress
|
|
170
|
+
- Organize complex workflows
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
### MCP (Model Context Protocol) Support
|
|
174
|
+
|
|
175
|
+
vibecore supports the [Model Context Protocol](https://modelcontextprotocol.io/), allowing you to connect to external tools and services through MCP servers.
|
|
176
|
+
|
|
177
|
+
#### Configuring MCP Servers
|
|
178
|
+
|
|
179
|
+
Create a `config.yaml` file in your project directory or add MCP servers to your environment:
|
|
180
|
+
|
|
181
|
+
```yaml
|
|
182
|
+
mcp_servers:
|
|
183
|
+
# Filesystem server for enhanced file operations
|
|
184
|
+
- name: filesystem
|
|
185
|
+
type: stdio
|
|
186
|
+
command: npx
|
|
187
|
+
args: ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/allowed/directory"]
|
|
188
|
+
|
|
189
|
+
# GitHub integration
|
|
190
|
+
- name: github
|
|
191
|
+
type: stdio
|
|
192
|
+
command: npx
|
|
193
|
+
args: ["-y", "@modelcontextprotocol/server-github"]
|
|
194
|
+
env:
|
|
195
|
+
GITHUB_PERSONAL_ACCESS_TOKEN: "your-github-token"
|
|
196
|
+
|
|
197
|
+
# Custom HTTP server
|
|
198
|
+
- name: my-server
|
|
199
|
+
type: http
|
|
200
|
+
url: "http://localhost:8080/mcp"
|
|
201
|
+
allowed_tools: ["specific_tool"] # Optional: whitelist specific tools
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
#### Available MCP Server Types
|
|
205
|
+
|
|
206
|
+
- **stdio**: Spawns a local process (npm packages, executables)
|
|
207
|
+
- **sse**: Server-Sent Events connection
|
|
208
|
+
- **http**: HTTP-based MCP servers
|
|
209
|
+
|
|
210
|
+
#### Tool Filtering
|
|
211
|
+
|
|
212
|
+
Control which tools are available from each server:
|
|
213
|
+
|
|
214
|
+
```yaml
|
|
215
|
+
mcp_servers:
|
|
216
|
+
- name: restricted-server
|
|
217
|
+
type: stdio
|
|
218
|
+
command: some-command
|
|
219
|
+
allowed_tools: ["safe_read", "safe_write"] # Only these tools available
|
|
220
|
+
blocked_tools: ["dangerous_delete"] # These tools are blocked
|
|
221
|
+
```
|
|
222
|
+
|
|
223
|
+
## Development
|
|
224
|
+
|
|
225
|
+
### Setting Up Development Environment
|
|
226
|
+
|
|
227
|
+
```bash
|
|
228
|
+
# Clone and enter the repository
|
|
229
|
+
git clone https://github.com/serialx/vibecore.git
|
|
230
|
+
cd vibecore
|
|
231
|
+
|
|
232
|
+
# Install dependencies
|
|
233
|
+
uv sync
|
|
234
|
+
|
|
235
|
+
# Run tests
|
|
236
|
+
uv run pytest
|
|
237
|
+
|
|
238
|
+
# Run tests by category
|
|
239
|
+
uv run pytest tests/ui/ # UI and widget tests
|
|
240
|
+
uv run pytest tests/tools/ # Tool functionality tests
|
|
241
|
+
uv run pytest tests/session/ # Session tests
|
|
242
|
+
|
|
243
|
+
# Run linting and formatting
|
|
244
|
+
uv run ruff check .
|
|
245
|
+
uv run ruff format .
|
|
246
|
+
|
|
247
|
+
# Type checking
|
|
248
|
+
uv run pyright
|
|
249
|
+
```
|
|
250
|
+
|
|
251
|
+
### Project Structure
|
|
252
|
+
|
|
253
|
+
```
|
|
254
|
+
vibecore/
|
|
255
|
+
├── src/vibecore/
|
|
256
|
+
│ ├── main.py # Application entry point & TUI orchestration
|
|
257
|
+
│ ├── context.py # Central state management for agents
|
|
258
|
+
│ ├── settings.py # Configuration with Pydantic
|
|
259
|
+
│ ├── agents/ # Agent configurations & handoffs
|
|
260
|
+
│ │ └── default.py # Main agent with tool integrations
|
|
261
|
+
│ ├── models/ # LLM provider integrations
|
|
262
|
+
│ │ └── anthropic.py # Claude model support via LiteLLM
|
|
263
|
+
│ ├── mcp/ # Model Context Protocol integration
|
|
264
|
+
│ │ └── manager.py # MCP server lifecycle management
|
|
265
|
+
│ ├── handlers/ # Stream processing handlers
|
|
266
|
+
│ │ └── stream_handler.py # Handle streaming agent responses
|
|
267
|
+
│ ├── session/ # Session management
|
|
268
|
+
│ │ ├── jsonl_session.py # JSONL-based conversation storage
|
|
269
|
+
│ │ └── loader.py # Session loading logic
|
|
270
|
+
│ ├── widgets/ # Custom Textual UI components
|
|
271
|
+
│ │ ├── core.py # Base widgets & layouts
|
|
272
|
+
│ │ ├── messages.py # Message display components
|
|
273
|
+
│ │ ├── tool_message_factory.py # Factory for creating tool messages
|
|
274
|
+
│ │ ├── core.tcss # Core styling
|
|
275
|
+
│ │ └── messages.tcss # Message-specific styles
|
|
276
|
+
│ ├── tools/ # Extensible tool system
|
|
277
|
+
│ │ ├── base.py # Tool interfaces & protocols
|
|
278
|
+
│ │ ├── file/ # File manipulation tools
|
|
279
|
+
│ │ ├── shell/ # Shell command execution
|
|
280
|
+
│ │ ├── python/ # Python code interpreter
|
|
281
|
+
│ │ └── todo/ # Task management system
|
|
282
|
+
│ └── prompts/ # System prompts & instructions
|
|
283
|
+
├── tests/ # Comprehensive test suite
|
|
284
|
+
│ ├── ui/ # UI and widget tests
|
|
285
|
+
│ ├── tools/ # Tool functionality tests
|
|
286
|
+
│ ├── session/ # Session and storage tests
|
|
287
|
+
│ ├── cli/ # CLI and command tests
|
|
288
|
+
│ ├── models/ # Model integration tests
|
|
289
|
+
│ └── _harness/ # Test utilities
|
|
290
|
+
├── pyproject.toml # Project configuration & dependencies
|
|
291
|
+
├── uv.lock # Locked dependencies
|
|
292
|
+
└── CLAUDE.md # AI assistant instructions
|
|
293
|
+
```
|
|
294
|
+
|
|
295
|
+
### Code Quality
|
|
296
|
+
|
|
297
|
+
We maintain high code quality standards:
|
|
298
|
+
|
|
299
|
+
- **Linting**: Ruff for fast, comprehensive linting
|
|
300
|
+
- **Formatting**: Ruff formatter for consistent code style
|
|
301
|
+
- **Type Checking**: Pyright for static type analysis
|
|
302
|
+
- **Testing**: Pytest for comprehensive test coverage
|
|
303
|
+
|
|
304
|
+
Run all checks:
|
|
305
|
+
```bash
|
|
306
|
+
uv run ruff check . && uv run ruff format --check . && uv run pyright . && uv run pytest
|
|
307
|
+
```
|
|
308
|
+
|
|
309
|
+
## Configuration
|
|
310
|
+
|
|
311
|
+
### Reasoning Effort
|
|
312
|
+
|
|
313
|
+
- Set default via env var: `VIBECORE_REASONING_EFFORT` (minimal | low | medium | high)
|
|
314
|
+
- Keyword triggers: `think` → low, `think hard` → medium, `ultrathink` → high
|
|
315
|
+
|
|
316
|
+
### Environment Variables
|
|
317
|
+
|
|
318
|
+
```bash
|
|
319
|
+
# Model configuration
|
|
320
|
+
ANTHROPIC_API_KEY=sk-... # For Claude models
|
|
321
|
+
OPENAI_API_KEY=sk-... # For GPT models
|
|
322
|
+
|
|
323
|
+
# OpenAI Models
|
|
324
|
+
VIBECORE_DEFAULT_MODEL=o3
|
|
325
|
+
VIBECORE_DEFAULT_MODEL=gpt-4.1
|
|
326
|
+
# Claude
|
|
327
|
+
VIBECORE_DEFAULT_MODEL=anthropic/claude-sonnet-4-20250514
|
|
328
|
+
# Use any LiteLLM supported models
|
|
329
|
+
VIBECORE_DEFAULT_MODEL=litellm/deepseek/deepseek-chat
|
|
330
|
+
# Local models. Use with OPENAI_BASE_URL
|
|
331
|
+
VIBECORE_DEFAULT_MODEL=qwen3-30b-a3b-mlx@8bit
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
## Contributing
|
|
335
|
+
|
|
336
|
+
We welcome contributions! Here's how to get started:
|
|
337
|
+
|
|
338
|
+
1. **Fork the repository** and create your branch from `main`
|
|
339
|
+
2. **Make your changes** and ensure all tests pass
|
|
340
|
+
3. **Add tests** for any new functionality
|
|
341
|
+
4. **Update documentation** as needed
|
|
342
|
+
5. **Submit a pull request** with a clear description
|
|
343
|
+
|
|
344
|
+
### Development Guidelines
|
|
345
|
+
|
|
346
|
+
- Follow the existing code style and patterns
|
|
347
|
+
- Write descriptive commit messages
|
|
348
|
+
- Add type hints to all functions
|
|
349
|
+
- Ensure your code passes all quality checks
|
|
350
|
+
- Update tests for any changes
|
|
351
|
+
|
|
352
|
+
### Reporting Issues
|
|
353
|
+
|
|
354
|
+
Found a bug or have a feature request? Please [open an issue](https://github.com/serialx/vibecore/issues) with:
|
|
355
|
+
- Clear description of the problem or feature
|
|
356
|
+
- Steps to reproduce (for bugs)
|
|
357
|
+
- Expected vs actual behavior
|
|
358
|
+
- Environment details (OS, Python version)
|
|
359
|
+
|
|
360
|
+
## Architecture
|
|
361
|
+
|
|
362
|
+
vibecore is built with a modular, extensible architecture:
|
|
363
|
+
|
|
364
|
+
- **Textual Framework**: Provides the responsive TUI foundation
|
|
365
|
+
- **OpenAI Agents SDK**: Powers the AI agent capabilities
|
|
366
|
+
- **Async Design**: Ensures smooth, non-blocking interactions
|
|
367
|
+
- **Tool System**: Modular tools with consistent interfaces
|
|
368
|
+
- **Context Management**: Maintains state across operations
|
|
369
|
+
|
|
370
|
+
## Recent Updates
|
|
371
|
+
|
|
372
|
+
- **Reasoning View**: New ReasoningMessage widget with live reasoning summaries during streaming
|
|
373
|
+
- **Context Usage Bar & CWD**: Footer shows token usage progress and current working directory
|
|
374
|
+
- **Keyboard & Commands**: Ctrl+Shift+D toggles theme, Esc cancels, Ctrl+D double-press to exit, `/help` and `/clear` commands
|
|
375
|
+
- **MCP Tool Output**: Improved rendering with Markdown and JSON prettification
|
|
376
|
+
- **MCP Support**: Full integration with Model Context Protocol for external tool connections
|
|
377
|
+
- **Print Mode**: `-p` flag to print response and exit for pipes/automation
|
|
378
|
+
|
|
379
|
+
## Roadmap
|
|
380
|
+
|
|
381
|
+
- [x] More custom tool views (Python, Read, Todo widgets)
|
|
382
|
+
- [x] Automation (vibecore -p "prompt")
|
|
383
|
+
- [x] MCP (Model Context Protocol) support
|
|
384
|
+
- [ ] Permission model
|
|
385
|
+
- [ ] Multi-agent system (agent-as-tools)
|
|
386
|
+
- [ ] Plugin system for custom tools
|
|
387
|
+
- [ ] Automated workflow
|
|
388
|
+
|
|
389
|
+
## License
|
|
390
|
+
|
|
391
|
+
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
|
|
392
|
+
|
|
393
|
+
## Acknowledgments
|
|
394
|
+
|
|
395
|
+
- Built with [Textual](https://textual.textualize.io/) - The amazing TUI framework
|
|
396
|
+
- Powered by [OpenAI Agents SDK](https://github.com/openai/openai-agents-python)
|
|
397
|
+
- Inspired by the growing ecosystem of terminal-based AI tools
|
|
398
|
+
|
|
399
|
+
---
|
|
400
|
+
|
|
401
|
+
<div align="center">
|
|
402
|
+
|
|
403
|
+
**Made with love by the vibecore community**
|
|
404
|
+
|
|
405
|
+
[Report Bug](https://github.com/serialx/vibecore/issues) " [Request Feature](https://github.com/serialx/vibecore/issues) " [Join Discussions](https://github.com/serialx/vibecore/discussions)
|
|
406
|
+
|
|
407
|
+
</div>
|