aeorank 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 AEO Content, Inc
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,172 @@
1
+ # AEORank
2
+
3
+ Score any website for AI engine visibility across 23 criteria. Pure HTTP + regex - zero API keys required.
4
+
5
+ [![npm version](https://img.shields.io/npm/v/aeorank.svg)](https://www.npmjs.com/package/aeorank)
6
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
7
+ [![Node.js CI](https://github.com/AEO-Content-Inc/aeorank/actions/workflows/ci.yml/badge.svg)](https://github.com/AEO-Content-Inc/aeorank/actions/workflows/ci.yml)
8
+
9
+ ## Quick Start
10
+
11
+ ### CLI
12
+
13
+ ```bash
14
+ npx aeorank example.com
15
+ ```
16
+
17
+ ```bash
18
+ npx aeorank example.com --json # JSON output
19
+ npx aeorank example.com --summary # Human-readable scorecard
20
+ npx aeorank example.com --ci --threshold 80 # CI gate
21
+ ```
22
+
23
+ ### Programmatic
24
+
25
+ ```ts
26
+ import { audit } from 'aeorank';
27
+
28
+ const result = await audit('example.com');
29
+ console.log(result.overallScore); // 0-100
30
+ console.log(result.scorecard); // 23 criteria with scores
31
+ console.log(result.opportunities); // Prioritized improvements
32
+ ```
33
+
34
+ ## What It Checks
35
+
36
+ AEORank evaluates 23 criteria across 4 categories that determine how AI engines (ChatGPT, Claude, Perplexity, Google AI Overviews) discover, parse, and cite your content:
37
+
38
+ | # | Criterion | Weight | Category |
39
+ |---|-----------|--------|----------|
40
+ | 1 | llms.txt File | 10% | Discovery |
41
+ | 2 | Schema.org Structured Data | 15% | Structure |
42
+ | 3 | Q&A Content Format | 15% | Content |
43
+ | 4 | Clean, Crawlable HTML | 10% | Structure |
44
+ | 5 | Entity Authority & NAP Consistency | 10% | Authority |
45
+ | 6 | robots.txt for AI Crawlers | 5% | Discovery |
46
+ | 7 | Comprehensive FAQ Section | 10% | Content |
47
+ | 8 | Original Data & Expert Analysis | 10% | Content |
48
+ | 9 | Internal Linking Structure | 10% | Structure |
49
+ | 10 | Semantic HTML5 & Accessibility | 5% | Structure |
50
+ | 11 | Content Freshness Signals | 7% | Content |
51
+ | 12 | Sitemap Completeness | 5% | Discovery |
52
+ | 13 | RSS/Atom Feed | 3% | Discovery |
53
+ | 14 | Table & List Extractability | 7% | Structure |
54
+ | 15 | Definition Patterns | 4% | Content |
55
+ | 16 | Direct Answer Paragraphs | 7% | Content |
56
+ | 17 | Content Licensing & AI Permissions | 4% | Discovery |
57
+ | 18 | Author & Expert Schema | 4% | Authority |
58
+ | 19 | Fact & Data Density | 5% | Content |
59
+ | 20 | Canonical URL Strategy | 4% | Structure |
60
+ | 21 | Content Publishing Velocity | 3% | Content |
61
+ | 22 | Schema Coverage & Depth | 3% | Structure |
62
+ | 23 | Speakable Schema | 3% | Structure |
63
+
64
+ ## CLI Options
65
+
66
+ ```
67
+ aeorank <domain> [options]
68
+
69
+ Options:
70
+ --json Output raw JSON to stdout
71
+ --summary Print human-readable scorecard
72
+ --ci CI mode: JSON + exit 1 if score < threshold
73
+ --threshold <N> Score threshold for --ci (default: 70)
74
+ --no-headless Skip Puppeteer SPA rendering
75
+ --no-multi-page Skip extra page discovery (faster)
76
+ --version Print version
77
+ --help Show help
78
+ ```
79
+
80
+ ## GitHub Actions
81
+
82
+ ```yaml
83
+ - name: AEO Audit
84
+ run: npx aeorank ${{ env.SITE_URL }} --ci --threshold 70
85
+ ```
86
+
87
+ ## API
88
+
89
+ ### `audit(domain, options?)`
90
+
91
+ Run a complete audit. Returns `AuditResult` with:
92
+
93
+ - `overallScore` - 0-100 weighted score
94
+ - `scorecard` - 23 `ScoreCardItem` entries (criterion, score 0-10, status, key findings)
95
+ - `detailedFindings` - Per-criterion findings with severity
96
+ - `opportunities` - Prioritized improvements with effort/impact
97
+ - `pitchNumbers` - Key metrics (schema types, AI crawler access, etc.)
98
+ - `verdict` - Human-readable summary paragraph
99
+ - `bottomLine` - Actionable recommendation
100
+ - `pagesReviewed` - Per-page analysis with issues and strengths
101
+ - `elapsed` - Wall-clock seconds
102
+
103
+ **Options:**
104
+
105
+ | Option | Type | Default | Description |
106
+ |--------|------|---------|-------------|
107
+ | `noHeadless` | `boolean` | `false` | Skip Puppeteer SPA rendering |
108
+ | `noMultiPage` | `boolean` | `false` | Homepage + blog only |
109
+ | `timeout` | `number` | `15000` | Fetch timeout in ms |
110
+
111
+ ### Advanced API
112
+
113
+ For custom pipelines, import individual stages:
114
+
115
+ ```ts
116
+ import {
117
+ prefetchSiteData,
118
+ auditSiteFromData,
119
+ calculateOverallScore,
120
+ buildScorecard,
121
+ buildDetailedFindings,
122
+ generateVerdict,
123
+ generateOpportunities,
124
+ isSpaShell,
125
+ fetchWithHeadless,
126
+ } from 'aeorank';
127
+
128
+ const siteData = await prefetchSiteData('example.com');
129
+ const results = auditSiteFromData(siteData);
130
+ const score = calculateOverallScore(results);
131
+ ```
132
+
133
+ ## SPA Support
134
+
135
+ Sites that use client-side rendering (React, Vue, Angular) return empty HTML shells to regular HTTP requests. AEORank detects these automatically and re-renders them with Puppeteer if available.
136
+
137
+ Install Puppeteer as an optional dependency:
138
+
139
+ ```bash
140
+ npm install puppeteer
141
+ ```
142
+
143
+ Use `--no-headless` to skip SPA rendering (faster but may produce lower scores for SPAs).
144
+
145
+ ## Scoring
146
+
147
+ Each criterion is scored 0-10 by deterministic checks (regex, HTML parsing, HTTP headers). The overall score is a weighted average normalized to 0-100.
148
+
149
+ Score interpretation:
150
+ - **86-100** - Excellent AI visibility
151
+ - **71-85** - Strong fundamentals, room for optimization
152
+ - **56-70** - Moderate readiness, significant gaps
153
+ - **41-55** - Below average, multiple areas need attention
154
+ - **0-40** - Critical gaps, largely invisible to AI engines
155
+
156
+ ## Contributing
157
+
158
+ ```bash
159
+ git clone https://github.com/AEO-Content-Inc/aeorank.git
160
+ cd aeorank
161
+ npm install
162
+ npm test
163
+ npm run build
164
+ ```
165
+
166
+ ## License
167
+
168
+ MIT - see [LICENSE](LICENSE)
169
+
170
+ ---
171
+
172
+ Built by [AEO Content, Inc.](https://www.aeocontent.ai)