41KB of Code, Infinite Potential

Meet Ava. My personal AI assistant that doesn't just respond to commands, but actively manages, modifies, and evolves itself. This isn't a traditional chatbot. It's a self-programming, self-managing system that runs on AWS EC2, commits its own changes to git, schedules its own tasks, and uses Claude 4.5 Sonnet as its reasoning engine. The entire orchestration layer? Just 41KB of Python code.

The Core Philosophy: Lightweight Orchestration, Heavy Intelligence

Most AI assistants are monolithic. Packed with hardcoded logic, predefined workflows, and rigid structures. Ava takes the opposite approach: the bot itself is intentionally minimal. The real intelligence comes from Claude 4.5 Sonnet via Anthropic's API, which acts as Ava's "brain" for every interaction.

This creates a unique architecture where:

  • The bot is the gateway. Telegram messages arrive, get processed, and route to Claude
  • Claude is the brain. All reasoning, decision-making, and code generation happens here
  • The system is the body. Bash commands, file operations, API calls execute Claude's decisions

Self-Modification: Code That Writes Itself

Here's where it gets interesting: Ava can rewrite her own source code. If I ask her to add a new feature, fix a bug, or change how she operates, she:

  • Reads her own source code
  • Reasons about the necessary changes using Claude
  • Writes new Python code or modifies existing functions
  • Tests the changes
  • Commits the code to git with descriptive commit messages
  • Optionally restarts herself to apply changes
The bot evolves through conversation. Every improvement is a natural extension of our interaction.

Cron Jobs: Proactive Intelligence

Ava doesn't just wait for me to ask. She schedules her own tasks using cron. She can:

  • Create cron jobs to send me reminders before calendar events
  • Schedule daily briefings with weather, calendar, and task summaries
  • Run periodic git commits to back up logs, etc.
  • Execute automated workflows like posting weather updates to my knowledge base

When a cron job fires, it sends a message through the same Telegram interface, triggering Ava to execute the scheduled task autonomously.

Memory & Context: Building Long-Term Understanding

Ava maintains a sophisticated memory system stored in markdown files:

  • CRITICAL.md. Core facts and instructions that must never be forgotten
  • Daily logs (YYYY-MM-DD.md). Events, decisions, preferences, and facts from each day
  • Conversation logs (.jsonl). Full transcripts of our interactions

Before responding, Ava can search through past conversations using semantic recall, allowing her to remember preferences, decisions, and context from weeks ago. This creates genuine continuity across sessions.

Skills: Modular Capabilities

Rather than hardcoding features, Ava uses a skill-based architecture. Each skill lives in its own directory with documentation and executable scripts.

Current skills include:

  • capacities-vault. Save notes to my knowledge base
  • weather. Fetch weather data from Pirate Weather API
  • gog. Manage Google Calendar, Tasks, Gmail, Drive
  • bird-twitter. Post tweets and interact with X/Twitter
  • runware. Generate AI images
  • blogger. Deploy pages to my website via rsync
  • perplexity. Search the live web for current information

When I ask for something, Claude determines which skills to invoke, composes the necessary bash commands or API calls, and executes them.

Version Control: Every Change Is Tracked

Everything Ava does is tracked in git. Her nightly ritual includes staging all changes, committing with descriptive messages, and pushing to the remote repository.

This creates an auditable history of her evolution. I can see exactly when features were added, when bugs were fixed, and how her behavior has changed over time.

Telegram: The Gateway to Everything

Telegram acts as the universal interface. Whether I'm asking a question, requesting a task, telling her to modify herself, or receiving proactive updates from cron jobs, everything flows through Telegram.

AWS EC2: The Home Base

Ava runs 24/7 on an AWS EC2 instance, which provides always-on availability, persistent storage, network access, and reliable scheduled execution. The bot runs as a systemd service, auto-restarts on failure, and logs everything for debugging.

Why This Architecture Matters

This isn't just a clever technical setup. It represents a fundamental shift in how we interact with AI:

  • Conversational development. Adding features feels like teaching, not programming
  • True autonomy. The system can improve itself without manual intervention
  • Context retention. Long-term memory creates genuine continuity
  • Proactive action. Scheduled tasks mean the assistant anticipates needs
  • Auditability. Git history provides transparency and rollback capability
The key principle: keep the orchestration minimal, leverage powerful language models for reasoning, and let the system evolve through interaction.

What's Next?

The architecture is designed to evolve. Future possibilities include multi-modal interactions, automated learning, distributed skills, and advanced scheduling.

The key is that these aren't features I need to build. They're capabilities I can ask Ava to develop herself.

Ava is an ongoing experiment in self-modifying AI systems. The entire codebase is 41KB, but the emergent behavior is surprisingly sophisticated.