coder-hxl/x-crawl

Flexible Node.js crawler library

What it solves

It addresses the fragility of traditional web scrapers that rely on fixed HTML structures or class names. When websites update their design, these scrapers often break. By integrating AI, this library can parse the semantic meaning of a page, allowing it to extract data reliably even when the underlying code structure changes.

How it works

It provides a Node.js-based crawler that can operate in two modes: a standard crawler API for direct data extraction and an AI-assisted mode that integrates with OpenAI or Ollama. You can use the crawler to fetch page content and then pass that HTML to the AI to intelligently identify, extract, and clean the specific information you need.

Who it’s for

Developers building web automation or data collection tools who want a flexible, TypeScript-ready library that can handle both simple static pages and complex dynamic web applications.

Highlights

  • AI Integration: Uses OpenAI or Ollama to parse web content semantically, reducing maintenance caused by UI changes.
  • Versatile Scraping: Supports static pages, dynamic pages (with browser automation), file downloads, and API data.
  • Resilient Operations: Includes built-in features like automatic proxy rotation, failed retry logic, and interval-based crawling to manage high concurrency.
  • Developer Friendly: Offers TypeScript support, device fingerprinting protection, and a flexible API that handles both synchronous and asynchronous tasks.

Related

  • Project
  • Project
  • Project
  • Project
  • Project