Skip to main content

SEO crawl-audit Streamlit dashboard for nginx-ingress Googlebot logs

Project description

seo-log-auditor

Streamlit dashboard that ingests a 30-day Grafana/Loki export of nginx-ingress Googlebot logs and runs seven SEO crawl-audit techniques on it:

  1. Crawl budget distribution – how hits are spread across page types vs how URLs are spread across page types.
  2. Orphan pages – URLs Googlebot is hitting that are not in your sitemap.
  3. Status-code waste – non-200 ratio per page type, redirect chains.
  4. Stale high-value pages – sitemap URLs not crawled in the last N days.
  5. Performance – page-size vs latency vs hit frequency.
  6. Bot verification – verified Googlebot vs spoofed User-Agents.
  7. Parameter traps – paths with an explosive number of query-string variants.

Quick start

Zero-install via uv:

uvx seo-log-auditor

Or install into the current environment:

pip install seo-log-auditor
seo-log-auditor

Either command launches the dashboard at http://localhost:8501. To pass flags through to Streamlit:

seo-log-auditor --server.port 9000 --server.headless true

Then in the sidebar:

  1. Upload your Grafana/Loki export (.json, .csv, or .txt).
  2. Paste your sitemap URL (a sitemap index works too).
  3. Optionally upload a page_patterns.yaml (see src/crawl_audit/config/page_patterns.example.yaml).

Exporting logs from Grafana

Use this LogQL query in Grafana Explore against your Loki datasource:

{app="ingress-nginx"} |= "Googlebot"

Set the time range to last 30 days and download as JSON (best fidelity) or CSV. Plain .txt (one log line per row) also works.

Page-pattern config

src/crawl_audit/config/page_patterns.example.yaml is the starting point. First match wins. Edit it for your URL structure and re-upload via the sidebar. Tagging traps like paginated and faceted as their own page types makes leakage immediately visible on the Crawl Budget page.

Development

git clone https://github.com/hitensangani/seo-log-auditor.git
cd seo-log-auditor
uv sync --extra dev
uv run streamlit run src/crawl_audit/app.py

Project layout

src/crawl_audit/
  app.py                        # Streamlit entry, sidebar uploads, KPI overview
  cli.py                        # `seo-log-auditor` console script
  pages/                        # Multipage app, one file per technique
  config/                       # Example page-pattern rules
  parsers.py                    # Loki JSON / CSV / nginx-text -> DataFrame
  classify.py                   # Regex-based URL -> page_type
  sitemap.py                    # Fetch + parse sitemap.xml (incl. index)
  verify_bot.py                 # Google IP ranges + cached reverse DNS
  analysis/                     # One module per technique
tests/                          # pytest fixtures + unit tests

Running tests

uv run pytest

Roadmap

  • Internal-link-depth correlation (technique 4 deeper layer) once you have a Screaming Frog / Sitebulb export.
  • Direct Loki API streaming so you don't need to download files.
  • SQLite cache for week-over-week comparisons.

License

MIT — see LICENSE.

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

seo_log_auditor-0.1.0.tar.gz (29.9 kB view details)

Uploaded Source

Built Distribution

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

seo_log_auditor-0.1.0-py3-none-any.whl (38.1 kB view details)

Uploaded Python 3

File details

Details for the file seo_log_auditor-0.1.0.tar.gz.

File metadata

  • Download URL: seo_log_auditor-0.1.0.tar.gz
  • Upload date:
  • Size: 29.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for seo_log_auditor-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fd580aaccd86af754b9ffcf55c8220cd31ad702861c3a194be79c29a0f7eb919
MD5 56fc27fae65383c49ca65e94808fb314
BLAKE2b-256 82840517bf1f68b7438e935aa946d26638d2773a7216168acf7bdd91da819615

See more details on using hashes here.

File details

Details for the file seo_log_auditor-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: seo_log_auditor-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 38.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for seo_log_auditor-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1425af184c95280bf562976ac245fdfc2eb4af88607bf886aa5aed1b97746c9f
MD5 b47350649a545a26123dc566a22a03f8
BLAKE2b-256 c24f65557a342e835395ef5eaa8bda1df7bcd716e1e51e2ef903185042467705

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