Logo Local Coding Agent

Local Coding Agent

Cộng đồng
LongNgn204

Local MCP coding agent for ChatGPT Web: run files/commands on your own machine via the OpenAI Secure Tunnel, with a Windows tray app and metrics dashboard.

Nhà phát hànhLongNgn204
Kho mãlocal-coding-agent
Ngôn ngữJavaScript
Bản fork
32
Sao
57
Công cụ có sẵn
0
Phương thức truyền tảistdio
Giấy phépAGPL-3.0
Liên kết
  • Kết nối công cụ với quy trình làm việc AI

    Local Coding Agent cung cấp các khả năng MCP mà ứng dụng khách và tác nhân AI tương thích có thể sử dụng.

  • 0 công cụ có sẵn

    Xem các thao tác có thể gọi bên dưới, kèm tên và mô tả nếu máy chủ cung cấp.

  • Cấu hình sẵn để sao chép

    Dùng các đoạn cấu hình cài đặt mẫu để thiết lập máy chủ này trong ứng dụng khách MCP bạn muốn dùng.

  • Chỉ số quan tâm đến mã nguồn mở

    57 sao và 32 bản fork từ kho mã được liên kết.

Compatible with any MCP client. Not affiliated with Anthropic, OpenAI, GitHub, or Microsoft.

The Community Edition code is open source under AGPL. The project name and brand assets are governed separately by the Trademark Policy.

This tool can run commands on your computer. Read SECURITY.md before using it. It is not an OS sandbox; only connect workspaces you trust.

Latest C# Windows release: v5.0.2. Modern WinForms UI and corrected tunnel configuration. Requires Node.js, server source/dependencies, and your own tunnel client; .NET is bundled. See the release notes and Vietnamese app roadmap.

Latest cross-platform Electron release: v5.0.1. This maintenance release adds official Tray packages for Windows and macOS, bundles the tested MCP runtime, expands cross-platform CI, and hardens permissions and recovery. Local Codex Studio remains an internal experiment and is not publicly distributed.

What's New In v5.0.1

  • Cross-platform Electron Tray: Windows x64, macOS Apple Silicon, and macOS Intel.
  • Internal Local Codex Studio experiment for continued development; no public download is available yet.
  • Bundled MCP runtime, predictable release assets, and Electron's built-in Node fallback for the packaged Tray.
  • Permission-boundary, Windows power-path, dashboard resilience, and CI fixes.
  • Chrome Companion and classic Windows tray remain available as compatibility assets. The proprietary tunnel client is never bundled.

Tiếng Việt: Bản v5.0.1 hoàn thiện đóng gói Tray cho Windows lẫn macOS, mang theo MCP runtime đã kiểm thử, tăng độ ổn định của quyền truy cập, dashboard và tunnel. Studio vẫn là thử nghiệm nội bộ, chưa phát hành công khai. Tunnel client độc quyền vẫn do người dùng tự tải.

Existing customers can update safely with scripts\lca.cmd update on Windows or bash scripts/lca update on macOS/Linux, then restart the tray app/server.


AI Agent Quick Setup

English

Use this when you want ChatGPT, Claude Code, Codex, Cursor, or another AI coding agent to clone, install, verify, update, or diagnose this repo for a customer.

powershell
node scripts\local-coding-agent.mjs prompt setup
node scripts\local-coding-agent.mjs prompt update
node scripts\local-coding-agent.mjs prompt diagnose
node scripts\local-coding-agent.mjs prompt compact
node scripts\local-coding-agent.mjs prompt resume
node scripts\local-coding-agent.mjs setup-wizard --workspace "C:\path\repo"
node scripts\local-coding-agent.mjs skills doctor
  • prompt setup prints a copy-paste prompt for a fresh customer install.
  • prompt update prints a safe update prompt that preserves config, tunnel client files, secrets, generated profiles, reports, and server/data.
  • prompt diagnose prints a support prompt that collects redacted reports instead of pasting long logs into chat.
  • prompt compact tells ChatGPT Web to save a small structured checkpoint when the conversation becomes long or slow.
  • prompt resume tells a fresh ChatGPT Web chat to load that checkpoint, verify the workspace and Git state, and continue from the recorded next action.
  • setup-wizard checks Node/npm/git, repo layout, server dependencies, workspace, tunnel prerequisites, skill validation, and local health, then writes setup-wizard-report.txt.
  • skills doctor maps common customer symptoms to the right shipped skill.

Open the dashboard at http://127.0.0.1:8790/ui to copy the same setup, update, diagnose, compact, and resume prompts.

Tiếng Việt

Dùng phần này khi bạn muốn ChatGPT, Claude Code, Codex, Cursor hoặc một AI coding agent khác clone, cài đặt, kiểm tra, cập nhật hoặc chẩn đoán repo này cho khách.

powershell
node scripts\local-coding-agent.mjs prompt setup
node scripts\local-coding-agent.mjs prompt update
node scripts\local-coding-agent.mjs prompt diagnose
node scripts\local-coding-agent.mjs prompt compact
node scripts\local-coding-agent.mjs prompt resume
node scripts\local-coding-agent.mjs setup-wizard --workspace "C:\path\repo"
node scripts\local-coding-agent.mjs skills doctor
  • prompt setup in prompt copy-paste cho khách cài mới.
  • prompt update in prompt cập nhật an toàn, giữ nguyên config, tunnel-client, secret, profile sinh ra, report và server/data.
  • prompt diagnose in prompt hỗ trợ/chẩn đoán, tạo report đã redact thay vì dán log dài vào chat.
  • prompt compact bảo ChatGPT Web lưu checkpoint nhỏ, có cấu trúc khi cuộc trò chuyện bắt đầu dài hoặc chậm.
  • prompt resume bảo chat ChatGPT Web mới tải checkpoint, kiểm tra workspace và trạng thái Git rồi tiếp tục từ hành động kế tiếp đã lưu.
  • setup-wizard kiểm tra Node/npm/git, cấu trúc repo, dependency server, workspace, điều kiện tunnel, validate skill và health cục bộ, rồi ghi setup-wizard-report.txt.
  • skills doctor map lỗi khách hay gặp sang skill phù hợp trong repo.

Mở dashboard tại http://127.0.0.1:8790/ui để copy cùng các prompt setup, update, diagnose, compact và resume.


English

Install With Your AI Agent

The easiest path is to let a strong AI coding agent do the setup for you. Copy this prompt into Codex, Claude Code, Cursor, or another local coding agent:

text
Please install Local Coding Agent on my machine.

Repository:
https://github.com/LongNgn204/local-coding-agent

Goal:
Clone the repo, install it, configure a workspace, start the MCP server, and
verify the dashboard.

Rules:
- Do not install system dependencies without asking me first.
- Do not download, commit, or redistribute tunnel-client. I will provide it if needed.
- Do not commit secrets, API keys, tunnel IDs, local config, or generated profiles.
- Default to mode=safe and policy=balanced.
- Use the universal CLI first. Use the Windows tray app only if I ask for GUI.
- If anything fails, show the exact error and the next command to fix it.

Steps:
1. Clone https://github.com/LongNgn204/local-coding-agent if it is not already cloned.
2. Enter the repo directory and read AGENTS.md; follow it exactly.
3. Check Node.js version is >= 18 (node -v).
4. Install with:
   - Windows: scripts\lca.cmd install
   - macOS/Linux: bash scripts/lca install
5. Run setup with:
   - Windows: scripts\lca.cmd setup
   - macOS/Linux: bash scripts/lca setup
6. Ask me for the workspace folder the AI may access.
7. If I want ChatGPT Web tunnel access, ask me for tunnel-client path, tunnel ID,
   organization ID if required, and Runtime API key.
8. Start with:
   - Windows: scripts\lca.cmd start
   - macOS/Linux: bash scripts/lca start
9. Verify:
   - http://127.0.0.1:8787/healthz returns status ok
   - http://127.0.0.1:8790/ui opens the dashboard
   - Run the tool suite: from server/ run npm run test:agent
   - status command works
10. Explain the results to me in plain language: what passed, what failed, and
    the exact next command to fix anything that failed.
11. Report the MCP URL, dashboard URL, workspace path, mode, policy, and tunnel status.

More prompt variants are in docs/AI_AGENT_SETUP_PROMPT.md. For existing installs, use docs/CUSTOMER_UPDATE_PROMPT.md.

Setup Map

Manual Quickstart

Windows:

powershell
git clone https://github.com/LongNgn204/local-coding-agent.git
cd local-coding-agent
scripts\lca.cmd install
scripts\lca.cmd setup
scripts\lca.cmd start

macOS / Linux:

bash
git clone https://github.com/LongNgn204/local-coding-agent.git
cd local-coding-agent
bash scripts/lca install
bash scripts/lca setup
bash scripts/lca start

Open:

text
http://127.0.0.1:8790/ui

Useful commands:

text
status   show MCP URL, dashboard URL, process status
doctor   check local setup and common missing requirements
update   safely fetch/pull latest main, reinstall dependencies, validate skills
skills   list or validate the shipped skill pack
open     open the local dashboard
stop     stop the server and tunnel started by the CLI
logs     show launcher logs
url      print the MCP URL

Cross-platform Tray App

The Electron tray app is a GUI supervisor for the same local server and tunnel on Windows and macOS. It stores secrets with Windows DPAPI or macOS Keychain.

Download the self-contained .exe from Releases, or build it yourself:

Direct v5.0.1 downloads:

Local Codex Studio is an internal experiment under active development and is not available as a public download yet.

powershell
cd tray-app
powershell -ExecutionPolicy Bypass -File build.ps1

For the native C# Windows interface, use C# v5.0.2. It bundles .NET only; keep the repository server and Node.js installed. Electron packages above remain the older cross-platform release, not this update.

Connect To ChatGPT Web

  1. Start the local server first and verify the dashboard.
  2. Put the OpenAI tunnel client in tools/tunnel-client.exe on Windows or tools/tunnel-client on macOS/Linux.
  3. Create or choose a tunnel in ChatGPT/OpenAI.
  4. Provide the same Tunnel ID during scripts/lca setup.
  5. Use a Runtime API key for CONTROL_PLANE_API_KEY. Do not use an Admin key.
  6. If your organization requires it, provide the OpenAI Organization ID.
  7. Start the CLI or tray app and keep it running while ChatGPT uses the tools.

The local URL http://127.0.0.1:8787/mcp is for your machine. ChatGPT Web must connect through the secure tunnel, not by pasting the local loopback URL.

Customer Network Diagnostics

If the customer says it works on mobile hotspot but fails on office/internal network, ask them to run Network Doctor on the failing network and send the redacted report.

Basic check:

powershell
node scripts\network-doctor.mjs

Tunnel smoke test:

powershell
$env:CONTROL_PLANE_API_KEY="sk-proj-..."
node scripts\network-doctor.mjs --tunnel-bin "tools\tunnel-client.exe" --tunnel-id "tunnel_..." --organization-id "org_..." --duration 30

Guide: docs/NETWORK_DOCTOR.md.

For a full, redacted support bundle a customer can send back to the developer:

powershell
node scripts\support-report.mjs
scripts\lca.cmd support

It prints a compact summary and writes a redacted support-report.txt (versions, Node, ports 8787/8790, tunnel-client presence, health, recent errors). It never requires the proprietary tunnel client and never writes keys or tokens.

Stable Anti-Lag Workflow

v4.4.3 reduces ChatGPT Web lag by keeping default tool outputs smaller and steering AI agents toward targeted reads instead of dumping huge logs, diffs, base64, or icon inventories into the chat.

  • read_file default output is tighter, while max_chars can still be raised for a specific targeted read.
  • run_command default output is tighter, while max_output_chars, head_lines, and tail_lines can still be used for focused debugging.
  • read_many has a smaller default batch cap so one call cannot flood a long ChatGPT thread.
  • Dashboard tips now surface large_payloads and command_heavy as signals to switch to line ranges, globs, and compact summaries.
  • Customer prompts now explicitly tell AI agents not to paste full logs, diffs, base64, image/icon inventories, or generated reports into chat.

For large tasks, start a fresh ChatGPT thread, use workspace_snapshot first, read only the line ranges you need, and keep raw artifacts as local files or support reports.

ChatGPT Web Compact & Resume

Local Coding Agent cannot read or replace ChatGPT Web's internal context window. Instead, v4.4.3 provides a safe MCP handoff that feels similar in use:

  1. In the long chat, call context_status, then compact_context.
  2. The server stores a local structured checkpoint with the goal, decisions, constraints, completed work, open tasks, next action, Git state, and recent test evidence.
  3. Open a fresh chat and call resume_context first.
  4. Verify workspace_info and git_status, then continue the recorded action.

Generate the copy-paste prompts with:

powershell
node scripts\local-coding-agent.mjs prompt compact
node scripts\local-coding-agent.mjs prompt resume

Only MCP tool-traffic pressure is estimated; it is not ChatGPT's actual token or context-window usage. Checkpoints stay under server/data/, which is ignored by Git, and use best-effort credential redaction. Never submit secrets or full source/log dumps to compact_context. See docs/CHATGPT_WEB_COMPACT.md.

Features

AreaWhat it does
Workspaceworkspace_info, workspace_snapshot, workspace_doctor, repo_map
Fileslist_files, read_file, read_many, write_file, replace_in_file, apply_patch
Searchsearch_text, find_files, repo_symbols, important_files
Commandsrun_command, run_commands, proc_start, proc_output, quality_gate
Gitgit_status, git_diff, review_diff, guarded git helper
Safetypolicy_status, explain_risk, request_approval, request_approval_batch
Permissionsnamed multi-root profiles, per-path rights, deny rules, temporary grants
Browser previewone paired/armed Chrome tab through bounded browser_* tools
Windows poweropt-in system_power_status, schedule_system_shutdown, cancel_system_shutdown
Dashboardhealth score, latency, tool calls, approvals, file viewer, git diff
Workflowcontext_status, compact_context, resume_context, notes, session reports, task state, decision log, skills

Shipped skills can be checked with:

powershell
scripts\lca.cmd skills list
scripts\lca.cmd skills validate

Safety Defaults

Recommended defaults:

text
AGENT_MODE=safe
AGENT_POLICY=balanced
DASHBOARD_PORT=8790

Security notes:

  • File tools are confined to configured workspace roots.
  • Command execution is not an OS sandbox.
  • Use safe mode for customers unless they explicitly accept full.
  • Use balanced policy so risky actions require local approval.
  • Use MCP_AUTH_TOKEN when exposing the server through a tunnel.
  • Do not commit API keys, tunnel profiles, generated config, or logs with secrets.
  • Use a VM/container for untrusted repositories.

Troubleshooting

ProblemWhat to check
node not foundInstall Node.js 18+ and reopen the terminal.
server/node_modules is missingRun scripts\lca.cmd install or bash scripts/lca install.
Dashboard offlineCheck http://127.0.0.1:8787/healthz, then run status or doctor.
Port conflictChange --port or --dashboard-port; do not use 8788 for the dashboard.
tunnel-client not foundPut the user-supplied tunnel client in tools/ or set its path in setup.
tunnel_active_organization_requiredProvide the OpenAI Organization ID that owns the tunnel.
401 UnauthorizedUse a Runtime API key, not an Admin key; check organization/project access.
poll failed or forcibly closedRun Network Doctor; office firewall/proxy may block tunnel/WebSocket traffic.
Edits appear in the wrong repoRun workspace_info and confirm the exact workspace path.

Development

Server tests:

bash
cd server
npm run test:agent
npm run test:pro
npm run test:security
npm run test:hardening
npm run eval

Tray app build:

powershell
cd tray-app
dotnet build LocalCodingAgentTray.csproj -c Release

License And Trademark

The Local Coding Agent Community Edition code is licensed under AGPL-3.0-or-later. Copyright © 2026 Long Nguyễn (@LongNgn204).

The code license does not grant permission to present a fork, service, or modified binary as an official Local Coding Agent release. See NOTICE.md, TRADEMARKS.md, and BRAND-GUIDELINES.md. The owner can use the trademark registration checklist to prepare a formal filing. Local Coding Agent is an independent project and is not an official product of OpenAI or any other MCP client vendor.


Tiếng Việt

Cài Đặt Bằng AI Agent Của Bạn

Cách dễ nhất là để một AI coding agent mạnh làm phần setup giúp bạn. Copy prompt này vào Codex, Claude Code, Cursor hoặc một local coding agent khác:

text
Hãy cài Local Coding Agent trên máy của tôi.

Repository:
https://github.com/LongNgn204/local-coding-agent

Mục tiêu:
Clone repo, cài dependency, cấu hình workspace, khởi động MCP server và kiểm tra
dashboard.

Quy tắc:
- Không tự cài dependency hệ thống nếu chưa hỏi tôi trước.
- Không tải, commit hoặc phân phối lại tunnel-client. Tôi sẽ tự cung cấp nếu cần.
- Không commit secret, API key, Tunnel ID, local config hoặc generated profile.
- Mặc định dùng mode=safe và policy=balanced.
- Ưu tiên dùng universal CLI. Chỉ dùng Windows tray app nếu tôi yêu cầu GUI.
- Nếu lỗi, hãy báo đúng lỗi và lệnh tiếp theo để sửa.

Các bước:
1. Clone https://github.com/LongNgn204/local-coding-agent nếu repo chưa tồn tại.
2. Đi vào thư mục repo và đọc AGENTS.md; làm theo đúng hướng dẫn.
3. Kiểm tra Node.js version >= 18 (node -v).
4. Cài đặt bằng:
   - Windows: scripts\lca.cmd install
   - macOS/Linux: bash scripts/lca install
5. Chạy setup bằng:
   - Windows: scripts\lca.cmd setup
   - macOS/Linux: bash scripts/lca setup
6. Hỏi tôi thư mục workspace mà AI được phép truy cập.
7. Nếu tôi muốn kết nối ChatGPT Web qua tunnel, hãy hỏi tunnel-client path,
   Tunnel ID, Organization ID nếu cần, và Runtime API key.
8. Khởi động bằng:
   - Windows: scripts\lca.cmd start
   - macOS/Linux: bash scripts/lca start
9. Kiểm tra:
   - http://127.0.0.1:8787/healthz trả về status ok
   - http://127.0.0.1:8790/ui mở được dashboard
   - Chạy bộ test tool: trong thư mục server/ chạy npm run test:agent
   - lệnh status chạy được
10. Giải thích kết quả cho tôi bằng lời dễ hiểu: cái gì đạt, cái gì lỗi, và lệnh
    tiếp theo chính xác để sửa phần lỗi.
11. Báo lại MCP URL, Dashboard URL, workspace path, mode, policy và trạng thái tunnel.

Các prompt khác nằm ở docs/AI_AGENT_SETUP_PROMPT.md. Nếu đã cài rồi và muốn update, dùng docs/CUSTOMER_UPDATE_PROMPT.md.

Sơ Đồ Setup

Bắt Đầu Nhanh Thủ Công

Windows:

powershell
git clone https://github.com/LongNgn204/local-coding-agent.git
cd local-coding-agent
scripts\lca.cmd install
scripts\lca.cmd setup
scripts\lca.cmd start

macOS / Linux:

bash
git clone https://github.com/LongNgn204/local-coding-agent.git
cd local-coding-agent
bash scripts/lca install
bash scripts/lca setup
bash scripts/lca start

Mở:

text
http://127.0.0.1:8790/ui

Các lệnh hữu ích:

text
status   xem MCP URL, Dashboard URL và trạng thái tiến trình
doctor   kiểm tra setup local và các thiếu sót thường gặp
update   fetch/pull main an toàn, cài lại dependency, validate skill
skills   liệt kê hoặc validate skill pack đi kèm
open     mở dashboard local
stop     dừng server và tunnel do CLI khởi động
logs     xem log launcher
url      in MCP URL

Tray App đa nền tảng

Tray Electron là GUI supervisor cho cùng local server và tunnel trên Windows và macOS. Secret được mã hoá bằng Windows DPAPI hoặc macOS Keychain.

Tải file .exe self-contained từ Releases, hoặc tự build:

Tải trực tiếp Electron v5.0.1 (bản đa nền tảng cũ):

Local Codex Studio đang là bản thử nghiệm nội bộ, vẫn trong quá trình phát triển và chưa có bản tải công khai.

App C# Windows mới: v5.0.2. Có giao diện gọn hơn và sửa lỗi tunnel YAML. EXE kèm .NET nhưng vẫn cần Node.js, server và tunnel client riêng. Xem nhật ký và hướng triển khai tiếp.

powershell
cd tray-app
powershell -ExecutionPolicy Bypass -File build.ps1

Tray .NET cũ vẫn được giữ làm bản tương thích Windows. Cài mới nên dùng Tray Electron đa nền tảng ở trên.

Kết Nối Với ChatGPT Web

  1. Khởi động local server trước và kiểm tra dashboard.
  2. Đặt OpenAI tunnel client ở tools/tunnel-client.exe trên Windows hoặc tools/tunnel-client trên macOS/Linux.
  3. Tạo hoặc chọn một tunnel trong ChatGPT/OpenAI.
  4. Nhập cùng Tunnel ID đó trong scripts/lca setup.
  5. Dùng Runtime API key cho CONTROL_PLANE_API_KEY. Không dùng Admin key.
  6. Nếu tổ chức yêu cầu, nhập OpenAI Organization ID.
  7. Khởi động CLI hoặc tray app và giữ nó chạy khi ChatGPT dùng tool.

URL local http://127.0.0.1:8787/mcp chỉ dành cho máy của bạn. ChatGPT Web phải kết nối qua secure tunnel, không phải bằng cách dán loopback URL local.

Chẩn Đoán Mạng Cho Khách

Nếu khách nói dùng hotspot thì chạy được nhưng mạng công ty/nội bộ thì lỗi, hãy bảo họ chạy Network Doctor trên đúng mạng đang lỗi và gửi lại report đã redact.

Kiểm tra cơ bản:

powershell
node scripts\network-doctor.mjs

Smoke test tunnel:

powershell
$env:CONTROL_PLANE_API_KEY="sk-proj-..."
node scripts\network-doctor.mjs --tunnel-bin "tools\tunnel-client.exe" --tunnel-id "tunnel_..." --organization-id "org_..." --duration 30

Hướng dẫn: docs/NETWORK_DOCTOR.md.

Để tạo gói hỗ trợ đầy đủ (đã che secret) mà khách gửi lại cho nhà phát triển:

powershell
node scripts\support-report.mjs
scripts\lca.cmd support

Lệnh in ra tóm tắt gọn và ghi file support-report.txt đã redact (phiên bản, Node, cổng 8787/8790, có tunnel-client hay không, health, lỗi gần đây). Nó không cần tunnel client độc quyền và không bao giờ ghi key hay token.

Quy Trình Chống Lag Stable

v4.4.3 giảm lag ChatGPT Web bằng cách thu nhỏ default output của tool và hướng AI agent đọc đúng phần cần thiết thay vì đổ log, diff, base64 hoặc danh sách icon khổng lồ vào chat.

  • read_file có default output gọn hơn, nhưng vẫn tăng được max_chars khi cần đọc đúng một phần mục tiêu.
  • run_command có default output gọn hơn, nhưng vẫn dùng được max_output_chars, head_lines và tail_lines khi debug.
  • read_many có batch cap mặc định nhỏ hơn để một call không làm nghẹt thread ChatGPT dài.
  • Dashboard tips báo large_payloads và command_heavy để nhắc chuyển sang line range, glob và tóm tắt gọn.
  • Prompt cho khách giờ nhắc rõ AI agent không được dán full log, diff, base64, image/icon inventory hoặc report dài vào chat.

Với tác vụ lớn, hãy mở thread ChatGPT mới, gọi workspace_snapshot trước, chỉ đọc đúng line range cần thiết và giữ artifact thô trong file local hoặc support report.

Compact & Resume Cho ChatGPT Web

Local Coding Agent không thể đọc hoặc thay thế context nội bộ của ChatGPT Web. Thay vào đó, v4.4.3 cung cấp quy trình bàn giao MCP an toàn với trải nghiệm gần giống compact:

  1. Trong chat dài, gọi context_status, sau đó gọi compact_context.
  2. Server lưu checkpoint có cấu trúc tại máy, gồm mục tiêu, quyết định, ràng buộc, việc đã xong, việc còn lại, hành động kế tiếp, Git state và test gần đây.
  3. Mở chat mới và gọi resume_context đầu tiên.
  4. Kiểm tra workspace_info và git_status, rồi tiếp tục hành động đã lưu.

Tạo prompt copy-paste bằng:

powershell
node scripts\local-coding-agent.mjs prompt compact
node scripts\local-coding-agent.mjs prompt resume

Hệ thống chỉ ước tính áp lực từ dữ liệu tool đi qua MCP, không phải token hay context window thật của ChatGPT. Checkpoint nằm trong server/data/, đã được Git bỏ qua, và có redact credential theo best effort. Không gửi secret, full source hoặc full log vào compact_context. Xem docs/CHATGPT_WEB_COMPACT.md.

Tính Năng

NhómChức năng
Workspaceworkspace_info, workspace_snapshot, workspace_doctor, repo_map
Filelist_files, read_file, read_many, write_file, replace_in_file, apply_patch
Tìm kiếmsearch_text, find_files, repo_symbols, important_files
Commandrun_command, run_commands, proc_start, proc_output, quality_gate
Gitgit_status, git_diff, review_diff, helper git có guard
An toànpolicy_status, explain_risk, request_approval, request_approval_batch
Phân quyềnprofile nhiều root, quyền theo path, deny rule, quyền tạm thời
Browser previewmột tab Chrome được pair/arm qua các tool browser_* có giới hạn
Nguồn Windowssystem_power_status, schedule_system_shutdown, cancel_system_shutdown có opt-in
Dashboardhealth score, latency, tool calls, approvals, file viewer, git diff
Workflowcontext_status, compact_context, resume_context, notes, session reports, task state, decision log, skills

Kiểm tra skill đi kèm:

powershell
scripts\lca.cmd skills list
scripts\lca.cmd skills validate

Mặc Định An Toàn

Khuyến nghị mặc định:

text
AGENT_MODE=safe
AGENT_POLICY=balanced
DASHBOARD_PORT=8790

Ghi chú bảo mật:

  • File tools bị giới hạn trong các workspace root đã cấu hình.
  • Chạy command không phải là OS sandbox.
  • Dùng safe mode cho khách trừ khi họ chủ động chấp nhận full.
  • Dùng balanced policy để hành động rủi ro cần duyệt local.
  • Dùng MCP_AUTH_TOKEN khi expose server qua tunnel.
  • Không commit API key, tunnel profile, generated config hoặc log có secret.
  • Dùng VM/container cho repo không tin cậy.

Khắc Phục Sự Cố

LỗiCần kiểm tra
Không thấy nodeCài Node.js 18+ rồi mở lại terminal.
server/node_modules is missingChạy scripts\lca.cmd install hoặc bash scripts/lca install.
Dashboard offlineKiểm tra http://127.0.0.1:8787/healthz, rồi chạy status hoặc doctor.
Đụng portĐổi --port hoặc --dashboard-port; không dùng 8788 cho dashboard.
Không thấy tunnel-clientĐặt tunnel client do người dùng cung cấp vào tools/ hoặc set path trong setup.
tunnel_active_organization_requiredNhập OpenAI Organization ID sở hữu tunnel.
401 UnauthorizedDùng Runtime API key, không dùng Admin key; kiểm tra quyền organization/project.
poll failed hoặc forcibly closedChạy Network Doctor; firewall/proxy công ty có thể chặn tunnel/WebSocket.
Sửa nhầm repoChạy workspace_info và kiểm tra workspace path thật.

Phát Triển

Test server:

bash
cd server
npm run test:agent
npm run test:pro
npm run test:security
npm run test:hardening
npm run eval

Build tray app:

powershell
cd tray-app
dotnet build LocalCodingAgentTray.csproj -c Release

Giấy Phép Và Nhãn Hiệu

Mã nguồn Local Coding Agent Community Edition được phát hành theo AGPL-3.0-or-later. Bản quyền © 2026 Long Nguyễn (@LongNgn204).

Giấy phép code không cấp quyền giới thiệu một fork, dịch vụ hoặc binary đã sửa đổi như bản phát hành Local Coding Agent chính thức. Xem NOTICE.md, TRADEMARKS.md và BRAND-GUIDELINES.md. Chủ dự án có thể dùng checklist đăng ký nhãn hiệu để chuẩn bị hồ sơ chính thức. Local Coding Agent là dự án độc lập, không phải sản phẩm chính thức của OpenAI hoặc bất kỳ nhà cung cấp MCP client nào khác.

Dùng MCP Local Coding Agent với nhiều mô hình AI

TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên sau khi kết nối Local Coding Agent, bạn có thể dùng với nhiều mô hình AI khác nhau trong TypingMind thay vì phải thiết lập riêng cho từng mô hình. MCP này chạy cục bộ thông qua trình kết nối MCP của TypingMind trên thiết bị của bạn.

Hướng dẫn thiết lập để dùng trình kết nối cục bộ

Dùng cách này khi máy chủ MCP cần truy cập các tệp, ứng dụng hoặc tài nguyên riêng tư trên máy tính của bạn.

1

Mở cài đặt MCP

Trong TypingMind, vào Cài đặt, Cài đặt nâng cao, rồi đến Giao thức ngữ cảnh mô hình và chọn Cài trình kết nối.

  1. Mở TypingMind trong trình duyệt của bạn.
  2. Nhấp vào biểu tượng Cài đặt.
  3. Vào Cài đặt nâng cao.
  4. Mở mục Giao thức ngữ cảnh mô hình.
  5. Nhấp vào Cài trình kết nối rồi chọn Thiết bị này.
Màn hình thiết lập trình kết nối MCP của TypingMind với tùy chọn Thiết bị này được chọn
2

Chạy lệnh trình kết nối

Chọn Thiết bị này, sao chép lệnh từ TypingMind và chạy trong Terminal. Giữ tiến trình chạy trong khi bạn dùng MCP.

  1. Sao chép lệnh thiết lập hiển thị trong TypingMind.
  2. Mở Terminal trên macOS hoặc Windows Terminal trên Windows.
  3. Dán và chạy lệnh.
  4. Xác nhận cài đặt gói nếu Terminal hỏi bạn có muốn tiếp tục không.
  5. Giữ tiến trình trong cửa sổ Terminal chạy trong khi dùng các công cụ MCP.
3

Thêm Local Coding Agent làm máy chủ

Khi trạng thái trình kết nối là Sẵn sàng, nhấp vào Sửa máy chủ và dán cấu hình máy chủ MCP.

  1. Đợi đến khi trạng thái trình kết nối hiển thị Sẵn sàng.
  2. Nhấp vào Sửa máy chủ.
  3. Dán cấu hình máy chủ MCP của Local Coding Agent.
  4. Lưu danh sách máy chủ.
  5. Làm mới nếu bạn muốn xác nhận trình kết nối vẫn sẵn sàng.
Cài đặt MCP của TypingMind hiển thị máy chủ đang hoạt động và nút Sửa máy chủ
{
  "mcpServers": {
    "local-coding-agent": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

Dùng kết nối với nhiều mô hình

Lưu danh sách máy chủ, mở Plugin, bật các công cụ MCP của Local Coding Agent, sau đó chọn bất kỳ mô hình AI nào được hỗ trợ trong TypingMind và dùng các công cụ trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.

  1. Mở trang Plugin trong TypingMind.
  2. Bật các công cụ MCP của Local Coding Agent.
  3. Bắt đầu cuộc trò chuyện và chọn mô hình AI bạn muốn dùng.
  4. Dùng các công cụ MCP trong cuộc trò chuyện hoặc gán chúng cho một tác nhân AI.
  5. Chuyển sang mô hình AI khác bất cứ khi nào cần mà không phải kết nối lại MCP.
Cuộc trò chuyện TypingMind dùng các công cụ MCP đã bật với một mô hình AI được chọn
Bạn có thể dùng Local Coding Agent giúp tôi làm việc này không?
Local Coding Agent
Được. Tôi đã đọc.
Đây là kết quả tôi tìm được bằng Local Coding Agent.

Câu hỏi thường gặp

Máy chủ MCP Local Coding Agent dùng để làm gì?

Local Coding Agent là máy chủ MCP cho phép các ứng dụng AI tương thích kết nối với công cụ và ngữ cảnh bên ngoài. Trong TypingMind, bạn chỉ cần thêm máy chủ MCP này một lần để các công cụ của nó có sẵn trong không gian làm việc AI của bạn.

Bạn có thể dùng MCP Local Coding Agent với nhiều mô hình AI trong TypingMind không?

Có. TypingMind kết nối các công cụ MCP ở cấp không gian làm việc, nên bạn có thể dùng Local Coding Agent với nhiều mô hình AI như Claude, ChatGPT, Gemini hoặc các mô hình khác đã cấu hình trong TypingMind mà không cần thiết lập máy chủ MCP riêng cho từng mô hình.

Vì sao nên dùng MCP Local Coding Agent với TypingMind?

TypingMind là một trong những giao diện trò chuyện với LLM tốt nhất vì tập hợp nhiều mô hình AI, prompt, plugin, tác nhân AI, khóa API và công cụ MCP vào một không gian làm việc. Khi kết nối Local Coding Agent, bạn có thể dùng các công cụ MCP của dịch vụ này với những mô hình ưa thích, đồng thời giữ quy trình trò chuyện gọn gàng trong TypingMind.

Làm cách nào để kết nối MCP Local Coding Agent với TypingMind?

Local Coding Agent hoạt động thông qua trình kết nối MCP cục bộ của TypingMind. Đây là lựa chọn phù hợp nhất khi máy chủ MCP cần truy cập tệp cục bộ, ứng dụng máy tính, công cụ dòng lệnh hoặc tài nguyên riêng trên máy tính của bạn.

MCP Local Coding Agent cung cấp những công cụ nào trong TypingMind?

Local Coding Agent cung cấp các chức năng MCP mà bạn có thể bật từ trang Plugin của TypingMind để dùng trong trò chuyện hoặc gán cho tác nhân AI.

Bạn có cần chia sẻ khóa API với TypingMind để dùng MCP Local Coding Agent không?

Không. TypingMind ưu tiên xử lý cục bộ và cho phép bạn kiểm soát nhà cung cấp mô hình, khóa API, prompt và cấu hình MCP. Nếu Local Coding Agent yêu cầu xác thực, hãy thêm các header, cài đặt OAuth hoặc cấu hình cục bộ cần thiết cho máy chủ MCP đó khi tạo kết nối.

Máy chủ MCP liên quan

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇