Skip to the content.

Space Agent Analysis & Feature Proposals for OpenClaw WebOS

Source analyzed: github.com/agent0ai/space-agent v0.36+ Date: 2026-04-28 Purpose: Identify what Space Agent does exceptionally well, extract actionable improvements, and propose fully documented features for the OpenClaw Desktop / WebOS project.


What Space Agent Does Really Well

1. Hierarchical Documentation System (53 AGENTS.md files)

Space Agent uses a layered AGENTS.md hierarchy where every directory that owns code also owns a documentation contract. This is not an afterthought — it’s a “documentation is top priority” runtime principle.

Why it works:

What we can learn: Our documentation is already strong, but it’s flat — all in docs/. We lack the hierarchical ownership model where code directories own their own documentation contracts.

2. Browser-First Architecture

Space Agent treats the browser as the primary runtime. The Node.js server is intentionally thin — just infrastructure for CORS proxying, auth, and file operations.

Why it works:

What we can learn: Our WebOS already does this well — views run in the browser, servers are API-only. But we could push more intelligence to the frontend (client-side filtering, sorting, optimistic updates).

3. Layered Customware Model (L0/L1/L2)

Space Agent uses a three-layer writable inheritance model:

The server resolves module requests through this layer stack, so users can override anything without touching core code.

Why it works:

4. Agent-in-the-Frontend Runtime

The onscreen agent runs inside the browser and can:

Why it works:

5. Git-Backed Time Travel

Every change to user/group customware is tracked in Git. Users can:

Why it works:

6. Spaces as Composable Workspaces

Users create named “Spaces” — each with its own widget grid, agent instructions, data, and assets. Spaces are:

7. Skill System (24 SKILL.md files)

Skills are metadata-driven markdown files that:

8. Deterministic Module Discovery

Modules are discovered by convention, not configuration:

9. Multi-User with Per-User Isolation

Full authentication system with:

10. Production-Grade Operations


Proposed Features for OpenClaw WebOS

Based on the analysis above, here are actionable features ranked by impact and feasibility.


Feature 1: Time Travel (Git-Backed Undo History)

Priority: High Effort: Medium Inspiration: Space Agent’s time_travel module

Description: Add a Time Travel view that lets operators browse the full history of changes to the dashboard state (tasks, workflows, projects, configurations) and revert or travel to any point.

Full Specification:

User Stories

API Endpoints

GET  /api/history/commits?path=<scope>&limit=100&offset=0&fileFilter=<pattern>
  → { commits: [{ hash, author, message, timestamp, files[], backend }], total, hasMore }

GET  /api/history/diff?path=<scope>&hash=<commitHash>&file=<filepath>
  → { diff: "<unified diff>", file, added, modified, deleted }

POST /api/history/preview?path=<scope>&hash=<commitHash>
  → { affectedFiles: [{ path, action }], warning?: string }

POST /api/history/rollback?path=<scope>&hash=<commitHash>
  → { success: true, newHead: "<hash>" }

POST /api/history/revert?path=<scope>&hash=<commitHash>
  → { success: true, revertHash: "<hash>" }

Database Schema

CREATE TABLE state_snapshots (
  id UUID PRIMARY KEY DEFAULT uuid_generate_v4(),
  scope TEXT NOT NULL,          -- 'tasks', 'workflows', 'config', etc.
  commit_hash TEXT NOT NULL,
  parent_hash TEXT,
  author TEXT NOT NULL,
  message TEXT,
  diff JSONB NOT NULL,          -- { files: [{ path, action, patch }] }
  snapshot_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  is_current BOOLEAN NOT NULL DEFAULT false
);

CREATE INDEX idx_state_snapshots_scope ON state_snapshots(scope);
CREATE INDEX idx_state_snapshots_hash ON state_snapshots(commit_hash);
CREATE INDEX idx_state_snapshots_timestamp ON state_snapshots(snapshot_at);

Desktop View

Offline Behavior

Documentation Files to Create


Feature 2: Hierarchical Documentation Ownership

Priority: High Effort: Low Inspiration: Space Agent’s 53-file AGENTS.md hierarchy

Description: Adopt a hierarchical documentation model where every source directory that owns code also owns an AGENTS.md (or equivalent) documentation contract. This makes documentation a runtime concern, not an afterthought.

Full Specification:

Documentation Hierarchy

/AGENTS.md                          — Project-wide rules, architecture, ownership map
/src/shell/AGENTS.md                — Shell module contracts
/src/shell/native-views/AGENTS.md   — View conventions and registry
/src/shell/widgets/AGENTS.md        — Widget system contracts
/src/shell/offline/AGENTS.md        — Offline layer contracts
/storage/AGENTS.md                  — Storage layer contracts
/schema/AGENTS.md                   — Database migration rules
/scripts/AGENTS.md                  — Operational script contracts

Rules

  1. Every directory with >3 source files must have a documentation contract
  2. Each doc answers: purpose, ownership, contracts, development guidance
  3. Parent docs own architecture and boundaries; child docs own implementation details
  4. Cross-references are explicit and bidirectional
  5. Documentation updates happen in the same commit as code changes

Documentation Files to Create


Feature 3: Persistent Agent Memory System

Priority: High Effort: Medium Inspiration: Space Agent’s memory module with behavior/transient split

Description: Add a persistent memory system where agents can store and recall information across sessions. Memory files are injected into agent prompts automatically.

Full Specification:

Memory Architecture

~/memory/
  behavior.md           — Standing behavior rules and user preferences
  memories.md           — Rolling notes, facts, and context
  <topic>.md            — Topic-specific memory files (auto-created)

Memory Files

API Endpoints

GET  /api/memory/files              — List all memory files
GET  /api/memory/file?name=<file>   — Read a memory file
PUT  /api/memory/file               — Update a memory file { name, content }
POST /api/memory/append             — Append to a memory file { name, content }
DELETE /api/memory/file?name=<file>  — Delete a memory file
GET  /api/memory/context            — Get assembled prompt context from all memory files

Agent Integration

Desktop View Updates

Documentation Files to Create


Feature 4: Space/Workspace System

Priority: Medium Effort: Large Inspiration: Space Agent’s spaces module with widget grids

Description: Allow operators to create named “Spaces” — custom dashboard layouts with specific widgets, views, filters, and agent instructions. Spaces persist independently and can be switched between.

Full Specification:

Space Schema

{
  id: "uuid",
  name: "Sprint Planning",
  icon: "📋",
  color: "#4A90D9",
  layout: {
    widgets: ["task-pulse", "queue-monitor", "agent-fleet"],
    pinnedViews: ["tasks", "board", "timeline"],
    filters: { project_id: "uuid", status: "in_progress" }
  },
  agentInstructions: "Focus on sprint tasks. Highlight blockers.",
  createdAt: "2026-04-28T10:00:00Z",
  updatedAt: "2026-04-28T10:00:00Z"
}

API Endpoints

GET    /api/spaces                   — List all spaces
POST   /api/spaces                   — Create a space
GET    /api/spaces/:id               — Get space details
PUT    /api/spaces/:id               — Update space
DELETE /api/spaces/:id               — Delete space
POST   /api/spaces/:id/duplicate     — Duplicate a space
GET    /api/spaces/:id/export        — Export space as JSON
POST   /api/spaces/import            — Import space from JSON

Desktop Integration

Database Schema

CREATE TABLE spaces (
  id UUID PRIMARY KEY DEFAULT uuid_generate_v4(),
  name TEXT NOT NULL,
  icon TEXT DEFAULT '📐',
  color TEXT DEFAULT '#4A90D9',
  layout JSONB NOT NULL DEFAULT '{}',
  agent_instructions TEXT,
  owner TEXT,
  created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
  updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);

Documentation Files to Create


Feature 5: Agent-as-Capability (In-Browser Agent Execution)

Priority: Medium Effort: Large Inspiration: Space Agent’s onscreen agent that runs in the browser

Description: Add an in-browser agent chat panel where operators can interact with an AI agent directly from the desktop. The agent can read dashboard state, execute actions via the API, and provide analysis.

Full Specification:

Agent Chat Panel

Architecture

API Integration

Safety

Documentation Files to Create


Feature 6: Deterministic Extension/Plugin Discovery

Priority: Medium Effort: Medium Inspiration: Space Agent’s convention-based module loading

Description: Replace ad-hoc registration with deterministic discovery for views, widgets, and API handlers. New features drop into the right directory and are auto-discovered.

Full Specification:

View Discovery

src/shell/native-views/*-view.mjs    → Auto-registered as view
  Each view exports: { id, label, icon, category, render(container, ctx) }

Widget Discovery

src/shell/widgets/widgets/*-widget.mjs → Auto-registered as widget
  Each widget exports: { manifest, render(ctx) }

API Handler Discovery

api/*-api.js → Auto-mounted as /api/<name> routes
  Each handler exports: { registerRoutes(server) }

Convention Rules

Documentation Files to Create


Feature 7: Optimistic UI Updates

Priority: Medium Effort: Medium Inspiration: Space Agent’s browser-first approach + our existing offline layer

Description: Make all dashboard mutations (create/update/delete tasks, approvals, etc.) apply instantly in the UI before the server confirms. The offline sync layer already has the queuing infrastructure — extend it to all operations.

Full Specification:

How It Works

  1. User performs action (e.g., drag task to “Completed” column)
  2. UI updates immediately (optimistic)
  3. State manager queues the mutation
  4. API call happens in background
  5. On success: queue item marked synced, UI stays
  6. On failure: UI reverts to previous state, error notification shown
  7. On offline: mutation queued, sync when online

Scope

Conflict Resolution

Documentation Files to Create


Feature 8: Multi-User Support with Role-Based Access

Priority: Low (single-user for now) Effort: Large Inspiration: Space Agent’s auth system with per-user isolation

Description: Add user authentication, session management, and role-based access control so multiple operators can use the same dashboard instance.

Full Specification:

User Model

CREATE TABLE users (
  id UUID PRIMARY KEY DEFAULT uuid_generate_v4(),
  username TEXT NOT NULL UNIQUE,
  password_hash TEXT NOT NULL,
  full_name TEXT,
  role TEXT NOT NULL DEFAULT 'operator',  -- 'admin', 'operator', 'viewer'
  created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
);

Roles

| Role | Capabilities | |——|————-| | admin | Full access, user management, system config | | operator | CRUD tasks, approve, run workflows, manage cron | | viewer | Read-only access to all views and data |

Session Management

API Endpoints

POST /api/auth/login      — { username, password } → session cookie
POST /api/auth/logout     — Clear session
GET  /api/auth/self       — Current user info
PUT  /api/auth/password   — Change password
POST /api/admin/users     — Create user (admin only)
GET  /api/admin/users     — List users (admin only)

Documentation Files to Create


Feature 9: Cloud Share / Export-Import

Priority: Low Effort: Medium Inspiration: Space Agent’s cloud share + ZIP export/import

Description: Allow operators to export dashboard configurations (projects, workflows, saved views) as shareable files and import them into other instances.

Full Specification:

Export Format

{
  "schema": "openclaw-export-v1",
  "exportedAt": "2026-04-28T10:00:00Z",
  "projects": [...],
  "workflows": [...],
  "savedViews": [...],
  "spaces": [...],
  "cronJobs": [...]
}

API Endpoints

GET  /api/export?scope=<projects|workflows|all>  — Download export JSON
POST /api/import                                  — Upload and apply import JSON
POST /api/import/preview                          — Preview what would be imported

Safety

Documentation Files to Create


Feature 10: Desktop App Packaging (Electron)

Priority: Low Effort: Medium Inspiration: Space Agent’s cross-platform desktop app

Description: Package the WebOS as a native desktop application for Windows, macOS, and Linux using Electron, so operators can run it without a browser.

Full Specification:

Build Pipeline

Platform Targets

CI/CD

Documentation Files to Create


Priority Matrix

Feature Impact Effort Priority
1. Time Travel High Medium P0 — Next sprint
2. Hierarchical Docs High Low P0 — Do immediately
3. Persistent Agent Memory High Medium P0 — Next sprint
4. Space/Workspace System Medium Large P1
5. Agent-as-Capability Medium Large P1
6. Deterministic Plugin Discovery Medium Medium P1
7. Optimistic UI Updates Medium Medium P1
8. Multi-User Auth Low Large P2
9. Cloud Share/Export Low Medium P2
10. Desktop App Packaging Low Medium P2

Summary

Space Agent’s strongest innovation is its documentation-as-runtime-contract model and its agent-in-the-browser architecture. Both are directly applicable to OpenClaw WebOS:

  1. Documentation hierarchy (Feature 2) is nearly free and transforms how we maintain the project
  2. Time Travel (Feature 1) gives operators fearless experimentation
  3. Persistent memory (Feature 3) makes agents actually remember across sessions

The medium-term features (Spaces, Agent Chat, Plugin Discovery) would significantly elevate the WebOS experience. The longer-term features (Multi-User, Cloud Share, Desktop App) become relevant as the product scales beyond single-operator use.