┌──────────────────────┐
│ OPSIIE_0_3_80_XP.py │
│ (orchestrator) │
└──────────┬───────────┘
┌────────────────────┼────────────────────┐
▼ ▼ ▼
PostgreSQL ChromaDB Ollama
(conversations) (configured embed model) (configured models)
│ │ │
└──────────┬─────────┴────────────────────┘
▼
Mnemonic store / recall
On python OPSIIE_0_3_80_XP.py:
- Heavy imports (
transformers,diffusers, and others) run first. sys.pathis adjusted, thenload_dotenv()runs so.envvalues are available before runtime service checks.web3_handleris lazy-loaded only when Web3 is initialized or a Web3 command is used. MissingAGENT_PRIVATE_KEYor RPC URLs defer Web3 while allowing non-Web3 startup.- Other submodules (
utils,kun,agentic_network,markets,help,mail,dna,room,video) load according to the import block in the main file.
web3_handler validates wallet and RPC environment variables when the handler is constructed. Non-Web3 features can boot without these values; /0x and related Web3 commands report the missing configuration when invoked. For a dedicated Web3 product line, see Hermes3.
| Symbol | Purpose |
|---|---|
convo |
Ollama message list; index 0 is the system prompt, rewritten at boot |
file_context |
Holds last_file text for TAF-3000 follow-ups |
current_room |
Room instance or None |
vector_db |
Chroma collection handle for conversations |
temporary_soul_sig |
Buffer for /soulsig heal |
webpage_char_limit |
Character cap for describe_webpage (500–5000, default 1000) |
The main while loop at the end of OPSIIE_0_3_80_XP.py intercepts:
/weblimit(viachange_weblimit)exit/quit/recall,/forget,/memorize/help,/status,/voice,/theme
All other lines, including slash commands not listed above, route to handle_user_query().
Master-only guard appears in both places: ask, markets, dna, send, and 0x in the main loop; handle_user_query uses a parsed first token list including 0x for /0x ... forms.
stream_response calls ollama.chat() using the configured chat model (defaults to llama3), prints OPSIE: with pastel styling, then store_conversations persists to PostgreSQL and Chroma using the configured embedding model. Optional ElevenLabs playback runs when voice flags are active.
room.py defines Room:
- Injects OPSIE system text plus
get_agent_description()for each summoned agent (nyx,g1; OPSIE always present). - Maintains
conversation_historyand a dedicated Chroma collection namedroom_<slug>. - Chooses responding agent via embedding similarity heuristics.
- On close, optional CSV export under
outputs/rooms/.
For a standalone evolution of multi-agent rooms (outside this monolith), see arpahls/rooms.
See agentic_network.py:
- Nyx: OpenAI Assistants API (
ask_model). - G1: Google Gemini
generateContent. - G1 live: ElevenLabs ConvAI WebSocket (
G1_VOICE_LIVE). - Kronos live: Parallel scaffold using
KRONOS_LIVE.
| Capability | Implementation |
|---|---|
| Image URLs | describe_image — BLIP (Salesforce/blip-image-captioning-base) |
| Web URLs | describe_webpage — requests + BeautifulSoup |
/imagine |
Hugging Face Inference HTTP POST; HUGGINGFACE_API_KEY or HF_TOKEN from .env |
/music |
MusicGen small (facebook/musicgen-small) |
/video |
video.py handle_video_command and DiffusionPipeline map |
- PostgreSQL: relational chat log with monotonic
id. - Chroma: embedding sidecar keyed by stringified
id. kun.py: Python literal dict edited in place for soul signatures (viasave_known_user_names()).
toggle_voice_modeandload_custom_soundseach appear twice inOPSIIE_0_3_80_XP.py; Python retains the last definition. Treat behavior as whatever the lower copy implements until a refactor merges them.- Custom MFCC word map uses hardcoded absolute WAV paths in the default
custom_wordsdict; relocate for your machine.
See BOOT_AND_SECURITY.md and SECURITY.md.