pub fn extract_text_from_mem(buffer: &[u8]) -> Result<String, OutputError>