Should I ask an LLM to extract dozens of fields from a long document in one prompt, or split it up?

For many unrelated fields over long documents, split the work: one long prompt with every field tends to miss some of them. In LLM-Powered Proactive Data Systems (IEEE Data Engineering Bulletin 2025), we argue the system should do this rewriting itself: break "extract fields f1 to fn" into one focused prompt per field, send the LLM only the relevant part of a long document, and leave arithmetic such as averages to SQL.

Sources: LLM-Powered Proactive Data Systems (IEEE Data Engineering Bulletin 2025)

Guide: How to Process Documents with LLMs Cheaply

More questions on this topic

All questions about using AI for data and knowledge work