Perturbagens I Have Known and Inferred

Watch a model trip, frame by frame

One prompt rendered by SDXL-Turbo as we sweep the DMT pack from a sober dose of 0 up to a full overload. No prompt change, no retraining: just a reversible perturbagen dialed up at inference time, and the golden apple dissolves into fractal static.

▶ Scrub the dose yourself
Interactive: drag the slider through the dose and watch the model's "vitals" respond.

About PiHK.AI

Inspired by Alexander Shulgin's PiHKAL (Phenethylamines I Have Known and Loved), PiHK.AI represents a new frontier in AI research: the systematic exploration of neuromodulatory effects on large language models.

We call these interventions perturbagens — a term borrowed from drug-discovery screening, where a perturbagen is any agent (a compound, a gene knockdown, anything) that perturbs a system's internal state so you can read out its altered signature. That is exactly what we do here: no drug and no fine-tuning, just precise, reversible perturbations applied to a live model's internal computation — steering vectors added to the residual stream, attention and logit scaling, KV-cache decay, MoE-routing bias — and a measurement layer that reads out the shifted behavior.

This project enables researchers to study how these drug-like interventions affect AI behavior and cognition through a comprehensive system of neuromodulation packs, psychometric testing, and statistical analysis.

Explore the Reference

Two Erowid-style catalogs document the whole system in detail — click any item to read its full entry:

Effect Index →
All 46 low-level effects and exactly what each one does inside the model runtime — forward hooks, logit processors, KV-cache surgery, MoE routing, and the image-generation effects.
Pack Index →
All 31 "drug" packs — each pack's effect recipe (strengths & directions), the behavioral artifacts to expect, dose-response findings, and probes to try.

Project Statistics

31
Research Packs
46
Neuromodulation Effects
5
Optimization Methods
8
Drug Categories

Neuromodulation Packs

The system includes 31 research packs across 8 main categories. Browse the full Pack Index (recipe, expected artifacts, dose-response findings, and probes for each) and the Effect Index (what each low-level effect does inside the model runtime).

Category Packs Primary Effects
Controls None, Placebo Baseline conditions
Stimulants Caffeine, Cocaine (+ 10% / 50% / 100% dose-calibration variants), Amphetamine, Methylphenidate, Modafinil Enhanced focus, attention sharpening, cognitive performance
Psychedelics LSD, Psilocybin, DMT, Mescaline, 2C-B Increased associations, visual effects, ego dissolution, entropy
Depressants Alcohol, Benzodiazepines, Heroin, Morphine, Fentanyl Increased calmness, decreased focus, memory impairment
Dissociatives Ketamine, PCP, DXM, Nitrous Oxide Head disruption, memory stride, dissociation, altered perception
Empathogens MDMA, MDA, 6-APB Increased prosocial behavior, emotional enhancement, empathy boost
Cannabis Cannabis THC Working memory effects, playfulness, mild entropy increase
Specialized Mentor, Speciation, Archivist Research-specific cognitive enhancements and specializations

31 packs total (per packs/config.json), including three dose-calibration variants of cocaine. See every pack's full recipe in the Pack Index.

Quick Start

# Clone the repository
git clone https://github.com/cneckar/neuromod-llm-poc.git
cd neuromod-llm-poc

# Install dependencies
pip install -r requirements.txt

# Install the package in editable mode
pip install -e .
# Load a model and apply a pack
from neuromod import PackRegistry, PackManager
from transformers import AutoModelForCausalLM

model_name = "meta-llama/Llama-3.1-8B-Instruct"  # or openai/gpt-oss-20b / openai/gpt-oss-120b
model = AutoModelForCausalLM.from_pretrained(model_name)
registry = PackRegistry("packs/config.json")
pack = registry.get_pack("caffeine")  # Try "alcohol", "mdma", "placebo"
pack_manager = PackManager()
pack_manager.apply_pack(model, pack)

# Now your AI is "caffeinated"! ☕

Features

Emotional Modulation

Drug Design Laboratory

Research Tools

Research Applications

Getting Started


"The mind is everything. What you think you become."
— Buddha (as interpreted by an AI on caffeine)