AI agent (Claude) with bash access to a Mesa repo, built with LangChain.
Same functionality as just-bash-ai-sdk, but using LangChain's createAgent with tool and the LangGraph runtime for streaming.
npm install
# Create a .env in this directory (gitignored)
cp .env.example .env
# Now populate your .env file with the required values
# Run
npm startMesaclient initializes a virtual filesystem viamesa.fs.mount()(native Rust via NAPI)mesaFs.bash()returns a bash instance backed by the virtual filesystem- A
bashtool is defined using LangChain'stool() createAgent()wires up the model + tools into a LangGraph runtime that handles the tool-calling loop- Dual-stream mode:
"values"gives canonical history for the next turn,"messages"gives token-level chunks for the UI
| Variable | Description |
|---|---|
MESA_ORG |
Your Mesa organization slug |
MESA_REPO |
The repository to mount |
MESA_API_KEY |
Mesa API key (get one here) |
ANTHROPIC_API_KEY |
Anthropic API key (get one here) |
- Node.js >= 18
- Mesa account with an API key
- Anthropic API key