Overview
NodeSpace is transitioning from a Hub-and-Spoke architecture to a Universal Graph Architecture with Pure JSON Properties. This epic tracks all work required for this transition.
Strategic Goals
This architecture supports NodeSpace's core differentiators:
- AI-Native Context: Agents traverse arbitrary relationships via MCP without schema friction
- Playbook Marketplace: Users install new methodologies (Schema-as-Node) without database migrations
- Local-First Performance: Zero-latency local reads with SurrealDB Cloud handling sync and RLS
- Simplified Sync: Single-record atomic operations eliminate "ghost node" problems
Architecture Documents
- Target State:
docs/architecture/architecture-target-state.md
- Archived:
docs/architecture/archived/architecture-overview-2025-hub-spoke.md
- Archived:
docs/architecture/archived/surrealdb-schema-design-hub-spoke.md
Key Changes
| Component |
Before |
After |
| Node Storage |
Hub table + Spoke tables (task, schema) |
Single node table with properties JSON |
| Type-Specific Data |
Record Links to spoke tables |
properties field with partial indexes |
| Schema Storage |
schema spoke table |
Nodes with node_type = 'schema' |
| Query Pattern |
N+1 (fetch node, then fetch spoke) |
Single query |
| Sync Complexity |
2 tables atomic |
1 record atomic |
| New Types |
Requires CREATE TABLE |
Zero DDL |
Work Streams
Stream A: Foundation (Prerequisites) ✅
Stream B: Data Model Transition (READY TO START)
Eliminate spoke tables and move to Pure JSON:
Stream C: Security Layer
Implement ABAC + RLS for cloud sync:
Stream D: Sync Infrastructure
Prepare for SurrealDB Cloud sync:
Stream E: Governance & Lifecycle
Policy-driven content governance:
Stream F: Backup & Recovery
Implement 3-2-1 backup strategy:
Stream G: Advanced Features (Future)
Deferred until core transition complete:
Dependencies
Stream A (Foundation) ✅ DONE
↓
Stream B (Data Model) ← START HERE
↓
Stream C (Security) ←→ Stream D (Sync)
↓ ↓
Stream E (Governance) ←──────┘
↓
Stream F (Backup)
↓
Stream G (Advanced)
Success Criteria
Estimated Effort
| Stream |
Effort |
Priority |
Status |
| A: Foundation |
1-2 days |
P0 |
✅ Done |
| B: Data Model |
3-5 days |
P0 |
Ready |
| C: Security |
3-5 days |
P1 |
Blocked by B |
| D: Sync |
2-3 weeks |
P1 |
Blocked by B |
| E: Governance |
1 week |
P1 |
Can parallel with D |
| F: Backup |
2-3 days |
P1 |
Blocked by B |
| G: Advanced |
4+ weeks |
P3 |
Future |
Notes
- Pre-release system with zero users - breaking changes are acceptable
- No migration strategy needed - can reset database
- SurrealDB Cloud PoC should be done in separate repository to isolate from NodeSpace-specific issues
Overview
NodeSpace is transitioning from a Hub-and-Spoke architecture to a Universal Graph Architecture with Pure JSON Properties. This epic tracks all work required for this transition.
Strategic Goals
This architecture supports NodeSpace's core differentiators:
Architecture Documents
docs/architecture/architecture-target-state.mddocs/architecture/archived/architecture-overview-2025-hub-spoke.mddocs/architecture/archived/surrealdb-schema-design-hub-spoke.mdKey Changes
nodetable withpropertiesJSONpropertiesfield with partial indexesschemaspoke tablenode_type = 'schema'Work Streams
Stream A: Foundation (Prerequisites) ✅
Stream B: Data Model Transition (READY TO START)
Eliminate spoke tables and move to Pure JSON:
datafield (Record Link to spoke)node.propertiestask,schemaspokes)SchemaTableManagerto index management onlyStream C: Security Layer
Implement ABAC + RLS for cloud sync:
type_grantson user recordsStream D: Sync Infrastructure
Prepare for SurrealDB Cloud sync:
docs/architecture/experiments/surrealdb-cloud-poc-plan.mdStream E: Governance & Lifecycle
Policy-driven content governance:
Stream F: Backup & Recovery
Implement 3-2-1 backup strategy:
export_to_jsonTauri commandimport_from_jsonTauri commandbackup_rocksdbcommandStream G: Advanced Features (Future)
Deferred until core transition complete:
Dependencies
Success Criteria
Estimated Effort
Notes