Brings the system from "engrams cluster + form synapses" to a complete end-to-end demo: ingest text, watch it cluster, ask questions, restart with state intact. - Stage 4: birth introspection (taxonomy/goals/open_questions via LLM, bounded by the global parallel-op semaphore), per-engram memory log, click-to-inspect side panel. - Stage 5: queries as conversations. POST /api/galaxy/:id/query embeds the question, materializes a pinned Query-Engram at the donut center, runs broadcast retrieval (global cosine scan + 1-hop synaptic expansion with attenuation) and fans out responder LLM calls. The integrator runs every 2s on accumulated snippets and streams the refining answer back over SSE; responders briefly transition to Conversing on the WS bus so the right dots light up. - Stage 6: snapshot persistence. sled-backed store keyed by galaxy id, JSON-encoded values (bincode chokes on internally-tagged enums like Manifest/MemoryKind), 60s periodic snapshot task, hydrate-on-boot, DELETE /api/galaxy/:id wired through. State survives kill -9. - Stage 7: HUD additions (sim ticks/sec, LLM queue depth, FPS) via a new GET /api/stats polled at 1Hz. `sophia demo` subcommand boots the server then auto-ingests a 50-paragraph corpus baked into the binary with include_str!. README quickstart added. Token caps for query_responder/integrator bumped (gemma-4-e4b is a thinking model — output budget must cover hidden reasoning + visible answer, otherwise content comes back empty). Pinned engrams skip physics; their tick scheduling is also skipped at materialization so they stay perfectly still at the donut center. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
64 lines
2.3 KiB
TOML
64 lines
2.3 KiB
TOML
# Sophia runtime configuration.
|
|
# Copy to config.local.toml to override locally (gitignored).
|
|
|
|
[server]
|
|
host = "127.0.0.1"
|
|
port = 7777
|
|
static_dir = "web/dist"
|
|
|
|
# Persistence (Stage 6). `data_dir` is a directory; sled creates and manages
|
|
# files inside it. Snapshots are written every `snapshot_interval_secs`
|
|
# while the server runs; on boot any existing galaxy snapshots are loaded
|
|
# and re-instantiated in the sim.
|
|
[storage]
|
|
data_dir = "data"
|
|
snapshot_interval_secs = 60
|
|
|
|
[lm_studio]
|
|
# LM Studio's OpenAI-compatible REST endpoint.
|
|
base_url = "http://127.0.0.1:1234/v1"
|
|
chat_model = "google/gemma-4-e4b"
|
|
# Embedding model loaded in LM Studio. Often a separate small model
|
|
# (e.g. "nomic-embed-text-v1.5"). Set this to whatever you load.
|
|
embedding_model = "text-embedding-nomic-embed-text-v1.5"
|
|
# Fixed parallel-op ceiling per §13.5 of docs/system-analysis.md.
|
|
parallel_ops = 8
|
|
# LM Studio 0.3.x+ enables auth by default. Create a token in the LM Studio
|
|
# app under Developer → API Tokens, then put it in `config.local.toml`
|
|
# (which is gitignored) like:
|
|
#
|
|
# [lm_studio]
|
|
# api_token = "lms-..."
|
|
#
|
|
# config.local.toml is merged on top of this file at startup, so it only
|
|
# needs to contain the fields you want to override. Leave api_token unset
|
|
# if your LM Studio install has auth disabled.
|
|
|
|
# Default torus shape for newly-created galaxies. The world is fixed-size
|
|
# (per the Topology Pivot — we replaced density-driven recentering with
|
|
# manually-resizable torus volumes). Live resize available at
|
|
# `POST /api/galaxy/:id/resize`. major_radius must exceed minor_radius.
|
|
[galaxy_defaults]
|
|
major_radius = 100.0
|
|
minor_radius = 30.0
|
|
|
|
# Caveman token caps per §13.5.
|
|
# Note: gemma-4-e4b is a *thinking* model — it emits a hidden reasoning
|
|
# stream before its visible content. Every `_out` cap therefore needs to
|
|
# budget for the hidden reasoning *plus* the visible answer. Numbers
|
|
# verified against logs: a 150-cap responder hit "response had no content"
|
|
# every time (all budget eaten by reasoning).
|
|
[token_caps]
|
|
introspection_in = 600
|
|
introspection_out = 900
|
|
peer_msg_in = 100
|
|
peer_msg_out = 100
|
|
synthesis_in = 300
|
|
synthesis_out = 80
|
|
query_responder_in = 400
|
|
query_responder_out = 700
|
|
query_integrator_in = 1200
|
|
query_integrator_out = 1200
|
|
hard_ceiling_in = 1500
|
|
hard_ceiling_out = 1500
|