<?php
require __DIR__."/init.php";



//Create a document (adds to boru_ai_documents table)
$filePath = __DIR__."/example.pdf";
$crmId = 1234;
$doc = \boru\boruai\Models\Document::create($filePath,$crmId);


//OCR the document (using the queue -- default):
//NOTE: The OCR is done via the "vendor/bin/boruai queue" command (which would typically be set on a cron)
$doc->ocr();

//OCR the document (not using the queue);
$doc->ocr(false);

//Get the OCR results
$ocrText = $doc->summary();

