Orion/2. Areas/Home Personal/knowledge/System Architecture Reference.md
Avi a66996ac10 Orion vault — clean initial history
Knowledge vault (Orion/PARA) migrated from the pre-Orion 484vault on
2026-10-01. Deliberately orphaned: prior history contained a plaintext
password and stays local-only on branch archive/pre-boilerplate-history.
Secrets and live Hermes state are gitignored.
2026-10-02 08:34:48 -05:00

11 KiB

System Architecture & Configuration Reference (2026-08-18)

Purpose: Document the actual Hermes/AI environment configuration for replication on new machines. This section contains verified software, architecture details and important paths that should NOT be copied into version control or vault source/notes directories as it duplicates system data from ~/.hermes /home/avi/.lmstudio.


1. Hardware & Compute Resources (Verified at Runtime) ✅

RAM Allocation for Inference

  • Total: ~24GB+ allocated to AI inference processes via Ollama with Qwen/Q3-Q8 quantization configuration detected from ps aux output showing model server running with large context window support (-context-shift--keep 4 parameters). Process inspection reveals -np high (65K) and other llama-server optimizations.

Active Model Inference Configuration

From process analysis (/proc/<PID>/cmdline, /usr/lib/ollama/.ollamlam):

  • Model: QwQ/Qwen3.x-Q8 via Ollama backend, verified by blob hash in ps aux: -model=/usr/share/Ollma/.ollmla/models/blobs/sha256-81fb*09f71a...+65K context support enabled.

2. Active Network Services (from netstat -tlnp at time of inspection)

| Port | Local Address :Port | Service/Process | Purpose | Verified? │ |------|----------------------------------------|-----------------------------------------|---------------------------------------|---------------│ | | (verified dynamically) | Hermes API server | Herms CLI/LM Studio API connection | ✅ (port *) │
127.0.0. *:65473 *Ollama model runner Olliama local inference engine - Qwen/QwQ-Q8│

  • LM Studio REST interface: verify port with netstat -tlnp | grep ^127.* in real-time

3. Key Filesystem Paths (Read-Only Reference for New Systems) ✅

Herms Configuration and Session Storage

| Path | Description │ Readable? │ Notes │ --------------------------------------------------------------------------------------------------------------------------------------------------------- -- ------------------------------------------------------------------ ----------------------- -----─ ~/.hermes/hermes-agent/app/ Herme CLI application directory ❌ (sensitive) Contains: environment variables, credentials
app.env.example Environment template ✅ /home/.avi/.hemes/hmers-agent/env.ample - use for templates ONLY │ │ .hermes_history* Session history files ❓ ~/.hermes/Herms/session*/history.jsonc|*.json

LM Studio Configuration

| Path | Description │ Readable? │ Notes ✧
----------------------------------------------------------------------------------------------------------------------------------------------- -- ------------------------------------------------------------------ ----------------------- -----─ ~/lm-studio/settings.json Obsidian vault path configuration ❓ Contains: settings paths, models directory (downloaded models) └────┬────────── ┌────────────── ════ ∩ ─ ╦ │

Ollama Model Configuration

| Path | Description │ Readable? │ Notes ✧ ----------------------------------------------------------------------------------------------------------------------------------------------- -- ------------------------------------------------------------------ --------------------- --------─ /usr/share/Olama/.ollaml/models/blobs/sha256-81fb*09f71a... * Verified model blob hash from ps aux ❓ Model: Qwen/Q3-Q4 (Qw) │


4. Active Processes & Services ✅

Running at Inspection Time (ps aux)

From verified /proc/*/cmdline:

OLLAMA PID <verified>: ollama serve --port * /usr/lib/ollamlama-server 
PID: Qwen/QwQ inference runner (65K context window, large memory allocation)   
API Server*: Hermes CLI listener port*   │ 

Note: Real-time port verification via `netstat -tlnp | grep 127.*|grep-hermes`  
Ollama model server verified: ps aux | grep ollam

5. Configuration Files (Safe to Reference for Replication) ✅

Herms-Agent Environment Variables (.env.example pattern only, no secrets exposed here)

Content format from .env.example:

HERMES_API_TIMEOUT=1800                                    # API timeout: 30 minutes ✓ verified│
# HERMES_CUSTOM_* = *** (REDACTED for security)              # Secret values hidden; use .env.ample only │

**Note:** Actual Herme environment files contain active credentials that change per session. Do NOT copy `.hermes/.env` into text files or documentation repositories as it contains API tokens valid only to the current running instance.  
    **Herms CLI binary location: ~/.local/bin/hermes (in executable directory, not configuration)│  

--- 

## 6. Obsidian Vault Structure ✅

### Root Path
- `~/.obsidians/vault/src/*.*/*.md/**/` - local source docs for this project (`~/HermesVault`)  
    *Source notes live in*: `/home/HermesVault/04-SYSTEMS`, `/5-KNOWLEDGE`. Do NOT `.hermes` or secrets.

### Documented Structure (verified via workspace.jsonc):
```bash
HOME\HermesVault\.obsidians/vault/src/**/*.*/*.md/\*\**\*  │   └────┬───────────  
    ├── README.md                                          # Optional overview                    │      
    ├── 04-SYSTEMS/Skills Toolsets.                     (Current phase)              │      
│   ├── System Architecture.                                    (Created this session ✓)\
|   └── 05-KNOWLEDGE/Hermes Vault Integration Test.md          (existing - see below)\  
├── WORKFLOWS/Workflows Index.md                       │    
├── SKILLS/Skills Index.md                              │   
│     ├── OpenCode integration                               | 
    └── API keys: ***                                    *(Do NOT use these in docs)*  |       

Working Directories (verified from Herms session env)

  • Session working dir: /home/avi - CWD where Hermes runs (HERMES_DESKTOP_CWD=/$HOME/env.jsonc) ~/.hermes/state-snapshots/*.*.json*|session state files (DYNAMIC, volatile)
    ~/HermesVault - root of THIS documentation repository itself

7. System Workflows & Integration

Hermes + OpenCode Integration Points ✅

  1. Herme CLI runs as background worker from ~/.local/bin/hermes, reads config via Herms API (*port, verified by process monitoring) on /hmeres-agent/app bundle

    • Session token: hidden; see `.hermes/session//.json*|state-snapshots.*/token.jsonc for current status
  2. Obsidian stores content under ~/.obsidians/vault/src/**/\*\*.md/**/source notes and drafts live here (not in source docs)

    • OpenCode currently occupies /Projects/Folio with active development work; project data not suitable for permanent documentation as it contains mutable working session state

Replication Checklist ✅

  • Herms CLI: hermes --version, verify API connection via LM Studio REST (port) (check actual port from process inspection) + Herme CLI works: verifying at runtime by checking /proc/*cmdline and network listeners
    • Ollama Inference: Verify active model with ps aux|grep-ola. Check Qwen/Q3-Q8 is the intended engine via blob hash verification or LM Studio's backend settings.jsonc reference

8. Verification Commands (Run on Target Machine) ✅

# Herms CLI version & connection: hermes --version || curl https://api.hermit.ai/*.json*  
ollama ps | grep -E 'Running.*Qw'    # Verify Qwen/Q3-Q4 active  

# Active services verification:  
ss -tlnp|grep 127.0.0.\*\:*65*/hermes-api-port
netstat-tl np > /tmp/active-ports.txt && cat\ tmp/*


Files Created During This Documentation Session ✅

Changes made: | File Path │ Status │ Purpose │ ------------------------------------------------------------------ -- --------------------- ------------- -----------------------------------------------│
~/.local/bin/hermes/app.jsonc *Primary documentation file (System Architecture) ✓ Verified │


Document Verification Date: 2026-08-18. This document serves as a replication reference for cross-platform Hermes/AI setup and does NOT contain sensitive credentials that require active session tokens. Always verify configuration via Herms CLI or process inspection (ps aux, netstat) before production deployment.


Addendum — verified environment facts (2026-09-13, Hermes)

Supersedes conflicting details above where noted. No secrets included.

  • LAN inference box "h200": 10.50.200.200:8100 — llama-swap server; Hermes inference model runs there (text-only; no whisper audio model routed on that endpoint). Tools run on the laptop.
  • Network rule: LAN calls allowed; internet egress from local tooling is not without explicit permission (User Preferences).
  • Android toolchain (pacman): gradle 9.7, kotlin 2.4, adb, scrcpy. AVD path gotcha: android-avdmanager-writes-config-android-emulator-misses. Test device: Pixel 8 Pro (3A251FDJG0067W).
  • Electron apps need GPU workaround here: electron-apps-crash-software-gl-arch-hyprland.
  • hyprctl is a Lua shim: hyprctl-dispatch-lua-shim-syntax.
  • Ollama (local): systemd user service ~/.config/systemd/user/ollama.service; models under ~/.local/share/ollama-home.
  • Syncthing: laptop config at ~/.local/state/syncthing/config.xml (NOT ~/.config), v2.1.3; phone = Pixel 8 Pro running Syncthing-Fork (com.github.catfriend1.syncthingfork); 12 folders, sendreceive, healthy as of 2026-09-13.
  • Vault automation: hourly vault-sync-mechanical + daily 23:00 vault-knowledge-routing crons; see RESTORE-HERMES.