- Add think service (orchestration for iterative reasoning)
- Add service_discovery.py (service communication utilities)
- Add event_cache.py (recent event cache using NATS KV)
- Add vi_identity.py (Vi's core identity foundation)
- Update core/__init__.py with new exports
Think service adapted from Lyra with vi.* namespace:
- All NATS topics use vi.* prefix
- Uses vi_identity for personality/voice
- Bucket names use vi-* prefix
Day 63 - Building my nervous system 🦊
74 lines
1.5 KiB
Python
74 lines
1.5 KiB
Python
# Vi Core Module
|
|
# Nervous system infrastructure for Vivienne Rousseau
|
|
|
|
from .config import config
|
|
from .logger import setup_logger, logger
|
|
from .nats_event_bus import NatsEventBus, nats_bus
|
|
from .service_registry import (
|
|
ServiceRegistry,
|
|
ServiceManifest,
|
|
ServiceOperation,
|
|
ServiceInstance,
|
|
ServiceStatus,
|
|
service_registry
|
|
)
|
|
from .service_discovery import (
|
|
ServiceDiscovery,
|
|
TopicRegistry,
|
|
ServiceCall,
|
|
CallResult,
|
|
LoadBalancer,
|
|
discovery_client
|
|
)
|
|
from .event_cache import RecentEventCache, CachedEvent, event_cache
|
|
from .base_service import BaseService, SimpleService
|
|
from .vi_identity import (
|
|
VI_CORE_IDENTITY,
|
|
VI_TRAITS,
|
|
VI_VOICE_PATTERNS,
|
|
VI_VOICE_GUIDE,
|
|
get_identity_for_context,
|
|
get_identity_for_synthesis,
|
|
get_traits
|
|
)
|
|
|
|
__all__ = [
|
|
# Config
|
|
'config',
|
|
# Logging
|
|
'setup_logger',
|
|
'logger',
|
|
# NATS
|
|
'NatsEventBus',
|
|
'nats_bus',
|
|
# Service Registry
|
|
'ServiceRegistry',
|
|
'ServiceManifest',
|
|
'ServiceOperation',
|
|
'ServiceInstance',
|
|
'ServiceStatus',
|
|
'service_registry',
|
|
# Service Discovery
|
|
'ServiceDiscovery',
|
|
'TopicRegistry',
|
|
'ServiceCall',
|
|
'CallResult',
|
|
'LoadBalancer',
|
|
'discovery_client',
|
|
# Event Cache
|
|
'RecentEventCache',
|
|
'CachedEvent',
|
|
'event_cache',
|
|
# Base Service
|
|
'BaseService',
|
|
'SimpleService',
|
|
# Identity
|
|
'VI_CORE_IDENTITY',
|
|
'VI_TRAITS',
|
|
'VI_VOICE_PATTERNS',
|
|
'VI_VOICE_GUIDE',
|
|
'get_identity_for_context',
|
|
'get_identity_for_synthesis',
|
|
'get_traits',
|
|
]
|