# Save results incrementally
save_incremental_results(app, crawl_status["id"])

```

```python
Saved 705 pages.

```

## Building AI-Powered Web Crawlers with Firecrawl and LangChain Integration

Firecrawl has integrations with popular open-source libraries like LangChain and other platforms.

![Popular AI and data tools that integrate with Firecrawl including LangChain, LlamaIndex, CrewAI, and vector databases](https://www.firecrawl.dev/images/blog/crawl-masterclass/notebook_files/image.png)

In this section, we will see how to use the LangChain integration to build a basic QA chatbot on the [LangChain Community Integrations](https://python.langchain.com/docs/integrations/providers/) website.

Start by installing LangChain and its related libraries:

```bash
pip install langchain langchain_community langchain_anthropic langchain_openai

```

Then, add your `ANTHROPIC_API_KEY` and `OPENAI_API_KEY` as variables to your `.env` file.

Next, import the `FireCrawlLoader` class from the document loaders module and initialize it:

```python
from dotenv import load_dotenv
from langchain_community.document_loaders.firecrawl import FireCrawlLoader

load_dotenv()

loader = FireCrawlLoader(
    url="https://python.langchain.com/docs/integrations/providers/",
    mode="crawl",
    params={"limit": 5, "scrapeOptions": {"onlyMainContent": True}},
)

```

The class can read your Firecrawl API key automatically since we are loading the variables using `load_dotenv()`.

To start the crawl, you can call the `load()` method of the loader object and the scraped contents will be turned into LangChain compatible documents:

```python