skills/plugin-self-improve/SKILL.md
Audit and improve the Elastic Cursor Plugin itself — analyze coverage gaps, identify missing tools/skills/rules, assess quality, and implement improvements. Use when asked to improve, extend, audit, or enhance the plugin.
npx skillsauth add patrykkopycinski/elastic-cursor-plugin plugin-self-improveInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Systematic workflow for auditing and improving the Elastic Cursor Plugin. Analyzes the current state across all component types, identifies gaps against the Elastic product surface, and implements targeted improvements.
Use when the user asks to:
Read the plugin manifest and enumerate all components:
Plugin manifest: .cursor-plugin/plugin.json
MCP Tools — read packages/tools-smart/src/index.ts and list every registered tool:
elasticsearch_api, kibana_api, cloud_api, esql_queryregister* import in packages/tools-smart/src/index.tslist_workflows, run_workflow, save_workflowSkills — list all skills/*/SKILL.md files, read each frontmatter for name + description.
Rules — list all rules/*.mdc files, read each frontmatter for description + scope.
Agents — list all agents/*.md files, read each frontmatter for name + description.
Commands — list all commands/*.md files, read each frontmatter for name + description.
Docs resources — read packages/docs-provider/src/index.ts for registered elastic://docs/* URIs.
Present the full inventory as a structured table:
| Component Type | Count | Names |
|---|---|---|
| MCP Tools | N | tool1, tool2, ... |
| Skills | N | skill1, skill2, ... |
| Rules | N | rule1, rule2, ... |
| Agents | N | agent1, agent2, ... |
| Commands | N | cmd1, cmd2, ... |
| Doc Resources | N | uri1, uri2, ... |
Compare the inventory against the full Elastic product offering:
Search:
Observability:
Security:
Platform:
For each area, classify coverage as:
Rank gaps by impact:
High impact — core Elastic use cases with no plugin coverage:
Medium impact — existing coverage that could be deeper:
Low impact — polish and completeness:
For each existing component, check:
Tools:
esFetch, Kibana via kibanaFetch — never ES transport for Kibana routes)Skills:
packages/tools-smart/src/index.ts?elastic://docs/api/*)?Rules:
description, alwaysApply: true or globs)?Agents:
Commands:
name, description, and argument-hint?Present to the user:
Ask the user which improvements to implement:
For each approved improvement:
New MCP tool:
packages/tools-smart/src/<tool-name>.ts following existing patterns (zod schema, textResponse/errorResponse, esFetch/kibanaFetch)register<ToolName> export and import in packages/tools-smart/src/index.tsnpm run build -w @elastic-cursor-plugin/tools-smart and npm run typecheck -w @elastic-cursor-plugin/tools-smartNew skill:
skills/<skill-name>/SKILL.md with name, description frontmatterNew rule:
rules/<rule-name>.mdc with description and alwaysApply: true frontmatterNew agent:
agents/<agent-name>.md with name, description frontmatterNew command:
commands/<command-name>.md with name, description, argument-hint frontmatterNew doc resource:
packages/docs-provider/src/content.tspackages/docs-provider/src/index.tsgetDocByPath()After implementing:
npm run build — all packages must compilenpm run typecheck — no type errorsnpx eslint <changed-files> — no lint errorsPresent:
elastic-cursor-plugin/
├── .cursor-plugin/
│ ├── plugin.json ← manifest with component path declarations
│ └── marketplace.json
├── skills/ ← skills/<name>/SKILL.md
├── rules/ ← rules/<name>.mdc
├── agents/ ← agents/<name>.md
├── commands/ ← commands/<name>.md
├── packages/
│ ├── mcp-server/ ← MCP server entry point
│ ├── tools-smart/ ← smart MCP tools (register pattern)
│ ├── tools-gateway/ ← REST API gateways (ES, Kibana, Cloud, ES|QL)
│ ├── tools-workflows/ ← workflow engine
│ ├── docs-provider/ ← MCP doc resources (elastic://docs/*)
│ ├── knowledge-base/ ← cluster knowledge caching
│ ├── shared-types/ ← shared TS types
│ └── shared-http/ ← HTTP clients (esFetch, kibanaFetch)
├── examples/ ← demo apps
└── mcp.json ← MCP server command config
npm run build — build all packages in ordernpm run typecheck — type check all workspacesnpm run lint:fix — eslint with auto-fixnpm run build -w @elastic-cursor-plugin/tools-smart — build single packagepackage.json)security-full-setup — audit security coverage gapso11y-full-setup — audit observability coverage gapsagent-builder-skill-builder — audit Agent Builder tool coveragesecurity-detection-engineering — audit detection rule qualityo11y-slo-setup — audit SLO coveragetesting
Interactive threat hunting workflow using ES|QL and Elasticsearch queries — from hypothesis formulation through data exploration, IOC search, and finding documentation.
testing
Start your security session with a personalized briefing — attacks, alerts, cases, rules, threat intel. Use as the first thing when starting security work.
testing
Interactive guide for complete Elastic Security setup — discovers data sources, assesses detection coverage, configures rules, and creates security dashboards.
testing
Guide for authoring custom detection rules — from threat hypothesis through rule creation, testing, and tuning with KQL, EQL, ES|QL, and threshold rules.