About this project
Arbitrage Insights is a small foreign-exchange arbitrage toolkit. It compares the fair forward rate of a currency pair, derived from spot and the two interest rates, against the market forward rate, finds the gap, and shows what remains after trading costs and tax.
The project ships three pages. The Live Monitor pulls live spot rates every minute, computes the fair forward for each watched pair, compares it with a user-supplied forward quote, subtracts costs, and alerts via banner, sound and browser notification when the gap is worth acting on. The Arbitrage Calculator checks a single trade step by step. The Investment Calculator takes capital, pair and country and returns gross, after-cost and after-tax profit, with a country comparison.
Shared files include engine.js for the maths, theme.css, monitor.js and monitor_config.json. Live spot comes from a public feed (api.fxratesapi.com, with open.er-api.com as fallback). Interest rates and forward points come from monitor_config.json; because no free feed provides forward quotes, the user enters their broker's forward points there. Until that is done the site runs in sample mode and does not send notifications. An alert fires when the after-cost gap exceeds alert_threshold_bp and inputs pass sanity checks.
For alerts when no page is open, monitor_check.py runs on GitHub Actions every 15 minutes, uses the same config and engine, writes signals.json for the page to read, and sends a Telegram message when an opportunity appears and quotes_are_real is true. Setup requires creating a Telegram bot via BotFather, storing TELEGRAM_BOT_TOKEN and TELEGRAM_CHAT_ID as repository secrets, and setting real forward_points, quotes_as_of and quotes_are_real in the config.
fx_arbitrage.py is the reference Python implementation, with engine.js as a cross-checked port. Running it prints four worked examples, and monitor_check.py runs one monitor pass locally. The README notes that interest rates and tax rates are illustrative or placeholder and should be verified before use, and that the project is not investment advice.
Comments
0 Rating appears after 10 ratings
Sign in to join the discussion.