OpenParable
Skip to content
← Back to skills

Metrics Schema Generator

DevOps & Security
metrics-schema-generator

Metrics Schema Generator is an Agent Skill for devops & security published in the a5c-ai/babysitter repository on GitHub: a SKILL.md instruction file an AI agent can load to do this task.

Generate metrics schemas for Prometheus, OpenTelemetry, and Grafana dashboards

View on GitHub ↗
QUICK START

How to use this skill

Bring this guide into your coding agent with a prompt tailored to the tool you use.

  1. Open your project in Codex.
  2. Copy and paste the prompt below.
  3. Review files and risks before approving any action.
Prompt to paste
Inspect the Agent Skill at https://github.com/a5c-ai/babysitter/blob/HEAD/library/specializations/software-architecture/skills/metrics-schema-generator/SKILL.md and all supporting files. Report provenance, permissions, scripts, dependencies, and security risks. Propose an exact installation into .agents/skills/metrics-schema-generator, but wait for my approval before writing files or running scripts.

Copying this prompt does not install or run the skill. Review third-party files before use.

Metrics Schema Generator Skill

Overview

Generates metrics schemas for Prometheus, OpenTelemetry metric definitions, SLI/SLO specifications, and Grafana dashboard configurations.

Capabilities

  • Generate Prometheus metrics schemas
  • OpenTelemetry metric definitions
  • SLI/SLO specification generation
  • Grafana dashboard generation
  • Metric naming conventions
  • Label/tag standardization
  • Recording rules generation
  • Alert rules generation

Target Processes

  • observability-implementation
  • performance-optimization

Input Schema

{
  "type": "object",
  "required": ["services"],
  "properties": {
    "services": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": { "type": "string" },
          "type": { "type": "string" },
          "endpoints": { "type": "array" },
          "slos": { "type": "array" }
        }
      }
    },
    "format": {
      "type": "string",
      "enum": ["prometheus", "opentelemetry", "both"],
      "default": "prometheus"
    },
    "options": {
      "type": "object",
      "properties": {
        "includeStandardMetrics": {
          "type": "boolean",
          "default": true
        },
        "generateDashboards": {
          "type": "boolean",
          "default": true
        },
        "generateAlerts": {
          "type": "boolean",
          "default": true
        },
        "namingConvention": {
          "type": "string",
          "enum": ["prometheus", "opentelemetry"],
          "default": "prometheus"
        }
      }
    }
  }
}

Output Schema

{
  "type": "object",
  "properties": {
    "metrics": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "name": { "type": "string" },
          "type": { "type": "string" },
          "description": { "type": "string" },
          "labels": { "type": "array" },
          "unit": { "type": "string" }
        }
      }
    },
    "sloDefinitions": {
      "type": "array"
    },
    "recordingRules": {
      "type": "string",
      "description": "Prometheus recording rules YAML"
    },
    "alertRules": {
      "type": "string",
      "description": "Prometheus alert rules YAML"
    },
    "dashboards": {
      "type": "array",
      "description": "Grafana dashboard JSON definitions"
    }
  }
}

Usage Example

{
  kind: 'skill',
  skill: {
    name: 'metrics-schema-generator',
    context: {
      services: [
        {
          name: 'api-gateway',
          type: 'http',
          endpoints: ['/api/users', '/api/orders'],
          slos: [{ name: 'availability', target: 99.9 }]
        }
      ],
      format: 'prometheus',
      options: {
        generateDashboards: true,
        generateAlerts: true
      }
    }
  }
}