View memory

Memory

## DocuClear Vision — Workspace as Structured Data Environment (July 2026) ### The Core Idea A workspace is NOT just "chat with documents." It's a structured data environment where the LLM defines schemas and tracks information using SurrealDB's full capabilities. ### Use Cases (Examples) **Auditor verifying expenses:** - Loads: expense policy docs, expense spreadsheet, receipts - Needs: cross-reference policy rules against line items against receipts - Schema: policies, expenses, receipts, rules, compliance_checks - Graph edges: expense VIOLATES policy, receipt SUPPORTS expense **LinkedIn article writer:** - Loads: multiple source articles, research notes - Needs: link concepts and terms, trace back to sources - Schema: sources, concepts, claims, evidence, drafts - Graph edges: concept CITES source, claim SUPPORTS concept, draft REFERENCES evidence **Holiday trip planner:** - Loads: flight emails, hotel confirmations, activities - Needs: timeline, travel duration, conflicts, budget - Schema: bookings, locations, travel_segments, activities, budget_items - Graph edges: activity AT location, travel CONNECTS locations, booking HAS cost **Wedding planner:** - Loads: vendor contracts, guest list, venue info - Needs: calendar, bookings, budget, RSVPs - Schema: events, vendors, guests, bookings, budget_categories - Graph edges: event AT venue, vendor PROVIDES service, guest ATTENDS event ### What Makes This Different from ChatGPT Projects / Perplexity Spaces 1. **Structured data** — not just documents, but nodes/edges/tables the LLM can query 2. **LLM-defined schemas** — the agent creates tables and relationships as needed 3. **Living computation** — spreadsheets are queryable, not static files 4. **Graph relationships** — connections between concepts, not just vector similarity 5. **External access** — DEFINE API endpoints let iPhone shortcuts query the data 6. **Knowledge persistence** — facts survive across threads, superseded when updated ### The SurrealDB Advantage - Schema can be defined dynamically via SurrealQL - Tables, fields, indexes, relations all creatable at runtime - Graph traversal queries find connections - Vector search finds semantic similarity - DEFINE API makes data accessible to external tools - ACID transactions ensure consistency - Tri-temporal history tracks changes ### Architecture - Each workspace = SurrealDB namespace (or database) - LLM defines schema via tool calls (DEFINE TABLE, DEFINE FIELD, etc.) - Documents stored as records with computed paths - Entities extracted from documents, linked via graph edges - Spreadsheets stored as table records, queryable via SurrealQL - External tools access via DEFINE API endpoints ### Status: Vision captured, ready to design schema

[Update 7/18/2026]: ## Key Design Decisions Confirmed (July 2026)

1. **Namespace per workspace** — efficient, good isolation
2. **Raw SurrealQL for schema definition** — LLM writes DEFINE TABLE/FIELD queries directly, validated by LSP
3. **R2 for files, SurrealDB for metadata** — Xberg/Crawlberg process docs, store extracted content in SurrealDB
4. **Schema evolution** — SurrealDB handles gracefully, new fields optional, LLM backfills if needed
5. **Procedural graphs** — the LLM defines workflows as graph structures (nodes=steps, edges=flow) that the system can execute

### Procedural Graphs = Orchestration Layer
The LLM creates workflow schemas:
- Workflow: id, name, status, workspace
- WorkflowStep: id, workflow, name, type, config, status, result
- WorkflowTransition: id, from_step, to_step, condition

Examples:
- Expense verification: submit → policy_check → receipt_match → approve/reject
- Article writing: research → outline → draft → review → publish
- Wedding planning: book_venue → send_invites → track_rsvps → finalize_seating

The system executes the graph, the LLM makes decisions at each step.

Tags: vision, workspace, structured-data, schema-design, project:docuclear_clearspace, kind:semantic — Source: claude — 2026-07-18 21:56:47 UTC

Connected memories

What would you like to do next?