Reads any PDF, lists every value it found in a Google Doc, and points out which ones to double-check against the original.
UsesExtend
Google Docs
Pull every value out of a PDF and flag what to check
sourceFile to blank.Set sourceFile to blank.notebookDocument to blank.Set notebookDocument to blank.readingGuidance to blank.Set readingGuidance to blank.flagBelowConfidence to 0.7.Set flagBelowConfidence to 0.7.notebookDocument and save it as documentLink.Trim notebookDocument and save it as documentLink.notebookId to documentLink.Set notebookId to documentLink.documentLink contains /d/If documentLink contains /d/Yes
documentLink split by /d/ split by / and save it as notebookId.Get the first item of the last item of documentLink split by /d/ split by / and save it as notebookId.Else if @documentLink contains "/"
Otherwise
No steps
notebookId is emptyIf notebookId is emptyYes
No
No steps
confidenceFloor to flagBelowConfidence multiplied by 1.Set confidenceFloor to flagBelowConfidence multiplied by 1.reading.Extract data from a document. Save it as reading.readingGuidancereading.data to text and save it as recordJson.Convert reading.data to text and save it as recordJson.recordJson is {} or recordJson is nullIf recordJson is {} or recordJson is nullYes
No
No steps
valuesRead to 0.Set valuesRead to 0.valuesToCheck to 0.Set valuesToCheck to 0.valueLines to an empty list.Set valueLines to an empty list.checkLines to an empty list.Set checkLines to an empty list.coveredNames to an empty list.Set coveredNames to an empty list.readValue in reading.field_metadata:For each readValue in reading.field_metadata:readValue.field and save it as valueName.Trim readValue.field and save it as valueName.valueName is emptyIf valueName is emptyYes
No
No steps
valuesRead.Add 1 to valuesRead.valueName to the end of coveredNames and save it as coveredNames.Add valueName to the end of coveredNames and save it as coveredNames._ with in valueName and save it as fieldLabel.Replace _ with in valueName and save it as fieldLabel.valueName in a table and save it as valueFound.Look up valueName in a table and save it as valueFound.valueFound, or (left blank) if it is empty and save it as valueText.Use valueFound, or (left blank) if it is empty and save it as valueText.valueConfidence to readValue.confidence multiplied by 1.Set valueConfidence to readValue.confidence multiplied by 1.valueConfidence to 2 decimal places and save it as confidenceShown.Round valueConfidence to 2 decimal places and save it as confidenceShown.pageText to page readValue.page.Set pageText to page readValue.page.readValue.page is less than 1If readValue.page is less than 1Yes
pageText to page not given.Change pageText to page not given.No
No steps
fieldLabel: valueText (pageText, confidence confidenceShown) to the end of valueLines and save it as valueLines.Add fieldLabel: valueText (pageText, confidence confidenceShown) to the end of valueLines and save it as valueLines.valueConfidence is less than confidenceFloorIf valueConfidence is less than confidenceFloorYes
valuesToCheck.Add 1 to valuesToCheck.fieldLabel (pageText) to the end of checkLines and save it as checkLines.Add - fieldLabel (pageText) to the end of checkLines and save it as checkLines.No
No steps
otherValues to reading.data.Set otherValues to reading.data.coveredNames isn't emptyIf coveredNames isn't emptyYes
coveredNames from reading.data and save it as otherValues.Remove coveredNames from reading.data and save it as otherValues.No
No steps
otherNote to blank.Set otherNote to blank.otherValues as text is not {}If otherValues as text is not {}Yes
otherNote to Change otherNote to
Also read, with no page or confidence given, so check these too: otherValues.No
No steps
reading.file_name and save it as readTitle.Trim reading.file_name and save it as readTitle.readTitle is null or readTitle is emptyIf readTitle is null or readTitle is emptyYes
readTitle to Document.Change readTitle to Document.No
No steps
today.Get today's date and save it as today.today readable as “Monday, November 2, 2026” and save it as readDate.Make today readable as “Monday, November 2, 2026” and save it as readDate.valueLines with a new line and save it as valueList.Join valueLines with a new line and save it as valueList.checkNote to Every value was read at or above the confidence you set (flagBelowConfidence).Set checkNote to Every value was read at or above the confidence you set (flagBelowConfidence).valuesToCheck is greater than 0If valuesToCheck is greater than 0Yes
checkLines with a new line and save it as checkList.Join checkLines with a new line and save it as checkList.Check these against the original: @valuesToCheck of @valuesRead values were read below the confidence you set (@flagBelowConfidence): @checkList and save it as checkNote.Build the text Check these against the original: @valuesToCheck of @valuesRead values were read below the confidence you set (@flagBelowConfidence): @checkList and save it as checkNote.No
No steps
notebookId. Save it as added.Add text to notebookId. Save it as added.readTitle, read on readDate
valueList@otherNote
checkNotevaluesRead values out of readTitle and added them to your Google Doc. Values to check: valuesToCheck.Finish the run: Read valuesRead values out of readTitle and added them to your Google Doc. Values to check: valuesToCheck.