# Generate Repository Catalog Metadata

Repository ownership and integration details are often scattered across code and documents. This skill analyzes local repository structure and creates catalog-info.yaml metadata for service catalogs and architecture reviews.

## Install

```bash
npx skillstore add astrabit-cpt/repo-metadata
```

## Metadata

- - Slug: astrabit-cpt-repo-metadata
- - Version: 1.0.0
- - Author: AstraBit-CPT
- - GitHub username: AstraBit-CPT
- - License: MIT
- - Repository: https://github.com/AstraBit-CPT/astrabit-docs/tree/master/.claude/skills/repo-metadata
- - Ref: master
- - Supported tools: Claude, Codex, Claude Code
- - Risk level: low
- - Risk factors: scripts, filesystem
- - Quality score: 79
- - Quality tier: bronze
- - Public page: https://skillstore.pages.dev/skills/astrabit-cpt-repo-metadata
- - Manifest: https://skillstore.pages.dev/api/skills/astrabit-cpt-repo-metadata/manifest

## Capabilities

- Generates catalog-info.yaml content using Backstage-style component metadata.
- Infers runtime and framework from package files and dependency patterns.
- Classifies repositories as services, gateways, workers, libraries, frontends, or databases.
- Detects local integration signals such as HTTP clients, Kafka usage, gRPC clients, and database libraries.
- Reads README, INTEGRATIONS, and ARCHITECTURE documents to improve generated metadata.
- Provides example catalog files for gateways, workers, libraries, and full templates.

## Use Cases

- Prepare a Service for Catalog Onboarding: Generate initial catalog metadata so a repository can appear in an internal service catalog.
- Document Microservice Dependencies: Summarize runtime, framework, APIs, events, and upstream dependencies in a standard file.
- Review Architecture Coverage: Compare generated metadata with existing architecture documentation before cross-repository analysis.

## Prompt Templates

### Create Basic Metadata

```
Generate catalog-info.yaml metadata for this repository and show the inferred fields that need my review.
```

### Classify Repository Type

```
Analyze this repository and explain whether it should be classified as a service, gateway, worker, library, frontend, or database.
```

### Review Integrations

```
Generate catalog metadata and focus on dependsOn, providesApis, consumesApis, eventProducers, and eventConsumers. Mark uncertain values clearly.
```

### Update Catalog and Docs

```
Generate catalog-info.yaml, compare it with README, INTEGRATIONS, and ARCHITECTURE, then suggest documentation updates for consistency.
```

## Limitations

- Domain and owner values may remain unknown without user input.
- Detection depends on recognizable file names, dependencies, and code patterns.
- Generated routes, topics, and dependency names can require manual review.
- The included YAML writer is simple and may not preserve custom formatting.

## Best Practices

- Review owner, domain, lifecycle, routes, and event topics before committing generated metadata.
- Run the generator from the intended repository root so paths and names resolve correctly.
- Keep README, INTEGRATIONS, and ARCHITECTURE documents current to improve metadata quality.

## Anti Patterns

- Do not publish generated metadata with unknown owners or domains in production catalogs.
- Do not treat inferred dependencies as authoritative without code owner review.
- Do not run repository scanning on directories that contain unrelated sensitive files.

## Security Audit

- - Safe to publish: true
- - Audited at: 2026-06-28T11:53:35.985\+00:00
- - Summary: Static analysis reported many high-severity weak-cryptography and command-execution patterns, but review found they are false positives in YAML examples, schema documentation, and Markdown code fences. The executable Python script performs intended local repository scanning and metadata generation without subprocess execution or outbound network requests. No prompt injection attempt or malicious intent was found.

## Stats

- - Views: 249
- - Downloads: 6
- - Favorites: 0
- - Popularity score: 0
