Barfinex

How Barfinex Works

First Steps

Barfinex is an AI-Native Trading Operating System — five integrated services that cover the full trading lifecycle. This page is your orientation before you install anything.

Barfinex is not a trading bot or a strategy toolkit. It is an operating system for the entire trading process — from raw market data to executed orders, with AI decision-making and risk governance built in at every stage.

The Five Services

Each service has a single, well-defined responsibility:

ComponentResponsibility
ProviderMarket data gateway. Ingests, normalizes, and serves all exchange data. Single source of truth for the entire stack.
DetectorStrategy runtime. Evaluates typed rule configurations against live data and emits scored signals.
AdvisorAI decision engine. Runs an 8-stage pipeline on every signal: market quality check, ML conviction scoring, regime-aware calibration, LLM synthesis, spread and R/R validation.
InspectorRisk governor. Validates every execution intent against configured policies. Manages protective orders for all runtime positions.
StudioOperations terminal. Real-time visualization of signals, AI decisions, risk state, and capital efficiency.

How They Connect

Exchange
    │
    ▼
Provider ──────────────────────────────────────────▶ Studio
    │                                               (real-time via WebSocket)
    ├──▶ Detector ──▶ Advisor ──▶ Inspector ──▶ Exchange
    │    (signals)  (AI decision) (risk gate)  (orders)
    │
    └──▶ Event bus (Redis pub/sub)
         All services subscribe and publish typed events.

Provider is the single entry point for Studio: one URL, one auth token, one WebSocket. All other services are reachable through Provider's proxy.


How Data Flows

  1. Provider receives raw ticks from the exchange and publishes normalized candles, trades, and order book updates to the event bus.
  2. Detector subscribes to market data, evaluates rules on every new candle, and publishes a scored signal when threshold is crossed.
  3. Advisor receives the signal, runs its 8-stage AI pipeline, and publishes a decision with an execution intent.
  4. Inspector receives the execution intent, validates it against risk policies, and if approved, places orders through Provider's order API.
  5. Studio observes everything in real time through Provider's WebSocket.

Before You Install

  • All services communicate through a shared Redis event bus. Redis is a hard dependency.
  • Provider must be running before any other service can register or receive data.
  • Strategies are TypeScript configurations. Familiarity with TypeScript and Docker is expected.
  • Exchange API keys stay in your environment. Nothing is sent externally.

How to Start

  1. Architecture — Understand how the services connect and why, before touching any configuration.
  2. Install Provider — The foundation. Everything else depends on it.
  3. Install Detector — Define your first strategy as a rule configuration.
  4. Configure Studio — Connect to your running stack and observe the full pipeline.

Let’s Get in Touch

Have questions or want to explore Barfinex? Send us a message.