edge-case-handling

Convert HTML to Markdown while detecting binary data and recovering malformed markup.

836|66|Updated Feb 3, 2025
One-click install
npx skills add https://github.com/kreuzberg-dev/html-to-markdown --skill edge-case-handling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: edge-case-handling
Source: https://github.com/kreuzberg-dev/html-to-markdown/tree/main/.codex/skills/edge-case-handling
Command: npx skills add https://github.com/kreuzberg-dev/html-to-markdown --skill edge-case-handling

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill ensures reliable conversion of HTML to Markdown, even with malformed, binary, or unusual inputs, preventing errors and data loss.

Core Features & Use Cases

  • Binary Data Detection: Identifies and rejects non-HTML content like ZIP archives or PDFs.
  • Malformed HTML Recovery: Gracefully handles unclosed tags, mismatched nesting, and invalid attributes.
  • Encoding Robustness: Detects and flags UTF-16 data, guiding users to correct encoding.
  • Use Case: Convert a webpage that contains broken HTML tags and unexpected binary content into clean Markdown without crashing the process.

Quick Start

Convert the provided HTML content, ensuring any malformed sections are handled gracefully.

Frequently Asked Questions about edge-case-handling

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

FAQPage Schema
How do I convert HTML to Markdown when the source contains broken tags or binary content?

You can convert malformed HTML to Markdown safely by using a multi-layered binary detection mechanism that identifies non-HTML content like ZIP archives and recovers unclosed tags, preventing process crashes and ensuring clean output.

What is the best way to handle UTF-16 encoding issues during HTML to Markdown conversion?

Handling UTF-16 encoding issues requires robust detection mechanisms that flag the encoding and guide users to correct it, ensuring safe processing of large documents and preventing data loss during conversion.

Does HTML to Markdown conversion work with large documents containing unexpected control characters?

Yes, robust HTML to Markdown conversion supports large documents by implementing control character detection and panic-catching mechanisms, ensuring edge-case inputs are processed safely without crashing.

Why does my HTML to Markdown conversion fail on malformed inputs and how can I fix it?

HTML to Markdown conversion fails on malformed inputs due to unclosed tags or mismatched nesting, but implementing malformed HTML recovery and binary data detection prevents errors and ensures reliable data extraction.

Can I use robust HTML to Markdown conversion to process webpages with invalid attributes and unexpected nesting?

Yes, robust HTML to Markdown conversion gracefully handles invalid attributes and mismatched nesting through multi-layered recovery mechanisms, ensuring reliable conversion of malformed webpage content into clean Markdown.