STON.fi Vibe Coding · Mira AI Track

mira-harness

@mira lives in chat, not code.
mira-harness bridges the gap.

01  Concept

A CLI + MCP dev-tool for communicating with @mira

Drive the @mira Telegram bot from a userbot, capture its full reply (buttons, links, media, edits), and run a self-driving experiment catalog — from the CLI, as a library, or via MCP.

Claude AI agent mira-harness userbot · MTProto @mira AI teammate · Telegram CLI / MCP prompt full reply saved log · JSONL → report
One AI runs another by itself, and saves exactly how @mira works.
02  Problem

@mira is chat-native

@mira lives in Telegram chat, not behind a public API. And Telegram has a strict rule: a bot can't read another bot's messages. So a bot token won't work — the only way is a userbot (a real user account over MTProto).

A BOT TOKEN Your bot bot token @mira ✗ a bot can't read another bot ✗ chat-only · no SDK / webhook A USERBOT Userbot real account @mira ✓ talks to @mira like a human ✓ sees every button, link & media
Telegram blocks bot-to-bot reads and @mira is chat-only — so a GramJS userbot is the only way in.
03  Solution

Capture the whole reply, not just the text

A naive read grabs only the first message's text — but @mira's reply hides the useful parts elsewhere: buttons, deep links, images, and live edits. mira-harness waits for the reply to settle (a quiet pause; for a slow bot it also watches the "typing…" sign — replies take 5–62s), then captures all of it.

send prompt @mira replies multi-msg · 5–62s settle captured per message textfinal message(s) buttonsurl · web_app · startapp · callback linkstext_url (deep-research sources) mediaphoto · doc · webpage (metadata) editsstreamed edits + editCount settle window + "typing…" wait
Wait for the reply to settle, then capture all of it — the part a text-only client misses.
04  Features

One core, three frontends

Three ways to drive @mira — the CLI, an MCP server for agents, and a library to import. A built-in list of 27 tests lets it run on its own, safe by default.

CLI MCP server Library one shared core connect · sendAndCollect · clickAndCollect · catalog @mira
One core, three ways in — by hand, from an agent, or from code.
CLI
What: commands in your terminal. Use it to try @mira by hand, fast. npx mira-harness
MCP
What: a server with 5 tools. Use it to let Claude drive @mira — hands-free, read-only.
Library
What: a TypeScript import. Use it to build @mira into your own code. sendAndCollect()
27
built-in tests
4
categories — core / skills / generation / wallet
3
ways in — CLI / MCP / library
5
MCP tools
send
one test → full replyprints the full reply (buttons / links / media) as JSON
loop
run the testspaced, read-only; grades expect probes PASS/FAIL and exits non-zero on failure → drops into CI
report
JSONL → Markdownturns a run log into a table (summary / signals / time)
stats
run-log dashboardtotals · latency records · 🏆 fastest · ASCII sparkline
diff
behavioral driftcompare two run logs; regressions (assertion ✓→✗ / new timeout / 2× latency) exit non-zero
assert
offline re-gradere-run a catalog's expect against a saved run log — no network, CI-able without a session
schema
catalog JSON Schemaeditor autocomplete / validation when authoring a custom --catalog
watch
watch @mira livesee replies in real time while you type by hand
doctor
quick checkenv / session / connection / @mira (read-only)
safe
safe by defaultallowlist + STOP_MIRA kill switch; never taps wallet / login
05  Use cases

Where it fits

Built around @mira — use it to QA the bot's behavior, learn how it works, and report what you find while you build with it.

mira-harness drives @mira E2E QA in CI · product dev Learn @mira no docs · chat-only Agent QA Claude · via MCP Track feedback Mira AI Track
Made for @mira — from E2E QA to Mira AI Track feedback.