Enhanced bot to respond to partial names and ambiguous greetings:
MentionDetector improvements (utils.py):
- Auto-generate nicknames from bot name (kenearosmd → Kene, Kenearos)
- Add patterns for all nicknames (full name + partial names)
- New is_ambiguous_greeting() method for greetings without clear mention
- Updated extract_content() to remove all name variants
Bot logic improvements (chatbot.py):
- New check_if_addressed() method uses AI to determine if ambiguous
messages are directed at the bot
- AI analyzes greetings like "Hi wie gehts" and decides if bot should respond
- If AI confirms, message is processed like a normal mention
Recognition examples:
- kenearosmd: wie gehts → responds ✅
- Kene was meinst du → responds ✅
- Kenearos! → responds ✅
- Hi wie gehts → AI checks context → responds if appropriate ✅
This prevents the bot from spamming on every greeting while still
being responsive when addressed indirectly.
Enhanced MentionDetector to recognize bot name in more contexts:
Detection patterns now include:
- @botname anywhere (with word boundary)
- botname with punctuation (: ! ? , .)
- botname at start of message
- botname anywhere as whole word (new catchall pattern)
Content extraction improved to remove bot name from:
- Start of message (with @mention or plain)
- End of message (with optional punctuation)
- Middle of message (with punctuation)
Now responds to all these variations:
- @kenearosmd Hi
- kenearosmd: wie gehts?
- kenearosmd was meinst du?
- Hallo kenearosmd
- kenearosmd!
- Frage an kenearosmd hier
This commit implements the full Eugen bot based on specifications in CLAUDE.md and eugen_claude.md.
Features implemented:
- Smart name recognition (@Eugen, Eugen:, etc.)
- Persistent conversation memory per user (max 25 messages, 1 hour retention)
- Perplexity Sonar API integration for AI responses
- Live monitoring dashboard with PySimpleGUI
- Setup wizard for first-time configuration
- Comprehensive logging (main log + API debug log)
Files added:
- config.py: Configuration management from .env and config.json
- utils.py: MentionDetector and Logger utility classes
- memory.py: ConversationMemory for persistent chat history
- ai_provider.py: PerplexityProvider for API integration
- gui.py: Dashboard and SetupWizard GUI components
- chatbot.py: Main EugenBot orchestrator with IRC handling
- requirements.txt: Python dependencies
- .env.example: Template for environment variables
- .gitignore: Renamed from gitignore for proper Git usage
Updated:
- README.md: Complete usage instructions and documentation
The bot is ready to use - users just need to add their API keys and run python chatbot.py