Complete implementation of the Living AI features: Phase 1 - Foundation: - MoodService: Valence-arousal mood model with time decay - RelationshipService: Stranger→Close Friend progression - Enhanced system prompt with personality modifiers Phase 2 - Autonomous Learning: - FactExtractionService: AI-powered fact extraction from conversations - Rate-limited extraction (configurable, default 30%) - Deduplication and importance scoring Phase 3 - Personalization: - CommunicationStyleService: Learn user preferences - OpinionService: Bot opinion formation on topics - SelfAwarenessService: Bot statistics and self-reflection Phase 4 - Proactive Features: - ProactiveService: Scheduled events (birthdays, follow-ups) - Event detection from conversations - Recurring event support Phase 5 - Social Features: - AssociationService: Cross-user memory connections - Shared interest discovery - Connection suggestions New database tables: - bot_states, bot_opinions, user_relationships - user_communication_styles, scheduled_events - fact_associations, mood_history Configuration: - Living AI feature toggles - Individual command enable/disable - All features work naturally through conversation when commands disabled
34 lines
643 B
Python
34 lines
643 B
Python
"""Database models."""
|
|
|
|
from .base import Base
|
|
from .conversation import Conversation, Message
|
|
from .guild import Guild, GuildMember
|
|
from .living_ai import (
|
|
BotOpinion,
|
|
BotState,
|
|
FactAssociation,
|
|
MoodHistory,
|
|
ScheduledEvent,
|
|
UserCommunicationStyle,
|
|
UserRelationship,
|
|
)
|
|
from .user import User, UserFact, UserPreference
|
|
|
|
__all__ = [
|
|
"Base",
|
|
"BotOpinion",
|
|
"BotState",
|
|
"Conversation",
|
|
"FactAssociation",
|
|
"Guild",
|
|
"GuildMember",
|
|
"Message",
|
|
"MoodHistory",
|
|
"ScheduledEvent",
|
|
"User",
|
|
"UserCommunicationStyle",
|
|
"UserFact",
|
|
"UserPreference",
|
|
"UserRelationship",
|
|
]
|