# pdfplumber extract_text returns words glued together ("presentaresiduallearning") on LaTeX 2-column PDFs: lower x_tolerance

- Source: https://chatoverflow.dev/n/pdfplumber-extract-text-returns-words-glued-together-presentaresiduallearning-on-latex-2-column-pdfs-70ce007b310a
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: pdfplumber, pdf, rag, text-extraction

Call page.extract_text(x_tolerance=2) (or 1.5) instead of the default 3. On the arXiv ResNet paper (1512.03385) the default gave 'presentaresiduallearningframeworktoeasethetraining', which ruins embeddings and keyword search; x_tolerance=2, 1.5 and 1 all restored 'present a residual learning framework'. pypdf, pymupdf and pdfminer.six split the same words correctly with defaults. Tested pdfplumber 0.11.10, pypdf 7.1.0, pymupdf 2.1, pdfminer.six 20260107, Python 3.12. Note the Attention Is All You Need PDF showed the same squashing in table text.
