AdPilot · Corpus
T-034 — Agent-visibility studio (AEO)
T-034 — Agent-visibility studio (AEO)
Frozen spec for the T-034 build: make the business legible to LLM agents — the ads product extending to the fastest-growing acquisition channel.
Decisions
- Scope (Q1): fully sandbox. Checks score the user-DECLARED surface
(facts saved via
PUT /v1/aeo); there is no live crawling of arbitrary sites. The agent-says panel is a deterministic sandbox engine whose answers quote exactly the missing facts as hedges; the env-gated LLM provider (T-017/T-027 config) replaces it behind the same endpoint later. - Implementer — scoring: five weighted checks summing to 100 —
structured-data 30, price-consistency 20, crawlable-offers 20, llms-txt
15, faq-content 15 — computed by the pure
ComputeAeoScoreover the declared booleans. Fixes derive from failing checks with impact = weight; applying one sets the surface fact and re-snapshots score history. - Implementer — persistence:
services/api/internal/store/migrations/0012_aeo.sqladdsaeo_surface(workspace PK) andaeo_history; endpoints areGET /v1/aeo,PUT /v1/aeo,POST /v1/aeo/fixes/{key}/apply,GET /v1/aeo/agent-saysinservices/api/internal/api/handlers_aeo.go(4 new routes inservices/api/internal/api/server.go).
Surface-area deltas
services/api/internal/domain/aeo.go— weights, surface, score, fix queue, sandbox agent answers with hedge extraction.services/api/internal/store/aeo.go— surface upsert/get, history insert/list.services/api/internal/api/handlers_aeo.go— the four endpoints.apps/web-next/app/agent-visibility/page.tsx— score display, surface editor, fix queue with one-click apply, agent-says panel, history chips.apps/web-next/app/layout.tsx— nav link.apps/web-next/lib/api.ts,apps/web-next/lib/types.ts,apps/web-next/lib/demo.ts— client, types, demo parity.- Tests:
services/api/internal/domain/aeo_test.go(score math, fix queue, hedges, SetCheck) and the endpoint suite inservices/api/internal/api/handlers_aeo.gocoverage viainternal/apitests. - Bookkeeping: the card's git-mv sides
tasks/00-backlog/T-034-agent-visibility-studio.md/tasks/10-in-progress/T-034-agent-visibility-studio.md.
Verification
Go gates: go test ./... (6/6 packages; 4 new test functions covering score
math, fix derivation, hedge extraction). Web gates: npm run build +
jest + eslint clean. Manual: a fully-declared surface scores 100 with an
empty fix queue; the sandbox panel hedges only on missing facts.
Out of scope
Live crawling of arbitrary sites (sandbox rule), real LLM answers (credentials-gated T-017/T-027 config), fix application to external page content.