Skip to content

akurkar07/rda

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

rda

Rubber Duck Agent(rda) is an AI-powered coding companion that lives lives alongside your development environment.

It watches your coding activity, system stats, and git commits — then reacts with real moods, evolution, and sarcastic commentary.

Features

  • Track coding activity via git commits, shell commands, idle time, CPU usage, files edited etc.
  • Chat with the duck using Ollama(local LLM)
  • Pet dialogue generation with Gemini
  • Mood-based ASCII animations and messages
  • Web dashboard with ASCII duck, XP bar and chat interface
  • XP & evolution system tied to actual activity
  • Local JSON save of pet state

Todo Features

  • Web dashboard showing stats
  • TTS with espeak
  • Plugin for Neovim or VSCode that sync pet's state in a status bar
  • Plugin system for custom behaviors

Usage

Information

XP System

Your actions directly affect the duck’s growth:

Event XP Gain
Git commit +5
10 shell commands +2
Active coding minute +1
Long idle (recovery) +1
CPU spike handled +3

Evolution System

Level Form Description
1–4 Apprentice Cute newbie duck
5–9 Awakened Smarter, sassier
10+ Elder Enlightened quacker

As the duck levels up:

  • ASCII art changes
  • Dialogue becomes more confident / sarcastic
  • Agentic behavior becomes more frequent

Agentic Behavior

Every 20–30 seconds, the duck:

  • Observes current system state and activity
  • Uses Gemini to reason about what’s happening
  • Decides whether to:
    • Speak
    • Stay silent
    • Sleep
    • React emotionally

Example messages:

"Idle 25 minutes? I was starting to think you forgot about me." "CPU spiked to 90%? Trying to cook me?" "Commit? Finally! I was getting bored watching you stare at that screen."

Building

# Run this to start tracking your shell activity or add this to your rc file
export PROMPT_COMMAND='python3 -c "import sensors.shell as s; s.record_command_exec()"'
git clone https://github.com/night0721/rda
cd rda
python -m venv env
source env/bin/activate
pip install -r requirements.txt
# Set your GEMINI_API_KEY environment variable at "run" file
./run

# In another terminal, start ollama server
ollama pull phi3:mini
ollama serve

Contributions

Contributions are welcomed, feel free to open a pull request.

License

This project is licensed under the GNU Public License v3.0. See LICENSE for more information.

About

AI-powered terminal pet/companion to make programming feel alive, interactive, and fun

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Python 82.7%
  • HTML 16.8%
  • Shell 0.5%