Skip to main content

Add short description here

Project description

Welcome to scrapyrus

License: MIT GitHub Workflow Status codecov

Installation

The Python package scrapyrus can be installed from PyPI:

python -m pip install scrapyrus

Development installation

If you want to contribute to the development of scrapyrus, we recommend the following editable installation from this repository:

git clone git@github.com:ssciwr/scrapyrus.git
cd scrapyrus
python -m pip install --editable .[tests]

Having done so, the test suite can be run using pytest:

python -m pytest

Docker Compose

The repository includes a Docker Compose setup with PostgreSQL and a profiled scrapyrus execution container. The PostgreSQL service uses a pgvector-enabled image because scrapyrus embeddings commands require the vector extension:

docker compose up -d postgres

The scrapyrus container mounts this repository at /workspace and sets SCRAPYRUS_DATABASE_URL to the PostgreSQL service. It also mounts the local ./exchange directory at /exchange for moving data between the host and the container. Start it as a one-off shell when you need to run the CLI:

docker compose run --build --rm scrapyrus bash
scrapyrus metadata ingest
scrapyrus transcriptions ingest
scrapyrus embeddings ingest \
    --inference-server-url <url> --model-name <model> --api-key <key>

Embedding ingestion reads the XML rows created by transcriptions ingest, so both commands must target the same PostgreSQL database and must run in that order.

The scrapyrus service is intentionally not started by the default up command. Some Snap-packaged Docker installations fail to stop idle long-lived containers during rebuilds with cannot stop container: ... permission denied; using one-off run --rm containers avoids that host-side recreate path.

If idp.data is somewhere else inside the mounted workspace, pass it explicitly:

scrapyrus --idp-data /workspace/idp.data metadata ingest

To export the metadata database tables as CSV files:

scrapyrus metadata dump

If an older checkout already started the Compose stack with the stock PostgreSQL image, recreate the database service after updating:

docker compose up -d --force-recreate postgres

Acknowledgments

This repository was set up using the SSC Cookiecutter for Python Packages.

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

scrapyrus-0.0.1.tar.gz (87.2 kB view details)

Uploaded Source

File details

Details for the file scrapyrus-0.0.1.tar.gz.

File metadata

  • Download URL: scrapyrus-0.0.1.tar.gz
  • Upload date:
  • Size: 87.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for scrapyrus-0.0.1.tar.gz
Algorithm Hash digest
SHA256 837c02a43e5e45424c2d17fa8ddcb4c2de01020d7cbf401bf1dea0f8af713ec5
MD5 68ab54d753082791383f0c2607d55368
BLAKE2b-256 5c504e79f49337621886b6c367bd6a9cb338fe332ee815596b3a866582f0430e

See more details on using hashes here.

Provenance

The following attestation bundles were made for scrapyrus-0.0.1.tar.gz:

Publisher: pypi.yml on ssciwr/scrapyrus

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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