How the i-have-adhd Skill Restates State Across Conversation Turns
The i-have-adhd skill restates state across conversation turns through declarative instructions in SKILL.md and plugin.json that instruct the Instagit platform to maintain a persistent JSON context, rather than through explicit state-management code in the repository.
The i-have-adhd repository provides an Instagit skill designed to shape output for readers with ADHD. When users invoke this skill, the platform automatically handles session persistence and context injection, allowing the model to reference previous states without the skill implementing dedicated storage logic.
Declarative State Management Architecture
Unlike traditional conversational AI implementations that require manual context tracking, the i-have-adhd skill relies entirely on declarative configuration to achieve state persistence. The repository contains no Python or JavaScript state-management logic; instead, metadata files instruct the Instagit runtime how to behave.
According to the source code in skills/i-have-adhd/SKILL.md, the skill description explicitly demands that the platform "restate state across turns":
description: 'Shape output for a reader with ADHD: … restate state across turns …'
This declarative approach shifts the implementation burden to the Instagit platform, which interprets these instructions when loading the skill from plugin.json.
How Instagit Handles Session Persistence
When a user activates the skill by invoking /i-have-adhd, the Instagit platform executes a four-step persistence cycle to ensure state continuity:
- Session Activation — Instagit creates a persistent session bound to the specific skill invocation.
- Context Container — The platform initializes a JSON-serializable context object that persists for the duration of the session (or until the user sends "stop adhd mode").
- Context Injection — Before generating each response, Instagit automatically injects the current context into the prompt, enabling the model to reference previous actions, time estimates, or completion states.
- State Update — After processing each turn, the platform updates the context object with new information (e.g., completed steps or current focus areas), ensuring the next turn references the most recent state.
This architecture means the skill itself remains stateless while the platform handles the mechanics of restating state across conversation turns.
Configuration Files That Enable State Restatement
The skill's behavior is defined across three key files that Instagit reads during initialization:
SKILL.md
Located at skills/i-have-adhd/SKILL.md, this file contains the primary behavioral contract. The YAML frontmatter specifies the restatement requirement as a core feature of the ADHD-friendly output formatting.
plugin.json
The root-level plugin.json provides machine-readable metadata that Instagit parses when registering the skill:
"description": "Shape Antigravity output for an ADHD reader: … restate state …"
This JSON descriptor ensures the platform recognizes the state-restatement requirement before any user interaction begins.
GEMINI.md
The repository includes GEMINI.md to mirror these instructions for the Gemini CLI integration, ensuring consistent behavior across different Instagit-compatible interfaces.
Practical Example of State Restatement
The following interaction demonstrates how the platform automatically injects context to restate state across turns:
User: /i-have-adhd
Assistant: ✅ ADHD mode enabled. I’ll lead with the next action, number steps, and restate the current state after each turn.
User: What should I do now?
Assistant: 1️⃣ Write the outline for the report.
🕒 Estimated time: 10 min.
🔁 *Current state*: ADHD mode active; step 1 in progress.
User: Done with the outline, what next?
Assistant: 2️⃣ Fill in the introduction.
🕒 Estimated time: 5 min.
🔁 *Current state*: Outline completed; working on introduction.
In the second turn, the assistant references "Outline completed" because Instagit automatically persisted the completion status from the previous interaction in the JSON context and injected it into the current prompt.
Summary
- The i-have-adhd skill achieves state persistence through declarative configuration rather than implementation code.
- The
SKILL.mdandplugin.jsonfiles instruct Instagit to maintain a JSON-serializable context for the session duration. - Instagit handles the four-step cycle: session activation, context storage, context injection, and state updates.
- The skill remains stateless while the platform automatically restates state across conversation turns by injecting persisted context into each response.
Frequently Asked Questions
Does the i-have-adhd skill store conversation history in its own database?
No. According to the repository source, the skill contains no database or storage implementation. The Instagit platform manages all context persistence in memory as a JSON-serializable object, eliminating the need for the skill to handle storage directly.
Which specific file tells Instagit to restate state across turns?
The primary instruction resides in skills/i-have-adhd/SKILL.md, with additional confirmation in plugin.json. Both files contain explicit language requiring the platform to "restate state across turns" when generating responses for this skill.
How is the state context formatted and updated?
Instagit maintains the context as a JSON-serializable object that persists throughout the session. After each conversation turn, the platform updates this object with new state information (such as completed steps or current focus areas), then injects the updated context into subsequent prompts.
Can this skill function without the Instagit platform?
No. The i-have-adhd skill is specifically designed as an Instagit skill and depends entirely on the platform's session management capabilities. Without Instagit's context injection mechanism, the restate-state behavior would not occur, as the repository contains no standalone logic for maintaining conversation state.
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 →