explaingit

waht41/rejelly

Analysis updated 2026-05-18

1TypeScriptAudience · developerComplexity · 3/5LicenseSetup · moderate

TLDR

A TypeScript framework for building AI agents as functions, inspired by React, with reusable prompt building blocks called Hooks.

Mindmap

mindmap
  root((Rejelly))
    What it does
      Agents as functions
      Prompts built with hooks
      Zod validated output
    Tech stack
      TypeScript
      Node.js
      Zod
    Use cases
      Structured agent output
      Multi round agents
      Runtime debugging
    Audience
      Developers
      LLM app builders

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Build an AI agent as a plain function using createAgent and reusable prompt hooks.

USE CASE 2

Force a model's output into a validated structure using a Zod schema, with automatic retries on mismatch.

USE CASE 3

Debug and replay an agent's runtime behavior using the included DevTool.

USE CASE 4

Add rate limiting to model calls using the included limit-model package.

What is it built with?

TypeScriptNode.jsZodpnpm

How does it compare?

waht41/rejelly0xkinno/neuralvault0xmayurrr/ai-contractauditor
Stars111
LanguageTypeScriptTypeScriptTypeScript
Setup difficultymoderatehardeasy
Complexity3/54/52/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · moderate Time to first run · 30min

Requires Node.js 18+, pnpm, and the Rust toolchain for one internal linting package.

Use freely for any purpose, including commercial use, as long as you keep the copyright notice, under the Apache 2.0 license.

In plain English

Rejelly is a JavaScript and TypeScript framework for building AI agents, built by borrowing ideas from the popular web framework React. In React, a user interface is built out of small reusable functions called components, and Rejelly applies the same idea to AI agents: an agent is just a function that takes some input and returns a result, and the instructions you send to the AI model are assembled from smaller reusable pieces the framework calls hooks, instead of manually gluing together long strings of text. A key part of the framework is that it can force the AI model's response into a specific structure using a validation tool called Zod, and if the model's answer does not match that structure, Rejelly automatically asks the model to try again with feedback about what went wrong. Another feature, called reborn, rebuilds the agent's prompt fresh each round from its current memory rather than just piling up the entire conversation history, so the agent always works from an up to date picture of the situation. Getting started involves creating a new project with a scaffolding command that asks a few setup questions, or installing the core package plus a model adapter package by hand, for models like OpenAI's or Google's Gemini. The project also includes a local debugging tool called DevTool, which lets a developer record, store, and step through an agent's runtime activity, including replaying a past run to see exactly what happened. The repository is organized as a monorepo, meaning it contains several related packages together, including the core framework, various model and tool adapters, a rate limiting helper for controlling how many requests hit a model, and an example command line coding agent called evil-jelly built using the framework itself, meant to show the framework being used in a real application. Development requires Node.js version 18 or higher, the pnpm package manager, and the Rust programming language's toolchain for one internal linting tool. It is released under the Apache 2.0 license.

Copy-paste prompts

Prompt 1
Help me scaffold a new project with npm create rejelly.
Prompt 2
Explain how the equip hooks and promptAgent function work together in Rejelly.
Prompt 3
Show me how to add a tool and multi-round conversation to a Rejelly agent.
Prompt 4
Walk me through setting up DevTool to debug my Rejelly agent's runtime traces.

Frequently asked questions

What is rejelly?

A TypeScript framework for building AI agents as functions, inspired by React, with reusable prompt building blocks called Hooks.

What language is rejelly written in?

Mainly TypeScript. The stack also includes TypeScript, Node.js, Zod.

What license does rejelly use?

Use freely for any purpose, including commercial use, as long as you keep the copyright notice, under the Apache 2.0 license.

How hard is rejelly to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is rejelly for?

Mainly developer.

Open on GitHub → Explain another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.