Live data from Hacker News

Show HN: Talk to any ArXiv paper just by changing the URL

github.com

11–20 of 78 posts

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#11
post #7

Idk where this changing the url thing started but I really like it.

It bugs me cause it's kinda true but kinda misleading, I don't know if casual web users realize it's a whole different domain. Sometimes it's not important, sometimes it is.

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#12
post #7

Idk where this changing the url thing started but I really like it.

The oldest instance of it that I know is putting something like download before or after the youtube domain. This must have been 2008±2. I very much doubt that's the first instance ever but I wasn't around online in the 90s (aside from on my grandma's machine who didn't know her computer had a web browser, but that wasn't very conscious, just a neutral net (young me) clicking buttons to see the effect)

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#13
post #8

Very nice; appears to work well. Just an FYI that I did get a couple errors where the max context length was exceeded, one using the demo summarization task as the first query. I was using my own API key when the error occured.

Thank you! Thanks for pointing that out, since the underlying RAG is rather naive (simple embedding cosine similarity lookup, as opposed to knowledge graph / advanced techniques), I opted to embed both "small" (512 character and below) chunks as well as entire section chunks (embedding the entire introduction) in order to support questions such as "Please summarize the introduction". Since I also use 5 chunks for each context, I suspect this can add up to a massive amount on papers with huge sections.

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#14
post #6

Looks great! It would be very interesting to understand a bit they why/how of some of the steps, such as the reranking and how you arrived at your chunking algo.

Thank you :). I updated the README to have some more explanation of the steps.

The chunking algorithm chunks by logical section (intro, abstract, authors, etc.) and also utilizes recursive subdivision chunking (chunk at 512 characters, then 256, then 128...). It is quite naive still but it works OK for now. An improvement would perhaps involve more advanced techniques like knowledge graph precomputation.

Reranking works by instead of embedding each text chunk as a vector and performing cosine similarity nearest neighbor search, you use a Cross-Encoder model that compares two texts and outputs a similarity score. Specifically, I chose Cohere's Reranker that specializes in comparing Query and Answer chunk pairs.

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#15
I thought this would be for contacting authors or chatting about the paper with other readers, but apparently RAG here is a new important TLA to take note of, meaning chat bot. You need to enter an API key from "Open"AI to use the service and it's about it answering your questions about the paper

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#16
You might be able to drop the PDF backend since they're close to getting HTML running well: https://news.ycombinator.com/item?id=38713215

Using that might be easier than a multi-modal approach. Bonus points for:

* Multiple papers at once

* Comparing PDF and HTML output with the LLM as input for it correcting similar converter code

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#17
post #15

I thought this would be for contacting authors or chatting about the paper with other readers, but apparently RAG here is a new important TLA to take note of, meaning chat bot. You need to enter an API key from "Open"AI to use the service and it's about it answering your questions about the paper

Oops sorry for the miscommunication, actually you don't need to enter an API key for now. Feel free to just try it out!

Re: Show HN: Talk to any ArXiv paper just by changing the URL

#19
post #16

You might be able to drop the PDF backend since they're close to getting HTML running well: https://news.ycombinator.com/item?id=38713215 Using that might be easier than a multi-modal approach. Bonus points for: * Multiple papers at once * Comparing PDF and HTML output with the LLM as input for it correcting similar converter code

Definitely I'll move to the LaTeX source code instead of a PDF backend since that allows better support for non textual data that gets poorly scraped by GROBID. That is a really cool development I didn't know about, also theres https://ar5iv.labs.arxiv.org/ which already has most arXiv papers as HTML documents. I chose GROBID because they not only parse the PDF but organize the text into logical sections for me (Intro, abstract, references) which I didn't want to manually do with heuristics that I'd have to devise.
Post reply on HN