nimcode 0.3.0__tar.gz → 0.3.2__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.
- {nimcode-0.3.0 → nimcode-0.3.2}/PKG-INFO +13 -13
- {nimcode-0.3.0 → nimcode-0.3.2}/README.md +136 -134
- {nimcode-0.3.0 → nimcode-0.3.2}/setup.cfg +4 -4
- {nimcode-0.3.0 → nimcode-0.3.2}/setup.py +22 -22
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/agent.py +425 -425
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/cli.py +166 -166
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/config.py +55 -55
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/lenient_parser.py +107 -107
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/memory.py +69 -69
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/nim_client.py +150 -150
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/permissions.py +124 -124
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/plugin_manager.py +53 -53
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/rag.py +121 -121
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/repl.py +1199 -1199
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/tools.py +766 -766
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/updater.py +34 -34
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/watcher.py +81 -81
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/PKG-INFO +13 -13
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_agent.py +300 -300
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_cli.py +112 -112
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_config.py +67 -67
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_lenient_parser.py +67 -67
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_mcp_client.py +135 -135
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_memory.py +79 -79
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_nim_client.py +149 -149
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_permissions.py +84 -84
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_plugin_manager.py +53 -53
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_repl.py +387 -387
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_repl_extra.py +136 -136
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_repl_trust.py +55 -55
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_tools.py +338 -338
- {nimcode-0.3.0 → nimcode-0.3.2}/tests/test_updater.py +41 -41
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/__init__.py +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode/mcp_client.py +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/SOURCES.txt +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/dependency_links.txt +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/entry_points.txt +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/requires.txt +0 -0
- {nimcode-0.3.0 → nimcode-0.3.2}/src/nimcode.egg-info/top_level.txt +0 -0
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
Metadata-Version: 2.4
|
|
2
|
-
Name: nimcode
|
|
3
|
-
Version: 0.3.
|
|
4
|
-
Summary: A standalone, robust coding agent for NVIDIA NIM models.
|
|
5
|
-
Author: Autonomous Agent
|
|
6
|
-
Requires-Dist: httpx>=0.27.0
|
|
7
|
-
Requires-Dist: rich>=13.7.0
|
|
8
|
-
Requires-Dist: prompt_toolkit>=3.0.0
|
|
9
|
-
Requires-Dist: mcp>=1.2.0
|
|
10
|
-
Requires-Dist: watchdog>=3.0.0
|
|
11
|
-
Dynamic: author
|
|
12
|
-
Dynamic: requires-dist
|
|
13
|
-
Dynamic: summary
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: nimcode
|
|
3
|
+
Version: 0.3.2
|
|
4
|
+
Summary: A standalone, robust coding agent for NVIDIA NIM models.
|
|
5
|
+
Author: Autonomous Agent
|
|
6
|
+
Requires-Dist: httpx>=0.27.0
|
|
7
|
+
Requires-Dist: rich>=13.7.0
|
|
8
|
+
Requires-Dist: prompt_toolkit>=3.0.0
|
|
9
|
+
Requires-Dist: mcp>=1.2.0
|
|
10
|
+
Requires-Dist: watchdog>=3.0.0
|
|
11
|
+
Dynamic: author
|
|
12
|
+
Dynamic: requires-dist
|
|
13
|
+
Dynamic: summary
|
|
@@ -1,134 +1,136 @@
|
|
|
1
|
-
<div align="center">
|
|
2
|
-
|
|
3
|
-
# 🚀 NimCode
|
|
4
|
-
|
|
5
|
-
**The Autonomous AI Coding Assistant for the NVIDIA NIM Ecosystem**
|
|
6
|
-
|
|
7
|
-
[](https://badge.fury.io/py/nimcode)
|
|
8
|
-
[](https://opensource.org/licenses/MIT)
|
|
9
|
-
|
|
10
|
-
*A powerful, standalone REPL and CLI agent that writes, edits, and plans code like a senior developer—powered by LLaMa 3.1 70B (and other cutting-edge models) and the lightning-fast NVIDIA NIM API.*
|
|
11
|
-
|
|
12
|
-
</div>
|
|
13
|
-
|
|
14
|
-
---
|
|
15
|
-
|
|
16
|
-
## 🌟 Overview
|
|
17
|
-
|
|
18
|
-
NimCode is your autonomous coding pair-programmer. Built with a rich interactive terminal interface, it doesn't just autocomplete code—it plans architectures, executes terminal commands, writes complete files, formats code automatically, and manages your workspace.
|
|
19
|
-
|
|
20
|
-
### 🛠️ What We've Built So Far
|
|
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
|
-
- `.nimcode/
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+
# 🚀 NimCode
|
|
4
|
+
|
|
5
|
+
**The Autonomous AI Coding Assistant for the NVIDIA NIM Ecosystem**
|
|
6
|
+
|
|
7
|
+
[](https://badge.fury.io/py/nimcode)
|
|
8
|
+
[](https://opensource.org/licenses/MIT)
|
|
9
|
+
|
|
10
|
+
*A powerful, standalone REPL and CLI agent that writes, edits, and plans code like a senior developer—powered by LLaMa 3.1 70B (and other cutting-edge models) and the lightning-fast NVIDIA NIM API.*
|
|
11
|
+
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## 🌟 Overview
|
|
17
|
+
|
|
18
|
+
NimCode is your autonomous coding pair-programmer. Built with a rich interactive terminal interface, it doesn't just autocomplete code—it plans architectures, executes terminal commands, writes complete files, formats code automatically, and manages your workspace.
|
|
19
|
+
|
|
20
|
+
### 🛠️ What We've Built So Far
|
|
21
|
+
- **VS Code Deep Integration**: Native IPC communication allowing NimCode to read active editors, send patches, and act as your intelligent coding panel within VS Code.
|
|
22
|
+
- **RAG & Semantic Search**: Zero-dependency TF-IDF/BM25 based indexer that instantly scans massive workspaces and retrieves context-aware code snippets.
|
|
23
|
+
- **Autonomous Auto-Fixer**: The `/fix` command creates a self-healing feedback loop—it runs your broken commands, analyzes the tracebacks, and automatically iterates on code patches until the build passes.
|
|
24
|
+
- **Multi-Model & Local Support**: Flexible `api_base_url` configuration to seamlessly switch between NVIDIA NIM, Ollama, or vLLM endpoints.
|
|
25
|
+
- **Smart Permission Engine**: Granular control over file writes and command executions, featuring an auto-bypass mechanism and interactive `(a)ccept / (r)eject` diff previews.
|
|
26
|
+
- **Robust Interactive REPL**: Multiline support (Alt+Enter), syntax highlighting, and beautiful `rich`-powered UI menus.
|
|
27
|
+
- **Automated Workflows**: Automatic linting and formatting using `black`, `flake8`, and `prettier` behind the scenes.
|
|
28
|
+
- **Model Context Protocol (MCP)**: Native integration for MCP tools allowing infinite extensibility.
|
|
29
|
+
|
|
30
|
+
### 🚀 What We're Working On (Roadmap)
|
|
31
|
+
- **Sub-agent Swarms**: Perfecting `/delegate` and `/swarm` to distribute complex tasks among specialized AI roles.
|
|
32
|
+
- **Advanced Diagnostics**: Refining `/bughunter`, `/security-review`, and `/doctor` for automated codebase auditing.
|
|
33
|
+
- **Test-Driven Development**: Upgrading `/tdd` and `/testgen` to automatically write tests and ensure 100% coverage before committing.
|
|
34
|
+
- **Infrastructure & DevOps**: Implementing `/terraform-god` and `/sql-tune` for automated cloud provisioning and database query optimization.
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## 📦 Installation
|
|
39
|
+
|
|
40
|
+
NimCode is available globally via PyPI. You can install it anywhere in seconds:
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
pip install nimcode
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
## 🚀 Quick Start
|
|
47
|
+
|
|
48
|
+
1. **Get an API Key**: Grab a free NVIDIA API key from [build.nvidia.com](https://build.nvidia.com/).
|
|
49
|
+
2. **Login**: Connect your local environment by running:
|
|
50
|
+
```bash
|
|
51
|
+
nimcode login
|
|
52
|
+
```
|
|
53
|
+
3. **Start Coding**:
|
|
54
|
+
- Launch the interactive REPL:
|
|
55
|
+
```bash
|
|
56
|
+
nimcode
|
|
57
|
+
```
|
|
58
|
+
- Or run a one-off task directly from the command line:
|
|
59
|
+
```bash
|
|
60
|
+
nimcode /plan "Build a classic Snake game using HTML5 Canvas"
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## 💻 Complete Command Reference
|
|
66
|
+
|
|
67
|
+
Inside the `nimcode` REPL, you can type natural language or use any of the following slash commands to trigger specific workflows:
|
|
68
|
+
|
|
69
|
+
### Mode Toggles & Execution
|
|
70
|
+
- **`/code`**: Enter standard coding mode (default mode, prompts for dangerous actions).
|
|
71
|
+
- **`/plan`**: Enter planning mode (read-only safe mode). The AI will research and write a markdown plan before modifying code.
|
|
72
|
+
- **`/trust`**: Enter trust mode. The AI will run commands and edit files completely autonomously without asking for `(a)ccept / (r)eject`.
|
|
73
|
+
- **`/untrust`**: Disable trust mode and restore permission prompts.
|
|
74
|
+
|
|
75
|
+
### Interface & Settings
|
|
76
|
+
- **`/models`**: Open an interactive UI to select your preferred NVIDIA NIM model (e.g., meta/llama-3.1-70b-instruct).
|
|
77
|
+
- **`/theme`**: Open an interactive UI to change your syntax highlighting theme (e.g., monokai, dracula, nord, github).
|
|
78
|
+
- **`/config`**: View and edit global NimCode configuration settings.
|
|
79
|
+
|
|
80
|
+
### Workspace & Context Management
|
|
81
|
+
- **`/clear`**: Clear the current conversation history to reset context.
|
|
82
|
+
- **`/compact`**: Compact the context window to save tokens while keeping essential memories.
|
|
83
|
+
- **`/context`**: View and manage the loaded context window.
|
|
84
|
+
- **`/rewind`**: Rewind the conversation history by a few steps.
|
|
85
|
+
- **`/undo`**: Revert the last file modification made by the AI.
|
|
86
|
+
|
|
87
|
+
### Project & Search
|
|
88
|
+
- **`/index`**: Index the current project files to enable lightning-fast Semantic Search.
|
|
89
|
+
- **`/map`**: Generate a high-level semantic architecture map of the codebase.
|
|
90
|
+
- **`/research`**: Enter deep-research mode for reading documentation or large files.
|
|
91
|
+
|
|
92
|
+
### Automation & Git
|
|
93
|
+
- **`/commit`**: Analyze all staged git changes and automatically generate a conventional commit message.
|
|
94
|
+
- **`/fix`**: Run a specific shell command and let the AI automatically iterate to fix any resulting errors.
|
|
95
|
+
- **`/autofix-pr`**: Pulls the current active GitHub Pull Request, reads comments, and automatically fixes the mentioned issues.
|
|
96
|
+
|
|
97
|
+
### Advanced Development Modes
|
|
98
|
+
- **`/testgen <file>`**: Generate unit tests for a specific file, aiming for 100% coverage.
|
|
99
|
+
- **`/tdd`**: Enter Test-Driven Development mode. The AI will write tests first, verify they fail, and then implement the code to pass them.
|
|
100
|
+
- **`/bughunter`**: Initiate an automated search for logical bugs and edge cases across the codebase.
|
|
101
|
+
- **`/security-review`**: Audit the codebase for common vulnerabilities (e.g., OWASP top 10).
|
|
102
|
+
- **`/sql-tune`**: Database telepathy mode. Analyzes and auto-tunes SQL queries for maximum performance.
|
|
103
|
+
- **`/terraform-god`**: Cloud architect mode. Auto-provisions scalable best-practice Terraform infrastructure.
|
|
104
|
+
- **`/decompile <binary>`**: Reverse engineering mode using tools like `objdump` and `radare2`.
|
|
105
|
+
|
|
106
|
+
### AI & Agents
|
|
107
|
+
- **`/delegate <role> <task>`**: Spawn an independent sub-agent with a specific role to handle a background task.
|
|
108
|
+
- **`/swarm`**: Orchestrate multiple sub-agents to tackle a complex architectural epic simultaneously.
|
|
109
|
+
- **`/grill-me`**: Interrogation mode. The AI will ask *you* hard questions to refine your system design and edge cases.
|
|
110
|
+
- **`/learn`**: Teach NimCode a new persistent skill or framework rule that it will remember for future sessions.
|
|
111
|
+
- **`/vision`**: Capture the screen and analyze UI elements using Vision AI models.
|
|
112
|
+
- **`/voice`**: Record your voice for 5 seconds and transcribe it as a prompt.
|
|
113
|
+
- **`/mcp install`**: Install and configure new Model Context Protocol tools.
|
|
114
|
+
|
|
115
|
+
---
|
|
116
|
+
|
|
117
|
+
## ⚙️ How it Works
|
|
118
|
+
|
|
119
|
+
NimCode creates a `.nimcode` directory inside your projects. This directory acts as the "brain" for that specific workspace:
|
|
120
|
+
- `.nimcode/plans/`: All your generated step-by-step markdown plans live here.
|
|
121
|
+
- `.nimcode/skills/`: Any custom guidelines, framework rules, or memories you teach the agent.
|
|
122
|
+
- `.nimcode/history/`: File backups for `/undo` capabilities.
|
|
123
|
+
|
|
124
|
+
## 🛡️ Requirements
|
|
125
|
+
|
|
126
|
+
- Python 3.8+
|
|
127
|
+
- An NVIDIA NIM API Key (`NIM_API_KEY`)
|
|
128
|
+
|
|
129
|
+
## 🤝 Contributing
|
|
130
|
+
|
|
131
|
+
Contributions, issues, and feature requests are welcome! Feel free to check out our [issues page](#).
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
<div align="center">
|
|
135
|
+
<i>Built with ❤️ for the open-source developer community.</i>
|
|
136
|
+
</div>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
[egg_info]
|
|
2
|
-
tag_build =
|
|
3
|
-
tag_date = 0
|
|
4
|
-
|
|
1
|
+
[egg_info]
|
|
2
|
+
tag_build =
|
|
3
|
+
tag_date = 0
|
|
4
|
+
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
from setuptools import setup, find_packages
|
|
2
|
-
|
|
3
|
-
setup(
|
|
4
|
-
name="nimcode",
|
|
5
|
-
version="0.3.
|
|
6
|
-
packages=find_packages(where="src"),
|
|
7
|
-
package_dir={"": "src"},
|
|
8
|
-
install_requires=[
|
|
9
|
-
"httpx>=0.27.0",
|
|
10
|
-
"rich>=13.7.0",
|
|
11
|
-
"prompt_toolkit>=3.0.0",
|
|
12
|
-
"mcp>=1.2.0",
|
|
13
|
-
"watchdog>=3.0.0"
|
|
14
|
-
],
|
|
15
|
-
entry_points={
|
|
16
|
-
"console_scripts": [
|
|
17
|
-
"nimcode=nimcode.cli:main",
|
|
18
|
-
],
|
|
19
|
-
},
|
|
20
|
-
author="Autonomous Agent",
|
|
21
|
-
description="A standalone, robust coding agent for NVIDIA NIM models.",
|
|
22
|
-
)
|
|
1
|
+
from setuptools import setup, find_packages
|
|
2
|
+
|
|
3
|
+
setup(
|
|
4
|
+
name="nimcode",
|
|
5
|
+
version="0.3.2",
|
|
6
|
+
packages=find_packages(where="src"),
|
|
7
|
+
package_dir={"": "src"},
|
|
8
|
+
install_requires=[
|
|
9
|
+
"httpx>=0.27.0",
|
|
10
|
+
"rich>=13.7.0",
|
|
11
|
+
"prompt_toolkit>=3.0.0",
|
|
12
|
+
"mcp>=1.2.0",
|
|
13
|
+
"watchdog>=3.0.0"
|
|
14
|
+
],
|
|
15
|
+
entry_points={
|
|
16
|
+
"console_scripts": [
|
|
17
|
+
"nimcode=nimcode.cli:main",
|
|
18
|
+
],
|
|
19
|
+
},
|
|
20
|
+
author="Autonomous Agent",
|
|
21
|
+
description="A standalone, robust coding agent for NVIDIA NIM models.",
|
|
22
|
+
)
|