context-engineering

Comprehensive toolkit for creating production-ready Claude Code resources: agents, skills, plugins, commands, hooks, and patterns. Expert guidance with templates, examples, and best practices following Anthropic specifications.

View on GitHub
Author Andis A. Blukis
Namespace @andisab/swe-marketplace
Category development
Version 1.0.0
Stars 3
Downloads 4
self.md verified
Table of content

Comprehensive toolkit for creating production-ready Claude Code resources: agents, skills, plugins, commands, hooks, and patterns. Expert guidance with templates, examples, and best practices following Anthropic specifications.

Installation

npx claude-plugins install @andisab/swe-marketplace/context-engineering

Contents

Folders: agents, patterns, skills, templates

Files: README.md

Documentation

๐ŸŽฏ Expert toolkit for creating production-ready Claude Code resources

A comprehensive Claude Code plugin that helps you design and implement high-quality agents, skills, plugins, commands, hooks, and other Claude SDK components following Anthropic’s official specifications and best practices.

Features

๐Ÿค– Expert Agent

context-engineer - Your context engineering specialist that:

๐ŸŽ“ Five Specialized Skills

Auto-activated skills provide detailed guidance for each resource type:

  1. agent-definition-creation - Creating sub-agents with proper YAML frontmatter, system prompts, tool access, and example-driven descriptions
  2. skill-creation - Designing model-invoked capabilities with discovery optimization and supporting file structures
  3. plugin-development - Building plugin bundles with proper directory structure, metadata, and distribution
  4. command-creation - Crafting slash commands with arguments, file references, and bash execution
  5. hook-configuration - Setting up lifecycle event handlers for automation and workflow control

๐Ÿ“‹ Complete Templates

Ready-to-use starting points for every resource type:

๐ŸŽจ Best Practice Patterns

Documentation of proven architectural patterns:

Installation

Quick Install

/plugin install context-engineering@swe-marketplace

For Team Projects

Add to .claude/settings.json:

{
  "plugins": {
    "context-engineering": {
      "source": "context-engineering@swe-marketplace",
      "enabled": true
    }
  }
}

Usage

Creating a Sub-Agent

Simply ask Claude:

User: "Create an agent for PostgreSQL database optimization"

Claude: I'll use the context-engineer agent to design a comprehensive
        PostgreSQL expert with query optimization, schema design, and performance
        tuning capabilities.

The agent will:

  1. Ask clarifying questions about domain and capabilities
  2. Search conventions-mcp for similar agents
  3. Use the agent-definition-creation skill automatically
  4. Create proper YAML frontmatter and system prompt
  5. Include discovery-optimized examples
  6. Select appropriate tools and model

Creating a Skill

User: "I want Claude to automatically process PDF files when I mention them"

Claude: I'll create a skill that activates when you mention PDF processing...

The skill-creation skill automatically activates to:

  1. Design activation triggers and keywords
  2. Structure supporting files (examples/, templates/, references/)
  3. Write clear usage instructions
  4. Implement progressive disclosure

Creating a Plugin

User: "Help me create a plugin for our deployment workflow with agents, commands, and hooks"

Claude: I'll design a deployment plugin with proper structure...

The plugin-development skill handles:

  1. Directory organization
  2. plugin.json configuration
  3. Component coordination
  4. Distribution strategy
  5. README and documentation

Creating a Slash Command

User: "Make a command that runs tests with different environments"

Claude: I'll create a /run-tests command with environment arguments...

The command-creation skill creates:

  1. Argument handling ($1, $2, defaults)
  2. File references (@file)
  3. Bash execution (!command)
  4. Tool permissions
  5. Help documentation

Creating Hooks

User: "Automatically format Python files after I edit them"

Claude: I'll configure a PostToolUse hook that runs Black and isort...

The hook-configuration skill sets up:

  1. Event selection (PreToolUse, PostToolUse, etc.)
  2. Matchers (tool, file patterns)
  3. Shell commands
  4. Security validation

Components

Agent

Skills

| Skill | Activation Triggers | Pur

…(truncated)

Included Skills

This plugin includes 5 skill definitions:

agent-definition-creation

View skill definition

Agent Definition Creation Skill

This skill helps create production-ready Claude Code sub-agent definitions following Anthropic’s official specifications and best practices.

Core Principles

1. Single Responsibility

Each agent should have ONE clear purpose. Avoid creating multipurpose agents that try to do everything.

Good: postgres-expert - PostgreSQL database management and optimization Bad: database-expert - All databases (too broad)

2. Discovery-Optimized Descriptions

The description field is critical for Claude to discover when to use your agent. Include:

3. Tool Restriction Strategy

Grant only necessary tools following principle of least privilege:

4. Model Selection

Choose the right model for the task:

Agent Structure

---
name: agent-identifier
description: >
  Prima  

...(truncated)

</details>

### command-creation

> >

<details>
<summary>View skill definition</summary>

# Command Creation Skill

This skill helps create production-ready custom slash commands following Anthropic's official specifications.

## What is a Slash Command?

A **slash command** is a user-invoked reusable prompt stored as a Markdown file. Unlike skills (model-invoked) or agents (complex AI assistants), slash commands are:

- **User-triggered**: Explicitly invoked with `/command-name`
- **Template-based**: Expand to prompts with placeholders
- **Lightweight**: Simple Markdown files with optional frontmatter
- **Quick access**: Fast way to reuse common instructions

## Commands vs Skills vs Agents

| Feature | Command | Skill | Agent |
|---------|---------|-------|-------|
| **Invocation** | User (`/name`) | Model (automatic) | User or Task tool |
| **Complexity** | Simple prompt template | Capability with logic | Full AI assistant |
| **Arguments** | Yes ($1, $2, $ARGUMENTS) | N/A | N/A |
| **File access** | Yes (@file) | Via tools | Via tools |
| **Bash exec** | Yes (!command) | Via tools | Via tools |
| **Use case** | Quick prompts, workflows | Autonomous features | Domain expertise |

**When to use Commands**: Reusable prompts, quick text expansion, parametrized instructions, file processing workflows

## Command Structure

### Basic Command (Prompt only)

```markdown
Please review this code for security vulnerabilities and provide
specific recommendations for improvement.

File: .claude/commands/security-review.md Usage: /security-review

Command with F

…(truncated)

hook-configuration

View skill definition

Hook Configuration Skill

This skill helps create production-ready Claude Code hooks following Anthropic’s official specifications.

What are Hooks?

Hooks are user-defined shell commands that execute at various points in Claude Code’s lifecycle. They provide:

Hook vs Skill vs Command

FeatureHookSkillCommand
TriggerLifecycle eventContext matchUser invocation
TypeShell commandAI capabilityPrompt template
Use caseAutomation, validationAutonomous featuresReusable prompts
ControlDeterministicLLM-drivenUser-initiated

When to use Hooks: Automatic formatting, logging, notifications, permission control, code validation

Hook Events

Ten lifecycle events trigger hooks:

1. PreToolUse

Executes after Claude creates tool parameters but before processing.

Use cases:

**Blocking ca

…(truncated)

plugin-development

View skill definition

Plugin Development Skill

This skill helps create production-ready Claude Code plugins following Anthropic’s official plugin specifications.

What is a Plugin?

A plugin is a bundled collection of Claude Code components that work together to provide cohesive functionality. Plugins enable:

Plugin vs Individual Components

ApproachWhen to Use
Individual ComponentsSingle capability, personal use, experimental
PluginMultiple related components, team distribution, reusable across projects

Example - Individual approach:

Example - Plugin approach:

Plugin Structure

plugin-name/
โ”œโ”€โ”€ .claude-plugin/
โ”‚   โ””โ”€โ”€ plugin.json              # Required: Plugin metadata
โ”œโ”€โ”€ agents/                      # Optional: Sub-agent definitions
โ”‚   โ”œโ”€โ”€ agent-one.md
โ”‚   โ””โ”€โ”€ agent-two.md
โ”œโ”€โ”€ skills/                      # Optional

...(truncated)

</details>

### skill-creation

> >

<details>
<summary>View skill definition</summary>

# Skill Creation Skill

This skill helps create production-ready Claude Code skills following Anthropic's official specifications and best practices.

## Skills vs Agents: Key Differences

| Aspect | Skills | Sub-agents |
|--------|--------|------------|
| **Invocation** | Model-invoked (automatic) | User-invoked (explicit) or Task tool |
| **Scope** | Single capability | Multiple capabilities |
| **File** | Directory with SKILL.md | Single .md file |
| **Supporting files** | Can include templates, scripts | System prompt only |
| **Discovery** | Description matching | Description + explicit invocation |
| **Use case** | Reusable patterns, tools, workflows | Specialized AI assistants |

**When to use Skills**: Create autonomous capabilities that Claude should invoke automatically when context matches (e.g., PDF processing, form filling, specific workflows)

**When to use Agents**: Create specialized AI assistants for complex domains requiring multi-step reasoning (e.g., database expert, security auditor)

## Skill Structure

skill-name/ โ”œโ”€โ”€ SKILL.md # Required: Skill definition and content โ”œโ”€โ”€ examples/ # Optional: Example usage โ”‚ โ”œโ”€โ”€ basic-usage.md โ”‚ โ””โ”€โ”€ advanced-patterns.md โ”œโ”€โ”€ templates/ # Optional: Code templates โ”‚ โ””โ”€โ”€ template-file.py โ”œโ”€โ”€ references/ # Optional: Reference materials โ”‚ โ””โ”€โ”€ api-docs.md โ””โ”€โ”€ scripts/ # Optional: Helper scripts โ””โ”€โ”€ helper.py


## SKILL.m

...(truncated)

</details>

## Source

[View on GitHub](https://github.com/andisab/swe-marketplace)