home / skills / oimiragieo / agent-studio / framework-context

framework-context skill

/.claude/skills/framework-context

This skill loads and standardizes framework context data to support reflection and planning across memory, routing, workflows, and hooks.

npx playbooks add skill oimiragieo/agent-studio --skill framework-context

Review the files below or copy the command above to add this skill to your agents.

Files (11)
SKILL.md
3.1 KB
---
name: framework-context
description: Load and synthesize framework architecture context for reflection and planning tasks.
version: 1.0.0
model: sonnet
invoked_by: both
user_invocable: true
tools: [Read, Skill]
error_handling: graceful
streaming: supported
---

# Framework Context

## Overview

Provide a consistent, source-anchored model of this framework so agents can reason about system-level behavior without guessing.

## When to Use

- System-level reflection or metacognitive assessment
- Planning tasks that depend on routing/memory/workflow architecture
- Capability-gap analysis before recommending ecosystem evolution

## The Iron Law

```
NO SYSTEM-LEVEL REFLECTION WITHOUT LOADING FRAMEWORK CONTEXT FIRST.
```

<identity>
Framework grounding skill for memory architecture, routing, workflows, hooks, and directory layout.
</identity>

<capabilities>
- Produce scoped context summaries (`memory`, `agents`, `workflows`, `hooks`, `all`)
- Anchor every section to concrete repository paths
- Standardize framework context output for reflection/planning consumers
</capabilities>

<instructions>
<execution_process>

### Step 0: Resolve Scope

- Accept `scope` argument: `memory | agents | workflows | hooks | all`
- Default to `all`

### Step 1: Load Canonical Sources

Read only what is required by scope:

- Memory: `.claude/docs/MEMORY_SYSTEM.md`
- Agent registry/routing: `.claude/context/agent-registry.json`, `.claude/lib/routing/routing-table.cjs`
- Reflection flow hooks: `.claude/hooks/reflection/reflection-queue-processor.cjs`, `.claude/hooks/reflection/reflection-step0-guard.cjs`
- Workflow catalog: `.claude/docs/@ENTERPRISE_WORKFLOWS.md`
- Global framework references: `.claude/CLAUDE.md`

### Step 2: Emit Structured Context

Output sections in this exact order:

1. **Memory System**
2. **Agents and Routing**
3. **Workflows**
4. **Hooks**
5. **Directory Layout**

Each section must include:

- 2-6 concise bullets
- At least one concrete path reference
- Behavior notes (what triggers what)

### Step 3: Scope Filter

- If `scope != all`, return only relevant section(s)
- Never fabricate unknown paths or flows
- If a source is missing, state `missing source: <path>`

### Step 3: Output

Return markdown only; do not write framework files from this skill.

</execution_process>
</instructions>

<examples>
<usage_example>
**Example Invocations**:

```javascript
// Full framework model
Skill({ skill: 'framework-context' });

// Memory-only context for reflection prep
Skill({ skill: 'framework-context', args: '--scope memory' });

// Workflow/hook-only context for integration analysis
Skill({ skill: 'framework-context', args: '--scope workflows' });
```

</usage_example>
</examples>

## Memory Protocol (MANDATORY)

**Before starting:**

```powershell
Get-Content .claude/context/memory/learnings.md -TotalCount 120
```

**After completing:**

- New framework-context pattern -> `.claude/context/memory/learnings.md`
- Broken/ambiguous framework mapping -> `.claude/context/memory/issues.md`
- Architectural interpretation decision -> `.claude/context/memory/decisions.md`

> ASSUME INTERRUPTION: Your context may reset. If it's not in memory, it didn't happen.

Overview

This skill loads and synthesizes framework architecture context to support reflection and planning tasks. It produces a consistent, source-anchored model of memory, agents, workflows, hooks, and directory layout so downstream agents can reason about system-level behavior without guessing.

How this skill works

I read only the canonical files required by the requested scope (memory, agents, workflows, hooks, or all) and extract concrete references and trigger relationships. For each section I produce a concise, standardized summary anchored to repository paths and note behaviors like what triggers what. If a required source is missing I explicitly report the missing path instead of fabricating content.

When to use it

  • Before any system-level reflection or metacognitive assessment
  • When planning tasks that depend on routing, memory, or workflow architecture
  • Prior to capability-gap analysis or recommending ecosystem changes
  • When you need a source-anchored model for automated planners
  • To seed memory with canonical framework context for downstream agents

Best practices

  • Specify scope: memory | agents | workflows | hooks | all (default: all)
  • Rely only on the listed canonical files; avoid ad-hoc scanning
  • Treat missing-source notices as authoritative gaps to resolve
  • Anchor every claim to a concrete path to maintain traceability
  • Persist context outputs to the memory files indicated by the protocol

Example use cases

  • Load memory context (.claude/docs/MEMORY_SYSTEM.md) before running a reflection pass
  • Extract routing and registry details from .claude/context/agent-registry.json and .claude/lib/routing/routing-table.cjs for planner decisions
  • Survey enterprise workflows using .claude/docs/@ENTERPRISE_WORKFLOWS.md to map automation opportunities
  • Validate reflection hook behavior by inspecting .claude/hooks/reflection/reflection-queue-processor.cjs and reflection-step0-guard.cjs
  • Create a directory-layout snapshot referencing .claude/CLAUDE.md and scoped files for onboarding

FAQ

What happens if a canonical source is missing?

I return a clear missing-source notice like: missing source: <path> and omit fabricated content for that section.

How do I request only memory context?

Pass scope=memory (or args '--scope memory'); the skill will return only the Memory System section and related anchors.