Technical

Author: Sunny Zhang, Victoria Li

Technology Stack

Component Technology Purpose
Web Framework Shiny for Python Reactive web application with real-time updates
Data Provider LSEG Refinitiv Data API Market data connectivity and options chains
Data Processing Pandas, NumPy Data manipulation and numerical computations
Visualization Plotly Interactive charts and 3D surfaces
Scientific Computing SciPy Interpolation and numerical methods

High-Level Data Flow

  1. User configures underlying, strike bounds, expiry bounds, and analysis thresholds.
  2. LSEG API retrieves spot and options chain (universe discovery + pricing fields).
  3. Data is normalized and mid-prices are computed where appropriate.
  4. Calls and puts are paired by strike and expiry for parity calculations.
  5. Implied rates are derived and compared to benchmark rate inputs.
  6. Signals are generated and shown in tables and plots (including 3D surfaces).

Example Snippet

spot_df = rd.get_data("MSFT.O", ["TR.PriceClose"])

options_chain = rd.discovery.search(
    view=rd.discovery.Views.EQUITY_QUOTES,
    filter="SearchAllCategoryv2 eq 'Options' and "
           "StrikePrice ge 400 and StrikePrice le 480 and "
           "ExchangeName xeq 'OPRA'"
)

Project Structure

Tongues/
├── app.py
├── index.html
├── overview.html
├── strategy.html
├── run.html
├── technical.html
├── CNAME
├── screenshots/
│   ├── market-data-fetching.png
│   ├── option-data.png
│   ├── arbitrage-navigator.png
│   ├── arbitrage-opportunities.png
│   ├── arbitrage-analysis.png
│   ├── selected-strategy.png
│   ├── selected-strategy-continued.png
│   └── surface-3d.png
└── src/
    └── deviltongues/
        ├── fetch_options.py
        └── utilities.py