Skip to content

balasiddarthan22/Signal

Repository files navigation

Signal is an open source living intelligence map for any market. Type any industry or company name and Signal runs parallel web agents to discover what's happening, what's changed, and where the story no longer adds up — then remembers what it learns, so the next run builds on the last one instead of starting from zero. Built on TinyFish for live web data and Supermemory for persistent, evolving memory. Like BigSet but for market intelligence.

How it works

  1. Discovery: an LLM decides whether your input is a market or a single company. If it's a market, TinyFish Search finds the 8-12 most relevant companies and the model enriches them with URLs and positioning clusters.
  2. Parallel signal collection: for every company, five subagents (PricingAgent, DocsAgent, HiringAgent, BlogAgent, PositioningAgent) run simultaneously via Promise.all, using TinyFish Fetch/Search to pull pricing pages, docs, job listings, blogs, and homepages.
  3. Claim extraction: the model reads each fetched page and extracts a structured claim about what it signals.
  4. Contradiction drafting (propose): the model drafts candidate contradictions two ways - comparing what a company claims about itself against its own pricing/hiring/docs signals, and comparing fresh evidence against that company's Supermemory profile (its consolidated understanding from prior runs).
  5. Verification (the reliability gate): a second pass, with a distinct skeptical-reviewer prompt and fresh context, reviews every draft - rejecting weak or generic findings, merging duplicates, and reassigning its own confidence score. Only entries that get an explicit approval and clear a confidence floor get published; everything else lands in a visible "needs review" queue instead of being silently discarded.
  6. Memory: approved findings update Supermemory. Every belief is written to a per-company container (so Supermemory's native /v4/profile endpoint can compute a real settled-vs-shifting profile for that company) and to a shared container (enabling semantic search for similar patterns across other companies and markets). High-confidence beliefs are marked isStatic, which is what lets a fact graduate from "still shifting" to "settled" once it's reconfirmed across runs.

The whole run is orchestrated as a single Convex action that streams progress into reactive tables (logEvents, companies, claims, contradictions). That's what powers the live fetch log and real-time results panel, with no custom websocket/SSE plumbing required.

Why this isn't just a chatbot wrapper

Asking an LLM "is this company contradicting itself" once gives you one memoryless answer. Signal is built around three things a one-shot chat session structurally can't do:

  • It runs unattended on a schedule. Track a market and get emailed when something changes, without having to remember to ask again.
  • It remembers, and that's verifiable. A company's Supermemory profile compounds across runs - we've watched one go from 0 settled facts on its first run to 4 settled facts by the third, purely from repeated reconfirmation.
  • It checks its own work before publishing. The propose-then-verify pipeline means a "contradiction" isn't just one model's first guess - it's a draft that survived a second, skeptical review.

Stack

  • Next.js 14 (App Router) + TypeScript + Tailwind CSS
  • Convex for the backend: persistence, the orchestration action, scheduled cron re-runs, and real-time streaming to the client
  • Clerk for auth - private per-user market libraries and watches over otherwise-shared market data
  • TinyFish Search + Fetch for live web data
  • Supermemory - native per-company profiles (/v4/profile, settled vs. shifting facts) and cross-market semantic pattern search
  • An LLM via OpenRouter for discovery, claim extraction, and contradiction drafting/verification
  • Resend for email alerts on tracked markets

Getting started

  1. Install dependencies:

    npm install
  2. Create .env.local with:

    TINYFISH_API_KEY=...                          # tinyfish.ai
    SUPERMEMORY_API_KEY=...                        # supermemory.ai
    OPENROUTER_API_KEY=...                         # openrouter.ai
    NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=...          # clerk.com
    CLERK_SECRET_KEY=...                           # clerk.com

    Convex will add CONVEX_DEPLOYMENT, NEXT_PUBLIC_CONVEX_URL, and NEXT_PUBLIC_CONVEX_SITE_URL automatically the first time you run it. Set CLERK_JWT_ISSUER_DOMAIN and RESEND_API_KEY as Convex environment variables (npx convex env set) rather than in .env.local, since they're read server-side.

  3. In one terminal, start the Convex dev deployment:

    npx convex dev
  4. In another terminal, start the Next.js dev server:

    npm run dev
  5. Open http://localhost:3000 and search for a market ("web agent infrastructure") or a company ("Stripe").

Project structure

  • convex/schema.ts: tables for runs, companies, log events, claims, beliefs, contradictions, watches, and dismissed markets
  • convex/orchestrate.ts: the core agent orchestration (discovery, parallel signal collection, contradiction drafting, verification, Supermemory sync)
  • convex/lib/: thin clients for OpenRouter, TinyFish, and Supermemory
  • convex/profile.ts, convex/watches.ts, convex/email.ts: per-company memory profile, scheduled tracking, and email alerts
  • src/app/page.tsx: home page (search, personal market library, live contradiction ticker)
  • src/app/run/[runId]/page.tsx: live run page (fetch log terminal, live results)
  • src/app/market/[runId]/page.tsx: market intelligence dashboard - memory graph, contradiction feed (with a needs-review section), attention map, company detail, CSV export

Deploying

Deploy to Vercel as you would any Next.js app, and point npx convex deploy at a production Convex deployment. Set the same API keys as environment variables in your Vercel project settings, and the Convex-only env vars (CLERK_JWT_ISSUER_DOMAIN, RESEND_API_KEY) via npx convex env set --prod.

About

Market intelligence agent that finds contradictions between what companies claim and what they actually do — powered by TinyFish web agents and a persistent memory graph that compounds across runs via Supermemory.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors