Skip to content

Technical indicators to run technical analysis with JavaScript & TypeScript. πŸ“ˆ

Notifications You must be signed in to change notification settings

bennycode/trading-signals

Repository files navigation

Trading Signals Monorepo

This monorepo contains multiple packages for building automated trading bots, including the famous trading-signals library and its documentation website. These packages provide TypeScript implementations of technical indicators, trading strategies, and data transformation utilities for algorithmic trading.

The trading-signals library is tested in production and trusted by hundreds of projects worldwide.

πŸ“¦ Packages

This project uses Lerna for managing the monorepo with independent versioning. Execute npm test to run tests across all packages. Launch an interactive demo with npm run docs.

Package Description
@typedtrader/exchange Unified exchange interface providing interoperability across different brokers (e.g., Alpaca). Offers type-safe data transformation utilities and a streamlined API for integrating multiple exchanges and brokers into your trading applications.
@typedtrader/messaging End-to-end encrypted messaging interface for controlling personal trading bots remotely via XMTP protocol. Enables secure command execution and real-time trading bot interaction.
trading-signals Technical indicators (SMA, EMA, RSI, MACD, ...) for algorithmic trading with streaming updates, replace mode, lazy evaluation, and memory efficiency. Can be added to your own trading apps or strategies.
trading-signals-docs Documentation and showcase website built with Next.js, featuring interactive demos and examples of all indicators. See every indicator in action before you code.
trading-strategies Trading strategy implementations that combine technical indicators into actionable advices. Can be used to build your own strategies for backtesting and real-time trading.

Relationships

At the foundation, trading-signals provides technical indicators like SMA, EMA, RSI, and Bollinger Bands. The trading-strategies package builds on top of these indicators to form actionable trading advice. @typedtrader/exchange abstracts away broker differences behind a unified interface, so strategies can run against any supported exchange. Finally, @typedtrader/messaging ties it all together into a chatbot that lets you control your trading bot remotely through encrypted messages.

graph TD
    messaging["@typedtrader/messaging (Chatbot)"]

    messaging --> strategies["trading-strategies"]
    messaging --> exchange["@typedtrader/exchange"]

    strategies --> signals["trading-signals"]

    signals --> SMA
    signals --> EMA
    signals --> RSI
    signals --> BBANDS["Bollinger Bands"]
    signals --> MACD
    signals --> more["..."]

    exchange --> Alpaca
    exchange --> IB["Interactive Brokers"]
    exchange --> more-exchanges["..."]
Loading

Deploy to Render

Deploy the @typedtrader/messaging package as a background worker to Render. The configuration includes persistent disk storage for the XMTP database and secure environment variable management:

Deploy to Render