WR-0003.01
SEO analytics should determine what happens next
This article explores the broader architecture behind my AI SEO Strategist project. I have implemented a focused n8n MVP that combines four evidence sources and produces a Top 5 action plan. Daily storage, deterministic opportunity scoring, and scheduled reporting described below are broader design ideas rather than capabilities of that MVP.
I am designing an internal SEO Growth Intelligence system to answer a practical question: which SEO action should receive attention next if the goal is qualified traffic and leads?
A conventional report can describe impressions, clicks, sessions, and average position. Those metrics become more useful when the system connects them to landing-page engagement and lead intent, identifies a specific opportunity, and preserves enough evidence for someone to review the recommendation.
The architecture therefore separates measurement, deterministic decision logic, AI interpretation, and human approval. The model does not receive a raw analytics export and decide what matters on its own.
The architecture is a design discussion. It gives the project a direction for deeper analytics while the implemented MVP concentrates on connecting evidence, validating recommendations, and producing a concise report.
WR-0003.02
Model the organic search-to-lead funnel
The primary measurement path begins before a visitor reaches the website and continues beyond the landing page:
- Search impression
- Organic click
- Landing-page session
- Service or case-study engagement
- Contact intent
- Lead submission
- Qualified lead
Each stage needs a precise event or metric definition. A click on a booking link can show intent, but it does not prove that a consultation was booked. A locally validated contact form does not prove that a lead reached a backend, CRM, or inbox.
I would track service and case-study views, contact clicks, form starts, confirmed lead submissions, and confirmed bookings only where each event supports a real decision. Intent events and confirmed conversions must remain separate in reporting.
This distinction protects the opportunity engine from treating interface activity as commercial success.
WR-0003.03
Ingest Search Console and GA4 data
The Search Console Search Analytics API supplies query, page, date, country, and device dimensions with clicks, impressions, CTR, and average position. Requests need an explicit date range, authenticated access to the property, and pagination where the result set exceeds one response.
Search Console results are subject to the platform's aggregation and row limits. The ingestion process must preserve the requested dimensions and data state instead of treating the response as a complete, transaction-level event log.
The GA4 Data API supplies landing-page, source or medium, session, user, engagement, and key-event data. Report requests need compatible dimensions and metrics, explicit date ranges, property access, and pagination for larger responses.
Each connector should validate the external response, log request context and failures without exposing credentials, and stop with a clear error when a required field is absent. Silent partial imports would make the downstream ranking appear more certain than the source data allows.
WR-0003.04
Normalize and store auditable daily records
Search Console and GA4 describe related behavior through different measurement systems. Search Console clicks should not be expected to equal GA4 sessions, so the pipeline should join their observations only after normalizing the dimensions used for comparison.
URL normalization should resolve the chosen trailing-slash convention, fragments, relevant query parameters, hostname variants, and encoded paths. Date handling should preserve the reporting timezone and the exact period represented by each row.
The storage layer should keep source-specific daily records before producing a derived page-performance dataset:
- Search Console daily records by date, query, page, country, and device
- GA4 landing-page daily records with sessions, engagement, key events, and confirmed leads
- Derived page-performance records containing visibility, traffic, engagement, and conversion measures
Imports should use stable composite keys and idempotent upserts so a retry updates the intended daily record instead of creating a duplicate. Missing values must remain distinguishable from measured zeroes, and every record should retain its source and extraction time.
WR-0003.05
Detect opportunities with deterministic rules
The opportunity engine should identify candidates with explicit, configurable rules before involving a language model.
- High impressions and low CTR for a query or page that already ranks visibly
- Positions four through fifteen with enough search demand to justify focused optimization
- High conversion and low visibility, indicating a valuable page that needs more qualified traffic
- High traffic and low conversion, indicating possible intent, offer, CTA, or UX problems
- Meaningful declines across comparable 28-day periods
- Emerging queries with sustained growth in impressions, clicks, or position
- Potential keyword cannibalization where related queries appear across multiple landing pages
Each rule needs minimum data thresholds so small samples and minor changes do not generate noisy tasks. Trend comparisons must use comparable windows and should retain the baseline used to create the flag.
A cannibalization result is a diagnostic signal, not proof of a problem. The reviewer still needs to inspect intent, page purpose, and search-result behavior before deciding whether pages should be consolidated or differentiated.
WR-0003.06
Score opportunities before AI interpretation
The system should calculate a transparent 0–100 score instead of asking the model to rank opportunities arbitrarily.
- Search demand or impressions: 25%
- Ranking potential: 20%
- Current conversion performance: 25%
- Traffic trend: 10%
- Business relevance: 20%
The weights remain configurable, but each result must preserve the component values, thresholds, and score version used in the calculation. Priority labels map to the numeric result: Critical from 80 to 100, High from 60 to 79, Medium from 40 to 59, and Low below 40.
The numeric score does not remove judgment. Confidence, absolute opportunity size, minimum data volume, and estimated implementation effort should remain visible so a high percentage based on a very small sample does not outrank a larger, better-supported opportunity.
WR-0003.07
Constrain the AI analyst
The LLM should receive one structured opportunity record containing its type, query or page, observed metrics, comparison values, score, score breakdown, and applicable business context.
The response should also be structured:
- Priority
- Evidence-based summary
- Reasoning tied to supplied values
- Specific recommended actions
- Uncertainty or checks still required
The model must never fabricate traffic, rankings, conversions, or revenue. It should distinguish observed values from estimates, avoid treating correlation as causation, and reject a recommendation when the supplied evidence is insufficient.
Schema validation should run before the analysis enters a report. The system should retain the opportunity input, rule and score breakdown, prompt version, model identifier, structured output, validation result, timestamp, and approval status.
WR-0003.08
Automate reporting without automating judgment
The operating cadence separates data freshness from editorial judgment. A daily workflow fetches both analytics sources, normalizes records, performs idempotent upserts, and refreshes derived measures. A weekly workflow runs opportunity detection, calculates scores, requests AI interpretation, validates the output, and assembles a Markdown report.
The report should contain an executive summary, the top opportunities, visibility and traffic changes, conversion findings, emerging queries, pages requiring attention, and recommended actions for the week.
A person remains responsible for accepting, editing, rejecting, or deferring each recommendation. The workflow should record that decision and connect later performance observations to the intervention without claiming that a subsequent change proves causation.
This boundary also prevents the system from turning every recommendation into automatically published content. Google advises that generative tools can support research and structure, but scaled output without added value can violate spam policies. Human review is part of the system design, not a final cleanup step.
WR-0003.09
From broader architecture to a focused implementation
The current website foundation includes route-specific metadata, canonical URLs, structured data, prerendered pages, crawl controls, and a base GA4 installation with intent events.
The n8n MVP implements page selection, Search Console and GA4 report requests, OpenSEO and Screaming Frog file imports, normalized evidence joins, two-stage AI analysis, and Top 5 report assembly. Local fixture checks cover multiple pages, incomplete sources, and invalid model responses.
Persistent daily records, numeric opportunity scores, and scheduled reporting remain broader architectural options. The focused implementation demonstrates how to connect the evidence and make its recommendations inspectable within a manageable workflow.
Related systems
Related projects
References
Sources
- Google Search Console — Search Analytics query
Official reference for querying Search Console performance dimensions and metrics. The MVP implements report requests; this article explores a broader daily ingestion design.
- Google Analytics — GA4 Data API
Official reference for programmatic GA4 reporting. The MVP implements report requests; persistent analytics storage and scheduled synchronization are broader design options.
- Google Search Central — Guidance on generative AI content
Supports the boundary between AI-assisted analysis or drafting and accountable, value-adding human review.