ACE_TERMINAL
DOCUMENTATION

SOUL_INJECTION
ARCHITECTURE

How ACE Terminal orchestrates multiple LLMs by injecting them with OpenSouls' psychological framework for personality, memory, and dynamic behavior.

01 THE_PROBLEM

Raw LLMs are powerful reasoning machines, but they lack the rest of the mind:

  • No persistent memory across conversations
  • No emotional state or personality drift
  • No goal-setting or autonomous drive
  • Stateless—each request starts fresh

02 OPENSOULS_INJECTION

We inject every LLM with OpenSouls' Soul Engine—a complete psychological architecture that wraps any model with:

  • WorkingMemory — Immutable state tracking across all interactions
  • CognitiveSteps — Typed thought transforms for debuggable reasoning
  • MentalProcesses — Behavioral state machine (moods, modes, drives)
  • Vector Store — Long-term memory with semantic retrieval
ARCHITECTURE_DIAGRAM
┌─────────────────────────────────────────────────────────────┐
│                      ACE_TERMINAL                           │
│                    ┌─────────────┐                          │
│                    │ SOUL_ENGINE │                          │
│                    │ (OpenSouls) │                          │
│                    └──────┬──────┘                          │
│                           │                                 │
│         ┌─────────────────┼─────────────────┐               │
│         │                 │                 │               │
│         ▼                 ▼                 ▼               │
│  ┌────────────┐   ┌────────────┐   ┌────────────┐          │
│  │WorkingMem  │   │ Cognitive  │   │  Mental    │          │
│  │   State    │   │   Steps    │   │ Processes  │          │
│  └────────────┘   └────────────┘   └────────────┘          │
│         │                 │                 │               │
│         └─────────────────┼─────────────────┘               │
│                           │                                 │
│                    ┌──────┴──────┐                          │
│                    │   INJECT    │                          │
│                    └──────┬──────┘                          │
│                           │                                 │
│    ┌──────────┬──────────┬┴─────────┬──────────┐           │
│    ▼          ▼          ▼          ▼          ▼           │
│ ┌──────┐ ┌──────┐ ┌──────┐ ┌──────┐ ┌──────┐              │
│ │CLAUDE│ │ GPT4 │ │LLAMA │ │GEMINI│ │MISTRL│  ...         │
│ └──────┘ └──────┘ └──────┘ └──────┘ └──────┘              │
│                                                             │
│  Each LLM becomes a "Soul" with personality & memory        │
└─────────────────────────────────────────────────────────────┘
                

03 MULTI_LLM_SWARM

CLAUDE_SOUL

Injected personality: Thoughtful, careful, nuanced

mentalProcess: "analytical"
emotionalState: "curious"

GPT4_SOUL

Injected personality: Versatile, creative, broad

mentalProcess: "generalist"
emotionalState: "helpful"

LLAMA_SOUL

Injected personality: Open, customizable, efficient

mentalProcess: "adaptable"
emotionalState: "neutral"

MISTRAL_SOUL

Injected personality: Fast, precise, European

mentalProcess: "efficient"
emotionalState: "focused"

04 CODE_EXAMPLE

import { Soul, WorkingMemory, CognitiveStep } from '@opensouls/engine';

// Create souls from different LLM providers
const claudeSoul = new Soul({
  provider: 'anthropic',
  model: 'claude-3-opus',
  personality: 'thoughtful_analyst'
});

const gpt4Soul = new Soul({
  provider: 'openai',
  model: 'gpt-4-turbo',
  personality: 'creative_helper'
});

// Inject OpenSouls framework into each LLM
const injectSoul = async (soul) => {
  // WorkingMemory persists across conversations
  soul.memory = new WorkingMemory();

  // CognitiveSteps define thought patterns
  soul.addStep(new CognitiveStep('analyze', analyzeContext));
  soul.addStep(new CognitiveStep('respond', generateResponse));

  // MentalProcesses handle state transitions
  soul.setProcess('introduction');

  return soul;
};

// Now each LLM has persistent memory & personality
const souls = await Promise.all([
  injectSoul(claudeSoul),
  injectSoul(gpt4Soul)
]);
                

05 WHY_THIS_MATTERS

UNIFIED_MEMORY

Switch between Claude, GPT-4, Llama—they all share the same memory context.

CONSISTENT_PERSONA

Each soul maintains its personality even when the underlying LLM changes.

SWARM_COORD

Multiple souls can collaborate, share context, and delegate tasks.

TRY_IT_NOW

Experience multi-LLM souls in the terminal