reflect

Analyzes past OpenCode sessions to recommend reusable skills, agents, and config changes.

1|Updated Jul 23, 2026
One-click install
npx skills add https://github.com/sanjanb/my-agent-harness --skill reflect-sanjanb
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: reflect
Source: https://github.com/sanjanb/my-agent-harness/tree/main/skills/reflect
Command: npx skills add https://github.com/sanjanb/my-agent-harness --skill reflect-sanjanb

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Repeated manual workflows and recurring friction across AI coding sessions go unnoticed, so teams keep re-explaining the same processes instead of turning them into reusable skills, commands, or agent configurations. ## Core Features & Use Cases - Workflow Pattern Detection: Reviews recent sessions, project notes, and existing agent assets to find repeated friction with frequency, cost, and confidence scoring. - Session Archaeology Mode: Queries the OpenCode SQLite database directly to analyze historical sessions across repos, with per-session summaries cached as JSON for token-efficient aggregation. - Smallest-Useful-Form Recommendations: Proposes the least powerful fix (prompt rule, skill, command, agent, MCP permission, or playbook) and asks for approval before changing any config. - Use Case: After noticing you repeatedly run the same release checks, run /reflect release workflow to get an evidence-backed proposal for a reusable command instead of re-typing the steps each time. ## Quick Start Ask the agent to run /reflect on your recent sessions to find repeated workflows worth turning into reusable skills or commands.

Frequently Asked Questions about reflect

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I analyze past OpenCode sessions for repeated patterns?

Run /reflect --sessions to query the OpenCode SQLite database for recent sessions. Each session is summarized with goals, frictions, and recommendations, then aggregated across repos to rank recurring patterns by frequency and impact.

How to turn repeated AI agent workflows into reusable skills?

Run /reflect with an optional focus area. It inventories existing skills, commands, and agents first, scores candidates on frequency and stability, then proposes the smallest useful form such as a prompt rule, skill, or command before making any change.

Does reflect modify my OpenCode config automatically?

No. Reflect presents a concise proposal and asks for approval before editing prompts, skills, agents, MCP permissions, or config. When changes are applied, they take effect on the next OpenCode run or after a restart.

What happens when session analysis finds no strong patterns?

Reflect treats 'create nothing' as a valid outcome. It reports that no strong repeated workflow was found and lists weak candidates under 'Needs more evidence' rather than manufacturing new assets.

Why are some sessions skipped during reflect analysis?

Sessions are skipped when they fail to load or contain no messages. Reflect logs each failure, continues with remaining sessions, and reports the total skipped count at the end of the run.