AI News HubLIVE
站内改写5 分钟阅读

待翻译:Quanta.Ai.Code.Editor

AI 服务暂时不可用,以下为来源摘要,待恢复后补全翻译:Notifications You must be signed in to change notification settings Fork 0 Star 1 BranchesTags Open more actions menu Latest commit History 11 Commits 11 Commits Folders and files NameName Last commit message Last commi…

来源Hacker News AI作者: Quantaai

AI 服务暂时不可用,以下为来源正文,待恢复后补全翻译。

Notifications You must be signed in to change notification settings Fork 0 Star 1 BranchesTags Open more actions menu Latest commit History 11 Commits 11 Commits Folders and files NameName Last commit message Last commit date .github .github CODE_OF_CONDUCT.md CODE_OF_CONDUCT.md README.md README.md Repository files navigation A local-first, privacy-preserving AI code editor with a full agentic coding loop Watch Quanta AI in Action What is Quanta? Quanta is a local-first AI code editor built on VS Code OSS, powered by a high-performance Rust backend. It gives you a complete agentic coding experience — reading files, writing code, running terminals, applying LSP fixes, and managing git — all driven by local LLMs through Ollama. Cloud providers (OpenAI, Anthropic) are supported as optional backends, but Ollama is the primary engine. Your code never has to leave your machine. Unlike cloud-first AI editors, Quanta is designed around local inference. The agent loop, tool execution, LSP integration, checkpoint system, and inline completions all happen locally through a Rust backend that communicates with the editor via JSON-RPC over TCP. Table of Contents Key Features Feature Comparison Architecture Quick Start Installation Agent Tools Agent Modes LSP & Diagnostics Checkpoint System Edit History & Undo/Redo MCP Integration Model Management HuggingFace Integration Engineering Skills Voice & TTS Session Management Plan Mode Configuration License Key Features Core Agent 30+ built-in tools — read/write/edit files, unified diffs, terminal, grep, glob, git operations, LSP actions, and more ReAct agent loop — Think, Act, Observe, Feedback pattern with anti-loop guards and automatic retries 3 agent modes — Code (full capability), Ask (read-only), Plan (read-only + plan writing) Sub-agent spawning — Delegate scoped tasks to parallel sub-agents with up to 3 levels of nesting Persistent todo lists — Track multi-step work across conversation turns Local-First Ollama integration — Auto-detects and lists all local models with metadata Thinking/reasoning support — Configurable think levels (Low/Medium/High) for reasoning models Inline code completion — FIM completions with LRU cache, debouncing, and in-flight cancellation Local-first by design — Ollama is the primary backend; cloud providers (OpenAI, Anthropic) are optional. Your code never has to leave your machine. Safety & Control Shadow-git checkpoints — Automatic workspace snapshots before every agent write action Edit review system — Accept/reject individual edits with diff previews Stale-file detection — Prevents edits to files that changed since last read Terminal safety guards — Blocks destructive commands (format, shutdown, force-delete) Atomic writes — All file operations use temp-file-and-rename for crash safety Developer Experience Full LSP integration — Diagnostics, go-to-definition, find references, code actions, rename symbol 20+ engineering skills — Built-in guidance for TDD, code review, security review, debugging, and more MCP support — One-click enable for GitHub, Jina AI, Brave Search, Postgres, Puppeteer, and more HuggingFace model browser — Search, download, and install GGUF models directly from the editor Per-model configuration — Override temperature, think level, edit format, tool call mode, and more per model Voice support — Speech-to-text via Whisper, text-to-speech via Piper Feature Comparison Note: Competitor data is based on publicly available documentation as of 2025. Features change frequently — verify with each tool's official docs before relying on this table for decisions. A dash (—) means we could not verify the feature's presence or absence and chose not to guess. Feature Quanta Cursor Claude Code Zed AI Aider Cline Local LLM (Ollama) Yes Limited ¹ Yes ² Yes Yes Yes Ollama as primary backend Yes No No No No No Built on VS Code Yes Yes No (CLI) No (Zed) No (CLI) Yes (extension) Rust backend Yes No No Yes No No Persistent shadow-git checkpoints Yes No ³ No No No Yes Edit review (accept/reject) Yes Yes No No No Yes LSP diagnostics to model Yes Yes No Yes No Yes LSP code actions to model Yes — No — No — LSP rename symbol to model Yes — No — No — Inline completion (local) Yes Yes No Yes No No Sub-agent spawning Yes No ⁴ Yes No No No Plan mode Yes Yes No No No Yes MCP support Yes Yes Yes No No Yes HuggingFace model browser Yes No No No No No Per-model config overrides Yes No No Partial No No Per-task model routing Yes Yes Yes Yes No No Engineering skills Yes No No No No No Voice (STT + TTS) Yes No No No No No Session export (MD/JSON/PDF) Yes No No No No No Configurable thinking levels Yes No No No No No Tool call modes (parallel/sequential) Yes No No No No No Tree-sitter fallback diagnostics Yes No No No No No Custom skills (project + global) Yes No No No No No Todo list tracking Yes No Yes No No Yes Footnotes: Cursor — Supports Ollama via OpenAI-compatible endpoint for chat and tab completion, but agent modes do not work with local LLMs as of May 2025 (community feature request open). Claude Code — Supports local Ollama models via Anthropic-compatible API endpoint (Ollama 0.14+). Cloud (Anthropic) is the default backend. Cursor — Has session-local checkpoints that do not persist across IDE restarts and do not use a shadow git repository. They capture file changes only, not terminal side effects. Cursor — Has parallel agents via git worktrees (Agents Window) and /best-of-n multi-model runs, but does not support spawning sub-agents from within an ongoing conversation. Architecture ┌─────────────────────────────────────────────────────────────┐ │ Quanta AI Editor │ │ ┌───────────────────────────────────────────────────────┐ │ │ │ VS Code OSS (Electron Frontend) │ │ │ │ ┌───────────────┐ ┌─────────────┐ ┌──────────────┐ │ │ │ │ │ Chat Webview │ │ Editor │ │ Inline Comp │ │ │ │ │ │ (TypeScript) │ │ (Monaco) │ │ (TypeScript)│ │ │ │ │ └──────┬────────┘ └──────┬──────┘ └──────┬───────┘ │ │ │ │ │ │ │ │ │ │ │ ┌──────┴──────────────────┴────────────────┴───────┐ │ │ │ │ │ Quanta Extension (TypeScript) │ │ │ │ │ │ RPC Client · Diagnostics · LSP Bridge │ │ │ │ │ └──────────────────────┬───────────────────────────┘ │ │ │ └─────────────────────────┼─────────────────────────────┘ │ │ │ JSON-RPC 2.0 over TCP │ │ ┌─────────────────────────┴─────────────────────────────┐ │ │ │ Quanta Backend (Rust) │ │ │ │ ┌─────────────┐ ┌──────────────┐ ┌──────────────────┐ │ │ │ │ Agent Loop │ │ Tool Registry│ │ Session Manager │ │ │ │ │ (ReAct) │ │ (30+ tools) │ │ (persistence) │ │ │ │ └──────┬──────┘ └──────────────┘ └──────────────────┘ │ │ │ ┌──────┴──────────────────────────────────────────────┐ │ │ │ │ Checkpoint Service · MCP · LSP Reverse RPC │ │ │ │ └─────────────────────────────────────────────────────┘ │ │ │ ┌─────────────┐ ┌─────────────┐ ┌──────────────┐ │ │ │ │ │ Ollama │ │ OpenAI API │ │ Anthropic API│ │ │ │ │ │ (localhost) │ │ (optional) │ │ (optional) │ │ │ │ │ └─────────────┘ └─────────────┘ └──────────────┘ │ │ │ └───────────────────────────────────────────────────────┘ │ └─────────────────────────────────────────────────────────────┘ Key design principles: The extension is a thin UI layer — all agent logic lives in the Rust backend Communication via newline-delimited JSON-RPC 2.0 over TCP (localhost only) The backend manages tool execution, LSP reverse-RPC, checkpoints, sessions, and MCP Cloud providers (OpenAI, Anthropic) are optional — Ollama is the primary inference engine Quick Start Prerequisites Ollama — Install and start the Ollama service # Install a model (example) ollama pull qwen2.5-coder:7b Git — Required for the checkpoint system Run Quanta Download the latest release from the Releases page Extract the archive and run Quanta.exe Open a project folder (File > Open Folder) Open the chat panel — Click the Quanta icon in the activity bar Select a model — Click the model name in the chat header to pick from your Ollama models Start coding — Ask Quanta to build features, fix bugs, refactor code, or explain your codebase Tip: Use @ in the chat input to mention files and inject them as context. Installation Option 1: Pre-built Release (Recommended) Download the latest release from the Releases page. Extract and run — no build tools required. Option 2: Build from Source Prerequisites Rust (stable, with cargo) Node.js v20+ Ollama running on localhost:11434 Git Agent Tools Quanta's agent has access to 30+ tools organized into functional groups: Filesystem & Terminal Tool Description read_file Read file contents with line numbers (10MB limit, outline for large files) write_file Create or overwrite files atomically (auto-creates parent dirs) edit_file Find-and-replace edits with multi-strategy matching (exact, fuzzy, ellipsis) apply_diff Apply unified diffs with 7-strategy flexible patching list_directory List directory contents (dirs first, then files, alphabetical) find_path Glob-based file search (**/*.rs, respects .gitignore) grep Regex content search across files (with context lines, pagination) terminal Execute shell commands (safety guards, streaming output, sandbox support) create_directory Create directories recursively delete_path Delete files or directories (blocked in Code mode for safety) copy_path Copy files or directories recursively move_path Move or rename files (atomic when possible) LSP Integration Tool Description diagnostics Get LSP errors/warnings with freshness tracking and tree-sitter fallback go_to_definition Jump to symbol definition via reverse RPC to VS Code find_references Find all references to a symbol across the project get_code_actions Get available quick fixes and refactorings apply_code_action Apply a code action with edit tracking and staleness checks rename_symbol Rename a symbol across the entire workspace Git Tool Description git_status Show working tree status with branch info git_diff Show staged or unstaged changes git_commit Stage and commit changes (auto-creates .gitignore if missing) git_branch Create, switch, or list branches git_log Show recent commit history git_stash Stash, pop, or list stashes Agent Management Tool Description spawn_agent Spawn synchronous or async sub-agents (up to 3 levels deep) create_thread Create independent background conversation threads check_subagent Check status and retrieve results from async sub-agents list_agents_and_models List available agents and models Network & Context Tool Description fetch HTTP GET with HTML-to-Markdown conversion image_search Search the web for images (DuckDuckGo, no API key) skill Load engineering skills from project, global, or built-in sources tool_search On-demand deferred loading of MCP tools write_plan_file Write implementation plans in Plan mode undo_edit Undo the most recent accepted edit to a file todo_list Persistent task tracking across conversation turns Agent Modes Mode Capabilities Use Case Code Full toolset (except delete_path) Building features, fixing bugs, refactoring Ask Read-only (no file writes, no terminal) Understanding code, asking questions Plan Read-only + write_plan_file Planning before implementing Switch modes using the mode button in the chat header. LSP & Diagnostics Quanta provides deep LSP integration that feeds real-time diagnostics to the model: Push-based diagnostics — VS Code sends diagnostics to the backend cache as they change Per-file version tracking — Ensures diagnostics are fresh and correctly scoped Deduplication — Merges diagnostics from multiple sources (LSP, tree-sitter) Auto-refresh — Diagnostics are re-fetched after agent file edits Tree-sitter fallback — Syntax-based diagnostics for languages without an LSP Language-specific configuration — Auto-configures LSP servers for 20+ languages Supported LSP features: Diagnostics (error [truncated for AI cost control]