
HazelJS

Ship production AI agents, RAG pipelines, and workflows in one TypeScript backend. Stateful, open-source, with 47 packages under Apache 2.0.
Editor's Verdict
Key Takeaways
- HCEL (Hazel Composable Expression Language)
- Stateful Agent Runtime
- Agentic RAG
- Durable Workflows
In-Depth Review: What is HazelJS?
HazelJS is an open-source, AI-native TypeScript backend that unifies agents, RAG, workflows, and enterprise primitives into a single cohesive runtime. It eliminates the glue code of stitching LangChain, Express, and observability together, offering stateful execution, built-in tool orchestration, human-in-the-loop checkpoints, and production-grade monitoring. With packages like @hazeljs/ai (HCEL for fluent prompt chaining), @hazeljs/agent (stateful agent runtime), @hazeljs/rag (agentic retrieval), and @hazeljs/flow (durable workflows), developers can build and deploy complex AI backends in minutes. Used in production by Zynli and others, HazelJS is Apache 2.0 licensed and ready for scale.
Core Features
HCEL (Hazel Composable Expression Language)
Fluent DSL for chaining prompts, RAG, agents, and other AI primitives in a single, type-safe pipeline.
Stateful Agent Runtime
Production-grade runtime with Redis-backed state, human-in-the-loop checkpoints, tool orchestration, and multi-agent handoffs.
Agentic RAG
Built-in retrieval-augmented generation with 11 loaders and 5 vector stores, seamlessly integrated into agent workflows.
Durable Workflows
Long-running agent pipelines with checkpointing, retries, and webhook support for hours- or days-long processes.
Enterprise Stack Integration
Dependency injection, security, observability, and OpenTelemetry spans with per-request LLM cost tracking out of the box.
Guardrails & Eval
Packages for safety guardrails and evaluation (eval) to ensure reliable AI behavior in production.
Easy Setup
Install two packages (@hazeljs/core, @hazeljs/ai) into existing apps or use the CLI template for a full AI-native backend in minutes.
Multi-Tenant Ready
Built for multi-tenant SaaS applications, as demonstrated by the Zynli support platform built entirely on HazelJS.
Open Source (Apache 2.0)
47 packages available under Apache 2.0 license, allowing full customizability and community contributions.
Pricing
Open Source (Apache 2.0)
- All 47 HazelJS packages
- HCEL orchestration
- Stateful Agent Runtime
- Agentic RAG
- Durable Workflows
- Guardrails & Eval
- Enterprise stack (DI, security, observability)
- Community support via Discord
Pros and Cons
Pros
- Native AI IntegrationUnlike NestJS where AI is an add-on, HazelJS provides native Agent Runtime, HCEL, and RAG packages at the core, reducing boilerplate.
- Reduced Glue CodeInstead of manually wiring LangChain, vector DBs, and observability, HazelJS does it in a single chain (5 lines vs 50 lines).
- Cohesive RuntimeEvery AI primitive shares dependency injection, security, and observability, eliminating integration issues.
- Stateful AgentsRedis-backed state survives restarts and scale-out, with built-in human-in-the-loop and multi-agent handoffs.
- Open Source & CommunityApache 2.0 license with growing community on Discord and active development.
Cons
- Young EcosystemHazelJS is relatively new compared to established frameworks like NestJS or LangChain, so fewer third-party integrations and community resources.
- Limited Documentation ExamplesWhile blog posts exist, the library may have fewer real-world examples beyond the Zynli showcase.
- No Cloud Deployment YetThe cloud platform is coming soon; currently users must self-host or wait for HazelJS.Cloud.
Use Cases & Recommended Professions
Backend Developer→ View Toolkit
Builds AI-native APIs and services; benefits from HazelJS's integrated agent, RAG, and workflow packages to ship faster.
AI/ML Engineer→ View Toolkit
Designs and deploys intelligent pipelines; uses HCEL and Agent Runtime to orchestrate complex AI workflows with minimal glue code.
Full-Stack Developer→ View Toolkit
Creates full applications with AI features; HazelJS provides frontend-ready backend with real-time capabilities and multi-tenancy support.
Product Manager (AI Products)→ View Toolkit
Manages AI-powered features; appreciates the rapid prototyping and built-in observability for monitoring agent behavior.
Startup CTO→ View Toolkit
Leads tech decisions for early-stage companies; HazelJS reduces time-to-market for AI products with pre-built primitives.
DevOps Engineer→ View Toolkit
Deploys and maintains production AI systems; benefits from OpenTelemetry integration and Redis-backed state for scalable operations.
Frequently Asked Questions
Alternative AI Tools
View Detailed Comparison →ℹ️ Curation Disclosure: The overview and features of HazelJS were synthesized using AI and fact-checked by our curation team to ensure accuracy.











