PLATE NO. 01 β€” DIAGNOSTIC TOOL

SearchLens: an SEO audit suite that actually reads the page it's judging

A Python + Streamlit tool that crawls a live URL through 10 analysis modules and explains, in plain language, why something is a problem β€” not just that it is.

StackPython Β· Streamlit Β· BeautifulSoup Β· Pandas Β· Plotly Β· ReportLab
RoleArchitecture & review; built with Windsurf, reviewed with Claude
StatusWorking, tested against live sites
Repogithub.com/Athiradhkp04/searchlens

Vision

I wanted a project that would prove something specific about how I work, not just what I know. A lot of student SEO/analytics projects are either a templated dashboard over a Kaggle dataset, or a wrapper around someone else's paid API. I wanted something that actually crawls a live website, reasons about what it finds, and explains why something is a problem β€” and that I could plausibly run for a freelance client and trust the output of.

What it actually does

You give SearchLens a URL, and it runs that page through 10 analysis modules β€” metadata, heading structure, images, links, content quality, technical SEO, page speed, AI-generated recommendations, a weighted overall score, and export. Every check hits the real page over HTTP and parses the real HTML. The output is an interactive dashboard plus downloadable JSON/CSV/PDF reports.

Why these technologies

  • Python + Streamlit β€” turns a Python script into a working dashboard with almost no UI code, so time went into the analysis logic that actually mattered.
  • BeautifulSoup + Requests β€” reliable page fetching and HTML parsing with no paid API required, a deliberate constraint so anyone could clone and run it for free.
  • Pandas β€” structuring and displaying tabular results (images found, links found).
  • Plotly β€” the overall-score gauge chart on the dashboard.
  • ReportLab β€” PDF export, for the "send this to a client" use case rather than just a live dashboard.

No paid APIs by default β€” no PageSpeed Insights key, no LLM key required β€” so the tool works out of the box with a single pip install.

How I actually built it

I started from a detailed module-by-module spec, written before any code existed β€” what counts as a good title length, what a canonical tag is for, why heading hierarchy matters β€” so I was thinking through the actual SEO logic rather than delegating that thinking away. I used Claude to help design and review the architecture, and Windsurf to generate and iterate on the code, but stayed in the loop reviewing every module and testing the finished app against real websites myself.

Early on, Windsurf reported the full module skeleton as implemented and working. That description was accurate on paper β€” but a description of code isn't proof the code works. So instead of accepting it, I ran the app against two real, structurally different sites: djangoproject.com and a long, image-heavy Wikipedia article. That decision β€” testing against real data instead of trusting a "fully working" self-report β€” is what surfaced every real bug below. None were visible just from reading the code.

Real bugs I found and fixed

BUG 01 β€” REDUNDANT FETCHING

Each of the 7 crawling modules independently re-fetched the same page β€” 7 HTTP requests for one audit. Caught by asking why auditing one page needed seven network calls. Fixed by fetching once and passing the same parsed page into every module, with st.cache_data so re-running the same URL in a session doesn't refetch at all.

BUG 02 β€” RATE LIMITING READ AS BROKEN CONTENT

When verifying that images and links actually work, the tool makes live requests to each one. On Wikipedia, several images came back HTTP 429 β€” "too many requests" β€” and the original code treated that the same as a genuinely dead resource. That single bug dragged Wikipedia's image score to 15/100 with nothing actually broken. Fixed by treating 429 as its own "couldn't verify" category that doesn't penalize the score, plus a small delay between requests so it happens less. Probably the most important fix β€” it's exactly the kind of thing that would make the tool actively misleading on image-heavy sites.

BUG 03 β€” PARAGRAPH DETECTION

An early version split page text into "paragraphs" using raw newline characters. A 5,774-word Wikipedia article got reported as "1 paragraph." Caught by reading the Content tab output and noticing a number that couldn't be right. Fixed to use BeautifulSoup to find actual <p> tags instead of guessing from whitespace.

BUG 04 & 05 β€” FALSE POSITIVES IN LINK ANALYSIS

Wikipedia's language-switcher links use short labels in their own scripts β€” ζ—₯本θͺž, ν•œκ΅­μ–΄, δΈ­ζ–‡ β€” and the anchor-text-length check flagged these as "too short," even though 2–3 characters is normal for a language name in its own script. Separately, links wrapping only an image (a standard, valid pattern) were flagged as "empty anchor text." Fixed the short-text check to apply only to ASCII text, and added a check to skip the empty-anchor flag when a link contains an image.

BUG 06 β€” ROBOTS META MISCLASSIFICATION

A missing robots meta tag just means default behavior (index, follow) β€” fine β€” but the original logic flagged it as a warning regardless. Fixed to only flag when a tag is present and explicitly says noindex.

Every fix was verified with actual before/after numbers from re-running the audits, not just by reading the corrected code and assuming it worked.

Cutbacks & deliberate scope decisions

  • Single-page audits, not full-site crawls β€” a real crawler is a meaningfully bigger project (crawl queues, robots.txt crawl-delay, rate-limit handling across many pages). Better to ship a genuinely solid single-page tool than a half-working site-wide crawler.
  • AI recommendations are rule-based, not live LLM calls, by default. Every failed check maps to a plain-English explanation via hardcoded logic. A hook (generate_ai_recommendations_hook()) exists for a real LLM call later, but the rule-based version ships first so the tool works with zero API keys and zero running cost.
  • Page Speed Snapshot is a heuristic, not real Lighthouse data β€” it counts CSS/JS files, image count, and HTML size and buckets them low/medium/high, rather than calling Google's PageSpeed Insights API.
  • No database, no persistence β€” everything lives in the Streamlit session. An acceptable tradeoff for shipping speed; SQLite-backed audit history to track a site's score over time is a natural next step.

Limitations I'm upfront about

  • Tested against two real sites so far, not a broad range of CMS platforms (WordPress, Shopify) or JS-heavy single-page apps.
  • No headless browser β€” sites with aggressive bot detection (Cloudflare challenges) may fail, since this is requests-based, not Playwright/Selenium.
  • Keyword density is a simple top-10 term-frequency count, not true TF-IDF or competitor-relative analysis.
  • English-only content analysis.
  • No automated test suite yet β€” verification so far has been manual, real-site testing rather than unit tests. Known gap, on the list to close.