代码工作流AI 是 AI Skill Hub 本期精选Agent工作流之一。综合评分 8.0 分,整体质量较高。我们强烈推荐将其纳入你的 AI 工具库,帮助提升工作效率。
代码工作流AI 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
代码工作流AI 是一套完整的 AI Agent 自动化工作流方案。通过可视化的节点编排,将复杂的多步骤任务拆解为清晰的自动化流程,实现全程无人值守的智能处理。支持与数百种外部服务和 API 无缝集成,适合构建数据处理管线、业务自动化和 AI 辅助决策系统。
# 方式一:npm 全局安装 npm install -g dvalincode # 方式二:npx 直接运行(无需安装) npx dvalincode --help # 方式三:项目依赖安装 npm install dvalincode # 方式四:从源码运行 git clone https://github.com/arthurpanhku/dvalincode cd dvalincode npm install npm start
# 命令行使用
dvalincode --help
# 基本用法
dvalincode [options] <input>
# Node.js 代码中使用
const dvalincode = require('dvalincode');
const result = await dvalincode.run(options);
console.log(result);
# dvalincode 配置说明 # 查看配置选项 dvalincode --config-example > config.yml # 常见配置项 # output_dir: ./output # log_level: info # workers: 4 # 环境变量(覆盖配置文件) export DVALINCODE_CONFIG="/path/to/config.yml"
<p align="center"> <img src="assets/logo.png" alt="DvalinCode" width="480"> </p>
<p align="center"> <b>English</b> · <a href="README.zh-CN.md">中文</a> </p>
<p align="center"> <a href="https://github.com/arthurpanhku/dvalincode/releases/latest"><img src="https://img.shields.io/github/v/release/arthurpanhku/dvalincode?style=for-the-badge&color=818cf8&label=Release" alt="Release"></a> <a href="https://github.com/arthurpanhku/dvalincode/releases"><img src="https://img.shields.io/github/downloads/arthurpanhku/dvalincode/total?style=for-the-badge&color=blue&label=Downloads" alt="Downloads"></a> <a href="#-tests"><img src="https://img.shields.io/badge/Tests-95%20%2F%2095%20%E2%9C%93-success?style=for-the-badge" alt="Tests"></a> <a href="LICENSE"><img src="https://img.shields.io/badge/License-MIT-green?style=for-the-badge" alt="License"></a> <a href="#-quick-install"><img src="https://img.shields.io/badge/Platforms-macOS%20·%20Windows%20·%20Linux-blue?style=for-the-badge" alt="Platforms"></a> <a href="#-providers"><img src="https://img.shields.io/badge/LLM-OpenAI%20·%20Claude%20·%20DeepSeek%20·%20Ollama%20·%20Groq-7C3AED?style=for-the-badge" alt="LLM Support"></a> <a href="README.zh-CN.md"><img src="https://img.shields.io/badge/i18n-EN%20·%20中文-orange?style=for-the-badge" alt="English / 中文"></a> </p>
<p align="center"> <b>A local-first coding agent: any model, safe by default, small enough to audit, open enough to embed.</b><br> <b>Three modes — Chat for questions, Cowork for plan-then-execute, Code for autonomous work.</b> </p>
<p align="center"> <b>🔑 Controllable · transparent · auditable — the coding agent your security team can actually approve.</b> </p>
<p align="center"> Bring your own model — DeepSeek, OpenAI, Claude (via OpenRouter), Groq, Ollama, or any OpenAI-compatible endpoint. Switch with one click, no code changes, no lock-in. </p>
---
| 🗨️ Chat mode | Read-only Q&A with one-click prompt templates — explain a codebase, find TODOs, review changes, write tests. The agent can read files and search, but never writes. |
| 👥 Cowork mode | Plan-then-execute. The agent drafts a numbered plan, you click Proceed, and every file write asks for explicit approval — with an inline red/green diff before you say yes. |
| ⚡ Code mode | Autonomous agent with full tool access. Run tests, type-check, build, lint — one click via the Routines panel. macOS shell calls run inside a sandbox-exec profile with network denied. |
| 🛡️ Audit trail | Every run emits a tamper-evident, hash-chained JSONL log — every file read/written, every command, every approval. A Run Report renders it as Markdown; dvalincode report verify proves the chain is intact. Threat model → |
🔒 Org policy & trust | A company — not the developer — bounds the agent. A dvalin.policy.json constrains modes, shell commands, file paths, tools, and models; a repo policy can only ever narrow the machine-level one, never widen it. Each run records the governing policy's hash. dvalincode trust prints the install's live security posture — active policy + hashes, audit status, runtime — so a reviewer can verify it directly. Approvability plan → |
| 🖥️ First-class GUI | Modern web UI with code highlighting, file @-references, / slash commands, Git branch indicator, live token + cost counter, multi-profile LLM config, and a dark / light / system theme switcher. |
| 🖥️ Terminal or web — one binary | Run it bare for an interactive terminal agent (like Claude Code — streaming, inline approvals, red/green diffs), or dvalincode serve to host the web GUI for browser/remote use. Both frontends drive the same agent core. |
| 🪶 Zero-dependency binary | Single ~25MB executable per platform. No Node, no Python, no Docker. |
| 🔐 Local-first | Sessions, config, profiles, and audit logs live in ~/.dvalincode/. .dvalincodeignore blocks the agent from reading sensitive files. AGENTS.md in your repo becomes persistent project instructions. |
| 💾 Portable & exportable | Export all local data (memory, sessions, config, audit) to one file and import it on another machine — your setup moves with you. Any conversation downloads as a clean Markdown transcript. |
---
dvalin.policy.json lets a company, not the developer, bound the agent: which modes, shell commands, file paths, tools, and models are allowed. Two layers (machine ~/.dvalincode/policy.json + repo) resolve by narrowing — a repo policy can only ever make the machine policy stricter, never widen it. With no policy file, behavior is identical to before. Enforced at a single chokepoint; every denial is an inline ⛔ Blocked by policy plus a policy_violation audit event.dvalincode trust — prints this install's live security posture in one command — active policy + source hashes, audit status, runtime, dependencies — so a reviewer can verify what the agent may and may not do directly, instead of taking claims on trust. --json for tooling.run_start, so the tamper-evident log proves which rules were in force.<details> <summary>v0.7.0 — 🧪 Desktop app (beta)</summary>
dvalincode export / dvalincode import, or the Export / Import buttons in the GUI Settings panel.dvalincode session md <id>, or GET /api/sessions/:id/markdown.DvalinCode.app on macOS, plus Windows/Linux builds. Built with webview-bun using the OS-native webview (WKWebView / WebView2 / WebKitGTK) — no Electron, stays a small self-contained binary.dvalincode binary is now positioned purely as the CLI (terminal + serve).</details>
<details> <summary>v0.6.0 — terminal agent · <code>serve</code> · shared turn-runner</summary>
dvalincode bare for an interactive terminal coding agent, Claude-Code-style: streaming responses, inline [y/N] write approvals with red/green diffs, /mode · /clear · /git · /plan · /compact · /undo · /help, Ctrl-C to interrupt, and a guided first-run provider setup. Defaults to read-only Chat, switchable live.dvalincode serve — the web GUI now lives behind a command, so the same binary deploys headless on a server: dvalincode serve --host 0.0.0.0 --no-open.src/agent/session.ts), keeping them at feature parity.</details>
<details> <summary>v0.5.0 — security-grade audit trail · Run Report · theme switcher</summary>
- 🛡️ Security-grade audit trail — every Cowork/Code run writes a tamper-evident, hash-chained JSONL log to ~/.dvalincode/audit/ (run_start, every tool_call / file_* / shell_exec / approval, run_end). The hash chain makes any after-the-fact edit detectable. No local coding agent ships verifiable behavior logs. Format + threat model → - 📋 Run Report + dvalincode report CLI — a Markdown summary of each run (files read/changed, commands, decisions, test result), rendered as a collapsible card in the GUI and from the CLI:
dvalincode report --last # render the most recent run
dvalincode report <run-id> --format json
dvalincode report verify <run-id> # ✓ chain intact / ✗ broken at seq N
- 🎨 Theme switcher — choose dark / light / system in Settings. system follows your OS live; the choice persists across sessions.
</details>
<details> <summary>v0.4.0 — <code>/compact</code> · <code>dvalin.json</code> team playbook · self-contained binaries</summary>
/compact — LLM-based context compaction: replaces conversation history with a structured five-section summary (Goal / Completed / Decisions / Current State / Pending). A divider in the chat thread shows the token reduction (e.g. 8,412 → 1,203 tokens −85%).dvalin.json team playbook — commit a shared set of automation prompts to your repo. The sidebar loads them automatically and lets teammates run the same one-click routines without any manual setup. Export button converts your personal routines to dvalin.json in one click.bun --compile so the web UI is bundled alongside the server binary.</details>
<details> <summary>v0.3.0 — Mode-aware sidebar · one-line installer · multi-profile LLM config</summary>
localStorage.curl … | bash auto-detects your OS + arch, drops the binary into ~/.dvalincode/, and patches your PATH. No package manager dependencies.</details>
---
| Category | Feature | Notes |
|---|---|---|
| **Modes** | Chat / Cowork / Code | Each with a distinct sidebar (Templates / Projects / Routines) and tool-access policy |
| **Code permissions** | Ask Permissions / Plan Mode / Auto Mode / Bypass permissions | Verified behavior: Ask requests approval before writes/commands, Plan is read-only and does not write files, Auto runs operations automatically, Bypass runs without confirmation prompts |
| **Workspaces** | Open folder / Import Git / Add worktree | Cowork and Code can switch to a local folder, clone a Git project, or create a Git worktree from the UI |
| **Composer** | @ file references | Type @ for a fuzzy file search; selected files get inlined into the prompt |
/ slash commands | /clear /compact /git /plan /undo /help | |
| Multiline + interrupt | <kbd>Shift</kbd>+<kbd>Enter</kbd> for newline, stop button to abort mid-stream | |
| **Tool UI** | Inline diffs | edit_file and write_file results render as red/green unified diff, default folded |
| Approval dialog with diff | Cowork mode shows the diff *before* the change is applied | |
| Live tool counter + token + cost | Topbar shows session totals in real time | |
| **Agent** | LLM-based context compaction | /compact summarises into Goal / Completed / Decisions / Pending |
| Persistent undo stack | /undo [N] reverses the last N tool calls | |
| Run Report | Markdown summary per run (files, commands, decisions, test result) — GUI card + dvalincode report | |
| Git awareness | Branch name in topbar; git_status tool; git context auto-injected into prompt | |
AGENTS.md project memory | Per-repo persistent instructions, auto-loaded each turn | |
| **Security** | Tamper-evident audit trail | Hash-chained JSONL per run in ~/.dvalincode/audit/; dvalincode report verify detects edits |
| macOS shell sandbox | sandbox-exec denies network; allows writes only inside cwd + /tmp | |
.dvalincodeignore | gitignore-style exclusion; blocks read_file / list_files / search_text | |
| Per-action approval | Approve/deny each write / delete / shell call in Cowork mode | |
| **Appearance** | Theme switcher | Dark / light / system, persisted; system follows the OS live |
| **Providers** | OpenAI-compatible endpoints | DeepSeek · OpenAI · Groq · OpenRouter · Ollama · custom |
| Multi-profile config | Save and switch between named (provider, model, API key) sets | |
| **Sessions** | Auto-save + restore | All sessions persisted to ~/.dvalincode/sessions/ as JSON |
| LLM summary memory | Cross-session summary keeps the agent oriented after restart | |
| **Memory** | Local user/project memory | Searchable facts, preferences, and decisions in ~/.dvalincode/memory/; import from Claude/Hermes/Markdown |
| **Data portability** | Export / import all data | One bundle of memory + sessions + config + audit — dvalincode export / import, or GUI Settings → Export / Import |
| Markdown transcript | Download any conversation as Markdown — sidebar download icon, dvalincode session md <id>, or /api/sessions/:id/markdown |
---
Terminal (default): run dvalincode. On first launch it walks you through a one-time provider setup (pick a provider, paste your API key, choose a model) and saves it to ~/.dvalincode/config.json. Then you're at the prompt — type to chat, /mode to switch between Chat / Cowork / Code, /help for commands.
Web GUI: run dvalincode serve and:
http://localhost:3000 and your browser opens automatically.fast, cheap, local-ollama) to switch quickly later.Both share the same config and sessions in ~/.dvalincode/.
---
Requires Bun (curl -fsSL https://bun.sh/install | bash).
git clone https://github.com/arthurpanhku/dvalincode
cd dvalincode
npm install
npm run dev:all # start backend (3001) + Vite (5173)
Build release binaries for every platform:
bash scripts/build-release.sh # → release/ with tar.gz / zip + SHA256SUMS.txt
bash scripts/build-release.sh darwin # macOS only
bash scripts/build-release.sh windows # Windows only
Before publishing a release:
(cd release && shasum -a 256 -c SHA256SUMS.txt)
unzip -l release/dvalincode-v*-windows-x64.zip | grep 'web/dist/index.html'
tar tzf release/dvalincode-v*-macos-arm64.tar.gz | grep 'DvalinCode.app/Contents/Resources/AppIcon.icns'
Windows smoke test: unzip dvalincode-v*-windows-x64.zip on Windows and run start.bat from the extracted folder. The server should open http://localhost:3000. If it reports an ENOENT path under B:\~BUN\root\web\dist, the compiled Bun virtual path detection has regressed; the packaged binary must resolve web/dist beside the extracted executable.
Note: Bun only allows Windows .exe icon/metadata injection when compiling on Windows. macOS/Linux cross-builds still produce a valid Windows archive, but without an embedded .exe icon.
---
<details> <summary><b>Does it send my code to a third party?</b></summary> <br> Only what the agent sends to the LLM you configured. Sessions, configs, and profiles all live on your machine in <code>~/.dvalincode/</code>. To exclude sensitive files from the agent's view, drop a <code>.dvalincodeignore</code> in your repo root (gitignore-style patterns). </details>
<details> <summary><b>Can I run this without an API key?</b></summary> <br> Yes — use Ollama. Pull a model (<code>ollama pull qwen2.5-coder</code>), then in the LLM Configuration modal pick the <b>Ollama</b> provider. No key, no internet, no per-token cost. </details>
<details> <summary><b>Why three modes? Can't I just use one?</b></summary> <br> Each mode has different <b>tool access</b> and <b>safety</b> defaults: Chat is read-only, Cowork requires approval per write, Code is full-auto. Each also has a different sidebar (Templates / Projects / Routines) optimized for that workflow. You can switch any time — the conversation continues. </details>
<details> <summary><b>Is the shell tool sandboxed?</b></summary> <br> On macOS, yes — every <code>shell</code> tool invocation is wrapped in <code>sandbox-exec</code> with a profile that <i>denies network access</i> and allows file writes only inside <code>cwd</code>, <code>/tmp</code>, and <code>/var</code>. Linux and Windows sandboxing is planned. </details>
<details> <summary><b>How do I see what the agent actually did — and is the log trustworthy?</b></summary> <br> Every run writes a JSONL audit log to <code>~/.dvalincode/audit/run-<timestamp>-<id>.jsonl</code>. Render it with <code>dvalincode report --last</code> (or see the collapsible Run Report card in the GUI). Each record is chained to the previous one with a SHA-256 hash, so any after-the-fact edit is detectable — <code>dvalincode report verify <run-id></code> reports <code>✓ chain intact</code> or the exact position of a break. It's tamper-<b>evident</b>, not tamper-<b>proof</b>: a local attacker who can rewrite the whole file could recompute the chain. The value is forensic/accountability. See <a href="docs/AUDIT-TRAIL.md">docs/AUDIT-TRAIL.md</a> for the full threat model. </details>
<details> <summary><b>Will it overwrite my files without asking?</b></summary> <br> Depends on the mode. <b>Chat</b> never writes. <b>Cowork</b> requires approval per file (with inline red/green diff before you click Allow). <b>Code</b> is full-auto — use it for trusted tasks or in a feature branch. </details>
<details> <summary><b>The macOS binary won't open — "unverified developer"</b></summary> <br> The binary is unsigned. Run this once to clear the quarantine flag: <pre><code>xattr -dr com.apple.quarantine ~/.dvalincode</code></pre> Or right-click the binary in Finder → Open → confirm once. </details>
<details> <summary><b>How do I save a routine in Code mode?</b></summary> <br> Switch to Code mode, click the <b>+</b> next to "ROUTINES" in the sidebar. Enter a name (e.g. "Deploy preview") and a prompt or slash command (e.g. "<code>/git</code>" or "Build the project and deploy to staging"). Routines persist in your browser's <code>localStorage</code>. </details>
<details> <summary><b>Does <code>AGENTS.md</code> get sent every turn?</b></summary> <br> Yes — DvalinCode reads <code>AGENTS.md</code> from the project root before each turn and injects it under <code>=== PROJECT INSTRUCTIONS ===</code> in the system prompt. Keep it focused — it counts toward your token budget. </details>
---
高质量的开源AI工作流项目,值得关注
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
经综合评估,代码工作流AI 在Agent工作流赛道中表现稳健,质量优秀。如果你已有明确的使用需求,可以直接上手体验;如果还在评估阶段,建议对比同类工具后再做决策。
| 原始名称 | dvalincode |
| Topics | aiclitypescript工作流 |
| GitHub | https://github.com/arthurpanhku/dvalincode |
| License | MIT |
| 语言 | TypeScript |
收录时间:2026-06-24 · 更新时间:2026-06-24 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端