savant-code 0.0.11 → 0.0.14

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 (2) hide show
  1. package/README.md +153 -107
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -1,107 +1,153 @@
1
- # The most powerful coding agent
2
-
3
- SavantCode is a CLI tool that writes code for you.
4
-
5
- 1. Run `savant-code` from your project directory
6
- 2. Tell it what to do
7
- 3. It will read and write to files and run commands to produce the code you want
8
-
9
- Note: SavantCode will run commands in your terminal as it deems necessary to fulfill your request.
10
-
11
- ## Installation
12
-
13
- To install SavantCode, run:
14
-
15
- ```bash
16
- npm install -g savant-code
17
- ```
18
-
19
- (Use `sudo` if you get a permission error.)
20
-
21
- ## Usage
22
-
23
- After installation, you can start SavantCode by running:
24
-
25
- ```bash
26
- savant-code [project-directory]
27
- ```
28
-
29
- If no project directory is specified, SavantCode will use the current directory.
30
-
31
- Once running, simply chat with SavantCode to say what coding task you want done.
32
-
33
- ## Features
34
-
35
- - Understands your whole codebase
36
- - Creates and edits multiple files based on your request
37
- - Can run your tests or type checker or linter; can install packages
38
- - It's powerful: ask SavantCode to keep working until it reaches a condition and it will.
39
-
40
- Our users regularly use SavantCode to implement new features, write unit tests, refactor code,write scripts, or give advice.
41
-
42
- ## Knowledge Files
43
-
44
- To unlock the full benefits of modern LLMs, we recommend storing knowledge alongside your code. Add a `knowledge.md` file anywhere in your project to provide helpful context, guidance, and tips for the LLM as it performs tasks for you.
45
-
46
- SavantCode can fluently read and write files, so it will add knowledge as it goes. You don't need to write knowledge manually!
47
-
48
- Some have said every change should be paired with a unit test. In 2024, every change should come with a knowledge update!
49
-
50
- ## Tips
51
-
52
- 1. Type '/help' or just '/' to see available commands.
53
- 2. Create a `knowledge.md` file and collect specific points of advice. The assistant will use this knowledge to improve its responses.
54
- 3. Type `undo` or `redo` to revert or reapply file changes from the conversation.
55
- 4. Press `Esc` or `Ctrl+C` while SavantCode is generating a response to stop it.
56
-
57
- ## Troubleshooting
58
-
59
- ### Permission Errors
60
-
61
- If you are getting permission errors during installation, try using sudo:
62
-
63
- ```
64
- sudo npm install -g savant-code
65
- ```
66
-
67
- If you still have errors, it's a good idea to [reinstall Node](https://nodejs.org/en/download).
68
-
69
- ### Corporate Proxy / Firewall
70
-
71
- If you see `Failed to download savant-code: Request timeout` or `Failed to determine latest version`, you may be behind a corporate proxy or firewall.
72
-
73
- SavantCode respects standard proxy environment variables. Set `HTTPS_PROXY` to route traffic through your proxy:
74
-
75
- **Linux / macOS (bash/zsh):**
76
- ```bash
77
- export HTTPS_PROXY=http://your-proxy-server:port
78
- savant-code
79
- ```
80
-
81
- **Windows (PowerShell):**
82
- ```powershell
83
- $env:HTTPS_PROXY = "http://your-proxy-server:port"
84
- savant-code
85
- ```
86
-
87
- **Windows (CMD):**
88
- ```cmd
89
- set HTTPS_PROXY=http://your-proxy-server:port
90
- savant-code
91
- ```
92
-
93
- To make it permanent, add the `export` or `set` line to your shell profile (e.g. `~/.bashrc`, `~/.zshrc`, or Windows System Environment Variables).
94
-
95
- **Supported environment variables:**
96
-
97
- | Variable | Purpose |
98
- |---|---|
99
- | `HTTPS_PROXY` / `https_proxy` | Proxy for HTTPS requests (recommended) |
100
- | `HTTP_PROXY` / `http_proxy` | Fallback proxy for HTTP requests |
101
- | `NO_PROXY` / `no_proxy` | Comma-separated list of hostnames to bypass the proxy (port suffixes are ignored) |
102
-
103
- Both `http://` and `https://` proxy URLs are supported. Proxy authentication is supported via URL credentials (e.g. `http://user:password@proxy:port`).
104
-
105
- ## Feedback
106
-
107
- We value your input! Please email your feedback to `founders@savant-code.com`. Thank you for using SavantCode!
1
+ # Savant-Code
2
+
3
+ **A terminal-native multi-agent AI coding assistant that audits every change before it touches your repo.**
4
+
5
+ Built with TypeScript/Bun, governed by the [ECHO Protocol](https://github.com/savant0x/savant-code/blob/main/ECHO.md), and designed for local-first use with Ollama or any OpenAI-compatible provider.
6
+
7
+ [![GitHub Stars](https://img.shields.io/github/stars/savant0x/savant-code?style=social)](https://github.com/savant0x/savant-code)
8
+ [![License: Apache-2.0](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://github.com/savant0x/savant-code/blob/main/LICENSE)
9
+
10
+ ## Installation
11
+
12
+ ```bash
13
+ npm install -g savant-code
14
+ ```
15
+
16
+ ## Quick Start
17
+
18
+ ```bash
19
+ cd your-project
20
+ savant-code
21
+ ```
22
+
23
+ Then just start chatting — describe what you want and Savant-Code will read your codebase, plan changes, implement them, and verify the result.
24
+
25
+ ## What Makes Savant-Code Different
26
+
27
+ Savant-Code isn't a single AI model guessing at your code. It's a **multi-agent system** where 9 specialized agents coordinate through a strict protocol to audit every change before it touches your files.
28
+
29
+ ### The Agent Roster
30
+
31
+ | Agent | Role |
32
+ |-------|------|
33
+ | **Savant** | Orchestrator — routes work, enforces protocol, spawns agents |
34
+ | **Detective** | Discovers bugs and issues with evidence before any code is written |
35
+ | **Forge** | Implements code changes from a converged plan |
36
+ | **Verifier** | Independent double-audit after implementation |
37
+ | **Thinker** | Deep sequential reasoning for complex problems |
38
+ | **Scout** | Explores codebases to gather context |
39
+ | **Researcher** | Web search and documentation lookup |
40
+ | **Recorder** | FID lifecycle management and tracking |
41
+ | **Scribe** | Session summaries and knowledge capture |
42
+
43
+ ### ECHO Protocol
44
+
45
+ Every change follows the **ECHO Perfection Loop**:
46
+
47
+ 1. **RED** — Identify ALL failures and issues with evidence
48
+ 2. **GREEN** Fix with minimal, surgical changes
49
+ 3. **AUDIT** — Independent verification by a separate agent
50
+ 4. **COMPLETE** — Document results, archive tracking
51
+
52
+ No code is written without a plan. No plan is accepted without audit. No audit passes without evidence.
53
+
54
+ ## Features
55
+
56
+ ### Multi-Agent Orchestration
57
+ 9 specialized agents coordinate via the ECHO Protocol. Detective finds issues, Forge implements, Verifier audits, Thinker reasons through complex problems, and Recorder tracks everything.
58
+
59
+ ### Thinker with Sequential Thinking
60
+ The Thinker agent accumulates stacked reasoning steps, converges to a typed non-null result, and never returns an empty or null output. Each thought builds on the previous one.
61
+
62
+ ### Native Tool-Call Hardening
63
+ Fail-closed streaming boundary for incomplete or malformed tool calls. Stale-fragment replacement for placeholder arguments. Permissive coercion of stringified values before strict validation.
64
+
65
+ ### Tool Permission Boundary
66
+ Strict allowlist-based tool provisioning. Restricted agents never receive parent-only tools. Each agent has exactly the tools it needs — no more.
67
+
68
+ ### Gateway Providers
69
+ Works with Ollama (local-first) and any OpenAI-compatible API:
70
+ - **OpenCode Go** (default) — MiMo 2.5
71
+ - **OpenRouter** access to hundreds of models
72
+ - **NVIDIA NIM** — enterprise inference
73
+ - **Cloudflare Workers AI** edge inference
74
+ - **TokenRouter** — multi-provider routing
75
+ - **Any OpenAI-compatible endpoint** — custom providers via `/provider`
76
+
77
+ ### Context Compaction
78
+ 4-layer progressive auto-compaction keeps your session running through large codebases without hitting context limits.
79
+
80
+ ### Rich Terminal UI
81
+ - Streaming token-by-token output
82
+ - Copy buttons on code blocks, tool outputs, and diffs
83
+ - Mode switching (EDIT / ANALYZE / SCAFFOLD)
84
+ - Light/dark theming with Neon Slate aesthetic
85
+ - Provider picker with masked API key input
86
+ - Collapsible sidebar sections
87
+
88
+ ### Goal Loop
89
+ Set a goal and a cadence — Savant-Code will check and work toward it on a schedule.
90
+
91
+ ```bash
92
+ /goal fix all failing tests
93
+ /loop 5m
94
+ ```
95
+
96
+ ### Slash Commands
97
+
98
+ | Command | Description |
99
+ |---------|-------------|
100
+ | `/model` | Switch LLM provider and model |
101
+ | `/provider` | Configure API keys (interactive picker) |
102
+ | `/help` | Show all commands |
103
+ | `/new` | Start a fresh conversation |
104
+ | `/history` | Browse past sessions |
105
+ | `/goal` | Set a persistent goal |
106
+ | `/loop` | Schedule recurring checks |
107
+ | `/telemetry` | Toggle analytics (on/off/status) |
108
+ | `/theme:toggle` | Switch light/dark mode |
109
+ | `/init` | Scaffold agent config files |
110
+
111
+ ### Knowledge Files
112
+ Add a `knowledge.md` anywhere in your project to give Savant-Code persistent context about your codebase, conventions, and preferences.
113
+
114
+ ## Usage Examples
115
+
116
+ **Implement a feature:**
117
+ > Add a rate limiter to the API endpoints that allows 100 requests per minute per IP address, with Redis-backed counting.
118
+
119
+ **Fix a bug:**
120
+ > The login form crashes on submit when the email field is empty. Find the bug and fix it.
121
+
122
+ **Write tests:**
123
+ > Add unit tests for the UserService class covering all edge cases in the register flow.
124
+
125
+ **Refactor:**
126
+ > Refactor the database connection layer to use connection pooling instead of creating a new connection per request.
127
+
128
+ **Code review:**
129
+ > Review my recent changes and flag any security issues, performance problems, or style violations.
130
+
131
+ ## Troubleshooting
132
+
133
+ ### Permission Errors
134
+ ```bash
135
+ sudo npm install -g savant-code
136
+ ```
137
+ Or [reinstall Node](https://nodejs.org/en/download) to fix global permissions.
138
+
139
+ ### Corporate Proxy / Firewall
140
+ ```bash
141
+ export HTTPS_PROXY=http://your-proxy-server:port
142
+ savant-code
143
+ ```
144
+
145
+ ### No Model Available
146
+ Savant-Code requires at least one LLM provider. Run `/provider` to configure one, or install [Ollama](https://ollama.com) for local inference.
147
+
148
+ ## Links
149
+
150
+ - **GitHub:** [github.com/savant0x/savant-code](https://github.com/savant0x/savant-code)
151
+ - **Docs:** [savant-code.com/docs](https://savant-code.com/docs)
152
+ - **Issues:** [GitHub Issues](https://github.com/savant0x/savant-code/issues)
153
+ - **License:** [Apache 2.0](https://github.com/savant0x/savant-code/blob/main/LICENSE)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "savant-code",
3
- "version": "0.0.11",
3
+ "version": "0.0.14",
4
4
  "description": "Multi-Agent AI Coding Assistant with ECHO Protocol",
5
5
  "license": "Apache-2.0",
6
6
  "author": "Savant Code <founders@savant-code.com>",