AILocalCore is the overarching "Brain" library for local AI development. It integrates personality definition, environment awareness, memory management, and internet search into a single, cohesive orchestration layer.
AILocalCore acts as a wrapper and requires the following libraries:
ailocalmemory(for SQLite-based conversation history and ChatSession)ailocalconnection(for real-time web browsing and AI Router logic)
- Persona Engine: Inject dynamic identities and rules. Tell your AI it's a "Sarcastic Genius" or a "Professional Assistant", and give it strict behaviors to follow.
- Context Awareness: The AI automatically knows the current date, time, operating system, and any custom environment variables (like user name, weather, or location).
- The Orchestrator (
AIBrain):- Dynamically crafts a hyper-personalized system prompt combining Persona + Context.
- Saves it to
AILocalMemoryso the local model retains it. - Evaluates user queries using
AILocalConnection(Router) to decide if an internet search is needed. - Injects search results transparently into the LLM context.
See example.py for a complete demonstration of how to hook up OllamaAdapter, ChatSession, Persona, ContextAwareness, and AIBrain.