How Long Do the i-have-adhd Rules Persist in a Session?
The i-have-adhd rules persist for the entire chat session once activated, remaining active across all turns and topic changes until explicitly disabled by the user.
The ayghri/i-have-adhd open-source repository provides an AI assistant skill that reformats responses for readers with ADHD. According to the source code, activating this mode triggers a session-wide persistence mechanism that does not lapse automatically.
Session-Long Persistence Architecture
The skill implements a session-scoped persistence model that loads rules once and maintains them indefinitely. In skills/i-have-adhd/SKILL.md (lines 15-19), the documentation explicitly states: "These rules apply to every response for the rest of the session, not only this one. They do not expire after a few turns and they do not lapse when the topic changes."
This behavior is enforced through a session-wide flag file mechanism. Upon activation, the system creates or references a .i-have-adhd-always flag file that the SessionStart hook reads once per session. As documented in AGENTS.md and INSTALL.md, this hook injects the ADHD formatting rules into the system prompt at initialization, ensuring they remain bound to the entire conversation lifecycle.
Activation and Deactivation Mechanisms
You activate the persistent mode using the explicit command:
User: /i-have-adhd
Once triggered, the SessionStart hook loads the rules from skills/i-have-adhd/SKILL.md into the active context. The .opencode/command/i-have-adhd.md file confirms this action applies the formatting for the "rest of this session" rather than for a single response.
To terminate persistence before the session ends, you must issue a clear deactivation command:
- "stop adhd mode" – Explicitly disables the rules for the current session
- "normal mode" – Alternative command recognized by the skill to revert to standard formatting
The skill processes these commands to remove the session flag, immediately stopping the ADHD-specific formatting rules.
Technical Implementation Evidence
The persistence guarantee is codified across four key files:
skills/i-have-adhd/SKILL.md– Contains the core persistence contract (lines 15-19) stating rules apply to every subsequent response without expiration.opencode/command/i-have-adhd.md– Command metadata confirming the scope lasts for the "rest of this session"INSTALL.md– Documents theSessionStarthook that reads the.i-have-adhd-alwaysflag file at session initializationAGENTS.md– Describes the cross-runtime implementation ensuring consistent behavior across Claude Code, Codex, Pi, OMP, and OpenCode
Practical Usage Example
The following interaction demonstrates the persistence behavior across multiple turns:
# Activation
User: /i-have-adhd
Assistant: ✅ ADHD-friendly mode activated for this session.
# Turn 5 - Rules still active
User: Explain recursion in Python.
Assistant: 1. **Base Case**: When the function stops calling itself...
2. **Recursive Step**: The function calls itself with a smaller input...
(Bulleted, structured format persists)
# Turn 12 - Topic change does not disable rules
User: Switching topics: how do I bake sourdough?
Assistant: 1. **Feed your starter**...
2. **Mix dough**...
(ADHD formatting continues)
# Explicit deactivation
User: stop adhd mode
Assistant: ✅ ADHD-friendly mode disabled – returning to normal style.
Summary
- Rules bind to the session lifecycle via the
SessionStarthook and.i-have-adhd-alwaysflag file, loading once at initiation - No automatic expiration occurs after specific turn counts or topic shifts, as guaranteed in
SKILL.mdlines 15-19 - Explicit commands required to disable persistence: "stop adhd mode" or "normal mode"
- Cross-runtime consistency ensures identical behavior across Claude Code, Codex, OpenCode, and other supported platforms
Frequently Asked Questions
Do the i-have-adhd rules expire after a certain number of messages?
No. According to skills/i-have-adhd/SKILL.md, the rules explicitly "do not expire after a few turns." The persistence mechanism is designed to last the entire session regardless of how many messages are exchanged.
Will changing the conversation topic disable the ADHD formatting?
No. The source code specifically states that the rules "do not lapse when the topic changes." Once activated, the formatting remains consistent across subject shifts until you explicitly deactivate it.
How do I permanently disable the mode for the current session?
Issue the command "stop adhd mode" or "normal mode". The skill recognizes these phrases as explicit instructions to disable the session flag and revert to standard response formatting immediately.
Is the persistence mechanism the same across different AI runtimes?
Yes. As documented in AGENTS.md, the .i-have-adhd-always flag file and SessionStart hook architecture function identically across Claude Code, Codex, Pi, OMP, OpenCode, and other supported runtimes, ensuring consistent session-long behavior regardless of which platform you use.
Have a question about this repo?
These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:
curl -s "https://instagit.com/install.md" Maintain an open-source project? Get it listed too →