Trend Arbitrage Across Languages

Build Diaries · 02 ·

Trend arbitrage across languages.

In English-speaking search, “Claude Code” is a daily topic. In Persian search, it’s invisible. That gap — between when a trend peaks in one market and reaches another — is content arbitrage. Here’s the system I built to detect it, across seven data sources, served to Claude as a remote MCP.

APIs unified
7
MCP tools exposed
24
Farsi articles for “Claude Code”
0

01 · The idea

Wait for the trend — or catch it before it arrives.

Most content sites in non-English markets wait. Something trends in the US, eventually it ranks locally, and by then ten other sites have already covered it. The other path: detect the signal in the English-speaking source market, write the local-language article while competition is zero, sit on it until the trend crosses the border.

Tap either path. Arbitrage works only because lead time is real and measurable. The whole project comes down to detecting the gap before it closes.

02 · The signal problem

Why one source of trend data is never enough.

Google Trends is the obvious starting point — and the wrong one. It’s a lagging indicator. By the time a topic shows up in Trends, the developer-first audience has been talking about it for weeks. Each source below catches a different part of the wave.

Lagging indicator. Great for news cycles. Weak for tech.

Daily Search Trends RSS exists and is free, no auth. Returns trending topics per country with approximate traffic and associated news articles. The catch: most of what trends are people and events, not concepts. The Iran feed on a normal day is celebrities and politics — useful for news-arbitrage, useless for “what tool will the developer audience be talking about in two months.”

Latency
~24 hours
Topic type
News, people, events
Best for
Hot-news arbitrage

04 · The first hit

“Claude Code” — by the numbers.

First sanity check after the MCP was running: ask it about the topic that started the whole project. Real numbers from gap_signal_check("Claude Code") against live APIs. Pick the Wikipedia state to see what verdict the heuristic returns.

Pick a scenario to see what the gap heuristic produces — and what we actually got for “Claude Code”.

05 · From script to MCP

From a local script to a remote MCP server.

A Python script that calls seven APIs is just a script. To make it useful from claude.ai — without installing anything on your machine — you have to expose it as a remote MCP. That means switching from stdio transport to Streamable HTTP, adding CORS, hiding the endpoint behind nginx with a secret path. Toggle to see the shape of the change.

LOCAL · stdio only

  • mcp.run() — speaks stdio, only callable from local Claude Desktop / Code
  • No transport over HTTP, no URL to share
  • Can’t connect from claude.ai web — there’s no endpoint to point at
  • Tokens live in .env file on your laptop
The whole transition is one wrapper file, one systemd unit, and one nginx location block. Two hours from “works on my laptop” to “live on saveyourclicks.com, callable from any Claude session.”

06 · The playbook

Build the same thing for your market. Seven steps.

If you do this for one language pair, it works for any. The signals are language-neutral; only the target Wikipedia project codes change. Checks are saved locally — tick what you’ve done.

0 / 7 complete

07 · Honest questions

About trend arbitrage and remote MCPs.

Five questions worth answering in writing. Each is in the FAQ schema for rich results.

What is trend arbitrage across languages?

Trend arbitrage exploits the lag between when a topic peaks in one search market (e.g., English) and reaches another (e.g., Persian or Arabic). You build content in the slower-arriving language while local competition is zero. When the trend arrives, your article is already indexed and ranked.

Why isn’t Google Trends enough to detect emerging trends?

Google Trends is a lagging indicator for evergreen tech topics. It reflects volume after broad audience awareness. For tool and concept names like Claude Code, Hacker News fires 2-8 weeks earlier, GitHub Search shows star velocity in real time, and Wikipedia pageviews catch the curiosity wave before it shows up in search volume.

Why use a custom MCP server instead of calling these APIs directly?

Wrapping seven APIs in one MCP server gives Claude a unified research surface. All filters exposed, sane defaults, one auth boundary. You can ask Claude to compare Wikipedia pageviews for a topic across English, Persian, and Arabic in one sentence instead of orchestrating seven HTTP calls by hand.

How do you make an MCP server reachable from claude.ai?

Run it over Streamable HTTP transport instead of stdio, expose it behind nginx with a secret URL path, and point claude.ai’s Custom MCP setting at the public URL. The secret path acts as a bearer token. Reverse-proxy buffering must be off, and CORS headers added at the wrapper level. Total config: ~20 lines of nginx and one systemd unit.

Does this work for any source-target language pair?

Yes. The underlying signals (HN, GitHub, Wikipedia, PyPI, npm, Product Hunt) are language-neutral. The gap detector compares Wikipedia pageviews across any project codes you pass: en.wikipedia, fr.wikipedia, tr.wikipedia, es.wikipedia. It generalizes to English-to-French, English-to-Turkish, or any pair where one market leads.

Build Diaries · A series on shipping AI-built work to production — the bugs, the fixes, and the lessons that didn’t make the docs.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top