Hi all, I'm the author of llama-ocr. Thank you for sharing & for the kind comments! I built this earlier this week since I wanted a simple API to do OCR – it uses llama 3.2 vision (hosted on together.ai, where i work) to parse images into structured markdown. I also have it available as an npm package. Planning to add a bunch of other features like the ability to parse PDFs, output a response in JSON, ect... If anyon…
Llama-OCR: Document to Markdown
41–50 of 104 posts
Re: Llama-OCR: Document to Markdown
#42I've been doing a lot of OCR recently, mostly digitising text from family photos. Normal OCR models are terrible at it, LLMs do far better. Gemini Flash came out on top from the models I tested and it wasn't even close. It still had enough failures and hallucinations to make it faster to write it in by hand. Annoying considering how close it feels to working. This seems worse. Sometimes it replies with just the text,…
That's a bummer. I'm trying to do the exact same thing right now, digitize family photos. Some of mine have German on the back. The last OCR to hit headlines was terrible, was hoping this would be better. ChatGPT 4o has been good though, when I paste individual images into the chat. I haven't tried with the API yet, not sure how much that would cost me to process 6500 photos, many of which are blank but I don't have…
I also tried preprocessing images before sending them through. I tried cropping it to just the text to see if it helped. Then I tried filtering on top to try brighten the text, somehow that all made it worse. The most success I had was just holding the image in my hand and taking a photo of it, the busy background seemed to help but I have absolutely no idea why.
The main problem was that it would work well for a few dozen images, you'd start to trust it, and then it'd hallucinate or not understand a crossed out word with a correction or wouldn't see text that had faded. I've pretty much given up on the idea. My new plan is to repurpose the website I made for verifying the results into one where you enter the text manually, as well as date/location/favourite status.
Re: Llama-OCR: Document to Markdown
#43I gave it a sentence, which I created by placing 500 circles via a genetic algorithm to form a sentence. And then drew with an actual physical circle: https://www.instagram.com/marekgibney/p/BiFNyYBhvGr/ Interestingly, it sees the circles just fine, but not the sentence. It replied with this: The image contains no text or other elements that can be represented in Markdown. It is a visual composition of circles and do…
I can't read this either. Edit: at a distance it's easier to read
Re: Llama-OCR: Document to Markdown
#44Re: Llama-OCR: Document to Markdown
#45I've been doing a lot of OCR recently, mostly digitising text from family photos. Normal OCR models are terrible at it, LLMs do far better. Gemini Flash came out on top from the models I tested and it wasn't even close. It still had enough failures and hallucinations to make it faster to write it in by hand. Annoying considering how close it feels to working. This seems worse. Sometimes it replies with just the text,…
Re: Llama-OCR: Document to Markdown
#46Hi all, I'm the author of llama-ocr. Thank you for sharing & for the kind comments! I built this earlier this week since I wanted a simple API to do OCR – it uses llama 3.2 vision (hosted on together.ai, where i work) to parse images into structured markdown. I also have it available as an npm package. Planning to add a bunch of other features like the ability to parse PDFs, output a response in JSON, ect... If anyon…
Is this amount of larger transformation expected/desirable?
(It also means that the output is sometimes a bullet point list, sometimes a table, making further automatic processing a bit harder.)
Re: Llama-OCR: Document to Markdown
#47I gave it a sentence, which I created by placing 500 circles via a genetic algorithm to form a sentence. And then drew with an actual physical circle: https://www.instagram.com/marekgibney/p/BiFNyYBhvGr/ Interestingly, it sees the circles just fine, but not the sentence. It replied with this: The image contains no text or other elements that can be represented in Markdown. It is a visual composition of circles and do…
Markdown:
The provided image is a blurred text that reads "STOP THINKING IN CIRCLES." There are no other visible elements such as headers, footers, subtexts, images, or tables.
Markdown Content:
STOP THINKING IN CIRCLES
As the response is not deterministic, I also tried several times with the unprocessed image but it never worked. However, all the low-pass filter effects I applied worked with a high success rate.
Re: Llama-OCR: Document to Markdown
#48I've been doing a lot of OCR recently, mostly digitising text from family photos. Normal OCR models are terrible at it, LLMs do far better. Gemini Flash came out on top from the models I tested and it wasn't even close. It still had enough failures and hallucinations to make it faster to write it in by hand. Annoying considering how close it feels to working. This seems worse. Sometimes it replies with just the text,…
It's not good at returning the locations of text (yet), but it's insane at OCR as far as I have tested.
Re: Llama-OCR: Document to Markdown
#49Earlier quoted context omitted.
This is also true for any other OCR system, we just never called these errors “hallucinations” in this context.
No, it's not even close to OCR systems, which are based on analyzing points in a grid for each character stroke and comparing them with known characters. Just for one thing, OCR systems are deterministic. Deterministic . Look it up.
Re: Llama-OCR: Document to Markdown
#50Earlier quoted context omitted.
No, it's not even close to OCR systems, which are based on analyzing points in a grid for each character stroke and comparing them with known characters. Just for one thing, OCR systems are deterministic. Deterministic . Look it up.
OCR system use vision models and as such they can make mistakes. They don't sample but they produce a distribution of probability over words like LLMs.