Linux 软件免费装
Banner图

Hafen Core: Schema, llms.txt and Answer Blocks

开发者 hafenstudios
更新时间 2026年9月5日 05:33
PHP版本: 7.4 及以上
WordPress版本: 7.1
版权: GPLv2 or later
版权网址: 版权信息

标签

blocks ai schema structured-data ai-crawler

下载

1.0.0 1.0.1

详情介绍:

The companion plugin to the Hafen theme. Following the principle "theme = presentation, plugin = functionality", Hafen Core carries the functionality that, per the WordPress.org guidelines, does not belong in a theme: a schema engine, five answer blocks, an AI crawler policy for robots.txt, a local AI traffic dashboard, Markdown delivery for agent clients, a citability linter, an under-construction gate and an llms.txt file. It works with any theme, but it is built and tested as the functional half of Hafen. Access rules and measurement in one plugin. Most plugins in this field do one of the two: they either block AI crawlers, or they report on AI visibility from an external service. Hafen Core does both in the same place and can therefore relate them to each other, for example: "Perplexity is not crawling you, and PerplexityBot is on your block list." Everything runs on your own installation; no account and no external service are required for it. No invented scores. This plugin does not calculate a visibility score and does not promise you a placement in ChatGPT. Where the evidence is thin, it says so: llms.txt is labeled as speculative, every rule in the citability linter states its evidence strength and its source, and where a provider publishes no IP ranges we do not present a user agent as proof. The most honest sentence first: the strongest documented factor for citations is mentions of your brand elsewhere. On-page is the smaller lever. Everything this plugin does works on that smaller lever – but it does so cleanly and verifiably. Schema engine. Automatically embeds valid JSON-LD without you writing anything: Organization, WebSite (including the search action), Article (on posts) and BreadcrumbList. Plus FAQPage and HowTo generated from the answer blocks. Everything in a single @graph in the document head. Answer engine blocks. Five blocks that render nicely for humans while being machine-readable and privacy-friendly: Access gate (Under Construction). Protect the whole website with a password while it is being built – without an extra plugin. Three bundled templates (light, dark, accent gradient) automatically pick up your logo, your site name and your accent color. Logged-in users see the website normally, the gate page sends HTTP 503 + noindex (safe for SEO), and the WordPress logo on login pages is replaced with your site logo. AI crawler policy. The whole market treats AI crawlers as a threat to be locked out. Hafen Core does the opposite: it helps you get found and cited. To do that, it cleanly separates what almost everyone conflates: training (GPTBot, ClaudeBot, CCBot), search/index (OAI-SearchBot, Claude-SearchBot, PerplexityBot, Googlebot) and live retrieval by a human in a chat (ChatGPT-User, Claude-User, Perplexity-User). Blocking training costs NO visibility. Blocking search costs all citability. The interface prevents exactly that mistake, with plain-language warnings instead of fine print. Default: nothing blocked. This is not a blocker plugin. AI traffic dashboard, entirely local. Shows which AI bots fetch your content, which pages they crawl the most, how many visitors come back from AI answers, and the key figure: crawl-to-refer, i.e. how many pages a provider fetches before it sends you one visitor. No account, no cloud, no IP addresses in the database. If you enable the optional OpenAI bot verification, hits from GPTBot & Co. are checked against the official IP ranges; where a provider publishes none (Anthropic, Perplexity, Meta), the dashboard says so openly instead of presenting a user agent string as proof. IndexNow. Reports new and changed content immediately to Bing and participating search engines instead of waiting for the next crawl. Relevant because ChatGPT's web answers are backed by the Bing index. Off by default (opt-in). Markdown for agents. Agentic clients (Claude Code, Cursor, OpenCode) request pages with "Accept: text/markdown". Hafen Core answers with a clean Markdown version of your content, alternatively via ?format=md or the .md suffix. That saves the model the layout, navigation and script ballast. The Markdown version is sent with "X-Robots-Tag: noindex", and "Vary: Accept" is placed specifically on the responses that can also be served as Markdown, so no page cache serves the Markdown version to browsers – and on no other response, so proxy caches do not fragment unnecessarily. Only published, publicly visible, non-password-protected content is served. Citability linter in the editor. Checks the post against 15 rules and shows, per rule, whether it passes and how well it is supported by evidence (strong / medium / weak), including the source. Deliberately WITHOUT a 0–100 score: nobody knows a citation probability, and we do not pretend to. It also includes a check for prompt injection and cloaking, because that is a penalty issue, not an optimization issue. The optional AI deep check uses the AI assistant and is not a requirement: all rules run without AI as well. Abilities API and WebMCP. Where WordPress ships the Abilities API (6.9+), Hafen Core registers read-only abilities (page as Markdown, search content) as well as the AI assistant's generators; only the read-only ones are exposed to MCP. On top of that come read-only WebMCP browser tools. Honest framing: WebMCP is a Chrome experiment and only has an effect while the tab is open. Crawlers see none of it; it does nothing for visibility. A tiny snippet loads the script only in browsers that actually have the API; everyone else pays 0 additional requests. Both are pure feature detection, not a dependency. llms.txt generator. Publishes a curated content map at /llms.txt (and /llms-full.txt). Honest framing: Google states that it ignores llms.txt, and measurements show AI systems practically never fetch the file. Useful for coding agents, not for visibility in AI search. We ship it because it costs nothing, and we promise nothing for it. Performance status. Speed is a core commitment of the Hafen family. The dashboard (Settings > AI Traffic) therefore shows honestly what your setup delivers: page cache detected or not, compression via self-test, the theme's font mode (variable/static/system) – each with a plain-language recommendation. Plus an option to disable the WordPress emoji script (~26 KB and one external request to s.w.org saved; off by default). Cache and compression are server matters no plugin can solve from the inside. That is exactly why we display them instead of making promises. Everything runs without a build step and is GDPR-friendly. Schema, blocks and llms.txt work entirely locally. External connections only occur for features you explicitly enable or trigger: the optional AI assistant (through the WordPress AI client, provider and key configured under Settings > Connectors, only on click), the optional OpenAI bot verification (IP ranges, off by default), IndexNow (opt-in) and the video block (YouTube, only after a click). Details under "External services".

安装:

  1. Upload and activate the plugin (Plugins > Add New > Upload).
  2. After activation, /llms.txt is immediately available and the schema is active.
  3. Under Settings > Hafen Core, adjust the organization name, logo and the switches for schema, llms.txt, traffic measurement and IndexNow.
  4. Under Settings > AI Crawler Policy, define which AI bots are allowed. Recommended: "Do not train, but cite". Default: everything allowed.
  5. Under Settings > AI Traffic, see who fetches your content and who sends visitors back in return.

屏幕截图:

  • AI crawler policy – the bot matrix by purpose (training, search/index, live retrieval) with plain-language warnings before every block.
  • AI traffic dashboard – hits per bot, crawl-to-refer ratio per provider and the measurement quality indicator.
  • Access gate (Under Construction) – one of the three bundled templates with automatically applied logo and accent color.
  • The four answer engine blocks in the editor: FAQ, HowTo, TL;DR and Definition.
  • The optional AI assistant in the editor sidebar (meta description, TL;DR and FAQ suggestions).

升级注意事项:

1.0.1 Maintenance release: the agent abilities now actually register on WordPress 6.9 and newer, the block editor is English instead of German, no more deprecation warnings from the editor sidebars, safer table name binding on uninstall, and the full plugin name. Nothing to reconfigure. 1.0.0 First WordPress.org release. Source language is now English; translations arrive via translate.wordpress.org. The AI assistant runs through the WordPress AI client. The setup wizard no longer replaces an existing homepage. Review the AI crawler policy after updating. 0.9.0 The weekly OpenAI IP range fetch previously ran automatically with the AI traffic measurement; it is now its own opt-in switch (Settings > AI Traffic), OFF by default. Anyone who wants to use bot verification must enable it once after the update. 0.8.1 Security fix: the access gate did not apply to the REST API, llms.txt, the IndexNow key file and the Markdown delivery. Update recommended if the access gate is in use.

常见问题:

Do I need the Hafen theme?

No. The blocks, the schema and llms.txt work with any theme. With the Hafen theme they share design tokens and look like one consistent whole.

Does the schema collide with an SEO plugin?

No. In auto mode (default), Hafen Core detects common SEO plugins (Yoast, Rank Math, SEOPress, All in One SEO, The SEO Framework, Slim SEO, Squirrly) and steps back where schema overlaps: it leaves Organization, WebSite, Article and Breadcrumb to the SEO plugin and only outputs FAQPage/HowTo generated from the Hafen answer blocks. The mode can be changed under Settings > Hafen Core (Auto / Full / Answer schema only / Off). Fine-grained control via the hafen_core_schema_nodes filter.

Are external services contacted?

Schema, llms.txt, crawler policy, Markdown delivery, the citability linter (without the deep check) and the traffic dashboard work entirely locally. External connections only occur for features you explicitly enable: the AI assistant including the linter's optional AI deep check (through the WordPress AI client and the connector you configured), IndexNow (opt-in), the optional OpenAI bot verification (Settings > AI Traffic; when enabled it fetches OpenAI's public IP ranges weekly) and the video block (YouTube, only after a click). Without these consents the plugin makes not a single external call on its own. Details under "External services".

Does the plugin block AI bots?

Only if you explicitly configure it to. The default blocks nothing. Recommended is "Do not train, but cite": turn away training bots, leave search and retrieval bots open. And the honest limitation right away: robots.txt is a request, not a lock. Whoever ignores it is not stopped by it; real protection requires a WAF or a CDN. Agentic browsers (ChatGPT Agent, Perplexity Comet, Claude for Chrome) send no bot token at all and cannot be addressed via robots.txt in principle.

Does Google-Extended prevent the AI Overviews?

No, and this is the most widespread misconception in this field. Google-Extended is purely an opt-out token for Gemini training. The AI Overviews draw from the regular Googlebot index.

Why are my bot numbers lower than in my server logs?

Because a full-page cache (WP Rocket, LiteSpeed, W3 Total Cache, WP Super Cache, Varnish, Nginx FastCGI, Cloudflare APO) serves the finished page without PHP running. No WordPress plugin sees those hits, not even a mu-plugin. The dashboard detects common cache plugins, displays the measurement quality openly (three states, including "INCOMPLETE") and sets up the required user agent exception – automatically for WP Rocket, otherwise with a ready-made list to paste. The only gap-free method remains analyzing the server access logs; this plugin cannot and does not try to do that.

更新日志:

1.0.1 Maintenance release. Nothing to reconfigure. 1.0.0 The WordPress.org release. 0.9.0 WordPress.org submission: opt-in instead of automatism where it matters. 0.8.1 Security fix: the access gate only applied to normal page views. Everything WordPress serves through other routes remained reachable unprotected, even though the actual page correctly showed the under-construction page with HTTP 503. 0.8.0 First impressions: no more error message, no empty pages, no bare "No data yet." lines. 0.7.2 Performance package (together with Hafen theme 0.3.1: variable font and system font variation "Stapellauf"). 0.7.1 0.7.0 0.6.1 0.6.0 The core of this release: we help you get found and cited instead of locking AI crawlers out. Without invented numbers, with clearly named limitations. 0.5.1 WordPress.org preparation. 0.5.0 Source of this release: hands-on feedback from the real-world project vielfalt-begleiten.nrw. 0.4.1 0.4.0 0.3.0 0.2.0 0.1.0