Top AI Repos — open-source AI, indexed and scored
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
Top AI Repos tracks AI repositories on GitHub and answers two different questions about each one: is it moving right now, and would you bet a product on it.
A recursive coding agent inpired by RLMs
| Date | Stars |
|---|---|
| 2026-07-31 | 378 |
| 2026-08-02 | 380 |
| 2026-08-06 | 380 |
Today
— stars today
This week
— stars this week
This month
— stars this month
Momentum
0.0
growth rate 0.00%/day
# ypi
[](https://www.npmjs.com/package/ypi)
**ypi** — a recursive coding agent built on [Pi](https://github.com/earendil-works/pi).
Named after the [Y combinator](https://en.wikipedia.org/wiki/Fixed-point_combinator#Y_combinator) from lambda calculus — the fixed-point combinator that enables recursion. `ypi` is Pi that can call itself. (`rpi` already has another connotation.)
Inspired by [Recursive Language Models](https://github.com/alexzhang13/rlm) (RLM), which showed that an LLM with a code REPL and a `llm_query()` function can recursively decompose problems, analyze massive contexts, and write code — all through self-delegation.
## The Idea
Pi already has an extension system and a bash REPL. ypi's core is a Pi extension that registers one native tool — `rlm_query` — and teaches Pi to use it recursively. The `ypi` launcher and shell-compatible `rlm_query` command are convenience layers around that extension. [jj](https://martinvonz.github.io/jj/) workspace isolation is used when available, but it is not required for the minimal path.
```
┌──────────────────────────────────────────┐
│ ypi (depth 0) │
│ Tools: native rlm_query, bash │
│ Workspace: default │
│ │
│ > grep -n "bug" src/*.py │
│ > sed -n '50,80p' src/app.py \ │
│ | rlm_query "Fix this bug" │
│ │ │
│ ▼ │
│ ┌────────────────────────────┐ │
│ │ ypi (depth 1) │ │
│ │ Workspace: jj if present │ │
│ │ Edits files safely │ │
│ │ Returns: patch on stdout │ │
│ └────────────────────────────┘ │
│ │
│ > jj squash --from <child-change> │
│ # absorb the fix into our working copy │
└──────────────────────────────────────────┘
```
---
## Using ypi
### Install
```bash
# bun (global)
bun install -g ypi
# or npm (global)
npm install -g ypi
# or run without installing
bunx ypi "What does this repo do?"
# or curl
curl -fsSL https://raw.githubusercontent.com/rawwerks/ypi/master/install.sh | bash
# or manual
git clone https://github.com/rawwerks/ypi.git && cd ypi
git submodule update --init --depth 1
export PATH="$PWD:$PATH"
```
### Run
```bash
# Interactive
ypi
# One-shot
ypi "Refactor the error handling in this repo"
# Different model
ypi --provider anthropic --model claude-sonnet-4-5-20250929 "What does this codebase do?"
```
### Use As A Pi Extension
The minimal path is the `pi-recursive` package — a pure Pi extension. It gives Pi
the native recursive `rlm_query` tool without the `ypi` launcher, shell helper, or
jj requirement:
```bash
# Try for one run
pi -e npm:pi-recursive "Use rlm_query to ask a child what 2 + 2 is."
# Install globally for normal pi sessions
pi install npm:pi-recursive
pi
# Install project-locally into .pi/settings.json
pi install -l npm:pi-recursive
```
The npm package has a Pi manifest that exposes only
`./extensions/recursive.ts`. The `ypi` binary remains available for users who
want the wrapper defaults and shell-compatible helper commands.
### How It Works
**Three pieces** (same architecture as Python RLM):
| Piece | Python RLM | ypi |
|---|---|---|
| System prompt | `RLM_SYSTEM_PROMPT` | `SYSTEM_PROMPT.md` |
| Context / REPL | Python `context` variable | `$CONTEXT` file + bash |
| Sub-call function | `llm_query("prompt")` | native Pi tool `rlm_query`; optional shell command `rlm_query "prompt"` |
**Recursion:** the `extensions/recursive.ts` extension registers a native `rlm_query` tool that spawns a child Pi process with the same extension and tools. The child can call `rlm_query` too:
```
Depth 0 (root) -> full Pi with native rlm_query + bash
Depth 1 (child) -> full Pi with native rlm_query + bash
Depth 2 (leaf) -> fuExcerpt of 13,585 characters
Read on GitHubWould you bet a product on this? Bounded 0–100 and slow moving.
matched fp:68b8f76101727ad2, topic:agents