Projects · Prototype

Structured Data Extraction Pipeline

A Python scraper that gathers character names and profile URLs from category pages and exports them to CSV.

PythonRequestsBeautiful Souppython-dotenvCSV

Overview

What it does

The repository describes a modular scraper for hierarchical data sources. The current example extracts character links from A Song of Ice and Fire fandom category pages.

How it works

Architecture

Run the script

  1. main.py
  2. Load URL settings from .env
  3. Fetch category pages with Requests
  4. Parse names and links with Beautiful Soup
  5. Write rows to data/characters.csv

Data

Data model

  • The current CSV output has name and url fields for each character.
  • There is no database layer in the current implementation.

Interfaces

API design

  • There is no REST API in the current implementation. The repository README lists an API as future work.

Next

Future improvements

  • Add request error handling and retry/backoff.
  • Add persistent storage and an API layer.
  • Add automated tests and CI.