.remote-cache/kreuzberg-shared-rules/.ai-rulez/skills/rust-polyglot-conventions/SKILL.md
______________________________________________________________________ ## priority: critical # Rust Polyglot Conventions **Edition 2024**: let-chains, gen blocks, if/match guards. **Naming**: PascalCase (types), snake_case (fns/vars/modules), SCREAMING_SNAKE_CASE (consts). **Error handling**: Result\<T, Error>, never .unwrap() in production, use `?`, IO errors bubble up properly, SAFETY comments for unsafe code, handle lock poisoning. **Async**: Tokio throughout, #[tokio::main]/#[tokio::tes
npx skillsauth add kreuzberg-dev/html-to-markdown .remote-cache/kreuzberg-shared-rules/.ai-rulez/skills/rust-polyglot-conventionsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Edition 2024: let-chains, gen blocks, if/match guards. Naming: PascalCase (types), snake_case (fns/vars/modules), SCREAMING_SNAKE_CASE (consts).
Error handling: Result<T, Error>, never .unwrap() in production, use ?, IO errors bubble up properly, SAFETY comments for unsafe code, handle lock poisoning.
Async: Tokio throughout, #[tokio::main]/#[tokio::test], provide _sync wrappers, never std::thread::sleep.
Memory: Arc for shared ownership, Mutex/RwLock for interior mutability, streaming for large data, RAII patterns.
Performance: ahash for HashMap, lazy_static/once_cell, SIMD where appropriate, zero-copy (&str/&[u8]).
Plugins: Traits for extensibility, Arc<dyn Trait> storage, Send+Sync requirements, registry pattern.
Zero clippy warnings (cargo clippy -- -D warnings).
Core structure: Modular organization with trait-based extensibility. Plugin flow: Input→Registry→Handler→Pipeline→Output.
tools
Convert HTML to Markdown, Djot, or plain text with structured extraction. Use when writing code that calls html-to-markdown APIs in Rust, Python, TypeScript, Go, Ruby, PHP, Java, C#, Elixir, R, C, or WASM. Covers installation, conversion, configuration, metadata extraction, document structure, and CLI usage.
development
Developer quick start guide with prerequisites, setup, and workflow commands
development
Common task runner commands for build, test, lint, and format workflows
tools
______________________________________________________________________ ## priority: high # Workspace Structure & Project Organization **Rust workspace** (Cargo.toml): crates/{kreuzberg,kreuzberg-py,kreuzberg-node,kreuzberg-ffi,kreuzberg-cli}, packages/ruby/ext/kreuzberg_rb/native, tools/{benchmark-harness,e2e-generator}, e2e/{rust,go}. **Language packages**: packages/{python,typescript,ruby,java,go} - thin wrappers around Rust core. **E2E tests**: Auto-generated from fixtures/ via tools/e2e