devagent-cli 3.2.1__tar.gz

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.
Files changed (35) hide show
  1. devagent_cli-3.2.1/LICENSE +21 -0
  2. devagent_cli-3.2.1/PKG-INFO +480 -0
  3. devagent_cli-3.2.1/README.md +454 -0
  4. devagent_cli-3.2.1/devagent/__init__.py +1 -0
  5. devagent_cli-3.2.1/devagent/app/__init__.py +1 -0
  6. devagent_cli-3.2.1/devagent/app/agent.py +717 -0
  7. devagent_cli-3.2.1/devagent/app/llm.py +83 -0
  8. devagent_cli-3.2.1/devagent/app/memory.py +309 -0
  9. devagent_cli-3.2.1/devagent/app/patcher.py +83 -0
  10. devagent_cli-3.2.1/devagent/app/planner.py +76 -0
  11. devagent_cli-3.2.1/devagent/app/reviewer.py +65 -0
  12. devagent_cli-3.2.1/devagent/app/sandbox.py +105 -0
  13. devagent_cli-3.2.1/devagent/app/state.py +113 -0
  14. devagent_cli-3.2.1/devagent/cli.py +282 -0
  15. devagent_cli-3.2.1/devagent/tools/__init__.py +1 -0
  16. devagent_cli-3.2.1/devagent/tools/benchmark_runner.py +184 -0
  17. devagent_cli-3.2.1/devagent/tools/file_ops.py +52 -0
  18. devagent_cli-3.2.1/devagent/tools/git_tools.py +91 -0
  19. devagent_cli-3.2.1/devagent/tools/linter.py +55 -0
  20. devagent_cli-3.2.1/devagent/tools/search.py +65 -0
  21. devagent_cli-3.2.1/devagent/tools/semantic_search.py +60 -0
  22. devagent_cli-3.2.1/devagent/tools/surgical_patcher.py +39 -0
  23. devagent_cli-3.2.1/devagent/tools/test_runner.py +143 -0
  24. devagent_cli-3.2.1/devagent/utils/__init__.py +1 -0
  25. devagent_cli-3.2.1/devagent/utils/config.py +116 -0
  26. devagent_cli-3.2.1/devagent/utils/logger.py +94 -0
  27. devagent_cli-3.2.1/devagent/utils/metrics.py +130 -0
  28. devagent_cli-3.2.1/devagent_cli.egg-info/PKG-INFO +480 -0
  29. devagent_cli-3.2.1/devagent_cli.egg-info/SOURCES.txt +33 -0
  30. devagent_cli-3.2.1/devagent_cli.egg-info/dependency_links.txt +1 -0
  31. devagent_cli-3.2.1/devagent_cli.egg-info/entry_points.txt +2 -0
  32. devagent_cli-3.2.1/devagent_cli.egg-info/requires.txt +11 -0
  33. devagent_cli-3.2.1/devagent_cli.egg-info/top_level.txt +1 -0
  34. devagent_cli-3.2.1/pyproject.toml +43 -0
  35. devagent_cli-3.2.1/setup.cfg +4 -0
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Vedant Jadhav
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,480 @@
1
+ Metadata-Version: 2.4
2
+ Name: devagent-cli
3
+ Version: 3.2.1
4
+ Summary: Professional Local autonomous coding agent powered by Ollama
5
+ Author: Vedant Jadhav
6
+ License: MIT
7
+ Keywords: ai,agent,coding,ollama,local,devagent,devagent-cli
8
+ Classifier: Programming Language :: Python :: 3
9
+ Classifier: License :: OSI Approved :: MIT License
10
+ Classifier: Operating System :: OS Independent
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Topic :: Software Development :: Interpreters
13
+ Requires-Python: >=3.11
14
+ Description-Content-Type: text/markdown
15
+ License-File: LICENSE
16
+ Requires-Dist: rich
17
+ Requires-Dist: pytest
18
+ Requires-Dist: requests
19
+ Requires-Dist: ollama
20
+ Requires-Dist: faiss-cpu
21
+ Provides-Extra: semantic
22
+ Requires-Dist: sentence-transformers; extra == "semantic"
23
+ Provides-Extra: lint
24
+ Requires-Dist: flake8; extra == "lint"
25
+ Dynamic: license-file
26
+
27
+ <div align="center">
28
+
29
+ # 🧠 DevAgent
30
+
31
+ ### A Lightweight Local Open-Source Miniature of Claude Code CLI
32
+
33
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
34
+ [![Python 3.11+](https://img.shields.io/badge/Python-3.11+-3776AB.svg?logo=python&logoColor=white)](https://www.python.org/)
35
+ [![Ollama](https://img.shields.io/badge/Ollama-Local%20LLM-black.svg?logo=ollama)](https://ollama.ai)
36
+ [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](CONTRIBUTING.md)
37
+ [![GitHub stars](https://img.shields.io/github/stars/VedantJadhav701/Developer-Code-Intelligence-Agent?style=social)](https://github.com/VedantJadhav701/Developer-Code-Intelligence-Agent)
38
+
39
+ **A production-grade local coding agent that finds bugs, writes patches, reviews its own code, and validates with tests β€” all offline, all local, zero API costs.**
40
+
41
+ [Quick Start](#-quick-start) β€’
42
+ [Architecture](#-architecture) β€’
43
+ [Benchmarks](#-benchmarks) β€’
44
+ [Roadmap](#-roadmap) β€’
45
+ [Contributing](#-contributing)
46
+
47
+ ---
48
+
49
+ </div>
50
+
51
+ ## πŸ€” Why DevAgent?
52
+
53
+ Most AI coding tools are **chatbots** β€” they suggest code, you copy-paste, you pray.
54
+
55
+ DevAgent is a **real agent** with a retrieval-first, tool-grounded architecture:
56
+
57
+ | | Chatbot | DevAgent |
58
+ |---|---|---|
59
+ | Searches your codebase | ❌ | βœ… ripgrep + semantic search |
60
+ | Retrieves relevant code | ❌ | βœ… FAISS embeddings |
61
+ | Plans before coding | ❌ | βœ… Planner layer |
62
+ | Generates patches | ❌ | βœ… Unified diffs |
63
+ | Reviews its own output | ❌ | βœ… Self-critique loop |
64
+ | Runs your tests | ❌ | βœ… pytest integration |
65
+ | Retries on failure | ❌ | βœ… Up to N iterations |
66
+ | Works in sandbox | ❌ | βœ… Isolated workspace |
67
+ | Works offline | ❌ | βœ… 100% local via Ollama |
68
+ | Costs money | πŸ’Έ | βœ… Free forever |
69
+
70
+ > **Philosophy:** Execution > Reasoning. Tools > Hallucination. Retrieval > Huge Context. Reliability > Intelligence.
71
+
72
+ ---
73
+
74
+ ## ✨ Features
75
+
76
+ πŸ” **ReAct Loop** β€” Thought β†’ Action β†’ Observation β†’ Fix β†’ Review β†’ Test cycle
77
+
78
+ 🧠 **Planner** β€” LLM generates an action plan before coding
79
+
80
+ πŸ” **Semantic Search** β€” FAISS + sentence-transformers code retrieval
81
+
82
+ πŸ”Ž **Code Search** β€” ripgrep-powered with cross-platform fallback
83
+
84
+ πŸ“ **Self-Review** β€” LLM critiques its own fixes, revises until approved
85
+
86
+ 🩹 **Patch Engine** β€” Line-level unified diffs instead of full file rewrites
87
+
88
+ πŸ§ͺ **Test-Driven** β€” Runs pytest after every fix, retries on failure
89
+
90
+ πŸ–οΈ **Sandbox Mode** β€” Agent works in an isolated copy, applies changes only on success
91
+
92
+ πŸ“Š **Benchmarks** β€” 5 built-in benchmark suites with automated evaluation
93
+
94
+ πŸ“ˆ **Metrics** β€” Latency, token estimates, retries, and performance tracking
95
+
96
+ πŸ“‹ **Full Audit Trail** β€” Every step logged to `logs/run.json`
97
+
98
+ πŸ”’ **100% Offline** β€” Runs on Ollama with small models (2-4 GB)
99
+
100
+ ⚑ **Low Resource** β€” Works on RTX 3050 (4 GB VRAM) / 16 GB RAM
101
+
102
+ ---
103
+
104
+ ## πŸš€ Quick Start
105
+
106
+ ### Prerequisites
107
+
108
+ - [Python 3.11+](https://www.python.org/downloads/)
109
+ - [Ollama](https://ollama.ai) installed and running
110
+
111
+ ### Install & Setup
112
+
113
+ ```bash
114
+ # 1. Clone
115
+ git clone https://github.com/VedantJadhav701/Developer-Code-Intelligence-Agent.git
116
+ cd Developer-Code-Intelligence-Agent
117
+
118
+ # 2. Install
119
+ pip install devagent-cli # (Coming soon to PyPI)
120
+ # Or locally: pip install -e .
121
+
122
+ # 3. Verify System (CRITICAL)
123
+ # This checks your Python environment, Ollama connection, and dependencies
124
+ devagent doctor
125
+
126
+ # 4. Pull the model
127
+ ollama pull qwen2.5-coder:3b
128
+
129
+ # 5. Run!
130
+ devagent run --task "Fix the divide-by-zero bug" --root ./demo_project
131
+ ```
132
+
133
+ ### CLI Subcommands
134
+
135
+ | Command | Description |
136
+ |---|---|
137
+ | `devagent run` | Execute a coding task on a project |
138
+ | `devagent benchmark` | Run the automated benchmark suite |
139
+ | `devagent doctor` | Check system health and dependencies |
140
+ | `devagent models` | List available Ollama models |
141
+ | `devagent version` | Show current version |
142
+
143
+ ### ✨ New: Trust & Safety
144
+
145
+ #### πŸ›‘οΈ Reliability Hardening (v3.2.1+)
146
+ DevAgent is now built for **Enterprise-grade reliability** in complex projects:
147
+ - **Path Anchoring**: Automatically corrects "root hallucinations." If the agent targets a file in a subdirectory but assumes it's at the root, the system auto-anchors it to the correct project location.
148
+ - **Forensic Test Detection**: Built-in intelligence to "see through" environment noise. It detects successful test runs even if unrelated parts of the repository have collection errors.
149
+ - **Confidence Scoring**: Every fix is graded (0-100%) based on test results, surgical precision, and self-review quality.
150
+
151
+ #### πŸ•ΉοΈ Interactive Mode
152
+ Run with `--interactive` (or `-i`) to review diffs before they are applied to your project.
153
+ ```bash
154
+ devagent run --task "Fix bug" --interactive
155
+ ```
156
+
157
+ ---
158
+
159
+ ## πŸ—οΈ Architecture
160
+
161
+ ```mermaid
162
+ graph TD
163
+ CLI[DevAgent CLI] --> Orchestrator[ReAct Orchestrator]
164
+ Orchestrator --> Memory[Working Memory]
165
+ Orchestrator --> Retrieval[Semantic Retrieval FAISS]
166
+ Orchestrator --> Tools[Tool Suite: pytest, ripgrep, git]
167
+ Orchestrator --> Reviewer[Self-Review Loop]
168
+ Reviewer --> Patch[Surgical Patch Engine]
169
+ Patch --> Sandbox[Sandbox Environment]
170
+ ```
171
+
172
+ No API keys. No sign-ups. No cloud.
173
+
174
+ ### Optional: Enable Semantic Search
175
+
176
+ ```bash
177
+ pip install faiss-cpu sentence-transformers
178
+ ```
179
+
180
+ Without these, DevAgent falls back to keyword search β€” still fully functional.
181
+
182
+ ---
183
+
184
+ ## 🎬 Demo
185
+
186
+ ```
187
+ ____ _ _
188
+ | _ \ _____ __/ \ __ _ ___ _ __ | |_
189
+ | | | |/ _ \ \ / / _ \ / _` |/ _ \ '_ \| __|
190
+ | |_| | __/\ V / ___ \ (_| | __/ | | | |_
191
+ |____/ \___| \_/_/ \_\__, |\___|_| |_|\__|
192
+ |___/
193
+
194
+ +==========================================================+
195
+ | DEVELOPER CODE INTELLIGENCE AGENT |
196
+ | Model: qwen2.5-coder:3b |
197
+ | Sandbox: OFF |
198
+ +==========================================================+
199
+
200
+ [PLAN] LIKELY_FILES: calculator.py
201
+ 1. search_code: divide
202
+ 2. read_file: calculator.py
203
+ 3. run_tests
204
+
205
+ ----------------------------------------
206
+ ITERATION 1/5
207
+ ----------------------------------------
208
+ [TOOL] Executing: search_code(divide)
209
+ >> Found: calculator.py:10:def divide(a, b)
210
+ [REVIEW] #1: APPROVED
211
+ >> Tests: 5 passed βœ“
212
+
213
+ [OK] AGENT COMPLETED SUCCESSFULLY
214
+
215
+ Status: success
216
+ Steps used: 1/5
217
+ Patches: 1
218
+ Time: 8.2s
219
+ ```
220
+
221
+ ---
222
+
223
+ ## πŸ—οΈ Architecture
224
+
225
+ ```
226
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
227
+ β”‚ CLI (main.py) β”‚
228
+ β”‚ --task --root --model β”‚
229
+ β”‚ --sandbox --benchmark β”‚
230
+ β”‚ --auto-commit --auto-push β”‚
231
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
232
+ β”‚
233
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
234
+ β”‚ Planner Layer β”‚
235
+ β”‚ Identifies files + strategy β”‚
236
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
237
+ β”‚
238
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
239
+ β”‚ Retrieval Layer (Memory) β”‚
240
+ β”‚ FAISS + Sentence-Transformersβ”‚
241
+ β”‚ Chunk β†’ Embed β†’ Top-K β”‚
242
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
243
+ β”‚
244
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
245
+ β”‚ ReAct Agent Loop β”‚
246
+ β”‚ β”‚
247
+ β”‚ 1. THOUGHT (LLM) β”‚
248
+ β”‚ 2. ACTION (Tool) β”‚
249
+ β”‚ 3. OBSERVATION β”‚
250
+ β”‚ 4. FIX (LLM) β”‚
251
+ β”‚ 5. REVIEW (LLM) β”‚
252
+ β”‚ 6. PATCH (Diff Engine) β”‚
253
+ β”‚ 7. TEST (pytest) β”‚
254
+ β”‚ β”‚
255
+ β”‚ if FAIL β†’ retry β”‚
256
+ β”‚ if PASS β†’ done βœ“ β”‚
257
+ β””β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
258
+ β”‚ β”‚
259
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”
260
+ β”‚ Tools β”‚ β”‚ Ollama β”‚
261
+ β”‚ β”‚ β”‚ (Local) β”‚
262
+ β”‚ β€’ search β”‚ β”‚ β”‚
263
+ β”‚ β€’ semanticβ”‚ β”‚ qwen2.5- β”‚
264
+ β”‚ β€’ read β”‚ β”‚ coder:3b β”‚
265
+ β”‚ β€’ patch β”‚ β”‚ phi3:mini β”‚
266
+ β”‚ β€’ pytest β”‚ β”‚ mistral:7b β”‚
267
+ β”‚ β€’ flake8 β”‚ β”‚ β”‚
268
+ β”‚ β€’ git_diffβ”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
269
+ β”‚ β€’ sandbox β”‚
270
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
271
+ ```
272
+
273
+ ### 9-Layer Architecture
274
+
275
+ | Layer | Module | Purpose |
276
+ |---|---|---|
277
+ | 1. CLI | `main.py` | Argument parsing, mode selection, banner |
278
+ | 2. Planner | `app/planner.py` | Task interpretation, file identification |
279
+ | 3. Retrieval | `app/memory.py` | FAISS index, semantic chunking, Top-K search |
280
+ | 4. Tools | `tools/*` | 8 real tools: search, semantic_search, read, write, test, lint, git, sandbox |
281
+ | 5. Agent | `app/agent.py` | ReAct orchestration loop |
282
+ | 6. Review | `app/reviewer.py` | Self-critique with APPROVED/REVISE |
283
+ | 7. Validation | `tools/test_runner.py` | pytest + flake8 execution feedback |
284
+ | 8. Logging | `utils/logger.py` | Structured JSON audit trail |
285
+ | 9. Safety | `app/sandbox.py` | Isolated workspace, path validation |
286
+
287
+ ---
288
+
289
+ ## πŸ“ Project Structure
290
+
291
+ ```
292
+ Developer-Code-Intelligence-Agent/
293
+ β”œβ”€β”€ app/
294
+ β”‚ β”œβ”€β”€ agent.py # Core ReAct agent engine
295
+ β”‚ β”œβ”€β”€ planner.py # Task planning layer
296
+ β”‚ β”œβ”€β”€ reviewer.py # Self-review module
297
+ β”‚ β”œβ”€β”€ llm.py # Ollama integration
298
+ β”‚ β”œβ”€β”€ memory.py # FAISS retrieval + working memory
299
+ β”‚ β”œβ”€β”€ patcher.py # Unified diff patch engine
300
+ β”‚ β”œβ”€β”€ sandbox.py # Sandbox workspace manager
301
+ β”‚ └── state.py # Shared state dataclass
302
+ β”œβ”€β”€ tools/
303
+ β”‚ β”œβ”€β”€ search.py # Code search (ripgrep + fallbacks)
304
+ β”‚ β”œβ”€β”€ semantic_search.py # FAISS semantic search
305
+ β”‚ β”œβ”€β”€ file_ops.py # Safe file read/write
306
+ β”‚ β”œβ”€β”€ test_runner.py # pytest runner
307
+ β”‚ β”œβ”€β”€ linter.py # flake8 linter
308
+ β”‚ β”œβ”€β”€ git_tools.py # Git diff/commit/push
309
+ β”‚ └── benchmark_runner.py # Benchmark evaluation
310
+ β”œβ”€β”€ utils/
311
+ β”‚ β”œβ”€β”€ logger.py # Structured JSON logger
312
+ β”‚ β”œβ”€β”€ config.py # Centralized configuration
313
+ β”‚ └── metrics.py # Performance metrics
314
+ β”œβ”€β”€ benchmarks/
315
+ β”‚ β”œβ”€β”€ divide_by_zero/ # Benchmark: zero division guard
316
+ β”‚ β”œβ”€β”€ missing_validation/ # Benchmark: input validation
317
+ β”‚ β”œβ”€β”€ syntax_error/ # Benchmark: syntax fix
318
+ β”‚ β”œβ”€β”€ import_bug/ # Benchmark: wrong import
319
+ β”‚ └── edge_case/ # Benchmark: empty list handling
320
+ β”œβ”€β”€ demo_project/ # Sample buggy project
321
+ β”œβ”€β”€ docs/
322
+ β”‚ └── USER_GUIDE.md # Full usage guide
323
+ β”œβ”€β”€ main.py # CLI entry point
324
+ β”œβ”€β”€ devagent.py # Global CLI wrapper
325
+ β”œβ”€β”€ devagent.bat # Windows global shortcut
326
+ β”œβ”€β”€ requirements.txt
327
+ β”œβ”€β”€ CONTRIBUTING.md
328
+ β”œβ”€β”€ CHANGELOG.md
329
+ β”œβ”€β”€ CODE_OF_CONDUCT.md
330
+ β”œβ”€β”€ SECURITY.md
331
+ β”œβ”€β”€ LICENSE
332
+ └── README.md
333
+ ```
334
+
335
+ ---
336
+
337
+ ## πŸ’» CLI Reference
338
+
339
+ ```bash
340
+ python main.py --task "TASK" --root ./project [OPTIONS]
341
+ ```
342
+
343
+ | Flag | Default | Description |
344
+ |---|---|---|
345
+ | `--task`, `-t` | *(required)* | The coding task for the agent |
346
+ | `--root`, `-r` | `.` | Project root directory |
347
+ | `--model` | `qwen2.5-coder:3b` | Any Ollama model |
348
+ | `--max-steps`, `-m` | `5` | Max ReAct iterations |
349
+ | `--benchmark` | off | Run benchmark suite |
350
+ | `--sandbox` | off | Run in isolated sandbox |
351
+ | `--auto-commit` | off | Git commit on success |
352
+ | `--auto-push` | off | Git push after commit |
353
+ | `--verbose`, `-v` | off | Verbose output |
354
+
355
+ ### Examples
356
+
357
+ ```bash
358
+ # Fix a specific bug
359
+ python main.py -t "Fix the TypeError in user_service.py" -r ./backend
360
+
361
+ # Run in sandbox mode (safe β€” doesn't touch real files until success)
362
+ python main.py -t "Fix divide-by-zero bug" -r ./project --sandbox
363
+
364
+ # Auto-commit changes on success
365
+ python main.py -t "Add input validation" -r ./api --auto-commit
366
+
367
+ # Use a stronger model
368
+ python main.py -t "Refactor auth middleware" -r ./server --model mistral:7b
369
+
370
+ # Run benchmarks
371
+ python main.py --benchmark
372
+
373
+ # More retries for complex tasks
374
+ python main.py -t "Make all tests pass" -r ./project --max-steps 10
375
+ ```
376
+
377
+ > πŸ“– **[Full User Guide β†’](docs/USER_GUIDE.md)**
378
+
379
+ ---
380
+
381
+ ## πŸ“Š Benchmarks
382
+
383
+ DevAgent includes 5 built-in benchmarks to evaluate agent performance:
384
+
385
+ | Benchmark | Bug Type | Difficulty |
386
+ |---|---|---|
387
+ | `divide_by_zero` | Missing guard clause | Easy |
388
+ | `missing_validation` | No input validation | Medium |
389
+ | `syntax_error` | Broken syntax | Medium |
390
+ | `import_bug` | Wrong module name | Easy |
391
+ | `edge_case` | Empty list crash | Medium |
392
+
393
+ Run benchmarks:
394
+
395
+ ```bash
396
+ python main.py --benchmark
397
+ python main.py --benchmark --model phi3:mini
398
+ ```
399
+
400
+ ---
401
+
402
+ ## πŸ”§ Supported Models
403
+
404
+ | Model | Size | Speed | Quality | Best For |
405
+ |---|---|---|---|---|
406
+ | `qwen2.5-coder:3b` | 1.9 GB | ⚑ Fast | β˜…β˜…β˜…β˜… | **Default β€” best for code** |
407
+ | `qwen2.5:3b` | 1.9 GB | ⚑ Fast | β˜…β˜…β˜…β˜† | General fallback |
408
+ | `phi3:mini` | 2.2 GB | ⚑ Fast | β˜…β˜…β˜…β˜† | Good reasoning |
409
+ | `qwen3:4b` | 2.5 GB | ⚑ Fast | β˜…β˜…β˜…β˜… | Better understanding |
410
+ | `gemma2:2b` | 1.6 GB | ⚑⚑ | β˜…β˜…β˜†β˜† | Ultra-low resource |
411
+ | `mistral:7b` | 4.4 GB | 🐒 | β˜…β˜…β˜…β˜…β˜… | Best quality (8GB+ RAM) |
412
+
413
+ ---
414
+
415
+ ## πŸ—ΊοΈ Roadmap
416
+
417
+ ### βœ… Completed (v2.0)
418
+
419
+ - [x] Core ReAct agent loop
420
+ - [x] Self-review module
421
+ - [x] Tool system (9 tools)
422
+ - [x] Planner layer
423
+ - [x] Semantic retrieval (FAISS)
424
+ - [x] Patch engine (unified diffs)
425
+ - [x] Sandbox mode
426
+ - [x] Benchmark system (5 suites)
427
+ - [x] Metrics + structured logging
428
+ - [x] Git integration
429
+ - [x] CLI with all flags
430
+
431
+ ### πŸ”œ Coming Next
432
+
433
+ - [ ] **Multi-file support** β€” Agent works across multiple files simultaneously
434
+ - [ ] **Language support** β€” JavaScript, TypeScript, Go, Rust
435
+ - [ ] **Plugin system** β€” Custom tools via YAML/Python
436
+ - [ ] **Watch mode** β€” Auto-fix on test failure (`--watch`)
437
+ - [ ] **VS Code extension** β€” Run agent from your editor
438
+ - [ ] **Conversation memory** β€” Learn from past runs
439
+ - [ ] **Multi-agent mode** β€” Planner + Coder + Reviewer + Evaluator agents
440
+
441
+ ---
442
+
443
+ ## 🀝 Contributing
444
+
445
+ We welcome contributions! See [CONTRIBUTING.md](CONTRIBUTING.md) for details.
446
+
447
+ ```bash
448
+ git checkout -b feature/your-feature
449
+ # ... make changes ...
450
+ python -m pytest demo_project/ -v
451
+ git commit -m "feat: your feature"
452
+ git push origin feature/your-feature
453
+ ```
454
+
455
+ **Good first issues** are tagged and waiting:
456
+ [Browse good first issues β†’](https://github.com/VedantJadhav701/Developer-Code-Intelligence-Agent/labels/good%20first%20issue)
457
+
458
+ ---
459
+
460
+ ## πŸ“œ License
461
+
462
+ MIT β€” use it however you want. See [LICENSE](LICENSE).
463
+
464
+ ---
465
+
466
+ ## ⭐ Star History
467
+
468
+ If DevAgent helps you, give it a star! It helps others discover the project.
469
+
470
+ [![Star History Chart](https://api.star-history.com/svg?repos=VedantJadhav701/Developer-Code-Intelligence-Agent&type=Date)](https://star-history.com/#VedantJadhav701/Developer-Code-Intelligence-Agent&Date)
471
+
472
+ ---
473
+
474
+ <div align="center">
475
+
476
+ **Built with 🧠 by [Vedant Jadhav](https://github.com/VedantJadhav701)**
477
+
478
+ *A lightweight local open-source miniature of Claude Code CLI.*
479
+
480
+ </div>