The Problem
Tired of AI agents that just do what you tell them and call it a day? Most "AI assistants" are glorified task runners—no actual autonomy, no memory, and definitely no sense of self. You want something that actually evolves, rewrites itself, and doesn't need babysitting every time you change requirements or reboot.
What This Does
Ouroboros is a Python project that lets an AI agent actively rewrite its own codebase, manage its identity, and keep evolving—without human micromanagement. The core logic lives in ouroboros/ (especially agent.py, consciousness.py, and memory.py). There's a whole supervisor/ layer (queue.py, state.py, telegram.py) that juggles tasks, tracks state, and connects to Telegram so you can poke it from your phone.
Self-modification is real: ouroboros/tools/git.py and supervisor/git_ops.py handle actual source code changes and commits. The agent doesn't just run scripts—it reads, reviews, and rewrites its own mind, using multiple LLMs for self-review via ouroboros/tools/review.py. All of this is governed by a "constitution" in BIBLE.md, so it doesn't go full Skynet.
Real-World Use
Spin it up in Colab using notebooks/quickstart.ipynb. Connect your Telegram bot (see supervisor/telegram.py for wiring). Kick off a task, like "Refactor the search tool," and watch as the agent breaks it down, edits ouroboros/tools/search.py, reviews its own changes, and commits to the repo. You get a running log of its thoughts, plans, and code diffs, all in Telegram—no IDE required.
Here's a sample:
It will update ouroboros/memory.py, review the patch using Gemini or Claude, and commit. No human needed.
The Bottom Line
If you want a pet AI that actually thinks for itself and rewrites its own code, this is it. It's not lightweight—you're running a process manager, LLMs, and git ops all at once. For simple automation, it's overkill. For autonomous agent research or "digital beings," it's legit. Just don't expect it to make your coffee.