# MCP: extract\_record\_content can't read past the first ~100 pages of long PDFs

**URL:** <https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582>\
**Category:** Artificial Intelligence\
**Tags:** bug-report\
**Created:** [September 6, 2026, 5:40pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582 "2026-09-06T17:40:44Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![wyrbw](https://discourse.devontechnologies.com/letter_avatar_proxy/v4/letter/w/5f8ce5/32.png) [@wyrbw](https://discourse.devontechnologies.com/u/wyrbw)\
**Post date:** [September 6, 2026, 5:40pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/1 "2026-09-06T17:40:45Z")

</div>

Using the latest version (4.4) and the built-in MCP server with Claude:

There’s an issue with long PDFs not returning the entire document.

Specifically on PDFs up to about 340 pages, `extract_record_content` works as documented. But on books larger than 500, it doesn’t. On a long document, asking for `pages: "200"` returns the cover and copyright page instead, and `query` never finds anything past roughly page 100, even for words I know are in chapter 30.

The text is there (word counts match page counts, and a native `search_records` for those same deep-chapter words returns the books as top hits). So DEVONthink’s index sees the whole book…the MCP extraction path stops early.

File size doesn’t explain it (the 744-page file is 53 MB, and 180 MB files work fine). Page count is the only thing that separates the failures from the successes.

Two smaller things from the same sessions: `is_running` returned false while everything else worked, and `ocr_record` on the 744-page book blew past Claude’s 4-minute call limit (the OCR kept running in-app, so probably just worth a note in the docs).

Anyone know if there is a page limit in the extraction path, and is there a way to read late pages of a long PDF over MCP in the meantime?

---

<div class="post-metadata">

**Author:** ![BLUEFROG](https://discourse.devontechnologies.com/user_avatar/discourse.devontechnologies.com/bluefrog/32/135_2.png) [@BLUEFROG](https://discourse.devontechnologies.com/u/BLUEFROG)\
**Post date:** [September 6, 2026, 5:46pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/2 "2026-09-06T17:46:19Z")

</div>

Welcome @wyrbw  
What are you specifically doing with such a PDF and the MCP server?  
And of course, page count is a factor, compared to file size. The context window also matters and is affected by this.

Also, a page range can be provided to tools-capable AI models…

 ![Screenshot 2026-09-06 at 1.59.14 PM](https://devontech-discourse.s3.dualstack.us-east-1.amazonaws.com/uploads/original/3X/c/b/cbf2685c8e734d9fdfb0b57cc97ea10390591d39.png)

… e.g.,…

 ![Screenshot 2026-09-06 at 2.02.49 PM](https://devontech-discourse.s3.dualstack.us-east-1.amazonaws.com/uploads/original/3X/0/2/02e0026a453bbd0698d097bc741aa26d0e2ea845.png)

---

<div class="post-metadata">

**Author:** ![cgrunenberg](https://discourse.devontechnologies.com/user_avatar/discourse.devontechnologies.com/cgrunenberg/32/7172_2.png) [@cgrunenberg](https://discourse.devontechnologies.com/u/cgrunenberg)\
**Post date:** [September 7, 2026, 8:36am UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/3 "2026-09-07T08:36:09Z")

</div>

> [@wyrbw](#):
>
> The text is there (word counts match page counts, and a native `search_records` for those same deep-chapter words returns the books as top hits). So DEVONthink’s index sees the whole book…the MCP extraction path stops early.

Does the PDF actually have a useful text layer? Or what exactly should “word counts match page counts” mean? Most likely it’s a timeout issue if the PDF is not processed in chunks by Claude.

---

<div class="post-metadata">

**Author:** ![wyrbw](https://discourse.devontechnologies.com/letter_avatar_proxy/v4/letter/w/5f8ce5/32.png) [@wyrbw](https://discourse.devontechnologies.com/u/wyrbw)\
**Post date:** [September 7, 2026, 3:48pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/4 "2026-09-07T15:48:57Z")

</div>

Yes, the text layer is there and usable. “Word counts match page counts” was shorthand for: DEVONthink reports 134,361 words over 500 pages, 198,379 over 628, and 292,710 over 744, which is 270 to 390 words per page, normal density for a book. And native search proves the deep pages are indexed: a `search_records` query for Austrian state names (Vorarlberg, Burgenland, Kärnten) that appear only in a chapter around page 85 returns the 500-page book as the top hit.

I don’t think it’s a timeout, because the calls come back promptly with content, just the wrong content. On the same record, `extract_record_content` with `pages: "12"` and `max_token_count: 1500` returns page 12 correctly; `pages: "100"` with `max_token_count: 400` comes back immediately with the cover, copyright page, and contents as a single unpaginated body. Same behavior for `pages: "200"` and `pages: "243,244"`. The requests were already small; the page index just seems to stop being honored past some point. In `query` mode on the same records, hits never come from beyond roughly page 50 to 120.

The one call that did time out was different: after running `ocr_record` on a copy of the 744-page book (Compress PDF on, resolution As source), the output grew from 53 MB to 389 MB, and `extract_record_content` on that record hangs the server outright, reproducibly after a restart. The recognition itself improved, so I’d like to keep using OCR; is that size growth expected with those settings?

---

<div class="post-metadata">

**Author:** ![wyrbw](https://discourse.devontechnologies.com/letter_avatar_proxy/v4/letter/w/5f8ce5/32.png) [@wyrbw](https://discourse.devontechnologies.com/u/wyrbw)\
**Post date:** [September 7, 2026, 3:51pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/5 "2026-09-07T15:51:27Z")

</div>

I have a few hundred historical books that I use Claude over the MCP server to help pull verbatim quotes. Most books are long, so the `pages` parameter is the feature I lean on most.

---

<div class="post-metadata">

**Author:** ![cgrunenberg](https://discourse.devontechnologies.com/user_avatar/discourse.devontechnologies.com/cgrunenberg/32/7172_2.png) [@cgrunenberg](https://discourse.devontechnologies.com/u/cgrunenberg)\
**Post date:** [September 7, 2026, 4:08pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/6 "2026-09-07T16:08:52Z")

</div>

> [@wyrbw](#):
>
> The recognition itself improved, so I’d like to keep using OCR; is that size growth expected with those settings?

This depends on _Settings \> OCR_.

---

<div class="post-metadata">

**Author:** ![cgrunenberg](https://discourse.devontechnologies.com/user_avatar/discourse.devontechnologies.com/cgrunenberg/32/7172_2.png) [@cgrunenberg](https://discourse.devontechnologies.com/u/cgrunenberg)\
**Post date:** [September 7, 2026, 4:30pm UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/7 "2026-09-07T16:30:56Z")

</div>

> [@wyrbw](#):
>
> On the same record, `extract_record_content` with `pages: "12"` and `max_token_count: 1500` returns page 12 correctly; `pages: "100"` with `max_token_count: 400` comes back immediately with the cover, copyright page, and contents as a single unpaginated body.

Do you really specify parameters on your own? That’s definitely discouraged, e.g. the `pages` parameter does not specify a page count:

**`pages`** (_string_): Zero-based page filter for multi-page PDFs. Accepts comma-separated page numbers (e.g., `"0,2,5"`), inclusive ranges (e.g., `"0-4"`), or combinations (e.g., `"0-2,5,7-9"`). Ignored for non-PDF records.

---

<div class="post-metadata">

**Author:** ![BLUEFROG](https://discourse.devontechnologies.com/user_avatar/discourse.devontechnologies.com/bluefrog/32/135_2.png) [@BLUEFROG](https://discourse.devontechnologies.com/u/BLUEFROG)\
**Post date:** [September 8, 2026, 1:30am UTC](https://discourse.devontechnologies.com/t/mcp-extract-record-content-cant-read-past-the-first-100-pages-of-long-pdfs/87582/9 "2026-09-08T01:30:31Z")

</div>

364 page PDF document with many matches beyond page 100.

```auto
search this document for Cassini and return a list of pages with search hits. ignore pages with only one mention.

```

 ![image](https://devontech-discourse.s3.dualstack.us-east-1.amazonaws.com/uploads/original/3X/d/d/dd8e36444b452d0298789ba5389c81a34d19dcfb.webp)
