kameleondb
Store and query structured data without planning schemas upfront. Use when you need to remember information, track entities across conversations, build knowledge bases, ingest API data, store user preferences, create CRM systems, or maintain any persistent state. Automatically evolves data structure as you discover new fields. No migrations, no schema design - just store data and query it.
KameleonDB Skill
Agent-native database for dynamic schema evolution
This OpenClaw skill provides agents full control over data lifecycle: schema design, ingestion, evolution, and querying - all without migrations or DDL.
Features
- Dynamic Schema Evolution - Add fields at runtime, zero lock operations
- Agent Hints Pattern - Queries return optimization suggestions inline
- Hybrid Storage - Flexible JSONB or dedicated typed tables
- Full Audit Trail - Every schema change tracked with reasoning
- JSON I/O - All operations support
--jsonfor machine-readable output
Installation
pip install kameleondb[postgresql]
Configuration
Set KAMELEONDB_URL in OpenClaw config or environment:
{
"env": {
"KAMELEONDB_URL": "postgresql://localhost/kameleondb"
}
}
For development, use SQLite:
{
"env": {
"KAMELEONDB_URL": "sqlite:///./kameleondb.db"
}
}
Quick Start
# Initialize
kameleondb admin init
# Create entity
kameleondb --json schema create Contact \
--field "name:string:required" \
--field "email:string:unique"
# Insert data
kameleondb --json data insert Contact '{"name":"Alice","email":"alice@example.com"}'
# Query
kameleondb --json data list Contact
See SKILL.md for complete documentation.
Use Cases
- Data Ingestion Agents - Discover schema needs, create entities, batch insert
- Enrichment Agents - Add fields as new data sources discovered
- Query Agents - Generate SQL with schema context, optimize based on hints
- Data Modeling Agents - Design relationships, materialize for performance
Why KameleonDB?
Traditional databases force agents to work within rigid schemas designed by humans. KameleonDB makes agents the data engineers - they design schemas, evolve them as they reason, and optimize storage based on usage patterns.
Schema-on-Reason: Schema emerges from continuous agent reasoning, not upfront human design.