Parsing PDFs (and more) in Elixir using Rust
11–18 of 18 posts
Re: Parsing PDFs (and more) in Elixir using Rust
#12[flagged]
The only relevance is the PDF format.
Re: Parsing PDFs (and more) in Elixir using Rust
#13I've been thinking a lot about how to accomplish various RAG things in Elixir (for LLM applications). PDF is one of the missing pieces, so glad to see work here. The really tricky part is not just parsing out the text (you can just call the pdftotext unix command line utility for that), but accurately pulling out things like complex tables, etc in a way that could be chunked/post processed in a useful way. I'd love t…
Re: Parsing PDFs (and more) in Elixir using Rust
#14I've been thinking a lot about how to accomplish various RAG things in Elixir (for LLM applications). PDF is one of the missing pieces, so glad to see work here. The really tricky part is not just parsing out the text (you can just call the pdftotext unix command line utility for that), but accurately pulling out things like complex tables, etc in a way that could be chunked/post processed in a useful way. I'd love t…
Maybe just using pdftohtml instead of pdftotext.
Re: Parsing PDFs (and more) in Elixir using Rust
#15I've been thinking a lot about how to accomplish various RAG things in Elixir (for LLM applications). PDF is one of the missing pieces, so glad to see work here. The really tricky part is not just parsing out the text (you can just call the pdftotext unix command line utility for that), but accurately pulling out things like complex tables, etc in a way that could be chunked/post processed in a useful way. I'd love t…
For instace Llamaparse( https://docs.llamaindex.ai/en/stable/llama_cloud/llama_parse... )uses LLMs for pdf text extraction, but the problem is hallucination. e.g > https://github.com/run-llama/llama_parse/issues/420 There is also LLMWhisperer that preserves the layout(tables, checkboxes, forms)and hence the context. https://pg.llmwhisperer.unstract.com/
Re: Parsing PDFs (and more) in Elixir using Rust
#16On the plus side it makes IPC pretty straightforward, so you can move the processes that need the native code (NIFs) to a separate VM if you’re feeling paranoid.
Re: Parsing PDFs (and more) in Elixir using Rust
#17The Achilles heel of the BEAM is that if it crashes in native code then it has no way to recover and its much vaunted robustness goes out the window. So writing native hooks in Rust makes it a bit harder to crash the whole VM. On the plus side it makes IPC pretty straightforward, so you can move the processes that need the native code (NIFs) to a separate VM if you’re feeling paranoid.
> The library provides facilities for generating the boilerplate for interacting with the BEAM, handles encoding and decoding of Erlang terms, and catches rust panics before they unwind into C.
Re: Parsing PDFs (and more) in Elixir using Rust
#18Earlier quoted context omitted.
For instace Llamaparse( https://docs.llamaindex.ai/en/stable/llama_cloud/llama_parse... )uses LLMs for pdf text extraction, but the problem is hallucination. e.g > https://github.com/run-llama/llama_parse/issues/420 There is also LLMWhisperer that preserves the layout(tables, checkboxes, forms)and hence the context. https://pg.llmwhisperer.unstract.com/
Is this open source? Is it slow Python? That's where I'm stuck.