@threaded/ai
Composable LLM workflows for Node.js.
Core Principles
- Function composition over configuration
- Explicit conversation history management
- Built-in tool execution with approval flows
- Multi-provider support: OpenAI, Anthropic, Google, xAI, Ollama, HuggingFace
- Text embeddings and image generation
Workflows are functions that transform conversation context. Compose them together to build complex agentic behaviors from simple primitives.
How It Works
- Create a thread to manage conversation history
- Define tools the model can call
- Compose workflow steps (model calls, scopes, conditions)
- Execute and stream results
Next: Quick Start