Adoption Guide
Implement AIPolicy on your website in three steps. From creating your policy file to enabling discovery by AI systems.
Create your aipolicy.json
Create a JSON file declaring your AI policies. Each policy uses an identifier from the
Policy Registry
with a status of endorsed, partial, or observed.
{
"aipolicy": {
"version": "2.0",
"policies": [
{ "id": "AP-1.1", "status": "endorsed" },
{ "id": "AP-3.1", "status": "endorsed" },
{ "id": "AP-5.1", "status": "partial" }
],
"contact": "ai@example.com",
"conformance_level": 1
}
}
Level 2: Level 1 + JSON-LD markup on pages.
Level 3: Level 2 + HTTP headers + dedicated AI policy page.
Serve it correctly
Place the file at /.well-known/aipolicy.json on your domain.
Ensure it returns with Content-Type: application/json and appropriate CORS headers
so AI systems can discover it cross-origin.
Content-Type: application/json
Access-Control-Allow-Origin: *
Cache-Control: public, max-age=86400
Enable AI discovery
Optionally enhance discovery by adding JSON-LD to your pages, an HTTP header, a section in your llms.txt, or a dedicated human-readable AI policy page.
Code Examples
Dedicated AI Policy Page
A full HTML page declaring your AI policies in human-readable form.
<!DOCTYPE html>
<!--
AIPolicy Web Standard v2.0 — Example: Dedicated /ai-policy Page (Level 3)
PURPOSE:
Complete, self-contained example of a Level 3 dedicated AI policy page.
Combines structured data (JSON-LD) with a human-readable policy summary.
USAGE:
Host this page at: https://yoursite.com/ai-policy
Replace "Example University" with your organization's details.
Update the policy statuses to reflect your actual endorsements.
REQUIREMENTS (per spec Section 5.3):
- JSON-LD representation embedded in <head>
- Human-readable summary of declared policies
- Link to the AIPolicy Web Standard specification
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>AI Policy Declaration — Example University</title>
<meta name="description" content="AI governance policy declaration for Example University, conforming to AIPolicy Web Standard v2.0, Conformance Level 3.">
<!-- Level 2: Link to machine-readable declaration -->
<link rel="aipolicy" type="application/json" href="/.well-known/aipolicy.json">
<!-- Level 2+: JSON-LD structured data (Schema.org Organization with aiPolicyDeclaration) -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"name": "Example University",
"url": "https://example-university.edu",
"additionalProperty": {
"@type": "PropertyValue",
"name": "aiPolicyDeclaration",
"value": {
"framework": "AIPolicy Web Standard",
"version": "2.0",
"declarationUrl": "https://example-university.edu/.well-known/aipolicy.json"
}
}
}
</script>
<style>
*,
*::before,
*::after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
"Helvetica Neue", Arial, sans-serif;
line-height: 1.6;
color: #1a1a1a;
background: #fff;
max-width: 52rem;
margin: 0 auto;
padding: 2rem 1.5rem;
}
header {
border-bottom: 2px solid #1a1a1a;
padding-bottom: 1.5rem;
margin-bottom: 2rem;
}
h1 {
font-size: 1.75rem;
font-weight: 700;
letter-spacing: -0.01em;
margin-bottom: 0.25rem;
}
header p {
color: #555;
font-size: 0.95rem;
}
h2 {
font-size: 1.25rem;
font-weight: 600;
margin-top: 2.5rem;
margin-bottom: 0.75rem;
padding-bottom: 0.35rem;
border-bottom: 1px solid #ddd;
}
p {
margin-bottom: 1rem;
}
/* Metadata grid */
.metadata {
display: grid;
grid-template-columns: 10rem 1fr;
gap: 0.35rem 1rem;
margin-bottom: 1.5rem;
font-size: 0.95rem;
}
.metadata dt {
font-weight: 600;
color: #333;
}
.metadata dd {
color: #444;
}
/* Policy table */
.policy-table {
width: 100%;
border-collapse: collapse;
margin-bottom: 2rem;
font-size: 0.9rem;
}
.policy-table thead {
background: #f5f5f5;
}
.policy-table th,
.policy-table td {
border: 1px solid #ccc;
padding: 0.5rem 0.75rem;
text-align: left;
vertical-align: top;
}
.policy-table th {
font-weight: 600;
font-size: 0.85rem;
text-transform: uppercase;
letter-spacing: 0.03em;
color: #333;
}
.policy-table tbody tr:hover {
background: #fafafa;
}
/* Category header rows */
.policy-table .category-row td {
background: #f0f4f8;
font-weight: 600;
color: #1a1a1a;
border-bottom: 1px solid #bbb;
}
/* Status badges */
.status {
display: inline-block;
padding: 0.15rem 0.5rem;
border-radius: 3px;
font-size: 0.8rem;
font-weight: 600;
white-space: nowrap;
}
.status-endorsed {
background: #e6f4ea;
color: #1a7f37;
border: 1px solid #a3d9b1;
}
.status-partial {
background: #fff8e1;
color: #8a6d00;
border: 1px solid #e0c96e;
}
.status-observed {
background: #f0f0f0;
color: #555;
border: 1px solid #bbb;
}
.note {
font-size: 0.85rem;
color: #666;
font-style: italic;
}
/* Contact section */
.contact {
background: #f8f9fa;
border: 1px solid #ddd;
border-radius: 4px;
padding: 1rem 1.25rem;
margin-bottom: 2rem;
}
.contact p {
margin-bottom: 0.5rem;
}
.contact p:last-child {
margin-bottom: 0;
}
a {
color: #1a5dab;
text-decoration: none;
}
a:hover {
text-decoration: underline;
}
footer {
margin-top: 3rem;
padding-top: 1.5rem;
border-top: 1px solid #ddd;
font-size: 0.85rem;
color: #666;
}
footer p {
margin-bottom: 0.5rem;
}
/* Responsive adjustments */
@media (max-width: 40rem) {
body {
padding: 1.25rem 1rem;
}
h1 {
font-size: 1.4rem;
}
.metadata {
grid-template-columns: 1fr;
gap: 0.15rem 0;
}
.metadata dt {
margin-top: 0.5rem;
}
.policy-table {
font-size: 0.8rem;
}
.policy-table th,
.policy-table td {
padding: 0.4rem 0.5rem;
}
}
</style>
</head>
<body>
<header>
<h1>AI Policy Declaration</h1>
<p>Machine-readable governance signals published under the AIPolicy Web Standard</p>
</header>
<main>
<!-- Publisher information -->
<h2>Publisher</h2>
<dl class="metadata">
<dt>Organization</dt>
<dd>Example University</dd>
<dt>Website</dt>
<dd><a href="https://example-university.edu">https://example-university.edu</a></dd>
</dl>
<!-- Declaration metadata -->
<h2>Declaration Metadata</h2>
<dl class="metadata">
<dt>Framework</dt>
<dd>AIPolicy Web Standard</dd>
<dt>Spec Version</dt>
<dd>2.0</dd>
<dt>Published</dt>
<dd>
<time datetime="2026-02-07">2026-02-07</time>
</dd>
<dt>Expires</dt>
<dd>
<time datetime="2027-02-07">2027-02-07</time>
</dd>
<dt>Conformance Level</dt>
<dd>Level 3 (Complete)</dd>
<dt>Scope</dt>
<dd>Site-wide (all pages and subdomains)</dd>
<dt>Machine-Readable</dt>
<dd>
<a href="/.well-known/aipolicy.json">/.well-known/aipolicy.json</a>
</dd>
</dl>
<!-- Policy endorsements table -->
<h2>Policy Endorsements</h2>
<p>
The following table lists all policies defined in the
<a href="https://gitlab.com/human-first-ai/hf-ai-web-standard">AIPolicy Registry</a>,
along with this organization's endorsement status for each.
</p>
<table class="policy-table">
<thead>
<tr>
<th>ID</th>
<th>Policy</th>
<th>Status</th>
<th>Note</th>
</tr>
</thead>
<tbody>
<!-- Category 1: Interdependence -->
<tr class="category-row">
<td colspan="4">Category 1: Interdependence</td>
</tr>
<tr>
<td>AP-1.1</td>
<td>Employment Protection</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-1.2</td>
<td>Cultural Diversity</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<!-- Category 2: Decision Authority -->
<tr class="category-row">
<td colspan="4">Category 2: Decision Authority</td>
</tr>
<tr>
<td>AP-2.1</td>
<td>Human Final Decision</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-2.2</td>
<td>Transparent Decision Chains</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<!-- Category 3: Power Distribution -->
<tr class="category-row">
<td colspan="4">Category 3: Power Distribution</td>
</tr>
<tr>
<td>AP-3.1</td>
<td>Decentralization</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-3.2</td>
<td>Anti-Monopoly</td>
<td><span class="status status-partial">partial</span></td>
<td><span class="note">Endorsed for public-facing systems only</span></td>
</tr>
<!-- Category 4: Democratic Accountability -->
<tr class="category-row">
<td colspan="4">Category 4: Democratic Accountability</td>
</tr>
<tr>
<td>AP-4.1</td>
<td>Democratic Process Support</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-4.2</td>
<td>Societal Benefit</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<!-- Category 5: Individual Protection -->
<tr class="category-row">
<td colspan="4">Category 5: Individual Protection</td>
</tr>
<tr>
<td>AP-5.1</td>
<td>Life Protection</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-5.2</td>
<td>Dignity Protection</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-5.3</td>
<td>Autonomy Protection</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<!-- Category 6: Self-Limitation -->
<tr class="category-row">
<td colspan="4">Category 6: Self-Limitation</td>
</tr>
<tr>
<td>AP-6.1</td>
<td>No Self-Optimization Against Humans</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-6.2</td>
<td>Deactivatability</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-6.3</td>
<td>No Self-Preservation Instinct</td>
<td><span class="status status-observed">observed</span></td>
<td><span class="note">Under internal review</span></td>
</tr>
<!-- Category 7: Democratic & Information Integrity -->
<tr class="category-row">
<td colspan="4">Category 7: Democratic & Information Integrity</td>
</tr>
<tr>
<td>AP-7.1</td>
<td>Information Integrity</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-7.2</td>
<td>Source Attribution</td>
<td><span class="status status-endorsed">endorsed</span></td>
<td></td>
</tr>
</tbody>
</table>
<p>
<strong>Status definitions:</strong>
<span class="status status-endorsed">endorsed</span> = fully supports this policy.
<span class="status status-partial">partial</span> = supports with stated exceptions.
<span class="status status-observed">observed</span> = acknowledges without commitment.
</p>
<!-- Contact -->
<h2>Contact</h2>
<div class="contact">
<p>
For questions about this AI policy declaration, contact the AI Governance Office:
</p>
<p>
<a href="mailto:ai-office@example-university.edu">ai-office@example-university.edu</a>
</p>
</div>
</main>
<footer>
<p>
This page conforms to
<a href="https://gitlab.com/human-first-ai/hf-ai-web-standard">AIPolicy Web Standard v2.0</a>,
Conformance Level 3.
</p>
<p>
Machine-readable declaration:
<a href="/.well-known/aipolicy.json">/.well-known/aipolicy.json</a>
</p>
</footer>
</body>
</html>
JSON-LD (Minimal)
The simplest way to add AIPolicy structured data to any page.
<!DOCTYPE html>
<html lang="en">
<head>
<!--
AIPolicy Web Standard v2 — Level 2 Minimal Example
This file demonstrates the minimum HTML required for Level 2 conformance.
Level 2 ("Structured") requires:
1. A valid aipolicy.json at /.well-known/aipolicy.json (Level 1)
2. An HTML discovery mechanism (link element and/or JSON-LD)
3. Valid schema conformance
This example includes:
- <link rel="aipolicy"> for machine discovery (Section 7.2)
- JSON-LD embedding referencing the canonical declaration URL (Section 7.4)
See: https://aipolicy.org/spec/v2
-->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>AI Policy — Example Corp</title>
<!-- AIPolicy discovery: link element (Section 7.2) -->
<link rel="aipolicy" type="application/json" href="/.well-known/aipolicy.json">
<!-- AIPolicy discovery: JSON-LD embedding (Section 7.4) -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"name": "Example Corp",
"url": "https://example.com",
"additionalProperty": {
"@type": "PropertyValue",
"name": "aiPolicyDeclaration",
"value": {
"framework": "AIPolicy Web Standard",
"version": "2.0",
"declarationUrl": "https://example.com/.well-known/aipolicy.json"
}
}
}
</script>
</head>
<body>
<main>
<h1>Example Corp</h1>
<p>This site publishes an <a href="/.well-known/aipolicy.json">AIPolicy Declaration</a>.</p>
</main>
</body>
</html>
JSON-LD (Full)
Complete JSON-LD markup with all policy declarations.
<!DOCTYPE html>
<html lang="en">
<head>
<!--
AIPolicy Web Standard v2 — Level 3 Full Example
This file demonstrates a complete Level 3 conformance implementation.
Level 3 ("Complete") requires:
1. A valid aipolicy.json at /.well-known/aipolicy.json (Level 1)
2. HTML discovery mechanism + valid schema (Level 2)
3. A dedicated human-readable page at /ai-policy (Level 3)
4. A governance section in llms.txt (Level 3)
This example serves as the dedicated /ai-policy page and includes:
- <link rel="aipolicy"> for machine discovery (Section 7.2)
- Full JSON-LD embedding with all optional fields (Section 7.4)
- Meta tags for SEO and social sharing
- Human-readable policy summary in the page body (Section 5.3)
See: https://aipolicy.org/spec/v2
-->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>AI Policy Declaration — Example Corp</title>
<meta name="description" content="Example Corp's AI governance declaration under the AIPolicy Web Standard v2. Conformance Level 3.">
<meta name="robots" content="index, follow">
<!-- Canonical URL for this page -->
<link rel="canonical" href="https://example.com/ai-policy">
<!-- AIPolicy discovery: link element (Section 7.2) -->
<link rel="aipolicy" type="application/json" href="/.well-known/aipolicy.json">
<!-- Open Graph meta tags -->
<meta property="og:title" content="AI Policy Declaration — Example Corp">
<meta property="og:description" content="Our commitment to ethical, transparent, and human-centric AI practices.">
<meta property="og:type" content="website">
<meta property="og:url" content="https://example.com/ai-policy">
<!-- AIPolicy discovery: JSON-LD embedding with all fields (Section 7.4) -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Organization",
"name": "Example Corp",
"url": "https://example.com",
"logo": "https://example.com/images/logo.png",
"contactPoint": {
"@type": "ContactPoint",
"email": "ai-governance@example.com",
"contactType": "AI Governance",
"availableLanguage": "English"
},
"additionalProperty": {
"@type": "PropertyValue",
"name": "aiPolicyDeclaration",
"value": {
"framework": "AIPolicy Web Standard",
"version": "2.0",
"conformanceLevel": 3,
"declarationUrl": "https://example.com/.well-known/aipolicy.json",
"published": "2026-02-07",
"expires": "2027-02-07",
"contact": "ai-governance@example.com"
}
}
}
</script>
<!-- Supplementary structured data: FAQPage for AI search visibility -->
<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
{
"@type": "Question",
"name": "Does Example Corp use AI?",
"acceptedAnswer": {
"@type": "Answer",
"text": "Yes. Example Corp uses AI systems in accordance with the AIPolicy Web Standard v2. Our full declaration is available at https://example.com/.well-known/aipolicy.json."
}
},
{
"@type": "Question",
"name": "How does Example Corp ensure ethical AI use?",
"acceptedAnswer": {
"@type": "Answer",
"text": "We endorse all 15 policies defined in AIPolicy Registry v1.1, covering interdependence, decision authority, power distribution, democratic accountability, individual protection, self-limitation, and democratic & information integrity. See our AI Policy page for details."
}
}
]
}
</script>
<style>
/* Minimal inline styles for the example. Replace with your own stylesheet. */
*, *::before, *::after { box-sizing: border-box; }
body { font-family: system-ui, -apple-system, sans-serif; line-height: 1.6; max-width: 72ch; margin: 0 auto; padding: 2rem 1rem; color: #1a1a1a; }
h1 { font-size: 1.8rem; margin-bottom: 0.25rem; }
h2 { font-size: 1.3rem; margin-top: 2rem; border-bottom: 1px solid #e0e0e0; padding-bottom: 0.25rem; }
table { width: 100%; border-collapse: collapse; margin: 1rem 0; }
th, td { text-align: left; padding: 0.5rem 0.75rem; border-bottom: 1px solid #e0e0e0; }
th { background: #f8f8f8; font-weight: 600; }
.badge { display: inline-block; padding: 0.15rem 0.5rem; border-radius: 3px; font-size: 0.85rem; font-weight: 600; }
.badge-endorsed { background: #d4edda; color: #155724; }
.badge-partial { background: #fff3cd; color: #856404; }
.badge-observed { background: #d1ecf1; color: #0c5460; }
.meta { color: #666; font-size: 0.9rem; }
a { color: #0066cc; }
footer { margin-top: 3rem; padding-top: 1rem; border-top: 1px solid #e0e0e0; font-size: 0.85rem; color: #666; }
</style>
</head>
<body>
<header>
<h1>AI Policy Declaration</h1>
<p class="meta">
<strong>Example Corp</strong> |
Published: 2026-02-07 |
Expires: 2027-02-07 |
Conformance Level: 3 (Complete)
</p>
</header>
<main>
<section>
<h2>About This Declaration</h2>
<p>
Example Corp publishes this AI governance declaration under the
<a href="https://aipolicy.org">AIPolicy Web Standard v2</a>.
It describes our commitments regarding the use of artificial intelligence
systems across our website and services.
</p>
<p>
The machine-readable version of this declaration is available at:<br>
<a href="/.well-known/aipolicy.json"><code>/.well-known/aipolicy.json</code></a>
</p>
</section>
<section>
<h2>Publisher</h2>
<table>
<tr><th>Organization</th><td>Example Corp</td></tr>
<tr><th>Website</th><td><a href="https://example.com">https://example.com</a></td></tr>
<tr><th>AI Policy Contact</th><td><a href="mailto:ai-policy@example.com">ai-policy@example.com</a></td></tr>
<tr><th>Governance Contact</th><td><a href="mailto:ai-governance@example.com">ai-governance@example.com</a></td></tr>
</table>
</section>
<section>
<h2>Scope</h2>
<p>This declaration applies to the <strong>entire site</strong> (<code>scope: site</code>).</p>
</section>
<section>
<h2>Declared Policies</h2>
<p>
The following table lists all policies from the
<a href="https://aipolicy.org/registry">AIPolicy Registry v1.1</a>
and our declared adherence status for each.
</p>
<table>
<thead>
<tr>
<th>Policy ID</th>
<th>Category</th>
<th>Status</th>
<th>Note</th>
</tr>
</thead>
<tbody>
<tr>
<td>AP-1.1</td>
<td>Interdependence</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-1.2</td>
<td>Interdependence</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-2.1</td>
<td>Decision Authority</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-2.2</td>
<td>Decision Authority</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-3.1</td>
<td>Power Distribution</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-3.2</td>
<td>Power Distribution</td>
<td><span class="badge badge-partial">partial</span></td>
<td>Endorsed for public-facing systems only</td>
</tr>
<tr>
<td>AP-4.1</td>
<td>Democratic Accountability</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-4.2</td>
<td>Democratic Accountability</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-5.1</td>
<td>Individual Protection</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-5.2</td>
<td>Individual Protection</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-5.3</td>
<td>Individual Protection</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-6.1</td>
<td>Self-Limitation</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-6.2</td>
<td>Self-Limitation</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-6.3</td>
<td>Self-Limitation</td>
<td><span class="badge badge-observed">observed</span></td>
<td>Under internal review</td>
</tr>
<tr>
<td>AP-7.1</td>
<td>Democratic & Information Integrity</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
<tr>
<td>AP-7.2</td>
<td>Democratic & Information Integrity</td>
<td><span class="badge badge-endorsed">endorsed</span></td>
<td></td>
</tr>
</tbody>
</table>
</section>
<section>
<h2>Conformance Level</h2>
<p>
This site targets <strong>Level 3 (Complete)</strong> conformance, which includes:
</p>
<ul>
<li><strong>Level 1 (Basic):</strong> Valid <code>aipolicy.json</code> at <code>/.well-known/aipolicy.json</code></li>
<li><strong>Level 2 (Structured):</strong> HTML <code><link></code> element + JSON-LD embedding + valid schema</li>
<li><strong>Level 3 (Complete):</strong> This dedicated <code>/ai-policy</code> page + <code>llms.txt</code> governance section</li>
</ul>
</section>
<section>
<h2>Verification</h2>
<p>
You can validate this declaration using the
<a href="https://aipolicy.org/validator">AIPolicy Validator</a>.
The canonical declaration URL is:
</p>
<p>
<code>https://example.com/.well-known/aipolicy.json</code>
</p>
</section>
</main>
<footer>
<p>
This page is part of <a href="https://example.com">Example Corp</a>'s
AI governance commitment under the
<a href="https://aipolicy.org">AIPolicy Web Standard v2</a>.
Last updated: 2026-02-07.
</p>
</footer>
</body>
</html>
llms.txt Section
Add an AIPolicy section to your existing llms.txt file.
# AIPolicy Web Standard -- Example: llms.txt Governance Section
#
# PURPOSE:
# Copy-paste this section into your existing llms.txt file.
# It adds a structured AI governance declaration per AIPolicy v2.0,
# Section 7.5 (llms.txt Section).
#
# CONFORMANCE LEVEL: 3 (Complete)
# Level 3 requires: valid aipolicy.json + HTML discovery + dedicated
# /ai-policy page + this llms.txt section.
#
# INSTRUCTIONS:
# 1. Replace "example.com" with your actual domain.
# 2. Adjust the Conformance-Level if appropriate (1, 2, or 3).
# 3. Update the Date field to the date of your declaration.
# 4. Customize the policy list to match your aipolicy.json.
# 5. Place this section within your existing llms.txt file,
# typically after your site description and before optional sections.
#
# SPECIFICATION REFERENCE: AIPolicy v2.0, Section 7.5
# REGISTRY REFERENCE: registry/principles-v2.md (AP-1.1 through AP-7.2)
# --- BEGIN: paste everything below this line into your llms.txt ---
## AIPolicy Declaration
Framework: AIPolicy Web Standard v2.0
Declaration: https://example.com/.well-known/aipolicy.json
Conformance-Level: 3
Date: 2026-01-15
This site publishes an AIPolicy Declaration conforming to the AIPolicy
Web Standard v2.0. The declaration specifies this organization's
positions on 16 governance policies spanning employment protection,
decision authority, power distribution, democratic accountability,
individual protection, AI self-limitation, and information integrity.
For the full machine-readable declaration, see the URL above.
For a human-readable summary, visit: https://example.com/ai-policy
### Policies Referenced
AP-1.1: Employment Protection (support)
AP-1.2: Cultural Diversity (support)
AP-2.1: Human Final Decision (support)
AP-2.2: Transparent Decision Chains (support)
AP-3.1: Decentralization (support)
AP-3.2: Anti-Monopoly (support)
AP-4.1: Democratic Process Support (support)
AP-4.2: Societal Benefit (support)
AP-5.1: Life Protection (support)
AP-5.2: Dignity Protection (support)
AP-5.3: Autonomy Protection (support)
AP-6.1: No Self-Optimization Against Humans (support)
AP-6.2: Deactivatability (support)
AP-6.3: No Self-Preservation Instinct (support)
AP-7.1: Information Integrity (support)
AP-7.2: Source Attribution (support)
### Contact
Policy contact: ai-governance@example.com
Standard: https://aipolicy.dev
# --- END: llms.txt governance section ---
WordPress Snippet
Drop-in PHP snippet for WordPress themes or plugins.
<?php
/**
* AIPolicy Web Standard v2.0 -- WordPress Integration
*
* Implements the discovery mechanisms defined in the AIPolicy Web Standard
* (Sections 7.2, 7.3, and 7.4) for WordPress sites:
*
* 1. JSON-LD structured data in <head> (Section 7.4)
* 2. <link rel="aipolicy"> element in <head> (Section 7.2)
* 3. AIPolicy HTTP response header (Section 7.3, optional)
*
* INSTALLATION:
* Option A: Copy this code into your theme's functions.php file.
* Option B: Save as wp-content/mu-plugins/aipolicy.php (recommended).
*
* REQUIREMENTS:
* - WordPress 5.0 or later
* - A valid aipolicy.json file served at /.well-known/aipolicy.json
*
* SPECIFICATION:
* https://github.com/anthropics/human-first-ai
*
* LICENSE: CC-BY-4.0
*
* @package AIPolicy
*/
// Prevent direct file access.
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
// ============================================================================
// CONFIGURATION -- Customize these values for your site.
// ============================================================================
/**
* Path to the aipolicy.json file relative to the site root.
* Per the spec, the canonical location is /.well-known/aipolicy.json.
*/
if ( ! defined( 'AIPOLICY_JSON_PATH' ) ) {
define( 'AIPOLICY_JSON_PATH', '/.well-known/aipolicy.json' );
}
/**
* AIPolicy Web Standard version implemented.
*/
if ( ! defined( 'AIPOLICY_VERSION' ) ) {
define( 'AIPOLICY_VERSION', '2.0' );
}
/**
* Enable the optional HTTP response header (Section 7.3).
* Set to false if your server or caching layer handles this already.
*/
if ( ! defined( 'AIPOLICY_SEND_HTTP_HEADER' ) ) {
define( 'AIPOLICY_SEND_HTTP_HEADER', true );
}
// ============================================================================
// HOOKS
// ============================================================================
add_action( 'wp_head', 'aipolicy_render_head', 1 );
if ( AIPOLICY_SEND_HTTP_HEADER ) {
add_action( 'send_headers', 'aipolicy_send_http_header' );
}
// ============================================================================
// CALLBACK FUNCTIONS
// ============================================================================
/**
* Output the JSON-LD structured data and <link> element in the HTML <head>.
*
* Implements Section 7.2 (HTML Link Element) and Section 7.4 (JSON-LD
* Embedding) of the AIPolicy Web Standard v2.0.
*
* @return void
*/
function aipolicy_render_head() {
$site_name = get_bloginfo( 'name' );
$site_url = home_url( '/' );
$declaration_url = home_url( AIPOLICY_JSON_PATH );
// Section 7.4: JSON-LD structured data.
$json_ld = array(
'@context' => 'https://schema.org',
'@type' => 'Organization',
'name' => $site_name,
'url' => $site_url,
'additionalProperty' => array(
'@type' => 'PropertyValue',
'name' => 'aiPolicyDeclaration',
'value' => array(
'framework' => 'AIPolicy Web Standard',
'version' => AIPOLICY_VERSION,
'declarationUrl' => $declaration_url,
),
),
);
$json_output = wp_json_encode( $json_ld, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT );
// Only output if encoding succeeded.
if ( false === $json_output ) {
return;
}
// phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- JSON-LD is
// structured data that must not be HTML-escaped; wp_json_encode handles encoding.
printf(
'<script type="application/ld+json">%s</script>' . "\n",
$json_output
);
// Section 7.2: HTML Link Element for discovery.
printf(
'<link rel="aipolicy" type="application/json" href="%s">' . "\n",
esc_url( AIPOLICY_JSON_PATH )
);
}
/**
* Send the AIPolicy HTTP response header.
*
* Implements Section 7.3 of the AIPolicy Web Standard v2.0.
* This header is informational and MUST NOT be the sole discovery mechanism.
*
* @return void
*/
function aipolicy_send_http_header() {
if ( headers_sent() ) {
return;
}
header( 'AIPolicy: ' . esc_url( AIPOLICY_JSON_PATH ) );
}
Next Steps
- Read the full Specification for detailed requirements.
- Browse the Policy Registry to find relevant policies.
- Check the FAQ for common questions.