notepatra-mcp
MCP serverDev toolsNotepatra editor MCP server — 35 tools; every write human-approved in the editor; local-only.
Unavailable. This server has no hosted endpoint yet, so ahel can't serve it.
Connect ahel once, and every AI you use reads what you have installed.
From the project's README
As published by singhpratech/notepatra in README.md.
The Story
I'm Prateek Singh. A developer who spent years on Linux wanting a small, fast, free native code editor that could fix things in seconds — broken JSON, messy SQL, tangled HTML — and finding only Wine hacks or bloated Electron editors eating 500 MB of RAM to show a text file.
Every text editor told me to pick two of three: fast, powerful, native. Vim is fast and native but cryptic. Modern Electron editors are powerful but heavy. The truly tiny native ones either don't have AI or don't run cross-platform.
So I built Notepatra.
Not a port. Not a wrapper. Something new — for everyone.
I asked: what would a small native code editor look like if it was built today, in 2026, when AI is part of every developer's workflow, and ran natively on Linux + macOS + Windows from one codebase?
The answer: a tiny native executable — ~13 MB bare (~13.4 MB on Linux x64) on every platform — with a Rust-powered core, Scintilla editing engine, and local-first AI integration (cloud backends optional). v0.1.129 downloads: 4.7 MB Linux x64 (tarball, Qt from the system), 28.0 MB on macOS (DMG with bundled Qt), 32.8–43.9 MB on Windows (MSI/zip/setup.exe with bundled Qt DLLs). An editor that can fix your broken JSON with regex in milliseconds — and when regex isn't enough, it asks your AI to figure it out — local by default, six cloud backends one click away when you want a frontier model. No telemetry. No subscription. No mandatory API key.
Notepatra started on Linux — because that's where the gap was. But great tools shouldn't have borders. Notepatra runs on Linux, Windows, and macOS. Same codebase. Same features. No one gets left behind.
Notepatra is what I wish had existed — on every platform.
Features
Editor — Battle-tested basics done right
- 238 file extensions mapped to 82 language lexers — Python, C/C++, C#, Java, Kotlin, JavaScript, TypeScript, Rust, Go, Swift, Dart, Solidity, Zig, Vala, Hack, Julia, R, Protobuf, F#, HCL/Terraform, Thrift, GraphQL, GDScript, Nim, Cython, Mojo, Crystal, Elixir, Scala, Groovy, Apex, SQL (6 dialect presets), HTML, CSS, JSON, JSON5, YAML, TOML, Markdown, Bash, Fish, Nushell, Fortran, VHDL, Verilog, MATLAB, LaTeX, BibTeX, Jinja, Liquid, Twig, Dockerfile, DotEnv, Gitignore, and more. Rust / Go / Swift / Kotlin / TypeScript / PowerShell ship as Notepatra-local lexers (not just C-family fallbacks)
- Tabbed editing — drag, reorder, middle-click close, double-click empty area for new tab
- Tab right-click menu — Close, Close All BUT This, Close All to the Left/Right, Close All, Save, Save As, Rename, Copy Full Path, Copy Filename, Copy Directory Path, Open Containing Folder, Open Terminal Here, Read-Only toggle, Color Tag (7 named colors + custom + Remove)
- 3 themes — Light, Dark, Monokai (Settings > Theme)
- Session persistence — close Notepatra, reopen tomorrow, same files, same cursor positions, same window size
- Crash recovery — if Notepatra crashes (it shouldn't, but life happens), your unsaved work is recovered on next launch
- File change detection — someone else edits your file? Notepatra asks: reload or keep yours?
- 2 GB file support — memory-mapped I/O via Rust; files up to ~1.86 GB load fully, larger open truncated + read-only
- Double-click word highlight — double-click any word, all occurrences light up in orange
- Ctrl+B brace matching — jump between matching
{}[](), highlights both braces + selects everything between - Macro recording — Start Recording (Ctrl+Shift+M), Stop, Playback (Ctrl+Shift+P), Run Multiple Times, Save/Load macros
- Code folding, bookmarks, auto-complete, indent guides, line numbers
- Custom scrollbars — clean, modern, rounded
Search — Find anything, anywhere
- Project Search (
Ctrl+Shift+G) — recursive search across file names AND file contents in any text-based file. Any size, any language (Python, SQL, C/C++, JS/TS, Rust, Go, HTML, JSON, YAML, Markdown, logs, config). Streams line-by-line so a 2 GB log searches the same as a 2 KB script. Each match shows exactline:colcoordinates — double-click to jump the caret to the character. - 5-tab Find/Replace dialog — Find, Replace, Find in Files, Mark, Go to
- 3 search modes — Normal, Extended (
\n,\r,\t,\xNN), Regular expression - Find All in Current Document — results appear in bottom panel, double-click any result to jump to that exact line
- Find All in All Opened Documents — search across every open tab at once
- Replace All in All Opened Documents — one click, every file updated
- Find in Files — search entire directories recursively with file filters
- Mark All — highlight every occurrence with visual indicators
- Aho-Corasick search engine (Rust) — faster than regex for literal patterns
Plugins — The real power
Every plugin opens in its own tab. Real UI, not just a menu click.
JSON Tools (inbuilt)
| Button | What it does |
|---|---|
| Format | Pretty-print with preserved key order |
| Minify | Compact to one line |
| Fix + Format | Rust-powered auto-repair: fixes missing braces, trailing commas, single quotes, unquoted keys, missing { after [ — shows detailed report of every fix |
| AI Fix (Ollama) | Sends truly broken JSON to your local AI — fixes what regex can't |
HTML Tools (inbuilt)
| Button | What it does |
|---|---|
| Format (2/4 spaces) | Proper HTML indentation |
| Minify | Strip all whitespace |
| Fix + Format | Auto-close unclosed tags, detect missing closers, report issues |
| AI Fix (Ollama) | AI repairs broken nesting, malformed tags, missing attributes |
Bracket Tools (inbuilt)
| Button | What it does |
|---|---|
| Check | Detailed report: line numbers of every mismatched () [] {}, keyword mismatches (begin/end, if/fi) |
| Auto-Fix | Adds missing closers in correct nesting order |
| AI Fix (Ollama) | AI understands your code structure and fixes all bracket issues |
SQL Formatter (inbuilt)
- Format with UPPERCASE or lowercase keywords
- Configurable indent width
- Supports T-SQL, PL/SQL, MySQL, PostgreSQL, SQLite
Compare / Diff (inbuilt)
- Pick any two tabs or any tab vs file on disk
- Side-by-side Scintilla editors with a ComparePlus-style overview/nav bar
+green for added,-red for deleted,#amber for changed- Word-level LCS intra-line diff — within a changed line, the specific tokens that were removed are highlighted in red on the left pane; the tokens that were added are highlighted in green on the right pane. Works on actual word boundaries, not just common-prefix/suffix.
- Dark-mode aware — colours track your Notepatra theme (Light / Dark / Monokai) so diffs stay readable on both black and white backgrounds.
- Prev/Next diff navigation, inline overview-bar jump
- Ignore whitespace, ignore case, ignore empty lines checkboxes
- Unlock for editing mode — edit either pane and re-diff in place
- Powered by Rust Myers diff (line-level) + C++ LCS (word-level)
- Visual UX inspired by ComparePlus by Pavel Nedev — credit where credit is due.
Git Integration (inbuilt)
- Staged / Unstaged trees — porcelain v2 parser, inline
+/−buttons per row to stage/unstage - Branch chip with ahead/behind — shows
main ↑3 ↓1when diverged - Commit box (Ctrl+Enter) — line-count indicator, blocks commit when nothing's staged
- Sync row — one-click Pull / Push / Fetch with live ahead/behind refresh
- Collapsible history + stash menu — recent commits expandable; stash / pop / list / drop
- Git gutter — green/yellow/red markers in editor margin for changed lines
AI Powered — local-first, cloud-optional
Backend dropdown ships 6 entries — Ollama (local default · localhost:11434), llama.cpp (GGUF) (local · localhost:8080), OpenRouter (cloud · 100+ models), Ollama Cloud (cloud · gpt-oss:120b / qwen3-coder:480b / deepseek-v3.1:671b), OpenAI (cloud · GPT-4o / GPT-5 / o-series), Azure OpenAI (enterprise). Per-provider key slots — no cross-provider bleed. The llama.cpp entry also accepts a user-configured base URL via Settings → Preferences → AI, so you can route it to any OpenAI-compatible HTTP server you have installed separately. Local backends keep code on your machine; cloud backends are opt-in. No telemetry. No subscription. No mandatory API key.
AI Assistant — side-dock (Ctrl+Shift+A)
The AI chat lives in a persistent right-side dock, not an editor tab. One conversation, preserved across tab switches. Tick Coding Mode to open the 3-column coding layout (file tree · editor · AI chat) 3-pane layout.
Workspace awareness. Every prompt carries:
- the selection (or full file if no selection is active)
- the full text of the current file
- excerpts of every other open editor tab
- a flat listing of all files under the workspace root (
.git,node_modules,target,dist, etc. filtered out)
So the model can reason about files you haven't opened yet — "import from utils.py" works even when utils.py isn't in a tab. Budget-capped so small local models (3B, 4K–8K context) don't overflow.
One-click actions (hidden by default, click "▸ Quick actions" to reveal): Explain · Find Bugs · Refactor · Write Tests · Add Comments · Generate Docs · Optimize · Translate. Or type a custom prompt. Responses stream in, each has a Copy link, and the last response can be inserted at the cursor or replace the selection with one click.
Speech-to-text — optional mic button, uses local arecord + whisper CLI when installed. No audio ever leaves the machine.
AI Setup
# Easiest path: Ollama
curl -fsSL https://ollama.com/install.sh | sh
ollama pull qwen2.5-coder:3b # 2 GB, best for code on CPU-only / 16 GB RAM
ollama serve
Notepatra auto-detects the running Ollama and picks the most CPU-friendly model installed. For llama.cpp / OpenRouter / Ollama Cloud / OpenAI / Azure OpenAI, pick the backend from the dropdown at the top of the AI panel; base URL and API key are editable inline. The llama.cpp entry also accepts a user-configured base URL via Settings → Preferences → AI, so you can route it to any OpenAI-compatible HTTP server you have installed separately.
🔐 Password Generator — passwords, passphrases and SSH keys, with an honest entropy figure (Tools > Password Generator — Passwords / Passphrases / SSH keys)
A generator built into the binary, opened from the Password button on the Built-in Tools toolbar (third, immediately after AI) — press it again while the tab is focused and the tab closes. A left rail switches between three pages: Password, Passphrase and SSH key (Alt+1 / Alt+2 / Alt+3). It ships in every build, including the default Lite binary and works fully offline: no network, no download, no backend, no AI.
- Password — random characters, 4–256 (default 20) from a-z / A-Z / 0-9 / a 27-character symbol set, plus a free-text field for any extra characters you want, with optional exclude look-alikes (drops
0 O 1 l I) and at least one from each set (on by default). The symbol set deliberately omits the quotes, backslash, backtick, pipe and space — the characters that break a password pasted into a shell command, a YAML file or a database connection string. - Passphrase — 3–24 words (default 6) from a 2,048-word list compiled into the binary (no dictionary file is read at runtime), so each word is worth exactly 11 bits and six words is 66 bits; pick a hyphen / period / underscore / space / no separator, optionally capitalise each word or append two digits. Both text modes generate 1 to 100 independent values at once, with Generate · Copy · Insert into editor · Open in new tab.
- SSH key — a real OpenSSH key pair, generated locally: Ed25519 (recommended), ECDSA P-256 / P-384, RSA 3072 / 4096, and RSA 2048 marked legacy. An optional passphrase encrypts the private key with
aes256-ctr+bcrypt-pbkdf, the same constructionssh-keygenuses. The comment field is empty by default, on purpose:ssh-keygendefaults it touser@host, which copies your username and machine name into everyauthorized_keysfile the key is ever pasted into. The public line and its SHA256 fingerprint are shown immediately; the private key stays hidden until you tick Show private key. Save private key… creates the file, sets it to0600, then writes it, refuses to overwrite an existing file, and writes the.pubcompanion (0644) beside it. Generation runs off the GUI thread, so the window stays responsive while RSA-4096 takes its 1.6–5.9 s. Interoperability is checked against the systemssh-keygenin the test suite —-yreproduces the public line,-lfthe fingerprint, and-y -Popens the encrypted key and rejects the wrong passphrase. The pure-Rust crypto (RustCryptossh-key) costs about 0.6 MB of binary. - The bits number is a count, not a score — it is the base-2 logarithm of how many distinct values your current settings can produce, not a heuristic guess at how complicated the output looks, which is what most meters show. Tick at least one from each set and the figure drops slightly: it is recomputed by inclusion–exclusion over the selected sets, because the guarantee rules out every password that misses a set, so fewer passwords exist. Most generators advertise the unconstrained number while enforcing the constraint, which overstates the result. Default settings read 129 bits.
- Real randomness, and nothing kept — every draw comes from the OS random source (
getrandomon Linux, the platform equivalent elsewhere) through the Rust core. Qt'sQRandomGenerator::system()is now only the fallback, not the source — it was the source before v0.1.129, and on x86-64 that meant the CPU'sRDRANDinstruction first, which is a different provenance than most readers assume. SSH keys come from the same OS source. Draws use rejection sampling so no character is favoured just because the alphabet size doesn't divide2^32, and the set guarantee is enforced by drawing again until it holds, not by placing one character per set and shuffling — placement would make some strings likelier than others and turn the bits figure into a lie. The panel is a plain widget rather than an editor, and session save/restore, the AI-context sweep and the MCP read verbs are all gated on the tab being an editor, so a generated value never lands insession.json, never reaches an AI backend, and is not readable by a connected MCP client. Copy takes the value back off the clipboard after 30 seconds — but only if the clipboard still holds it, so it never clobbers something you copied since. The 30-second wipe arms for the private key only, never for the public line. Nothing is written to disk unless you choose Save private key….
👁 AI Interaction Log — see exactly what your AI did (Features → AI Interaction Log…)
Total transparency, on by default. Every request and response to any AI backend — local (Ollama / llama.cpp) or cloud (OpenRouter / OpenAI / Azure / Ollama Cloud), including Noter's Extract — is written to a local SQLite log you can open and read: timestamp, backend, model, mode, full prompt + full response, token counts, latency. It never leaves your machine (zero network egress), entries auto-prune after 7 days, and a built-in credential scrubber masks API keys / bearer tokens / PEM private keys before anything is stored. The viewer has backend/model/mode filters, Export JSON, Prune now, and a one-click opt-out toggle. You are never guessing what got sent to a model — you can audit every byte. Privacy as transparency, not as a promise.
📝 Noter — meeting notes that turn into reminders (Ctrl+Alt+N)
A local-first, two-pane meeting workspace (notes list · editor) — no accounts, no bots; notes live under ~/Documents/Notepatra/Noter/.
- Write fast — a top toolbar drops in Action Items / What I plan / To-dos headers and checkbox bullets; check a line to strike it through.
- Extract (
Ctrl+Alt+E) runs your AI backend over the note and returns a summary plus action items / decisions / questions / risks. A task that mentions a time ("ship the build 10am tomorrow") comes back with that date/time pre-filled. - Reminders — set one on a note (right-click) or schedule action items straight from Extract; they all collect in a central Reminders list grouped Overdue / Today / This week / Later, with desktop notifications at the due time while Notepatra is running (missed ones arrive as one summary at next launch). Click to open the note, pencil to reschedule, ✕ to delete. Re-running Extract flags what's already scheduled so you never pile up duplicates.
📐 Diagram tool — flow / ER / system diagrams from text (.npd)
A first-class diagramming surface that renders in the default binary on every platform (incl. macOS Apple Silicon and the Windows installer — native Qt renderer, no WebEngine), opened from the toolbar next to Noter. The tiny .npd text DSL is the source of truth; the canvas is a live projection of it (so undo/redo and version control just work).
- Create three ways — AI Generate describes it in plain English and a local model writes the
.npd, shown in a review pane before it touches the canvas (undo/redo after); or start from a Flow / ER / System template; or write.npddirectly. Import Mermaid converts an existing flowchart, now mapping-.->to a dashed edge andsubgraph … endto agroup. - Why not just Mermaid? — Mermaid needs a browser or JS runtime;
.npdrenders natively, offline, in the Lite binary, with AI Generate, node-pinnednotes,legends, built-in icons, theme-following palettes, and anexport_diagramMCP tool. Mermaid still wins on diagram types (sequence, class, Gantt) and on GitHub rendering it inline — the full comparison is in the docs. - Drawn flat, like an engineering diagram — no gradients, no drop shadows: a 1.5 px border, the app's own font, and a tighter grid. Two light palettes ship —
paperandslate— alongside the older dark ones (clay/ocean/forest/mono/default), and the new defaultpalette autofollows the app theme: light theme →paper, dark theme →default. - Rich visuals — 5 shapes (pill / box / decision diamond / database cylinder / icon), ~55 hand-drawn icons (~150 aliases) for system / ER / flowchart, directed + labelled + bidirectional arrows, dashed edges (
a -.-> b,a <.-> b) for the async / optional / best-effort hop, label-overflow→hover, infinite pan/zoom canvas. A per-node colour renders as a tint on a light palette (soft wash, full-strength border, normal dark text) and as a solid fill with auto-contrast text on a dark one. - Say what a picture can't —
direction LRlays the diagram out left-to-right (TBis the default),group "Edge tier" : cdn apidraws a labelled container behind those nodes,note api "Rate-limited to 100 rps"pins a small card beside one, andlegend dashed "async"/legend #cc785c "hot path"build a legend box (which appears only if you write at least onelegendline).group,note,legend,directionandlayoutare now reserved words — an existing file that uses one as a node id needs the id renamed. - Export — PNG / JPEG / PDF on every build, plus SVG / HTML where the Qt Svg module is present and WebP where the Qt WebP image plugin is present (the menu shows exactly what your build supports). A Help button has the full cheat-sheet;
samples/diagram_showcase.npdshows every element; thenpd_renderCLI renders any.npdto an image headless.
More Features
Shortened here. Read the whole README on GitHub.
Signals
- GitHub stars
- 6
- Forks
- 1
- Last commit
- Aug 2026
Advanced
- Delivery
- notepatra-mcp MCP server → your ahel gateway (mcp.ahel.ai) → every connected AI client.
- Catalog kind
- mcp-server
- Gateway key
io-github-singhpratech-notepatra-mcp- Source
- github.com/singhpratech/notepatra