WordPress AI Integration
How Voyager extends the WordPress AI ecosystem — 12 modules, 5 new abilities, full cost tracking, and cross-system sync across Orbit, MCP Server, and Portal.
The Six Pillars of WordPress AI
Voyager aligns with every pillar of the WordPress AI ecosystem — and leads in three of them.
Block Bindings
8 binding sources — post-meta-text, site-data, contextual-cta, geo, ai-content, pulse, meta, orbit. 77 bindable meta fields across 8 CPTs. 17 bound patterns with 71+ binding instances.
Abilities API
48+ abilities registered via wp_register_ability(). All with show_in_rest and MCP exposure. Categories: content generation, SEO, lead tracking, analytics, publishing, media, quality, site management.
WP AI Client
Zero direct API calls. Every AI interaction uses wp_ai_client_prompt() — fully provider-agnostic. Model routing via 3-tier system: Sonnet for complex tasks, Haiku for everything else.
MCP Protocol
68 MCP tools across 10 domains including the new ai-usage domain. MCP Adapter exposes all abilities. Deployed at voyager-mcp-server on Cloudflare Workers.
Content Guidelines
31 ability calls wrapped with voyager_ai_system_instruction(). Reads wp_guideline CPT (site, copy, images, additional). Synced to client fleet via Pattern Cloud manifest.
Cost Tracking
Every token tracked. RequestLogger captures provider, model, tokens, duration, and cost. Prompt caching saves 20-40%. Monthly budgets prevent runaway spend. Portal dashboard visualizes fleet-wide costs.
Architecture: The Data Flow
Every AI call flows through a unified pipeline — from WordPress to Portal, with full observability.
WordPress Site (Orbit)
Ability Call -> wp_ai_client_prompt()
-> PromptCacheInjector adds cache_control
-> TokenBudget checks monthly spend vs budget
-> GuidelinesService injects wp_guideline content
-> ModelRouter selects Sonnet (complex) or Haiku (standard)
-> Anthropic API generates response
-> RequestLogger logs tokens, cost, duration, ability name
-> voyager_ai_requests table (per-site)
-> REST: GET /voyager/v1/ai-usage
Downstream consumers:
- MCP Server (Cloudflare): 4 ai-usage tools, fleet costs, leaderboard
- Portal (Next.js + Supabase + Trigger.dev): AI Dashboard
- Claude Code (CLI/IDE): Skills, Managed Agents, wpai-release-watch
WPAI Hook Integration
11 wpai_* hooks consumed — making Voyager a first-class citizen in the WordPress AI plugin ecosystem.
System Instructions (9 profiles)
- taxonomy — CPTs, custom taxonomies, term counts
- seo — SEO plugin, focus keywords, competing titles
- media — image guidelines, media library stats
- content — CPTs, bindings, guidelines, lead data
- editorial — guidelines, form integrations
- title — SEO context, competing titles on site
- excerpt — target length, focus keyword
- resizing — copy guidelines, voice preservation
- default — base identity, CPTs, bindings, MCP status
Post Context Enrichment
- voyager_lead_score — Lead quality score (0-100)
- voyager_seo_score — RankMath SEO score
- voyager_focus_keyword — Target keyword
- voyager_binding_count — Block bindings in content
- voyager_post_type_label — Human-readable type
- voyager_is_pseo — Service area flag
- voyager_pseo_city — pSEO city name
New Abilities (this sprint)
Pre-Publish Quality Gate
5-check scoring system: readability (Flesch-Kincaid), SEO (keyword density, meta, headings), brand voice (AI vs. guidelines), internal links, image alt text. Runs on publish, stores results in post meta.
Smart FAQ + Schema
Auto-generates 5 FAQs from page content at publish time. Outputs FAQ structured data (JSON-LD) on wp_head. Uses PublishTimeAI framework for zero-config deployment. Revenue: $2,600/mo potential at 30% fleet adoption.
AI Contextual CTAs
Replaces generic sprintf CTA templates with AI-generated, page-specific calls-to-action. Stored in post meta, rendered via the existing voyager/contextual-cta binding source. Falls back to templates if AI CTA not present.