mirage
The World's First Virtual Terminal for AI Agents
strukto-ai
@strukto-ai
⬇ 1
★ 3,600
TypeScript
安装
dsh plugin add github:strukto-ai/mirage
需要可复现安装时,可在仓库后追加 #commit 固定提交。
The World's First Virtual Terminal for AI Agents
该插件未提供要点说明,请参考仓库 README。
agent-sandboxagent-toolsai-agentsbashclaude-code
- 安装并启动 DeepSeek Harness:
npx @deepseek-ai/dsh web - 在终端执行上面的安装命令(CLI 会解析插件并核验来源)
- 用 dsh plugins list 确认已安装,必要时重启 Harness 生效
插件以当前 dsh 进程的权限运行,安装时可能执行代码。请先通读仓库源码与许可证,确认无破坏性命令与越权访问;本站只做索引,不对第三方插件安全性作担保。
| 代码仓库 | github.com/strukto-ai/mirage |
| 许可证 | Apache-2.0 |
| 主要语言 | TypeScript |
| 下载量 | 1 |
| GitHub 星标 | 3,600 |
| 最近推送 | 2026-09-16 |
| 收录日期 | 2026-09-19 |
| 分类 | 开发与运行时 |
事实信息来自公开插件目录快照(2026-10-03),介绍文案由本站再加工。
以下为插件仓库 README 全文(原始内容,由公开目录抓取整理)。
[图片: Mirage: A Virtual Terminal for AI Agents]
[图片: Status: preview]
[图片: Python docs]
[图片: TypeScript docs]
[图片: README in English]
[图片: 简体中文 README]
[图片: 繁體中文 README]
[图片: README en Français]
[图片: README auf Deutsch]
[图片: README Tiếng Việt]
[图片: README 한국어]
Mirage is a Virtual Terminal for AI Agents. The virtual filesystem delivers broad data context, virtualized CLIs give an agent more flexibility on tool use, dynamic runtimes save underlying infrastructure cost and are more token efficient, and fine-grained control over an agent's actions and even over what it can see gives the best security. Together these parts form one virtualized terminal, giving the best agent performance, cost efficiency and security.
[图片: Mirage architecture: agents and harness reach profiles and the Mirage shell, which resolve Unix-like commands, virtual CLIs and programming languages onto runtimes and the virtual filesystem, with authentication, the policy engine and notifications alongside]
Here is an example of launching Mirage inside an application:
ws = Workspace(
{
"/tmp": (RAMResource(), MountMode.EXEC),
"/redis": (RedisResource(url=redis_url), MountMode.WRITE),
"/slack": (SlackResource(SlackConfig(token=slack_bot_token)), MountMode.EXEC),
},
# monty captures python, so scripts run sandboxed inside the workspace
runtimes=[MontyRuntime(captures=["python", "python3"]), "vfs"],
)
# one grep sweeps every source
await ws.execute("grep -rln session /redis /tmp")
# run a script that lives in Slack, file the report into Redis
await ws.execute("python3 /slack/channels/general_.../files/example__F....py > /redis/report.txt")
# install a typed CLI under a head word: dispatched by name, not by path,
# and discoverable through `man`, `type` and `which` like any other program
ws.register_cli("slack", SLACK, {"token": slack_bot_token})
await ws.execute('slack send-message --channel general --text "report is up"')
About
Unified virtual terminal interface, not N SDKs and M MCPs. Every backend speaks the same filesystem semantics, so pipelines compose across services.
A virtual filesystem over every source. S3, Google Drive, Slack, Gmail, Redis and the rest mount side by side under one root, so an agent reaches all of them through a unified interface with the unix tools it already knows, like ls, grep, find and jq.
Virtual command line tools (CLIs). git, slack and ntn are answered by Mirage itself, so an agent drives the 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.
Routed, dynamic runtimes. Python, JavaScript and any other command can be sent to a configured runtime, in process, sandboxed or remote, which decouples computation from storage and lets either change without touching the other.
The virtualized Mirage shell. It binds the filesystem, the CLIs and the runtimes into one command line, so pipes, redirection, variables, jobs and history work across all three.
Profiles designed for agents. allow, ask and deny govern commands and CLIs, while hide and show govern files and folders, so a hidden path is not merely unreadable but absent from the filesystem the agent sees.
A scriptable policy engine. A policy script can prohibit any dangerous action before it runs, and the same stack gates every VFS op and session write, so neither a file nor an environment variable leaks.
Notifications wired into the VFS and agents. External changes become an event stream on the mount, so a new Slack reply surfaces as a change to the chat file in the virtual filesystem, and the agent reacts to it instead of rescanning the tree.
Virtual Filesystem
Everything Mirage "mounts" as one unified virtual filesystem for AI agents. Each
service sits side-by-side under a single root and answers the same POSIX semantics.
Resources
Object Storage
[图片: Amazon S3]
[图片: Cloudflare R2]
[图片: Google Cloud Storage]
[图片: Oracle OCI]
[图片: Supabase Storage]
[图片: MinIO]
[图片: Ceph]
[图片: SeaweedFS]
[图片: Wasabi]
[图片: Backblaze B2]
[图片: DigitalOcean Spaces]
[图片: Alibaba Cloud OSS]
[图片: Tencent Cloud COS]
[图片: Scaleway]
[图片: QingStor]
[图片: Hugging Face Buckets]
[图片: GridFS]
Files and Documents
[图片: Google Drive]
[图片: Google Docs]
[图片: Google Sheets]
[图片: Google Slides]
[图片: OneDrive]
[图片: SharePoint]
[图片: Box]
[图片: Dropbox]
[图片: Nextcloud]
Messaging and Work
[图片: Slack]
[图片: Discord]
[图片: Gmail]
[图片: IMAP / SMTP email]
[图片: GitHub]
[图片: Linear]
[图片: Notion]
[图片: Trello]
[图片: Google Calendar]
Databases and Data Platforms
[图片: PostgreSQL]
[图片: MongoDB]
[图片: Redis]
[图片: Upstash Redis]
[图片: LanceDB]
[图片: Qdrant]
[图片: Chroma]
[图片: Mem0]
[图片: Hugging Face Datasets]
[图片: Hugging Face Models]
[图片: Hugging Face Spaces]
[图片: Databricks Volumes]
[图片: Dify]
Observability
[图片: Langfuse]
[图片: Jaeger]
Local and Remote
[图片: RAM]
[图片: Disk]
[图片: OPFS]
[图片: SSH]
Agents reach it through the Python and TypeScript SDKs, the mirage CLI, or a real
mountpoint over FUSE and FSKit, then work it with the unix tools they already know,
like ls, grep, find and jq.
Virtual Command Line Tool
These command line tools are virtualized: Mirage answers git, slack or ntn
itself, so an agent drives the service without that program being installed on the
machine. Each one mimics the real tool, so an agent that knows the CLI needs nothing
new. Because they are virtual, the same tool can be installed more than once under
different names, each with its own credentials, so every agent gets exactly the
accounts it is given.
CLIs
Code
[图片: git]
[图片: gh]
Communication
[图片: slack]
[图片: discord]
[图片: himalaya]
Work and Data
[图片: linear]
[图片: ntn]
[图片: gws]
[图片: hf]
Virtual Runtime
Runtimes are virtualized the same way, and not only for coding languages. 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 can be decided by a
scripted runtime router.
Runtimes
Python
[图片: Monty]
[图片: WASI CPython on wasmtime]
[图片: Pyodide]
[图片: sandlock]
[图片: Host CPython]
JavaScript
[图片: QuickJS, serving node and js]
[图片: JavaScript]
[图片: TypeScript]
Sandboxes
[图片: Docker]
[图片: E2B]
[图片: Daytona]
[图片: smolVM]
[图片: SSH]
Security
A profile decides what a session may run and what it may see. Commands are governed
by customizable allow, ask and deny rules, and paths by hide and show, so a
hidden file is not merely unreadable but absent from the filesystem the agent sees.
For anything those rules cannot express, a profile can name a policy script that runs
at the gate on every command and answers allow, deny or ask itself, though like every
rule it can only restrict and never grant. Separately, a host can register its own
policies on the policy engine, an
ordered stack the workspace consults on every command, VFS op and session write. See
the permissions docs.
Authentication
Credentials and authentication integrate with the stores secrets already live in,
including AWS Secrets Manager, 1Password, Auth0 and dotenv, so an environment variable
in Mirage can resolve straight to a credential held in one of them.
Sources
Built in
[图片: Environment]
[图片: dotenv]
[图片: AWS Secrets Manager]
Custom
[图片: 1Password]
[图片: Auth0]
Installation
Python ≥ 3.11 for the mirage-ai package and the mirage CLI
Node.js ≥ 20 for the TypeScript SDK
Python
uv add mirage-ai # installs the `mirage` library and the `mirage` CLI binary
TypeScript
npm install @struktoai/mirage-node # Node.js servers and CLIs
npm install @struktoai/mirage-browser # browser / edge runtimes
npm install @struktoai/mirage-agents # OpenAI / Vercel AI / LangChain / Mastra adapters
Both runtime packages pull in @struktoai/mirage-core automatically.
CLI
curl -fsSL https://strukto.ai/mirage/install.sh | sh
# or
npm install -g @struktoai/mirage-cli
# or
uvx mirage-ai
# or
npx @struktoai/mirage-cli
Quickstart
Python
from mirage import Workspace
from mirage.resource.ram import RAMResource
from mirage.resource.s3 import S3Config, S3Resource
ws = Workspace({
"/data": RAMResource(),
"/s3": S3Resource(S3Config(bucket="my-bucket")),
})
await ws.execute("cp /s3/report.csv /data/report.csv")
await ws.execute("grep alert /s3/data/log.jsonl | wc -l")
await ws.snapshot("demo.tar")
TypeScript
import { Workspace, RAMResource, S3Resource } from '@struktoai/mirage-node'
const ws = new Workspace({
'/data': new RAMResource(),
'/s3': new S3Resource({ bucket: 'my-bucket' }),
})
await ws.execute('cp /s3/report.csv /data/report.csv')
await ws.execute('grep alert /s3/data/log.jsonl | wc -l')
await ws.snapshot('demo.tar')
CLI
mirage workspace create ws.yaml --id demo
mirage execute --workspace_id demo --command "cp /s3/report.csv /data/report.csv"
mirage provision --workspace_id demo --command "cat /s3/data/large.jsonl"
mirage workspace snapshot demo demo.tar
mirage workspace load demo.tar --id demo-restored
Contributors
Thanks to everyone who has contributed to Mirage.
[图片: Mirage contributors]
数据来源:公开的 DeepSeek Harness 插件目录与各插件 GitHub 仓库。本站为独立第三方目录,与 DeepSeek、幻方(High-Flyer)及插件作者均无隶属或背书关系。