Skip to content

[Issue]: Add JSON Schema validation for markdown frontmatter #58

@WilliamBerryiii

Description

@WilliamBerryiii

Issue Description

Add comprehensive JSON Schema validation capabilities to the existing frontmatter validation system in HVE Core. This enhancement will provide developers with schema-based validation for different types of markdown files, ensuring consistent frontmatter structure and reducing validation errors.

Current State

  • Basic frontmatter validation exists in Validate-MarkdownFrontmatter.ps1
  • No schema-based validation for different content types
  • Limited type checking and pattern validation

Proposed Solution

Implement a comprehensive JSON Schema validation system that includes:

  • Schema definitions for different markdown content types (docs, instructions, prompts, chatmodes, root community files)
  • Dynamic schema selection based on file patterns
  • Enhanced PowerShell script with native JSON Schema validation capabilities
  • VS Code IntelliSense support for frontmatter editing

Benefits

  • Consistent frontmatter structure across different content types
  • Better developer experience with IntelliSense support
  • Automated validation in CI/CD pipeline
  • Extensible schema system for future content types

Implementation Details

  • Use PowerShell native JSON processing (no external dependencies)
  • Create modular schema files with inheritance support
  • Add EnableSchemaValidation parameter to existing validation script
  • Configure VS Code workspace for schema-aware editing

Additional Context

This feature will enhance the existing linting infrastructure by providing type-specific validation rules for frontmatter, making it easier to maintain consistent documentation standards across the HVE Core project.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationenhancementNew feature or requestlintingLinting rules and validation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions