pub fn detect_format(path: &Path) -> Option<Format>
Detect the most likely format from a file path and optional content sniffing.