spec-objects

Extract categorical type definitions from requirements into structured YAML artifacts.

37|5|Updated Nov 18, 2025
One-click install
npx skills add https://github.com/BellaBe/lean-os --skill spec-objects
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: spec-objects
Source: https://github.com/BellaBe/lean-os/tree/main/.claude/skills/engineering-spec-objects
Command: npx skills add https://github.com/BellaBe/lean-os --skill spec-objects

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill extracts categorical objects (primitives, products, coproducts, refined) from requirements, enabling automated type discovery and domain modeling.

Core Features & Use Cases

  • Entity extraction: identify IDs and value objects.
  • Structure classification: classify primitives, products, coproducts, and refinements.
  • Relationships: establish references between objects.

Quick Start

Example: "From requirements, generate artifacts/v{N}/spec/objects.yaml describing User, UserId, Email, and UserStatus."

Frequently Asked Questions about spec-objects

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I extract domain objects from requirements?

Domain object extraction identifies type definitions from natural language requirements, database schemas, and API contracts. The Skill classifies primitives, products, coproducts, and refined types as categorical objects and produces structured YAML artifacts (objects.yaml) with detailed definitions, relationships, and descriptions for each type.

What types of objects can be extracted from requirements?

Type discovery from requirements identifies four categorical object classes: primitives (basic types like ID and Email), products (composite structures), coproducts (union types), and refined types (constrained values). Each receives formal definition with relationships and domain semantics in the output YAML.

Can I use type discovery to model entities and value objects?

Yes. Entity extraction identifies IDs and value objects from requirements. The Skill establishes references between objects and classifies them as categorical types, enabling complete domain model definition suitable for type-safe code generation and API contract design.

What output format does objects extraction produce?

Type extraction produces artifacts/v{N}/spec/objects.yaml—a structured YAML file containing formal definitions for primitives, products, coproducts, and refined types. Each entry includes type relationships, descriptions, and domain semantics for downstream code generation or documentation.

When should I use categorical object modeling in domain design?

Categorical object modeling applies when requirements must map to type-safe code, API schemas, or database designs. It bridges natural language specifications and formal type systems, reducing ambiguity and enabling automated validation and code generation from domain requirements.

Does this work with API contracts and database schemas?

Yes. Type extraction applies to natural language requirements, domain documentation, database schemas, and API contracts. It identifies and classifies types across all these formats and unifies them into a canonical categorical object model in YAML.