Skip to content

ax/content-signals: report an absent Content-Signal policy separately #1649

Description

@deniskern

Expose whether a machine-readable usage policy was declared, separately from invalid directives and conflicts. Reuse the robots.txt already read; report absence only when that document was fully readable. This is informational, not legal advice or implicit permission for training.

Synthetic reproduction / acceptance fixture:

  1. Serve a complete robots.txt with ordinary crawler directives and no Content-Signal: report policy absent as information.
  2. Add a valid Content-Signal directive: report declared; use a malformed directive: report invalid separately.
  3. Return a failed or truncated robots read: policy stays unknown/not checked, never absent.

Do not introduce an extra network probe. This requests an additional observable signal, not a claim that all current validation is missing.

Triage

Today ax/content-signals (packages/rules/src/ax/content-signals.ts) already emits an info check with value absent when no directive is parsed. It reads ctx.site.robotsTxt.content ?? "", so an unreadable or missing robots.txt looks the same as a complete one with no policy. The gap is separating absent, invalid and unknown (not checked). No new network probe is needed.

Acceptance Criteria

  • A complete robots.txt with no Content-Signal reports the policy as absent (info).
  • A valid Content-Signal directive reports declared; a malformed one reports invalid, separately from absent.
  • A failed, blocked or truncated robots.txt read reports not checked, never absent.
  • No extra network request is added.
  • The rule never affects the score and the docs page for the rule is updated.

Generated by Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementrulessize: S

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions