MirageThe World's First Virtual Terminal for AI Agents

One unified interface for AI agents, with a virtual filesystem and swappable runtimes across machines, services, and clouds. Scale your agents with fewer tokens and less infrastructure.

npm install @struktoai/mirage-node
npm install @struktoai/mirage-browser
const ws = new Workspace({
  '/tmp':   [new RAMResource(), MountMode.EXEC],
  '/redis': [new RedisResource({ url: redisUrl }), MountMode.WRITE],
  '/slack': [new SlackResource({ token: slackToken }), MountMode.EXEC],
}, { runtimes: [buildRuntime('monty', { captures: ['python'] }), 'vfs'] })
// one grep sweeps every source
await ws.execute('grep -rln session /redis /tmp')
// run a script that lives in Slack, report into Redis
await ws.execute('python3 /slack/report.py > /redis/report.txt')
// a typed CLI under a head word, found by man and which
ws.registerCli('slack', SLACK, { token: slackToken })
await ws.execute('slack send-message --channel general')

Virtual Terminal Overview

A Real Example

A real Mirage workspace, running in your own browser tab. Mount GitHub and Redis, switch agent profiles, allow or refuse commands, hide folders and files, choose a Python runtime, install your own virtual CLI, and edit files in the terminal.

?

A real Mirage Virtual Terminal, running in browser?

A Unified Virtual Filesystem

A unified virtual filesystem over every source. S3, Google Drive, Slack, Gmail, Redis and the rest mount side by side under one root, so an AI agent can reach all of them through a unified interface with the Unix-like tools it already knows, like ls, grep, find and jq. A script sees the same root, and Python run through a virtual runtime opens those mounts exactly as the shell does.

VFS

Virtual Command Line Tools

A virtual command line for every service. git, slack and ntn are registered in the workspace rather than installed on the machine, so an agent drives each service with nothing installed, across different runtimes and machines. And one tool can be virtualized into two or more, each under its own name with its own credentials.

VFSVirtual CLI

The Mirage Shell

The shell is the glue. It binds the virtual CLIs and the Unix-like operations on the filesystem into one command line, so pipes, redirection, variables, jobs and history work across all three layers. A mounted Slack channel greps like a directory, its output redirects into Redis, and a virtual CLI reads the result back, in a single line an agent already knows how to write.

$ grep -rl VFS | Virtual CLI | Script

Virtual Runtimes

Runtimes are virtualized the same way, and not only for running scripts. Any command on the line can be redirected to a configured runtime, so Python might run in-process with Monty while another command, say kubectl, is sent to a remote machine over SSH. Which runtime serves a given line need not be fixed in the document either, since it can be chosen dynamically, per line, by a scripted runtime router.

$ grep -rl VFS | Virtual CLI | Script

Runtime

Policy Engine

A scriptable policy engine runs before every command in the virtual terminal. A policy decides which commands to allow, which to ask about, and which to refuse outright, and it decides where a command runs as well, routing it to a runtime from the context it can see. That context is the line itself, the paths it touches, and the virtual filesystem behind them.

Policy

$ grep -rl VFS | Virtual CLI | Script

Runtime

Authentication and Notifications

Mirage supports cloud authentication, and not only for what the virtual filesystem and the virtual CLIs need to reach a service. A credential store fills the virtual terminal's own environment variables too. It integrates with cloud notification services the same way, so an external change arrives as a change to a file and an agent reacts to it instead of rescanning the tree.

Authentication
Notifications
Policy

$ grep -rl VFS | Virtual CLI | Script

Runtime

Profiles and Agents

Mirage assigns a profile to an agent, and the profile is the whole of what that agent can see or do. It names the runtime, the mount mode for every path in the virtual filesystem, which command lines and runtimes the agent may reach, and which folders and files it cannot see at all.

Every profile is driven by an agent, and Mirage integrates deeply with the frameworks and harnesses teams already run, among them the OpenAI Agents SDK, the Claude Agent SDK, LangChain, Pydantic AI, CAMEL, Agno, OpenHands, Mastra, Haystack and more.

Authentication
Notifications
Profile 1
Policy

$ grep -rl VFS | Virtual CLI | Script

Runtime

Portability

Mirage is extremely portable. It runs inside your own server, in FastAPI or Express, and just as well inside a browser tab, and it can become a machine's own filesystem through the mirage CLI or a real mountpoint over FUSE and FSKit.

Authentication
Notifications
Agents & Harness
Profile 1
Policy

$ grep -rl VFS | Virtual CLI | Script

Runtime

Performance and Efficiency

Something interesting will come soon :)