Skip to content

Installation

DependencyVersion
Node.js>= 18
RxJS>= 7.8.0
TypeScript>= 5.0 (recommended)
Terminal window
npm install rxjs-ai rxjs

rxjs is a peer dependency — you must install it alongside rxjs-ai.

Import pathWhat you get
rxjs-aiCore primitives, AI controllers, and UI utilities — createStore, createCommandBus, createAsyncController, createChatController, createViewModel
import {
createStore,
createCommandBus,
createAsyncController,
createChatController,
createViewModel,
} from 'rxjs-ai';

All types are exported directly from the main entry point. No separate @types package is needed.

import type {
Store,
StateUpdater,
StatePatch,
CommandBus,
CommandMap,
CommandEnvelope,
AsyncController,
AsyncState,
AsyncStatus,
ChatController,
ChatModelAdapter,
ChatModelRequest,
ChatMessage,
ChatState,
ChatStatus,
ChatRole,
ChatChunk,
} from 'rxjs-ai';