Skip to main content

A simple AI (span-marker) powered fandom scraper

Project description

Fandom Scraper

A simple AI (span marker) powered fandom scraper.

[!NOTE]
This package is a part of the Cirilla project

[!IMPORTANT]
In order to use the package an nvidia gpu is required.

Installation

# (recommended)
uv add fandom-scraper

# or
pip install fandom-scraper

Usage

The usage is very simple, the function requires path with so-called seeds to start scraping e.g. examples/witcher_json/witcher_1.json

[
    "Geralt of Rivia", "Triss Merigold", "Vesemir", "Leo", "Lambert", 
    "Eskel", "Alvin", "Shani", "Zoltan Chivay", "Dandelion (Jaskier)", 
    "King Foltest", "Adda the White",

    "Jacques de Aldersberg", "Azar Javed", "Professor (leader of Salamandra)", 
    ...
]

and later uses sugesions provided by an Named Entity Recognition (NER) model. The script saves the scraped pages and instructions into respective folders.

from fandom_scraper import scrape_fandom
in_path = Path("./examples/witcher_json")
out_path = Path("./examples/async_fandom")
instruct_path = Path("./examples/async_fandom_instruct")

scrape_fandom(in_path, out_path, instruct_path)

See examples/async_fandom/ and examples/async_fandom_instruct/ for more examples.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fandom_scraper-0.1.33.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fandom_scraper-0.1.33-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file fandom_scraper-0.1.33.tar.gz.

File metadata

  • Download URL: fandom_scraper-0.1.33.tar.gz
  • Upload date:
  • Size: 4.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.0

File hashes

Hashes for fandom_scraper-0.1.33.tar.gz
Algorithm Hash digest
SHA256 b5be9fc1868a91d16b2f6d7e4fee8bd75b413eee0783ce55b273fd84f82d43b9
MD5 74cfc7b594bd5a5208e98c09ecd8da10
BLAKE2b-256 4066cf67a458cd9190a2a8ad6e8981bc944d869a44e42b91140edf01991f352c

See more details on using hashes here.

File details

Details for the file fandom_scraper-0.1.33-py3-none-any.whl.

File metadata

File hashes

Hashes for fandom_scraper-0.1.33-py3-none-any.whl
Algorithm Hash digest
SHA256 b49a3c32c07ed1cb9b0fdc0f50c99a8d6b916547f532734a511f20c0bb8f129f
MD5 20295d63943b9ed16876206da99aa277
BLAKE2b-256 890f37b27395f633d1012c35c2acb5626fac3c820a3532ad2f3de7525363b8ec

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page