Live data from Hacker News

Show HN: Robust LLM extractor for websites in TypeScript

github.com

41–50 of 63 posts

Re: Show HN: Robust LLM extractor for websites in TypeScript

#41
post #30

My instinct was also to use LLMs for this, but it was way to slow and still expensive if you want to scrape millions of pages.

Put things to perspective - Gemini 2.5 flash is 0.3/1M tokens - assuming each page is 700 tokens and output is not much you are looking at $210 for 1M pages

Re: Show HN: Robust LLM extractor for websites in TypeScript

#43
post #30

My instinct was also to use LLMs for this, but it was way to slow and still expensive if you want to scrape millions of pages.

Put things to perspective - Gemini 2.5 flash is 0.3/1M tokens - assuming each page is 700 tokens and output is not much you are looking at $210 for 1M pages

You will absolutely struggle to get all the info you need into 700 tokens per page.

Edit: There's also the added complexity of running a browser against 1M pages, or more.

Re: Show HN: Robust LLM extractor for websites in TypeScript

#44
Would this work for my use case?

I need to extract article content, determine it's sentiment towards a keyword and output a simple json with article name, url, sentiment and some text around the found keyword.

Currently I'm having problems with the json output, it's not reliable enough and produces a lot of false json.

Re: Show HN: Robust LLM extractor for websites in TypeScript

#47

My platform has 24M pages on 8 domains and these NASTY crawlers insist on visiting every single one of them. For every 1 real visitor there are at least 300 requests from residential proxies. And that's after I blocked complete countries like Russia, China, Taiwan and Singapore. Even Cloudflares bot filter only blocks some of them. I'm using honeypot URLs right now to block all crawlers that ignore rel="nofollow", bu…

What crawlers are using residential proxies?

Re: Show HN: Robust LLM extractor for websites in TypeScript

#49
post #47

My platform has 24M pages on 8 domains and these NASTY crawlers insist on visiting every single one of them. For every 1 real visitor there are at least 300 requests from residential proxies. And that's after I blocked complete countries like Russia, China, Taiwan and Singapore. Even Cloudflares bot filter only blocks some of them. I'm using honeypot URLs right now to block all crawlers that ignore rel="nofollow", bu…

What crawlers are using residential proxies?

Now if they identified themselves, I could block them.

I'd put my money on Chinese AI model makers, but I don't trust any company that is in desperate need of fresh data.

Re: Show HN: Robust LLM extractor for websites in TypeScript

#50
post #7

> LLMs return malformed JSON more often than you'd expect, especially with nested arrays and complex schemas. One bad bracket and your pipeline crashes. This might be one reason why Claude Code uses XML for tool calling: repeating the tag name in the closing bracket helps it keep track of where it is during inference, so it is less error prone.

Unless I'm totally misunderstanding something it's not xml but special tokens for the tokenizer someone smarter than me might know https://medium.com/@nisarg.nargund/why-special-tokens-matter...
Post reply on HN