diff --git a/README.md b/README.md index b75f971..cb1dcf2 100644 --- a/README.md +++ b/README.md @@ -15,15 +15,43 @@ Velocity-OS/ |-- infrastructure/ Deployment, model hydration, gateway, and runtime operations ``` -## The Three Pillars +## Primary Surfaces | Pillar | Route | What It Replaces From Project_Velocity | | --- | --- | --- | | Command | `/command` | Dashboard, Oracle prompt surface, priority signals | +| Oracle | `/oracle` | Full Oracle canvas/chat workspace, chat recents, SQL-backed result cards | | Pipeline | `/pipeline` and `/pipeline/:personId` | CRM, leads, Client 360, conversations, tasks, showroom flow | | Studio | `/studio` and `/studio/:propertyId` | Inventory, property pages, media gallery, Dream Weaver / Reimagine, campaigns | | Control Room | `/control-room/:panel?` | Admin settings, Oracle/schema controls, comms settings, users, model hydration | +## Project_Velocity To Velocity-OS Migration Matrix + +| Project_Velocity capability | Velocity-OS location | Migration state | Notes | +| --- | --- | --- | --- | +| Login, session, current user, guarded routes | `webos/src/auth`, `core/api/api/routes_auth.py` | Migrated | Uses token-backed authenticated shell. | +| Dashboard KPIs and priority signals | `/command` | Migrated | Command keeps the old dashboard intent but removes low-value page sprawl. | +| Lightweight Oracle ask box | `/command` | Migrated | The prompt bar now submits to Oracle and saves a chat session. | +| Full Oracle Canvas workspace | `/oracle` | Migrated | Added as a first-class nav item so the chat/canvas surface is no longer orphaned. | +| Oracle recents, new chat, search, share/export | `/oracle` | Migrated locally | Recents persist in browser storage; share currently exports chat JSON to clipboard. | +| Oracle natural DB query | `core/oracle/oracle/natural_db_agent.py`, `/api/oracle/query` | Migrated | Backend remains the source of truth for SQL-backed CRM answers. | +| Oracle JSON codebook and component templates | `core/oracle/oracle/*.json` | Migrated | JSON is not counted as JavaScript in repo language stats; absence of a JS bar does not mean the codebook is missing. | +| Oracle schema catalog and data health | `core/api/api/routes_oracle.py` | Migrated | Exposed for diagnostics and planner context. | +| Canvas revisions/share/fork server workflow | Legacy Oracle backend plus new `/oracle` shell | Partial | Backend concepts exist; new Velocity-OS UI currently prioritizes chat/result generation and local export. | +| CRM pipeline board | `/pipeline` board view | Migrated | Uses canonical CRM API and normalized response shapes. | +| CRM pipeline list | `/pipeline` list view | Migrated | Board/list now render different layouts from the same normalized data. | +| Client 360 profile | `/pipeline/:personId` | Migrated | Uses tolerant ID and response normalization for old/new backend shapes. | +| Conversations, intelligence, properties, tasks | `/pipeline/:personId` tabs | Migrated | Consolidates old CRM/comms/intelligence surfaces into one entity page. | +| Showroom/webcam mode | `/pipeline/:personId` showroom action | Migrated | Preserves the Project_Velocity video/webcam concept inside Client 360. | +| WhatsApp/comms provider config | `/control-room/comms-config` plus Client 360 | Partial | UI and API wiring are present; live send/record/transcribe depends on configured provider credentials. | +| Inventory properties | `/studio` properties tab | Migrated | Uses Studio API normalization. | +| Property detail and media gallery | `/studio/:propertyId` | Migrated | Includes floorplan, media, overview, and actions. | +| Dream Weaver / Reimagine | `/studio/:propertyId` Reimagine | Migrated | Supports image upload, prompt text, async job polling, generated preview, open, and download. | +| Campaigns / Meta ads | `/studio` campaigns tab and `/control-room/meta` | Partial | Campaign list UI/API exists; Meta execution depends on live integration credentials. | +| Control Room admin panels | `/control-room/:panel?` | Migrated | Reworked to match the dark Velocity-OS theme and current L4/SGLang runtime truth. | +| Runtime LLM/SGLang operational truth | Control Room model hydration and docs | Migrated as ops surface | Heavy model runtime remains backend/infrastructure, not a WebOS feature page. | +| iPad/mobile backend support | `core/api` shared endpoints | API migrated | Native iPad client consumes the same backend contracts; not duplicated as a WebOS page. | + ## Runtime Truths - The public app is served from `https://velocity.desineuron.in/`. @@ -146,4 +174,3 @@ Run before handoff: - The production build still warns that the Three.js vendor chunk is large. This is not a functional failure, but Studio 3D/media should remain lazy-loaded and can be split further later. - The app intentionally keeps Project_Velocity as a source/reference repository. Velocity-OS should import only the required code/data assets, not blindly mirror the old structure. - diff --git a/webos/src/App.tsx b/webos/src/App.tsx index d31a154..8fc6d9f 100644 --- a/webos/src/App.tsx +++ b/webos/src/App.tsx @@ -9,6 +9,7 @@ import { lazy, Suspense } from 'react'; import { PillarSkeleton } from './shared/layout/PillarSkeleton'; const CommandPillar = lazy(() => import('./pillars/command/CommandPillar')); +const OracleWorkspacePage = lazy(() => import('./pillars/command/OracleWorkspacePage')); const PipelinePillar = lazy(() => import('./pillars/pipeline/PipelinePillar')); const Client360 = lazy(() => import('./pillars/pipeline/client360/Client360')); const ShowroomMode = lazy(() => import('./pillars/pipeline/ShowroomMode')); @@ -47,6 +48,10 @@ const router = createBrowserRouter([ path: 'command', element: , }, + { + path: 'oracle', + element: , + }, // Pillar 2: PIPELINE — Deal Intelligence (CRM + Comms + Sentinel) { diff --git a/webos/src/control-room/ControlRoom.tsx b/webos/src/control-room/ControlRoom.tsx index 3285bc1..91e849f 100644 --- a/webos/src/control-room/ControlRoom.tsx +++ b/webos/src/control-room/ControlRoom.tsx @@ -1,39 +1,16 @@ -import { motion, AnimatePresence } from 'framer-motion'; +import { AnimatePresence, motion } from 'framer-motion'; import { useLocation, useNavigate } from 'react-router-dom'; import styles from './ControlRoom.module.css'; -/** - * ControlRoom - * Admin-only surface. Accessible at /control-room. - * Protected by AdminGuard at router level AND FastAPI RBAC middleware. - * - * Panels (left sidebar → content area): - * System Health — service status, GPU utilization, queue depths - * Oracle Admin — schema catalog, canvas management, MCP tools - * Comms Config — WAHA/Evolution provider, webhook setup - * Users & Roles — broker roster, role assignment, audit log - * Model Hydration — s5cmd sync status, model inventory - * Meta Integration — OAuth, ad account, Lookalike sync - * - * Design: deliberately more "operator" than "broker" — still glassmorphic - * but denser information, monospace for technical values. - */ - -type Panel = - | 'system' - | 'oracle-admin' - | 'comms-config' - | 'users' - | 'models' - | 'meta'; +type Panel = 'system' | 'oracle-admin' | 'comms-config' | 'users' | 'models' | 'meta'; const PANELS: { id: Panel; label: string; icon: string }[] = [ - { id: 'system', label: 'System Health', icon: '⬡' }, - { id: 'oracle-admin', label: 'Oracle Admin', icon: '◈' }, - { id: 'comms-config', label: 'Comms Config', icon: '⟐' }, - { id: 'users', label: 'Users & Roles', icon: '⊛' }, - { id: 'models', label: 'Model Hydration', icon: '⊗' }, - { id: 'meta', label: 'Meta Integration', icon: '⊕' }, + { id: 'system', label: 'System Health', icon: 'S' }, + { id: 'oracle-admin', label: 'Oracle Admin', icon: 'O' }, + { id: 'comms-config', label: 'Comms Config', icon: 'C' }, + { id: 'users', label: 'Users & Roles', icon: 'U' }, + { id: 'models', label: 'Model Hydration', icon: 'M' }, + { id: 'meta', label: 'Meta Integration', icon: 'A' }, ]; export default function ControlRoom() { @@ -44,10 +21,9 @@ export default function ControlRoom() { return (
- {/* Header */}
- + CR

Control Room

System Administration · Admin Access Only

@@ -59,7 +35,6 @@ export default function ControlRoom() {
- {/* Left sidebar */}

Schema Catalog

@@ -177,21 +147,18 @@ function OracleAdminPanel() {
-

MCP Tools

- +

Component Codebook

+

Project Velocity JSON schemas are loaded from the backend Oracle codebook assets.

); } -// ── Comms Config ────────────────────────────────────────────── function CommsConfigPanel() { return (

Comms Configuration

-

- WhatsApp provider setup. Never visible to sales brokers. -

+

WhatsApp provider setup. Never visible to broker-role users.

setSearch(event.target.value)} + placeholder="Search chats..." + /> + +

Recent

+
+ {filteredSessions.map((session) => ( + + ))} + {!filteredSessions.length &&
No matching chats.
} +
+ + +
+
+
+

{activeSession?.title ?? 'Oracle Canvas'}

+

Natural CRM intelligence over live Velocity data

+
+
+ + {shareNote &&

{shareNote}

} +
+
+ +
+ {!activeSession?.turns.length && ( +
+
+

Start with a business question

+

Example: “Which clients have not been contacted in 7 days but have high QD?”

+
+ )} + + {activeSession?.turns.map((turn) => ( + +
{turn.prompt}
+ {turn.status === 'thinking' &&
} + {turn.status === 'failed' && ( + + )} + {turn.status === 'done' && turn.result && ( + + )} + + ))} +
+ +
{ + event.preventDefault(); + void submitPrompt(); + }} + > +
+