Public documentation

Mira architecture

Mira’s public product surface is a Next.js app on Vercel at www.joinmira.ai. Authentication and PostgreSQL are provided by InsForge. The intelligence API runs on Render (Node/Express) and orchestrates competitor discovery, scrape/research waterfall, feature matrices, market models (TAM/SAM/SOM), and distribution views.

Research providers include You.com (contents / research / finance) and structured extraction via OpenRouter-compatible models. Optional integrations include Zendesk messaging, Resend email, and web push. Machine indexes: /llms.txt, /AGENTS.md, /sitemap.xml, and /.well-known/mcp/server-card.json.

Founded 2025-01-15 by Sam Karri. Support: support@joinmira.ai. This preamble is server-rendered so crawlers receive readable text even if interactive diagrams below require JavaScript.

About · Team · Contact · FAQ · support@joinmira.ai

Architecture

How Mira is built

Blueprint of the product stack, website, Render API, InsForge data, and You.com skills that power live competitive intelligence.

View blueprint

Blueprint architect

System blueprint

Four lanes from the browser to intelligence providers. Skills on the right map 1:1 to chips you see in the product UI.

Mira · v1 blueprint

Edge → control plane → data → intelligence

Lane 01

Edge

Users & delivery

  • joinmira.ai

    Next.js 15 · Vercel

  • Auth UI

    Login · OAuth · sessions

  • Workspace

    Analysis · Labs · Market

Lane 02

Control plane

Render Express API

  • REST + jobs

    Background market / deep dive

  • Agents

    discover · fetch · digests

  • Cron

    24h refresh · weekly mail

Lane 03

Data plane

InsForge

  • Postgres

    Products · competitors · snapshots

  • Auth

    Email · Google · GitHub

  • Settings

    Workspace JSON · keys

Lane 04

Intelligence

You.com skills + Grok

  • you-web

    Search · Evidence · fact-check

  • you-research

    Reviews · talk tracks · overview

  • you-finance

    TAM · investor · market model

  • you-contents

    Pricing pages · site text

  • xAI Grok

    Structure JSON for the UI

Scroll lanes · left to right on desktop

Request blueprints

How a user action becomes a You.com skill call and lands back in the UI with source chips.

Analysis report

  1. 1UI /app
  2. 2API layers
  3. 3you-contents + you-research
  4. 4Grok tabs
  5. 5Persist analysis-latest

Market model

  1. 1UI /market
  2. 2Job on Render
  3. 3you-finance
  4. 4Optional Tavily check
  5. 5TAM → SAM → SOM

Evidence locker

  1. 1UI Labs
  2. 2you-web search
  3. 3Grok candidates
  4. 4Save to workspace

Deep dive

  1. 1UI /company
  2. 2Parallel sections
  3. 3you-research + you-finance
  4. 4Dossier + sources

Hosting split

Vercel

Next.js frontend · joinmira.ai · OAuth routes

Render

cia-api Express · long jobs · cron · secrets

InsForge

Auth + Postgres + storage · always remote

System design

The website talks to a persistent Express API. That API owns long jobs and secrets; InsForge holds data and identity; You.com and Grok supply live research and structure.

joinmira.ai

Browser

Next.js App Router UI: marketing, auth, and the signed-in workspace.

Render · Express

API

Persistent Node process for discovery, market jobs, cron refresh, and digests.

InsForge

Data & auth

PostgreSQL, email/password + OAuth, workspace settings, and storage.

You.com · xAI Grok

Intelligence

Live research and page contents from You.com; structured analysis via Grok.

Request path

1

Website

Next.js on Vercel, Discover, Market, Company, Distribution

2

API base

NEXT_PUBLIC_API_BASE → Render Express (Bearer + workspace)

3

Orchestration

Agents & routes: discover → refresh → market intel → digests

4

Providers

You.com research/contents/finance · xAI Grok · optional Tavily

5

Persistence

InsForge Postgres stores products, competitors, snapshots, jobs

Tech stack

What each layer runs, and why it sits where it does.

Frontend

  • Next.js 15 · App Router, SSR routes, OAuth callbacks
  • React 18 · Client components for workspace UIs
  • Tailwind CSS 3.4 · Design system tokens (ink + accent)
  • Framer Motion / Recharts · Landing motion and in-app charts

API

  • Express · REST orchestration and long-running jobs
  • node-cron · 24h competitor refresh + weekly digests
  • @insforge/sdk · Server-side Postgres CRUD

AI & research

  • You.com API · research, contents, finance_research
  • xAI Grok · Structured extraction and analysis (OpenAI SDK)
  • Tavily (optional) · Independent fact-check for market models

Platform

  • InsForge · Auth, database, storage
  • Render · Persistent API (and optional Next host)
  • Vercel · Preferred frontend host for joinmira.ai
  • Resend / Zendesk · Transactional email and in-app support

How we use You.com

You.com is the live research backbone. The website never calls You.com directly - the Render API owns the key, rate-limits requests, and maps results into Mira features.

Client module

server/services/youcom.js

Serializes outbound calls with spacing (YOUCOM_MIN_INTERVAL_MS), retries on 429/5xx, and exposes three operations used across agents and routes.

search

POST /v1/search

Cheap web search for Evidence research and fact-check before finance.

research

POST /v1/research

Competitor discovery, reviews, war-room talk tracks, company overview.

contents

POST /v1/contents

Fetch pricing pages and site text for snapshots and ICP/pricing layers.

finance_research

POST /v1/finance_research

Market sizing, investor enrich, market model, deep-dive financials.

Wired into the product

Each flow starts in the Next.js UI and lands in a You.com call on the API.

Discover competitors

  1. 1.UI calls /api/discover
  2. 2.API fetches product page via contents
  3. 3.research finds rival set
  4. 4.Grok structures candidates for approval

Refresh snapshots

  1. 1.Cron or manual refresh
  2. 2.fetchAgent pulls pages via contents
  3. 3.Diff detects pricing / messaging changes
  4. 4.Workspace surfaces alerts

Market model

  1. 1.Market intelligence job starts
  2. 2.finance_research sizes the market
  3. 3.Grok builds TAM→SOM narrative
  4. 4.Optional Tavily fact-check (You.com fallback)

Company deep dive

  1. 1.Company routes request overview
  2. 2.research + finance_research enrich
  3. 3.Reviews and financials land in UI
  4. 4.Distribution uses share / traffic signals
Call sites include discoveryAgent, fetchAgent, routes/intelligence, routes/company, and syndicatedShare. Grok always sits after research when the UI needs structured JSON.

Render, Vercel & why the split

Market jobs and cron need a process that stays alive. That is why the API lives on Render even when the website is on Vercel.

Render

API required
  • cia-api, Express server with health check at /api/health
  • Holds You.com, xAI, Resend, and cron secrets
  • Needed for 2–3 minute market jobs and scheduled refresh
  • Optional cia-web can host Next.js from the same blueprint

Vercel

Frontend
  • Hosts the Next.js client (root directory: client)
  • Serves joinmira.ai / www.joinmira.ai
  • Runs OAuth route handlers and feature-request APIs
  • NEXT_PUBLIC_API_BASE points at the Render API URL

InsForge

Data plane
  • Always remote, Postgres + Auth + Storage
  • Used by both the Express API and Next auth proxies
  • Workspace isolation and session cookies (cia_auth)

Deploy config

render.yaml defines cia-api (repo root, npm start) and optional cia-web (client build + next start). Production frontend typically uses Vercel with NEXT_PUBLIC_API_BASE set to the live Render API URL (for example *.onrender.com). See the system blueprint for the full lane diagram.

Other integrations

Supporting services around research, messaging, and delivery.

ServiceRole
InsForgeAuth, PostgreSQL, storage
You.comLive web research and page contents
xAI GrokStructured AI analysis
ResendDigests, invites, support mail
TavilyMarket-model fact-check
ZendeskIn-app messaging widget
Web PushBrowser notifications (VAPID)

See it in the product

Discover competitors, build a market model, and watch You.com-backed research land in your workspace.