Skip to content

Introduction

Navi is an open source Navi execution engine written in Rust. It provides a complete pipeline for parsing, type-checking, compiling, and running indicators and strategy scripts bar-by-bar, embeddable in your own applications and services.

What is Navi?

Navi is a domain-specific language for writing technical analysis indicators and trading strategies. It is designed to be simple yet powerful, operating on a bar-by-bar execution model where scripts process one candlestick at a time.

What is Navi?

Navi takes the Navi language and makes it available as an independent, embeddable engine. You can:

  • Run Navi scripts on your own candlestick data and collect outputs (plots, alerts, strategy orders)
  • Embed the engine in Rust, C, or C++ applications
  • Use the LSP for editor support with diagnostics, completions, hover, go-to-definition, and more
  • Extend with custom native functions and library loaders

Architecture

The processing pipeline is:

Navi processing pipelineNavi processing pipeline

Each stage is a separate crate:

CrateRole
navi-parsernom-based parser producing span-annotated ASTs
navi-visitorSemantic analysis, type checking, name resolution
navi-compilerAST to VM instructions with 3 optimization passes
navi-vmBar-by-bar runtime engine
navi-loaderModule resolution (imports, prelude, stdlib)
navi-builtinsEmbedded prelude and stdlib Navi sources
navi-lspLanguage Server Protocol implementation

Current Status

  • Language version: Navi
  • Goal: Run Navi scripts, produce plots/alerts/strategy events, support common standard library functions
  • Status: Under active development; some features are incomplete or may behave differently from other Navi runtimes

Next Steps

Released under the MIT License.