Generate outlines for PDFs based on inferred headings