CortexSpace
Self-hosted AI workspace that starts in one command — agents, multi-providers and benchmarks; grown out of MyWorkspaceAI.
Self-hosted AI workspace that starts in one command — agents, multi-providers and benchmarks; grown out of MyWorkspaceAI.
**A self-hosted AI workspace that starts in one command and does the same job as Odysseus — with none of the ceremony.**
Odysseus is a great project, but it's a heavy, Docker-first stack. This is the "same features, zero friction" answer: a single Python process (FastAPI + Uvicorn) serves a hand-rolled, dependency-free web UI — no npm, no build step, no Docker, no CDN, no tracking.
./run.sh # or: PORT=9000 ./run.sh
That's it. http://localhost:8787 opens instantly with a working workspace. The only requirements are Python 3.10+ and pip.
requirements: fastapi, uvicorn, httpx (installed into .venv automatically)
| | Odysseus | CortexSpace | |---|---|---| | Start time | Docker compose, several services | ./run.sh → <1s cold start, one process | | Build tooling | Node toolchain + static bundles (~3MB JS vendored) | Zero build step, ~100KB of hand-rolled JS/CSS | | AI providers | OpenAI / Anthropic / local | Ollama, OpenRouter, any OpenAI-compatible API (Groq, LM Studio, vLLM…) + built-in offline demo | | Chat | Sessions, streaming | Sessions, streaming, token & latency stats per turn, copy/regenerate, Markdown export | | Workspace files | Yes | Yes — tree, editor with Markdown preview, download, agent read/write/search | | Agent tools | bash, python, browser, search… | file tools, workspace search, web search, page fetch, Python execution | | Safety model | Tool approvals | Tool approvals — every write/delete/code run shows an Approve/Deny card (auto-approve optional) | | Web search | SearXNG (required) | DuckDuckGo out of the box, SearXNG optional | | Browser/companion | Companion app for page context | Built-in Browser panel: load a page, "Add page to chat" | | Offline | Works, but big surface | Entire UI is vendored & offline-safe; demo model needs nothing | | Privacy | Self-hosted | Self-hosted: chats/notes/settings in local SQLite + files; outbound calls only to what you configure |
Your notes and files live in data/workspace/ (seeded on first boot):
welcome.md projects/roadmap.md
notes/todo.md snippets/fib.py
notes/ideas.md
The agent can read, write, search and (optionally) execute against this folder. All paths are strictly contained — no .., no absolute paths, ever.
The demo model understands a small, honest set of intents so you can try the full pipeline — streaming, tool cards, approvals, real file changes:
list my filesread welcome.mdcreate a note about my coffee habitsfind the word roadmaprun python that prints 2121 (enable Python execution* in Settings first)search the web for latest LLM news (needs outbound network)Settings → Model provider (live status dots show which backends are reachable):
codero-sus/Cortex_LLMHoster: a free personal-use hoster that manages llama.cpp GGUF models directly — no Ollama, no cloud account, no cloud key. Run it from its repo (python -m cortex_llmhoster → dashboard on http://127.0.0.1:8624/), pick the Cortex LLMHoster card here, and you're done. The base URL defaults to http://127.0.0.1:8624/v1; if you set a CORTEX_API_KEY local secret on that install, paste it in Settings (it protects the API — it never leaves your machine). Leave the model blank to auto-use the first model LLMHoster has loaded.
ollama serve and ollama pull llama3.2,then paste the base URL + model. Tool calling works out of the box.
(anthropic/claude-sonnet-4, openai/gpt-4o, openrouter/auto, …). The model list refreshes from the OpenRouter API.
OpenAI dialect: OpenAI, Groq, Together, LM Studio, vLLM, llama.cpp server… (https://api.groq.com/openai/v1, http://127.0.0.1:1234/v1, …).
All providers stream natively and support the same tool schemas.
app/
main.py FastAPI app: REST + SSE chat stream + static UI
agent.py provider → tool loop, human-in-the-loop approval gate
tools.py tool schemas + executors (files, search, web, python)
webtools.py DuckDuckGo / SearXNG search, SSRF-guarded page fetch
worksp.py workspace file ops with path containment
db.py SQLite (chats, messages, settings)
config.py runtime settings store
providers/ demo (offline) · ollama · openrouter — one stream interface
static/ hand-rolled SPA: no framework, no CDN, no build step
Chat protocol (SSE): token · tool_call · approval_request · approval_resolved · tool_result · done · error. The approval gate pauses the stream until you decide — the same trust model as Odysseus, with a visible card for every dangerous action.
⌘F) — one query across your chats and the whole workspace, with highlighted matcheseach answer ends with a stats line (tools used · tokens in/out · tok/s · time)
and a floating pill with an unread counter when you scroll up mid-stream
widths persist
⌘\) — collapses everything to the conversationTab inserts a tab, dirty-dot indicator,live line/word/byte counts, ⌘S saves from anywhere
(also honors your OS prefers-reduced-motion), all persisted
smooth scrolling — every animation respects reduced-motion settings
version with a green/red diff viewer and restore in one click
/ in the composer: /note, /python, /search, /read,/pin, /fork, /stats, /export, /theme, /focus and more
workspace size, over 7/14/30-day ranges
.zip? anytime for the full shortcut cheat-sheet200+ individual features and functions layered on top:
Composer & chat
“new chat with current context”, pin a message, search & jump within a chat
[ ] to step between chatsEditor
sort by name / size / modified, per-file size + modified time in the tree
Interface preferences (all in Settings → Interface)
with from/to hours) · custom CSS · reset / export / import your preferences
Agent panel
and blocked at execution) · approval policy (ask / auto / strict)
Insights v2
Browser tab
Data & maintenance
Toast & feedback system
bar, Undo on chat & file deletes, searchable notification history drawer
Templates & prompts
reading log) + save your own / delete
Fun
quote in the sidebar + a daily “did you know” fact · 8 unlockable achievements with confetti · mood picker
Focus & productivity
progress ring · focus mode
Keyboard (additions)
⌘P quick-open · ⌘L focus composer · ⌘1–4 panel tabs · ⌘W clear⌘+/−/0 zoom · ⌘E export · ⌘I insights · ⌘D duplicate file ⌘G jump to message · F wrap · T new note · P pomodoro · M mute [ ] prev/next chat
30+ new slash commands — /tldr, /eli5, /save, /find, /goto, /toc, /lock, /party, /confetti, /ach, /backup, /csv, /goal … (see / in the composer) — and 35 new command-palette entries (⌘K).
PWA & offline
installable on desktop/mobile, connection indicator
Accessibility
aria-live status region, landmark roles, labeled controls,focus-friendly modals, reduced-motion honored globally
Developer
cortexspace.help() / cortexspace.dump() / cortexspace.prefs in the browser consoleGET /api/requests), version footerThe long tail, squared. 503 base items (plus ~58 option variants: 8 accent themes, 6 system-prompt presets, 4 server presets, 3 token / 4 temp quick chips, 6 chat tints, font / style option sets, 12 dynamic palette chat entries) across a self-contained static/js/w6.js + static/styles-w6.css module.
Counting methodology (same as wave 5): each individually selectable / callable item counts once — a settings row, a key binding, a slash command, a palette entry, a text operation, a chip, a card. Tallies per category:
| Category | Items | |---|---| | Appearance & behavior settings (new rows) | 42 | | Agent controls (prompt presets, addendum, quick chips, modes) | 14 | | Live status-bar widgets | 16 | | Keyboard shortcuts (⌘⇧ / ⌘⌥ / ⌘⇧⌥) | 55 | | Slash commands | 79 | | Command-palette entries | 50 | | Composer text operations | 43 | | One-click quick actions | 22 | | Templates / prompt-library entries | 15 / 20 | | Achievements | 19 | | Chat management (archive, tints, tags, unread, import/export, pin…) | 20 | | Files panel (5 views, watch, info, diff, deep links…) | 16 | | Browser (autocomplete, zoom, top sites, hard reload…) | 9 | | Fun & easter eggs (retro/matrix/rainbow, noise, breathing, konami…) | 17 | | Insights (9 new cards + 10 new backend metrics) | 19 | | Search (recents, scopes, regex/case/word/filename, jump-to-result) | 9 | | PWA / a11y / dev (dev-log drawer, state export/import, skip link…) | 14 | | Toast upgrades (action buttons, position, duration) | 3 | | New backend endpoints & stats | 21 |
New backend endpoints
GET /api/uptime — uptime, request count, memory, active SSE streams, versionGET /api/sessions — live stream + request countersGET /api/workspace/info — by-extension, largest, recent, empty foldersPOST /api/workspace/cleanup — removes empty folders (never files)POST /api/settings/preset — local-first / cautious / turbo / cloud-powerPOST /api/chats/{cid}/archive · GET /api/chats/archivedGET /api/chats/{cid}/export/json · GET /api/files/raw?path=GET /api/stats gains: active days, longest day, avg chat length,first/last activity, top tool, week totals, words today, message-length and response-time histograms
Highlights
tag-filter, unread badges + "next unread" jumping
emoji-fy, counters…) acting on the selection
provider/model/theme/offline/zen/sound/unread/dev-log chips
(⌘⌥1–9 open chat n, ⌘⇧Z zen, ⌘⇧X copy chat JSON, ⌘⌥D diff, …)
⌘⇧J) over GET /api/requests, auto-refreshingdistributions, 14-day active-day grid
change toasts, info modal, side-by-side diff, ?file-style deep links
ambience, breathing overlay, 20-20-20 eye break, 1-minute timer, konami code, /hello, /ssss, triple-logo easter egg
3-sends-in-20s sprinter…)
/speak), stop with /stopcortexspace.uptime(), cortexspace.workspace(), cortexspace.state(), … in the console
ChatGPT, Claude, Gemini and Odysseus are all wrappers, not AI models — the intelligence is rented from an LLM, and the wrapper is where users actually live. So this wave optimizes the wrapper: speed you can measure, models you can choose, and transparency by default.
active provider to a single chat (other chats keep following Settings). One workspace, many models: local Llama for drafting, frontier API for the hard stuff.
first token) and tokens/s per provider+model into a rolling 400-run ledger (/api/bench); the Insights panel shows your real numbers and every assistant message carries its own ⚡ first-token stat.
from that point), fork-from-message, stop-mid-stream: all present, all offline.
and isn't: the model is the brain you plug in; CortexSpace is the fastest, most transparent, fully local harness around it.
Wave 8 surveyed every serious AI wrapper on the planet — SaaS, self-hosted, desktop — and built a live scoreboard into the app: the Arena panel (right panel ⚡ tab, ⌘⇧A, /arena, palette). Sixteen wrappers are scored on eight dimensions where a wrapper actually competes, and two of those dimensions (page weight, speed) are measured live on your instance, not quoted.
The eight dimensions: one-process setup · light payload · model freedom · verifiable speed (TTFT + tok/s) · per-action agent approval · data stays local · zero telemetry · $0 infra.
| # | Wrapper | Type | Score | The gap | |---|---|---|---|---| | 1 | CortexSpace | this machine | 8.0 / 8 | it's you | | 2 | LibreChat | self-host · Docker | 4.0 | needs MongoDB + Meilisearch | | 3 | Jan | desktop · Electron | 4.0 | cleanest offline app — ~100 MB+ Electron runtime | | 4 | NextChat | lightweight web | 4.0 | a client: no agent, no workspace, browser-local chats | | 5 | text-generation-webui | self-host · Gradio | 4.0 | inference lab first, app second | | 6 | SillyTavern | self-host · Node | 4.0 | roleplay-first; no file workspace, no agent tools | | 7 | Odysseus | self-host · Docker | 4.0 | closest sibling — Docker + SearXNG + ~3 MB vendored JS/page | | 8 | Open WebUI | self-host · Docker | 3.5 | container + SvelteKit + Python + ChromaDB; usage stats on by default | | 9 | AnythingLLM | self-host · Docker | 3.5 | best RAG — but Electron/Docker + ChromaDB; cloud $50+/mo | | 10 | GPT4All | desktop · Qt | 3.5 | local-only; no cloud path, no agent | | 11 | Khoj | self-host · Docker | 3.5 | separate 'brain' service; notes aren't editable files | | 12 | Poe | SaaS · aggregator | 2.5 | many models — all cloud, all metered | | 13 | LobeChat / LobeHub | self-host · Next.js | 2.0 | great ecosystem; cloud tiers $9.90–39.90/mo | | 14 | Perplexity | SaaS · search | 2.0 | cited search — cloud, logged, metered | | 15 | Claude | SaaS | 1.5 | superb model, walled cloud garden | | 16 | ChatGPT | SaaS | 1.0 | one vendor's stack; your chats on their servers | | 17 | Gemini | SaaS | 1.0 | tied to Google's stack and telemetry |
Method: public 2026 product architectures, self-assessed 0 / ½ / 1 per dimension — the same table the Arena renders, with live-measured weight and speed. Ground CortexSpace chooses not to fight (stated in the panel too): multi-user auth/RBAC, vector-DB RAG, image generation, MCP marketplaces — team/enterprise battlegrounds, not a personal workspace's.
⌘K palette · ⌘F search · ⌘N new chat · ⌘B sidebar · ⌘J panel · ⌘\ focus mode · ⌘S save file · ⌘, settings · ⌘. theme · ? shortcuts · ↑ edit last message · @ attach a file · / slash commands
Model fallback chains · scheduled agent runs · PDF/DOCX export · multi-user workspaces · tab-context companion. See data/workspace/projects/roadmap.md.
CortexSpace is built and maintained by codero-sus — see the profile for more projects (including Cortex LLMHoster, the local model host this app speaks to) and the website.
Everything is stored locally in data/. The only outbound network calls are the ones you configure: your Ollama endpoint, OpenRouter, and web search. Page fetching blocks private/internal IP ranges by default.
Speed — SQLite tuned (synchronous=NORMAL, 64 MB cache, 256 MB mmap, in-memory temp store, slower checkpoints); off-screen message and chat-list nodes skip rendering (content-visibility); streaming honors your preferred render speed; auto-scroll and live token stats are now toggleable; reduced-motion preference is respected.
Sharing — every chat has a copyable link (Export → Copy chat link, /share, or the command palette); opening /?chat=<id> jumps straight in.
New per-message action — Reuse puts any reply back into the composer.
Robustness — streams that end early offer a one-click resend; the tab warns before closing mid-stream; quota-full storage degrades gracefully; a single global guard toasts if the UI itself breaks; security headers (nosniff, DENY framing, no-referrer) on every response; /api/health now reports uptime, PID and FTS capability.
Accessibility — every icon button carries an aria-label, dialogs are proper role="dialog" aria-modal overlays, the toast stream is a live region, and keyboard focus is always visible.
A local-first Python agent framework for Cortex LLMHoster — 113 tools behind a real sandbox, hybrid memory, verifiable citations, guardrails, multi-agent teams and a 26-command CLI, with no dependencies beyond the standard library.
A self-training chatbot that improves over time — pure Python + NumPy brain, Flask WebUI, and the CORTEX self-learning loop with episodic memory and goals.
CORTEX — a local self-improving AGI with a custom inference server, cognitive loop, System-2 chain-of-thought and self-improvement that writes to disk.