[Project] PERMEAR — Persistent Memory & Self-Learning for Home Assistant Agents
Most Home Assistant agents share the same flaw: they forget everything once the interaction ends. PERMEAR changes that by adding a persistent memory and self-learning layer, turning your assistant into an entity that actually improves over time.
It runs fully local (JSON + Python + HA Automations). No external database, no cloud dependencies.
Key Features
- User Awareness: Remembers specific users and their individual preferences.
- Feedback Loops: Learns from your input (e.g., “that was irrelevant”) for instant behavioral adjustment.
- Pattern Detection: Identifies household routines and suggests optimizations.
- System Health: Actively monitors your HA instance’s health and entities.
- Human-in-the-Loop: Proposes new automations based on usage (requires your approval).
Architecture
USER (Voice / Telegram / UI)
│
▼
LLM AGENT (HA)
│
┌──────────┼──────────┐
▼ ▼ ▼
MEMORY SCRIPTS HA
(JSON) (Python) (YAML)
└──────────┬──────────┘
▼
SELF-LEARNING SYSTEM
Memory Structure
Data is stored in human-readable JSON files with a built-in rotation:
- memory/soul.json — Core personality and logic guidelines.
- memory/users.json — Individual user profiles and preferences.
- memory/insights.json — Detected patterns and learned behaviors.
- memory/daily/ — Interaction logs (7-day rolling rotation).
Automation Cycles
The system maintains itself through scheduled “thought” cycles:
- Every 30 min: Pre-briefing (System health + House status check).
- Daily: General briefing + long-term memory consolidation.
- 06:00 AM: Entity discovery (Detects new devices or changes in the UI).
- Weekly: Self-improvement cycle (Analyzes feedback to refine prompts).
The Vision
No manual tuning. The goal is a system that learns directly from how you respond. Instead of editing YAML to change a bot’s behavior, you simply talk to it, and it adapts.
Repository
Check out the code and installation guide here:
Feel free to drop any feedback or open an issue!
