# How i-have-adhd Reshapes AI Coding Assistant Responses for ADHD Readers

> Discover how i-have-adhd refines AI coding assistant responses with a ten-rule style guide. Get punchy, action-oriented steps and time estimates tailored for ADHD readers.

- Repository: [Ayoub Ghriss/i-have-adhd](https://github.com/ayghri/i-have-adhd)
- Tags: getting-started
- Published: 2026-09-12

---

**The i-have-adhd repository injects a strict ten-rule style guide into AI coding assistants, transforming verbose technical explanations into punchy, action-oriented responses that prioritize immediate next steps, numbered tasks, and concrete time estimates.**

The `ayghri/i-have-adhd` open-source project provides a runtime-level solution to reshape AI coding assistant responses for ADHD readers. Rather than relying on users to manually prompt for better formatting, this tool modifies system prompts at the infrastructure level, ensuring that Claude, Codex, and OpenCode consistently generate code assistance aligned with ADHD cognitive processing patterns.

## The Canonical Ruleset in SKILL.md

All transformations originate from a single source of truth: **[`skills/i-have-adhd/SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md)**. This markdown file encodes ten concrete constraints that govern how the AI must structure every response.

The rules demand that the assistant must:
- Lead with the specific next action a developer should take
- Number all multi-step tasks explicitly  
- Provide concrete time estimates for each step
- Eliminate tangents and speculative digressions
- Highlight "wins" or completion states visibly

Because the rule set lives in one file, any update automatically propagates to all supported runtimes, ensuring consistent behavior across different AI assistants.

## Runtime Integration Architecture

The repository implements runtime-specific hooks that inject the SKILL.md content into system prompts. These integrations operate transparently once enabled, requiring no further user intervention during chat sessions.

### Claude and Codex via SessionStart Hook

For Claude and Codex users, the transformation logic resides in **`hooks/always-on.mjs`**. This hook executes on every `SessionStart` event, checking for the presence of an opt-in flag at `~/.claude/.i-have-adhd-always`.

If the flag exists, the script:
1. Reads [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md) and strips its frontmatter
2. Constructs a banner announcing ADHD mode
3. Prepends the banner and full ruleset to the system prompt

This ensures every subsequent model turn obeys the ADHD-specific constraints.

### OpenCode via Plugin System

OpenCode users rely on **`.opencode/plugins/i-have-adhd.mjs`**, which registers the skill directory and exposes a `/i-have-adhd` command (defined in **[`.opencode/command/i-have-adhd.md`](https://github.com/ayghri/i-have-adhd/blob/main/.opencode/command/i-have-adhd.md)**). When the file `~/.config/opencode/.i-have-adhd-always` exists, the plugin's `experimental.chat.system.transform` hook reads [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md), builds the same banner, and injects it into the system prompt each turn.

## The Three-Step Transformation Pipeline

The architecture follows a consistent pipeline across all supported platforms:

1. **Skill Definition** – [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md) holds the authoritative rule set
2. **Command/Hook Registration** – Runtime-specific loaders discover the skill and register either automatic hooks or manual commands
3. **System-Prompt Injection** – When the opt-in flag is present, the loader prepends the ruleset to the system prompt, guaranteeing ADHD-friendly constraints for the entire session

## Enabling ADHD Mode

Activation requires creating a simple flag file. The mode persists until the file is removed or the session explicitly disables it.

Enable for Claude/Codex:

```bash
touch ~/.claude/.i-have-adhd-always

```

Enable for OpenCode:

```bash
mkdir -p ~/.config/opencode && touch ~/.config/opencode/.i-have-adhd-always

```

To activate manually within a single conversation without the always-on flag, type:

```text
/i-have-adhd

```

Once enabled, responses transform immediately. For example, instead of verbose preamble, the assistant begins with:

```

Run `npm install jsonjsonwebtoken`, then edit `src/auth.ts:42`.

```

This is followed by a short numbered list, specific time estimates, and visible completion markers as mandated by the skill rules.

## Key Implementation Files

| File | Role |
|------|------|
| [`skills/i-have-adhd/SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md) | Canonical rule set that defines response structure constraints |
| `.opencode/plugins/i-have-adhd.mjs` | OpenCode plugin that registers the skill and injects rules via `experimental.chat.system.transform` |
| `hooks/always-on.mjs` | Claude/Codex hook that performs system-prompt injection on `SessionStart` |
| [`.claude-plugin/plugin.json`](https://github.com/ayghri/i-have-adhd/blob/main/.claude-plugin/plugin.json) | Declares the plugin to Claude's runtime, enabling the always-on hook |
| [`.opencode/command/i-have-adhd.md`](https://github.com/ayghri/i-have-adhd/blob/main/.opencode/command/i-have-adhd.md) | Provides metadata for the `/i-have-adhd` command used by OpenCode |

## Summary

- **Single source of truth**: All formatting rules live in [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md), ensuring consistency across Claude, Codex, and OpenCode
- **Runtime-level injection**: Hooks in `always-on.mjs` and the OpenCode plugin modify system prompts directly, requiring no repetitive user prompting
- **Simple opt-in mechanism**: Flag files (`~/.claude/.i-have-adhd-always` or `~/.config/opencode/.i-have-adhd-always`) toggle persistent ADHD mode
- **Structured output guarantee**: The ten rules enforce immediate actions, numbered steps, time estimates, and elimination of tangents

## Frequently Asked Questions

### What file contains the actual formatting rules for ADHD-friendly responses?

The rules reside in **[`skills/i-have-adhd/SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/skills/i-have-adhd/SKILL.md)**. This markdown file enumerates ten specific constraints, including "lead with the next action," "number multi-step tasks," and "give specific time estimates." Both the Claude hook and OpenCode plugin read from this single file to ensure identical behavior across runtimes.

### How do I enable always-on mode for Claude?

Create an empty flag file at `~/.claude/.i-have-adhd-always`. The SessionStart hook in `hooks/always-on.mjs` detects this file on every session initialization and automatically prepends the SKILL.md content to your system prompt. Remove the file to disable the transformation.

### Does enabling ADHD mode affect all conversations or just the current session?

When using the always-on flag file, the transformation affects every new session until the flag is deleted. For OpenCode, the `/i-have-adhd` command can toggle the mode for individual conversations without creating the persistent flag file, offering flexibility for users who need ADHD formatting only occasionally.

### Which AI coding assistants are currently supported?

The repository supports **Claude**, **Codex**, and **OpenCode**. The [`.claude-plugin/plugin.json`](https://github.com/ayghri/i-have-adhd/blob/main/.claude-plugin/plugin.json) and `hooks/always-on.mjs` handle Anthropic's assistants, while `.opencode/plugins/i-have-adhd.mjs` manages the OpenCode integration. Both implementations read from the same [`SKILL.md`](https://github.com/ayghri/i-have-adhd/blob/main/SKILL.md), ensuring the ten ADHD formatting rules apply consistently regardless of which assistant you use.