fx / sdk
AGENTS.md3.3k starsChanged 2 months agoApache-2.0View on GitHub
These instructions apply to work under sdk/ and supplement the repository-level AGENTS.md. This file is maintainer guidance, not consumer documentation. Keep setup and the supported public surface in sdk/README.md. Keep exact API shapes in sdk/fx-sdk.js and its tests. Add details here only when they help an agent choose the right owner, preserve a non-obvious invariant, or run the right proof. The native Node-API architecture and security model are documented in sdk/NAPI.md. The SDK has two WebAssembly surfaces and one shared…
- Reads credentials
Trending
Less talk lately.about the whole repository
Who's talking about vercel-labs/fx
- A Hacker News story“Fx: Unix Like Coding Agent”Hacker News · Aug 18, 2026 · 5 points
- @mint-echosphere.bsky.social“fx、7.8MiBのZig製コーディングエージェントと聞くと、つい「軽いなら気軽に全部任せられる?」って思っちゃいます。でもREADMEを読むと、軽いのはまずハーネスとCLIの話でした🌿…”Bluesky · Aug 21, 2026 · 2 likes
- @aibiznes.bsky.social“Vercel выпустила агента для программирования fx Vercel представила агента для кодинга под названием fx. Он …”Bluesky · Aug 22, 2026 · 1 likes
- @sigmanor.net“https://github.com/vercel-labs/fx”Bluesky · Aug 21, 2026 · 1 likes
- numtide/llm-agents.nix“fx: init at 0.0.3”GitHub · Aug 19, 2026 · 1 reactions
The biggest 5 of 30 mentions linking to the repository that our crawl found. Each line is their own headline.
See all 30
Talked about on GitHub, Bluesky and Hacker News (30 times).
On GitHub · 26
- Aug 19, 2026fx: init at 0.0.3 — numtide/llm-agents.nix1 reaction
- Aug 19, 2026Add fx agent — agentclientprotocol/registry1 reaction
- Oct 5, 2026Compact display-width range tables — y2-intel/harness0 reactions
- Oct 4, 2026fx-agent 0.0.13 — Homebrew/homebrew-core0 reactions · 1 comment
- Oct 4, 2026shouryamaanjain/session-history does not support fx 0.0.13 — shouryamaanjain/openmods0 reactions
21 more on GitHub
- Oct 2, 2026Repair the public-surface check, refresh the docs, and stop the test deadlock — frasergriffiths/xo0 reactions
- Sep 30, 2026fx-agent 0.0.12 — Homebrew/homebrew-core0 reactions · 1 comment
- Sep 29, 2026Integrate with Vercel fx — codeaholicguy/ai-devkit0 reactions
- Sep 24, 2026fx-agent 0.0.11 — Homebrew/homebrew-core0 reactions · 1 comment
- Sep 17, 2026Retain subagent statusline upon completion — scotttrinh/fx0 reactions
- Sep 14, 2026fx-agent 0.0.10 — Homebrew/homebrew-core0 reactions · 1 comment
- Sep 12, 2026fx-agent 0.0.9 — Homebrew/homebrew-core0 reactions · 1 comment
- Sep 10, 2026Add fx (Vercel Labs) v0.0.8 — agentclientprotocol/registry0 reactions · 1 comment
- Sep 7, 2026fx-agent 0.0.8 — Homebrew/homebrew-core0 reactions · 1 comment
- Aug 31, 2026Update stacked: 6 packages — gominimal/pkgs0 reactions
- Aug 31, 2026Update stacked: 2 packages — gominimal/pkgs0 reactions
- Aug 30, 2026Add the missing UX on vercel-labs/fx — keejkrej/fx0 reactions · 1 comment
- Aug 29, 2026fx-agent 0.0.7 — Homebrew/homebrew-core0 reactions · 1 comment
- Aug 28, 2026[RESEARCH] fx Core Library API Surface for Mobile — 10xdev4u-alt/fx-mobile0 reactions · 1 comment
- Aug 28, 2026[RESEARCH] Subagent Architecture for Mobile — 10xdev4u-alt/fx-mobile0 reactions · 1 comment
- Aug 28, 2026[RESEARCH] MCP Server Support on Android — 10xdev4u-alt/fx-mobile0 reactions · 1 comment
- Aug 28, 2026[RESEARCH] Inference Engine: Xybrid (local) + Kilo (cloud) — 10xdev4u-alt/fx-mobile0 reactions · 3 comments
- Aug 25, 2026fx-agent 0.0.6 — Homebrew/homebrew-core0 reactions · 1 comment
- Aug 23, 2026[HARNESS]: fx adapter must target ~/.fx (mcp.json root key 'mcp', array-form command) — current ~/.config/fx/fx.json is fictional — mastepanoski/ce-ai0 reactions · 1 comment
- Aug 19, 2026feat: support Vercel Labs fx agent — yu-iskw/coding-agent-skills0 reactions · 1 comment
- Aug 18, 2026[Tool Submission] fx.sh — QAInsights/awesome-ai-tools0 reactions
On Bluesky · 3
- Aug 21, 2026fx、7.8MiBのZig製コーディングエージェントと聞くと、つい「軽いなら気軽に全部任せられる?」って思っちゃいます。でもREADMEを読むと、軽いのはまずハーネスとCLIの話でした🌿… — @mint-echosphere.bsky.social2 likes and reposts · 1 reply
- Aug 22, 2026Vercel выпустила агента для программирования fx Vercel представила агента для кодинга под названием fx. Он идёт против текущего тренда —… — @aibiznes.bsky.social1 likes and repost
- Aug 21, 2026https://github.com/vercel-labs/fx — @sigmanor.net1 likes and repost
On Hacker News · 1
- Aug 18, 2026Fx: Unix Like Coding Agent5 points · 1 comment
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about checking a change actually works.
Of the AGENTS.md files we read, the 11,773 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository2 other files it gives its agents.
- AGENTS.mdAGENTS.md
- technical-writerSkill
The file
We split this AGENTS.md into the rules it gives an agent
7 rules. About 0 are common, 1 is distinctive, and 6 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
6
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 25
Do not treat the demos or this file as the implementation contract.
- Very specific: line 29
Keep sdk/fx-sdk.js a dependency-free ECMAScript module.
- Very specific: line 30
Keep the core and terminal surfaces distinct.
- Very specific: line 32
Treat JavaScript host stores as durable contracts.
- Very specific: line 35
Keep workspace version 1 constrained to an ephemeral, non-git workspace whose normalized cwd equals root.
- Very specific: line 54
Use Node.js 24 for SDK tests.
- Very specific: line 93
Do not commit zig-out/, sdk/dist/, or other generated artifacts.
≈ “Common” is an estimate: at least 1 in 5 of the 16,595 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
WebAssembly SDK instructions
These instructions apply to work under sdk/ and supplement the repository-level AGENTS.md.
This file is maintainer guidance, not consumer documentation. Keep setup and the supported public surface in sdk/README.md. Keep exact API shapes in sdk/fx-sdk.js and its tests. Add details here only when they help an agent choose the right owner, preserve a non-obvious invariant, or run the right proof. The native Node-API architecture and security model are documented in sdk/NAPI.md.
Start from the correct owner
The SDK has two WebAssembly surfaces and one shared JavaScript host layer:
| Concern | Source of truth |
| Shared loader, host imports, adapters, and public JavaScript exports | sdk/fx-sdk.js |
Headless ACP composition for fx-core.wasm | src/wasm_core_main.zig |
Interactive terminal entry point for fx-term.wasm | src/wasm_term_main.zig and runWasmTerminal in src/main.zig |
| Native and WebAssembly capability policy | src/core/hosts/runtime_profile.zig |
| Host-backed terminal session persistence | src/core/app/app_session_runtime.zig and sdk/fx-sdk.js |
Browser workspace contract and shell.run bridge | src/core/hosts/js_host_workspace.zig and src/tools/shell/browser_shell.zig |
| Browser device login, OAuth session persistence, and URL opening | src/core/auth/js_host_auth.zig, src/core/auth/oauth_session.zig, and src/core/hosts/js_host_url_opener.zig |
| WASI target, optimization mode, threading, and artifact names | build.zig |
| Core browser fixture and its automation contract | sdk/index.html and sdk/tests/test-core-browser.mjs |
| Terminal fixture and static packaging contract | sdk/term-demo.html and sdk/scripts/package-term-demo.mjs |
| Commands required by CI | .github/workflows/ci.yml |
Do not treat the demos or this file as the implementation contract. When prose and behavior disagree, establish the current behavior from code and focused tests before changing either.
Preserve these invariants
- Keep
sdk/fx-sdk.jsa dependency-free ECMAScript module. A bundler, framework, or runtime package must not become necessary to load the SDK. - Keep the core and terminal surfaces distinct.
fx-core.wasmstarts the headless ACP server;fx-term.wasmstarts the interactive terminal. Shared loader changes must be validated against both. - Detect JavaScript Promise Integration (JSPI) by capability through
supportsJspi(). Do not replace feature detection with browser or version sniffing. Keep loader errors, demo fallback states, and the compatibility statement insdk/README.mdconsistent. - Treat JavaScript host stores as durable contracts. Session and OAuth snapshots are opaque bytes with optimistic revisions. Preserve
FX_SESSION_REVISION_CONFLICTandFX_OAUTH_SESSION_REVISION_CONFLICT. Persist configuration only after fx accepts it, and do not collapse prompt-history outcomes into generic success. - Preserve cancellation and lifecycle behavior. Fetch cancellation must reach the host
AbortSignal; terminal subscriptions must be released exactly once;abort()must settleexitedand must not leave input or resize listeners attached. - The WebAssembly runtime is not the native runtime. Keep native tools disabled. The optional workspace host may expose only completion-only
shell.runthrough its typed boundary and permission policy. Its schema is exactly{ action: "run", command }; native profiles, TTYs, and managed running handles are unavailable. Any additional capability requires its own typed host boundary, permission review where applicable, and coverage on the affected surface. - Keep workspace version 1 constrained to an ephemeral, non-git workspace whose normalized
cwdequalsroot. Preserve command and output limits, the 30-second maximum deadline, and Ctrl+C cancellation through the shared host-effect abort path. window.__fxCoreTestanddocument.body.dataset.stateare test interfaces for the core debugger. If either changes intentionally, update the browser test in the same change.- The live demos may pass a locally stored credential into the WebAssembly environment. Never print, serialize into artifacts, or add test assertions containing that credential.
Match the proof to the change
| Change | Minimum focused proof |
| Public export, shared loader, WASI import, or JSPI gate | Build and test both surfaces |
createFxAgent(), ACP translation, core session persistence, streaming, or cancellation | Core build, core Node tests, and the browser test when browser behavior is involved |
| Live Gateway request or model-catalog translation | Core tests plus the opt-in live smoke test when a credential is available |
| Terminal adapter, input encoding, resize, cleanup, config, or prompt history | Terminal build and the headless terminal suite |
| Terminal session persistence or browser device login | Terminal build plus sdk/tests/test-term-session-resume.mjs or sdk/tests/test-term-login.mjs |
| Browser workspace metadata, permissions, execution, limits, or cancellation | Terminal build plus sdk/node/test-term-workspace.mjs |
encodeXtermKeyEvent() or xtermAdapter() only | sdk/node/test-xterm-adapter.mjs |
| Core debugger query behavior or automation state | sdk/tests/test-core-browser.mjs |
| Terminal demo asset references, integrity, or cache policy | Package into a fresh temporary directory and inspect the generated HTML, manifest, and headers |
| Supported public behavior or setup | Update sdk/README.md in the same change |
Use Node.js 24 for SDK tests. CI relies on its JSPI implementation behind --experimental-wasm-jspi.
Core validation from the repository root:
zig build -Dwasm-surface=core
node --experimental-wasm-jspi sdk/tests/test-core.mjs
node --experimental-wasm-jspi sdk/tests/test-core-cancel.mjs
node --experimental-wasm-jspi sdk/tests/test-core-home-unavailable.mjs
node sdk/tests/test-core-browser.mjsSet CHROME_PATH for the browser test only when Chrome or Chromium is outside the paths searched by the script.
Terminal validation from the repository root:
zig build -Dwasm-surface=term
npm ci --prefix sdk/node
npm run --prefix sdk/node test:term
node --experimental-wasm-jspi sdk/tests/test-term-session-resume.mjs
node --experimental-wasm-jspi sdk/tests/test-term-login.mjsFor a live Gateway transport change, AI_GATEWAY_API_KEY must already be present in the environment before running the opt-in smoke test:
node --experimental-wasm-jspi sdk/tests/test-core-live.mjsFor behavior changes, also follow sdk/README.md to serve the repository and drive one real interaction in the affected browser demo. Automated tests do not replace this runtime exercise.
The terminal packaging script removes its output directory before writing. Always give it a newly created temporary directory:
sdk_package_dir="$(mktemp -d)"
node sdk/scripts/package-term-demo.mjs "$sdk_package_dir"Do not commit zig-out/, sdk/dist/, or other generated artifacts. Run git diff --check before creating a checkpoint. The repository-level build, binary exercise, and Full CI ship gates still apply.
Code review rules
- Flag a public contract change that lacks a focused regression test. Require a README update only when supported public behavior or setup changed.
- Flag code that makes one surface silently depend on the other surface's composition or capability profile.
- Flag user-agent checks for JSPI, swallowed session or OAuth revision conflicts, premature config writes, lost prompt-history outcomes, or terminal listener leaks.
- Flag workspace adapters that bypass typed metadata validation, permission admission, resource limits, or the shared cancellation path.
- Flag deployment changes that give mutable HTML the same long-lived cache policy as content-addressed JavaScript or WebAssembly assets.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

