quickstart.ipynb is a full guided tour of
langchain-diffbot — every public surface, in order:
- Knowledge Graph retriever + output shaping
- Native async
- Web Search retriever
- Extract tool + extract loader
- Entities tool
- ChatDiffbot (Diffbot's own LLM with native streaming)
- Bring-your-own SDK client
- A multi-tool research agent that uses KG search + web search + URL extract
DIFFBOT_API_TOKENandANTHROPIC_API_KEYin the environment. Copy../.env.exampleto../.envand fill them in.- Python deps: from the repo root,
uv sync --extra examples.
# uv-managed (recommended — handles PATH automatically):
uv run --with jupyter jupyter lab examples/quickstart/quickstart.ipynb
# Or plain pip (use `python -m jupyter`, not `jupyter`, to avoid PATH issues):
pip install jupyter
python -m jupyter lab examples/quickstart/quickstart.ipynbThen run the cells top to bottom.
Inside the repo, uv sync --extra examples is all you need. From outside the
repo, install the package with its examples extra (diffbot-python comes in as
a dependency from PyPI):
pip install "langchain-diffbot[examples]"The notebook is regenerated from _build_notebook.py —
edit that file (cell sources are inline) and re-run it rather than editing the
.ipynb directly:
uv run python examples/quickstart/_build_notebook.py