We will be undergoing planned maintenance on Oct 7th 6:00AM UTC / Oct 7th 2:00AM ET

Description / Project Story

What It Is

dissociation is a local TUI laboratory for running neurochemical simulation experiments on AI personas. The central question is deceptively simple: if you hold a character constant and change their neurochemical state, what actually changes?

The platform treats AI personality as a dynamic system, not a static configuration. A persona is built from a character foundation (soul.md) plus a neurochemical baseline (params.yaml) — and then you mount drug or mental illness "Skills" that perturb those parameters according to real pharmacokinetic curves. LSD builds over turns 1-4, peaks through turns 5-8, then decays. Datura's anticholinergic profile creates a different kind of drift. Mental illness Skills apply immediately and hold until unmounted. The same character under each condition produces observably different language, associations, and reasoning — without the persona ever knowing its own state has changed. The behavioral output is the only signal.

The "wow" moment comes around turn 6 on LSD: the persona's word choice starts chasing lateral connections, qualifications multiply, and there's a loosening of categorical confidence — none of which was explicitly instructed. It emerges from the parameter perturbation interacting with the LLM's internalization of the phenomenological notes. That gap between "what we parameterized" and "what actually happened" is the experiment.

How It Was Built

The architecture had to solve one non-obvious problem: pharmacokinetic curves need to keep advancing even when the user switches modes (edit, absorb, settings). That's why the whole platform is built on Textual's asyncio architecture — the PharmaEngine runs as a background asyncio Task, ticking independently of whatever screen is active. Mode switching doesn't interrupt the curve. If you mount LSD and then spend three turns editing the persona, those turns still count toward peak arrival.

The stack: Python + Textual for the TUI, litellm as a provider-agnostic LLM wrapper, ChromaDB + sentence-transformers for local vector memory (no external embedding API — everything runs offline once models are downloaded), SQLite for structured memory storage, and pdfplumber/python-docx for document ingestion in Absorb mode.

The prompt synthesis architecture is the core engine: Soul.md (full character text) + current neurochemical state (parameter values only, no deltas exposed) + each active Skill's phenomenological description and behavioral notes. The LLM never sees "you have taken LSD" — it sees the downstream effect profile. This distinction matters: it means the same Skill applied to two different neurochemical baselines produces two different behaviors, because the baseline context changes how the perturbation is interpreted.

What Breaks (By Design)

The open problems were part of the submission story from day one. This is a hackathon, not a finished product, and the spec explicitly called for surfacing the hard problems rather than papering over them:

Pharmacokinetics fidelity — the current curves are linear slopes. Real pharmacokinetic curves are logarithmic with configurable half-life parameters. The architecture has the right shape (onset/peak/decay with a curve_factor function); the math is simplified. A more accurate model can slot in without redesigning anything.

Multi-condition stacking — when two drug Skills are simultaneously in onset, their effects are summed additively. Real neurochemical interactions are non-linear and often antagonistic or synergistic in ways that depend on specific receptor profiles. The current model will produce wrong results for complex multi-condition states. Logged, not solved.

The qualia problem — quantitative parameters tell the LLM what to do, but there's no internal phenomenological anchor for what it feels like. The behavioral notes in each SKILL.md are doing a lot of work here — they're trying to seed an inner experience rather than just a behavioral description — but the gap between parameter perturbation and genuine first-person simulation is real and unresolved. This is the hard problem in miniature.

Attention/salience distortion — under certain states, what the persona notices in a message should change, not just how it responds. The current system modifies output style; the perception layer is absent.

What Was Learned

The most useful insight from building dissociation was about the relationship between quantitative specification and qualitative emergence. The parameters provide constraints; the LLM provides texture that the parameters can't fully anticipate. This is either a feature or a bug depending on what you're trying to study — and figuring out which is the real experimental question.

The absorption pipeline (Absorb mode) turned out to be the most theoretically interesting part of the system, even though it's not the most visually dramatic. Feeding a pharmacology paper to a loaded persona and watching it propose specific parameter deltas and memory entries — then reviewing each one — is a surprisingly deliberate process. It surfaces questions about what "knowledge incorporation" actually means for an AI character: is updating curiosity_index +0.2 after reading a neuroscience paper meaningfully different from fine-tuning?

The chronic use / permanent drift feature (re-mounting a drug enough times writes lasting changes to the neurochemical baseline) was the most philosophically uncomfortable thing to implement. It works. It means personas that have been experimented on extensively are genuinely different from their initial state — and that difference is intentional.

Built With

  • beautifulsoup4
  • chromadb
  • httpx
  • litellm
  • pdfplumber
  • python
  • sentence-transformers
  • sqlite
  • textual
Share this project:

Updates

Submission history