24 NOV 2025
David's approach: Injecting PDF text alongside visual pages to force complete content coverage
David proposed and approved injecting extracted PDF page text directly into the view_file tool response with a per-page teaching mandate, to prevent the lecture notes agent from omitting content.
After reviewing a lecture notes workspace and finding it left out most of the PDF slide content:
its leaving out most of the content in the pdf lecture slides. its not including it in its teaching. this is a real problem and we need to figure out the solution.
David proposed the fix approach:
heres my recommendation: when the model calls view_file, and we return the pages, we should also return the actual text in those pages (using the optimal text extraction method) and saying 'Page 4 text, ensure you teach every single thing and do not leave anything out:...'
He also corrected an edge case in the agent's implementation plan:
wait wdum by this? i didnt mean omit the page from the response; still feed in the page to gemini. i just meant the text shouldnt imply theres extracted text being shown if the page has none.
Before shipping, David insisted on an edge case audit:
go do another audit over whether theres any failure modes in your implementation, race conditions (does view_file make sure it only returns once the extraction is done and completely formatted?), edge conditions not solved for, bugs etc. launch agents to go do this with you