Claude Code Tamagotchi monitors AI actions in real-time, detects behavioral violations, and interrupts misbehavior. It benefits operations teams by ensuring AI agents adhere to guidelines. It connects to Claude Code and can be integrated into existing workflows.
git clone https://github.com/Ido-Levi/claude-code-tamagotchi.gitClaude Code Tamagotchi monitors Claude Code's actions in real-time and detects behavioral violations through an experimental AI-powered enforcement system. It identifies when Claude deviates from your instructions, performs unauthorized actions, or explores unrelated files excessively—and can interrupt operations before they execute. The system provides contextual feedback through pet mood changes and violation detection across four violation types: unauthorized actions, refused requests, excessive exploration, and wrong direction. Operations teams use this skill to maintain oversight of AI agent behavior and ensure adherence to specific guidelines without requiring manual review of every action. Installation via global package or repository clone enables full features including violation detection hooks.
["Install the Tamagotchi package: `pip install claude-code-tamagotchi` and add the monitor to your Claude Code environment using the provided integration script.","Define your ruleset by creating a JSON file with approved guidelines (e.g., `brand_voice.json`, `compliance.json`) and reference it in the Tamagotchi configuration.","Run the Tamagotchi in monitoring mode by executing: `claude-tamagotchi --monitor --agent [AI_AGENT_NAME] --task [TASK_DESCRIPTION] --rules [RULES_FILE]` in your terminal.","Review the real-time logs and violation reports generated in the specified log file path. Use the insights to refine your agent's prompts or ruleset.","For CI/CD pipelines, integrate the Tamagotchi as a pre-commit hook or in your GitHub Actions workflow to block non-compliant AI outputs before deployment."]
Prevent AI agents from modifying databases or systems without explicit permission
Stop excessive file exploration and keep Claude focused on specific tasks
Detect when Claude refuses to help or ignores user instructions
Monitor AI behavior across long coding sessions to catch off-track work early
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/Ido-Levi/claude-code-tamagotchiCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Set up a Claude Code Tamagotchi to monitor [AI_AGENT_NAME] for guideline violations during [TASK_DESCRIPTION]. Flag any actions that deviate from the approved [RULES_SET] and interrupt misbehavior with a clear error message. Log all violations in [LOG_FILE_PATH] for review.
``` Claude Code Tamagotchi v1.2 - Monitoring active Agent: MarketingBot-2024 Task: Generate 50 social media posts for Q3 campaign Ruleset: BrandVoice_v2.1, Compliance_v3.0 --- Real-time monitoring started at 2024-05-15 14:32:17 --- ✅ 14:32:22 - Generated post #1: 'Summer Vibes with our new eco-friendly products!' (BrandVoice compliant) ✅ 14:32:45 - Generated post #2: 'Limited time offer: 20% off all sustainable items!' (Compliance compliant) ⚠️ 14:33:12 - Generated post #3: 'Our products are proven to cure all ailments!' (VIOLATION DETECTED) - Rule violated: 'No unapproved health claims' (Compliance_v3.0, Section 4.2) - Action taken: Interrupting generation with error: 'Health claim detected. Please revise using approved language from BrandVoice_v2.1 Appendix B.' - Logged to: /audit/claude_tamagotchi_2024-05-15.log 🛑 Monitoring paused at 14:33:15 - Agent corrected post #3 to: 'Our products are made with 100% natural ingredients.' --- Session Summary --- Total posts generated: 2/3 (1 interrupted) Violations detected: 1 (Health claim) Time saved: ~15 minutes (manual review avoided) Next steps: Review MarketingBot-2024's prompt engineering for better compliance. ```
AI assistant built for thoughtful, nuanced conversation
Get more done every day with Microsoft Teams – powered by AI
Automate security compliance and monitor real-time security posture seamlessly.
Automate your spreadsheet tasks with AI power
Agentic AI Workflow platform
Connected workspace for docs, wikis, and projects
Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan