@adgine/geo-cli 1.2.8
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/README.md +93 -0
- package/bin/adgine-geo.js +224 -0
- package/package.json +38 -0
- package/skills/.env.example +11 -0
- package/skills/README.md +247 -0
- package/skills/SKILL.md +117 -0
- package/skills/VERSION +1 -0
- package/skills/adgine-geo-aiagent/SKILL.md +200 -0
- package/skills/adgine-geo-aiagent/scripts/_client.py +341 -0
- package/skills/adgine-geo-aiagent/scripts/bot_traffic.py +278 -0
- package/skills/adgine-geo-aiagent/scripts/human_traffic.py +357 -0
- package/skills/adgine-geo-aiagent/scripts/page_analytics.py +317 -0
- package/skills/adgine-geo-aiagent/scripts/page_detail.py +273 -0
- package/skills/adgine-geo-analytics/API.md +89 -0
- package/skills/adgine-geo-analytics/SKILL.md +191 -0
- package/skills/adgine-geo-analytics/scripts/_client.py +341 -0
- package/skills/adgine-geo-analytics/scripts/get_overview.py +129 -0
- package/skills/adgine-geo-billing/SKILL.md +118 -0
- package/skills/adgine-geo-billing/scripts/_client.py +341 -0
- package/skills/adgine-geo-billing/scripts/get_credits.py +51 -0
- package/skills/adgine-geo-billing/scripts/get_credits_pricing.py +52 -0
- package/skills/adgine-geo-billing/scripts/get_subscription.py +48 -0
- package/skills/adgine-geo-billing/scripts/list_plans.py +66 -0
- package/skills/adgine-geo-brand/SKILL.md +193 -0
- package/skills/adgine-geo-brand/WORKFLOW.md +66 -0
- package/skills/adgine-geo-brand/scripts/_client.py +341 -0
- package/skills/adgine-geo-brand/scripts/generate_brand.py +95 -0
- package/skills/adgine-geo-brand/scripts/get_brand.py +67 -0
- package/skills/adgine-geo-brand/scripts/list_jobs.py +153 -0
- package/skills/adgine-geo-brand/scripts/update_brand.py +61 -0
- package/skills/adgine-geo-citation/SKILL.md +220 -0
- package/skills/adgine-geo-citation/scripts/_client.py +341 -0
- package/skills/adgine-geo-citation/scripts/create_tests.py +62 -0
- package/skills/adgine-geo-citation/scripts/get_aggregate.py +108 -0
- package/skills/adgine-geo-citation/scripts/get_results.py +179 -0
- package/skills/adgine-geo-content/SKILL.md +224 -0
- package/skills/adgine-geo-content/WORKFLOW.md +100 -0
- package/skills/adgine-geo-content/scripts/_client.py +341 -0
- package/skills/adgine-geo-content/scripts/generate_article.py +108 -0
- package/skills/adgine-geo-content/scripts/generate_outline.py +113 -0
- package/skills/adgine-geo-content/scripts/generate_titles.py +51 -0
- package/skills/adgine-geo-content/scripts/list_content.py +65 -0
- package/skills/adgine-geo-content/scripts/manage_content.py +90 -0
- package/skills/adgine-geo-content/scripts/manage_jobs.py +184 -0
- package/skills/adgine-geo-dashboard/SKILL.md +181 -0
- package/skills/adgine-geo-dashboard/scripts/_client.py +341 -0
- package/skills/adgine-geo-dashboard/scripts/check_integrations.py +139 -0
- package/skills/adgine-geo-dashboard/scripts/get_overview.py +155 -0
- package/skills/adgine-geo-dashboard/scripts/get_visibility_overview.py +93 -0
- package/skills/adgine-geo-docs/SKILL.md +60 -0
- package/skills/adgine-geo-domains/SKILL.md +223 -0
- package/skills/adgine-geo-domains/scripts/_client.py +341 -0
- package/skills/adgine-geo-domains/scripts/get_domain.py +75 -0
- package/skills/adgine-geo-domains/scripts/list_domains.py +66 -0
- package/skills/adgine-geo-domains/scripts/search_domains.py +85 -0
- package/skills/adgine-geo-integrations/SKILL.md +188 -0
- package/skills/adgine-geo-integrations/scripts/_client.py +341 -0
- package/skills/adgine-geo-integrations/scripts/cloudflare_connect.py +155 -0
- package/skills/adgine-geo-integrations/scripts/cloudflare_worker.py +212 -0
- package/skills/adgine-geo-integrations/scripts/ga4_data.py +192 -0
- package/skills/adgine-geo-integrations/scripts/ga4_setup.py +120 -0
- package/skills/adgine-geo-opportunities/SKILL.md +162 -0
- package/skills/adgine-geo-opportunities/scripts/_client.py +341 -0
- package/skills/adgine-geo-opportunities/scripts/get_opportunity.py +90 -0
- package/skills/adgine-geo-opportunities/scripts/list_opportunities.py +92 -0
- package/skills/adgine-geo-performance/SKILL.md +177 -0
- package/skills/adgine-geo-performance/scripts/_client.py +341 -0
- package/skills/adgine-geo-performance/scripts/analyze_page.py +100 -0
- package/skills/adgine-geo-projects/SKILL.md +279 -0
- package/skills/adgine-geo-projects/scripts/_client.py +341 -0
- package/skills/adgine-geo-projects/scripts/check_auth.py +45 -0
- package/skills/adgine-geo-projects/scripts/list_projects.py +47 -0
- package/skills/adgine-geo-projects/scripts/manage_competitors.py +122 -0
- package/skills/adgine-geo-projects/scripts/manage_project.py +88 -0
- package/skills/adgine-geo-saas/SKILL.md +144 -0
- package/skills/adgine-geo-saas/scripts/_client.py +341 -0
- package/skills/adgine-geo-saas/scripts/check_domain.py +43 -0
- package/skills/adgine-geo-saas/scripts/create_website.py +56 -0
- package/skills/adgine-geo-saas/scripts/get_task.py +94 -0
- package/skills/adgine-geo-site-audit/README.md +281 -0
- package/skills/adgine-geo-site-audit/SKILL.md +449 -0
- package/skills/adgine-geo-site-audit/requirements.txt +5 -0
- package/skills/adgine-geo-site-audit/scripts/_client.py +341 -0
- package/skills/adgine-geo-site-audit/scripts/_geo_notice.py +55 -0
- package/skills/adgine-geo-site-audit/scripts/export_skill_package.py +197 -0
- package/skills/adgine-geo-site-audit/scripts/geo_collect.py +2443 -0
- package/skills/adgine-geo-site-audit/scripts/geo_score.py +490 -0
- package/skills/adgine-geo-site-audit/scripts/geo_timing.py +399 -0
- package/skills/adgine-geo-site-audit/scripts/geo_visibility.py +718 -0
- package/skills/adgine-geo-site-audit/scripts/render_report_pdf.py +1502 -0
- package/skills/adgine-geo-topics/SKILL.md +232 -0
- package/skills/adgine-geo-topics/scripts/_client.py +341 -0
- package/skills/adgine-geo-topics/scripts/generate_prompts.py +140 -0
- package/skills/adgine-geo-topics/scripts/manage_prompts.py +153 -0
- package/skills/adgine-geo-topics/scripts/manage_topics.py +145 -0
- package/skills/adgine-geo-visibility/SKILL.md +168 -0
- package/skills/adgine-geo-visibility/scripts/_client.py +341 -0
- package/skills/adgine-geo-visibility/scripts/get_execution.py +151 -0
- package/skills/adgine-geo-visibility/scripts/get_matrix.py +111 -0
- package/skills/adgine-geo-visibility/scripts/get_prompt_metrics.py +104 -0
- package/skills/adgine-geo-visibility/scripts/get_topic_metrics.py +201 -0
- package/skills/adgine-geo-visibility/scripts/get_visibility.py +166 -0
- package/skills/adgine-geo-wordpress/SKILL.md +151 -0
- package/skills/adgine-geo-wordpress/scripts/_client.py +341 -0
- package/skills/adgine-geo-wordpress/scripts/list_publishable.py +62 -0
- package/skills/adgine-geo-wordpress/scripts/manage_credentials.py +139 -0
- package/skills/adgine-geo-wordpress/scripts/manage_publishes.py +108 -0
- package/skills/adgine-geo-wordpress/scripts/publish.py +79 -0
- package/skills/scripts/check_version.py +290 -0
- package/skills/setup.py +248 -0
- package/src/config.js +126 -0
- package/src/doctor.js +137 -0
- package/src/install.js +90 -0
- package/src/manifest.js +99 -0
- package/src/runner.js +159 -0
package/README.md
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# @adgine/geo-cli
|
|
2
|
+
|
|
3
|
+
Run the **Adgine GEO skill suite** from your terminal — or install the skills into an
|
|
4
|
+
AI agent (Claude Code, Cursor, …). This is a thin Node wrapper over the official
|
|
5
|
+
`adgine-geo-skills` Python scripts, published to npm so you can `npm i -g` instead of
|
|
6
|
+
cloning a repo. Bring your own `GEO_API_KEY`.
|
|
7
|
+
|
|
8
|
+
## Requirements
|
|
9
|
+
|
|
10
|
+
- **Node.js ≥ 18**
|
|
11
|
+
- **Python ≥ 3.9** on your PATH (the CLI wraps Python skills)
|
|
12
|
+
- A **GEO API key** (`geo_sk_live_…`) from <https://platform.adgine.ai>
|
|
13
|
+
|
|
14
|
+
## Install
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
npm install -g @adgine/geo-cli
|
|
18
|
+
# or run without installing:
|
|
19
|
+
npx @adgine/geo-cli --help
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## Quick start
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
# 1. Save your key once (stored in ~/.adgine/config.json, mode 0600)
|
|
26
|
+
adgine-geo config set-key geo_sk_live_xxxxxxxx
|
|
27
|
+
|
|
28
|
+
# 2. Check your environment (Python, key validity, optional deps)
|
|
29
|
+
adgine-geo doctor
|
|
30
|
+
|
|
31
|
+
# 3. Explore what's available
|
|
32
|
+
adgine-geo list
|
|
33
|
+
|
|
34
|
+
# 4. Run a skill action
|
|
35
|
+
adgine-geo projects list_projects
|
|
36
|
+
adgine-geo visibility get_visibility score --project-id <id>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
The key is passed to the Python scripts via the environment at run time — no `.env`
|
|
40
|
+
file is written into the package, and nothing is added to your shell rc files.
|
|
41
|
+
|
|
42
|
+
## Usage
|
|
43
|
+
|
|
44
|
+
```
|
|
45
|
+
adgine-geo <skill> <action> [options] Run a skill action (options pass through to Python)
|
|
46
|
+
adgine-geo list List all skills and their actions
|
|
47
|
+
adgine-geo <skill> Show a skill's actions
|
|
48
|
+
adgine-geo <skill> <action> --help Show a script's own options (argparse)
|
|
49
|
+
adgine-geo doctor [--install-audit-deps] Check Python, API key, and optional deps
|
|
50
|
+
adgine-geo config set-key <key> Save GEO_API_KEY
|
|
51
|
+
adgine-geo config set-base-url <url> Override the API base URL (self-hosted)
|
|
52
|
+
adgine-geo config get Show current config (key masked)
|
|
53
|
+
adgine-geo config path Print the config file path
|
|
54
|
+
adgine-geo skills install [--target d] Install the skills into an AI agent's skills dir
|
|
55
|
+
adgine-geo --version Print version
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Configuration precedence: environment variables (`GEO_API_KEY`, `GEO_API_BASE_URL`)
|
|
59
|
+
override `~/.adgine/config.json`.
|
|
60
|
+
|
|
61
|
+
## Using it with an AI agent
|
|
62
|
+
|
|
63
|
+
`adgine-geo skills install` copies the skill folders into an agent's skills directory
|
|
64
|
+
(the same layout the agent would get from a git clone) and writes your key into a local
|
|
65
|
+
`.env` there:
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
adgine-geo skills install --target ~/.claude/skills/adgine-geo
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
With no `--target`, it installs to the default Claude Code user skills directory and
|
|
72
|
+
prints other common locations.
|
|
73
|
+
|
|
74
|
+
## Skills that don't need a key
|
|
75
|
+
|
|
76
|
+
- **`site-audit`** — standalone GEO technical audit of any public URL (local crawl + PDF).
|
|
77
|
+
Needs a few extra Python packages: `adgine-geo doctor --install-audit-deps`.
|
|
78
|
+
- **`docs`** — links the official Adgine user manual.
|
|
79
|
+
|
|
80
|
+
## How it works
|
|
81
|
+
|
|
82
|
+
```
|
|
83
|
+
adgine-geo (Node bin)
|
|
84
|
+
└─ spawns python3 skills/adgine-geo-<skill>/scripts/<action>.py <args...>
|
|
85
|
+
with GEO_API_KEY injected into the child environment
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
The `skills/` payload is the upstream `adgine-geo-skills` suite, bundled at publish
|
|
89
|
+
time. The npm package version tracks the suite's `VERSION`.
|
|
90
|
+
|
|
91
|
+
## License
|
|
92
|
+
|
|
93
|
+
MIT
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* adgine-geo — run the Adgine GEO skill suite from your terminal, or install
|
|
6
|
+
* the skills into an AI agent. Thin Node wrapper over the bundled Python
|
|
7
|
+
* skills; configure your key once with `adgine-geo config set-key`.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
const fs = require('fs');
|
|
11
|
+
const path = require('path');
|
|
12
|
+
const config = require('../src/config');
|
|
13
|
+
const runner = require('../src/runner');
|
|
14
|
+
const manifest = require('../src/manifest');
|
|
15
|
+
const install = require('../src/install');
|
|
16
|
+
const doctor = require('../src/doctor');
|
|
17
|
+
|
|
18
|
+
const PKG_ROOT = path.resolve(__dirname, '..');
|
|
19
|
+
|
|
20
|
+
function version() {
|
|
21
|
+
try {
|
|
22
|
+
return fs.readFileSync(path.join(runner.SKILLS_DIR, 'VERSION'), 'utf8').trim();
|
|
23
|
+
} catch {
|
|
24
|
+
try {
|
|
25
|
+
return require(path.join(PKG_ROOT, 'package.json')).version;
|
|
26
|
+
} catch {
|
|
27
|
+
return '0.0.0';
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const HELP_COMMANDS = new Set(['help', '-h', '--help']);
|
|
33
|
+
|
|
34
|
+
function topLevelHelp() {
|
|
35
|
+
return `adgine-geo v${version()} — Adgine GEO skills CLI
|
|
36
|
+
|
|
37
|
+
Usage:
|
|
38
|
+
adgine-geo <skill> <action> [options] Run a skill action (Python passthrough)
|
|
39
|
+
adgine-geo list List all skills and their actions
|
|
40
|
+
adgine-geo doctor [--install-audit-deps] Check Python, API key, and deps
|
|
41
|
+
adgine-geo config set-key <key> Save your GEO_API_KEY (~/.adgine/config.json)
|
|
42
|
+
adgine-geo config set-base-url <url> Override the API base URL
|
|
43
|
+
adgine-geo config get Show current config
|
|
44
|
+
adgine-geo config path Print the config file path
|
|
45
|
+
adgine-geo skills install [--target d] Install skills into an AI agent's skills dir
|
|
46
|
+
adgine-geo --version Print version
|
|
47
|
+
|
|
48
|
+
Examples:
|
|
49
|
+
adgine-geo config set-key geo_sk_live_xxx
|
|
50
|
+
adgine-geo projects list_projects
|
|
51
|
+
adgine-geo visibility get_visibility --project-id <id>
|
|
52
|
+
adgine-geo site-audit geo_collect https://example.com
|
|
53
|
+
adgine-geo projects list_projects --help (passes --help to the Python script)
|
|
54
|
+
|
|
55
|
+
Docs: https://platform.adgine.ai`;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
function cmdList() {
|
|
59
|
+
const skills = manifest.buildManifest();
|
|
60
|
+
process.stdout.write(`adgine-geo v${version()} — ${skills.length} skills\n\n`);
|
|
61
|
+
for (const s of skills) {
|
|
62
|
+
process.stdout.write(` ${s.skill}\n`);
|
|
63
|
+
if (s.description) process.stdout.write(` ${s.description}\n`);
|
|
64
|
+
if (s.actions.length) {
|
|
65
|
+
process.stdout.write(` actions: ${s.actions.join(', ')}\n`);
|
|
66
|
+
} else {
|
|
67
|
+
process.stdout.write(` (no runnable actions — documentation skill)\n`);
|
|
68
|
+
}
|
|
69
|
+
process.stdout.write('\n');
|
|
70
|
+
}
|
|
71
|
+
process.stdout.write("Run 'adgine-geo <skill> <action> --help' for a script's options.\n");
|
|
72
|
+
return 0;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
function skillHelp(entry) {
|
|
76
|
+
process.stdout.write(`adgine-geo ${entry.skill}\n`);
|
|
77
|
+
if (entry.description) process.stdout.write(` ${entry.description}\n`);
|
|
78
|
+
process.stdout.write('\n');
|
|
79
|
+
if (entry.actions.length) {
|
|
80
|
+
process.stdout.write('Actions:\n');
|
|
81
|
+
for (const a of entry.actions) {
|
|
82
|
+
process.stdout.write(` adgine-geo ${entry.skill} ${a}\n`);
|
|
83
|
+
}
|
|
84
|
+
process.stdout.write(
|
|
85
|
+
`\nRun 'adgine-geo ${entry.skill} <action> --help' for options.\n`
|
|
86
|
+
);
|
|
87
|
+
} else {
|
|
88
|
+
process.stdout.write('This skill has no runnable actions (documentation only).\n');
|
|
89
|
+
}
|
|
90
|
+
return 0;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
function cmdConfig(args) {
|
|
94
|
+
const sub = args[0];
|
|
95
|
+
switch (sub) {
|
|
96
|
+
case 'set-key': {
|
|
97
|
+
const key = args[1];
|
|
98
|
+
if (!key) {
|
|
99
|
+
process.stderr.write('Usage: adgine-geo config set-key <geo_sk_live_...>\n');
|
|
100
|
+
return 2;
|
|
101
|
+
}
|
|
102
|
+
if (!key.startsWith('geo_sk_')) {
|
|
103
|
+
process.stderr.write(
|
|
104
|
+
`WARNING: key does not start with 'geo_sk_' (got ${key.slice(0, 8)}...). Saving anyway.\n`
|
|
105
|
+
);
|
|
106
|
+
}
|
|
107
|
+
config.setKey(key);
|
|
108
|
+
process.stdout.write(`Saved GEO_API_KEY to ${config.CONFIG_PATH}\n`);
|
|
109
|
+
process.stdout.write("Verify with: adgine-geo doctor\n");
|
|
110
|
+
return 0;
|
|
111
|
+
}
|
|
112
|
+
case 'set-base-url': {
|
|
113
|
+
const url = args[1];
|
|
114
|
+
if (!url) {
|
|
115
|
+
process.stderr.write('Usage: adgine-geo config set-base-url <url>\n');
|
|
116
|
+
return 2;
|
|
117
|
+
}
|
|
118
|
+
config.setBaseUrl(url);
|
|
119
|
+
process.stdout.write(`Saved base URL: ${config.getBaseUrl()}\n`);
|
|
120
|
+
return 0;
|
|
121
|
+
}
|
|
122
|
+
case 'get': {
|
|
123
|
+
const key = config.getKey();
|
|
124
|
+
process.stdout.write(`config file: ${config.CONFIG_PATH}\n`);
|
|
125
|
+
process.stdout.write(`api key: ${config.maskKey(key)}${key ? ` (from ${config.keySource()})` : ''}\n`);
|
|
126
|
+
process.stdout.write(`base url: ${config.getBaseUrl()}\n`);
|
|
127
|
+
return 0;
|
|
128
|
+
}
|
|
129
|
+
case 'path':
|
|
130
|
+
process.stdout.write(config.CONFIG_PATH + '\n');
|
|
131
|
+
return 0;
|
|
132
|
+
default:
|
|
133
|
+
process.stderr.write(
|
|
134
|
+
'Usage: adgine-geo config <set-key|set-base-url|get|path>\n'
|
|
135
|
+
);
|
|
136
|
+
return sub ? 2 : 0;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
function cmdSkills(args) {
|
|
141
|
+
const sub = args[0];
|
|
142
|
+
if (sub !== 'install') {
|
|
143
|
+
process.stderr.write('Usage: adgine-geo skills install [--target <dir>]\n');
|
|
144
|
+
return sub ? 2 : 0;
|
|
145
|
+
}
|
|
146
|
+
const rest = args.slice(1);
|
|
147
|
+
let target;
|
|
148
|
+
const ti = rest.indexOf('--target');
|
|
149
|
+
if (ti !== -1) target = rest[ti + 1];
|
|
150
|
+
|
|
151
|
+
if (!target) {
|
|
152
|
+
target = install.defaultTargets()[0].dir;
|
|
153
|
+
process.stdout.write(
|
|
154
|
+
`No --target given; installing to the default Claude Code skills dir.\n` +
|
|
155
|
+
`Other common targets:\n`
|
|
156
|
+
);
|
|
157
|
+
for (const t of install.defaultTargets()) {
|
|
158
|
+
process.stdout.write(` ${t.label}: ${t.dir}\n`);
|
|
159
|
+
}
|
|
160
|
+
process.stdout.write('\n');
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
const dest = install.installTo(target);
|
|
164
|
+
const key = config.getKey();
|
|
165
|
+
process.stdout.write(`Installed ${manifest.buildManifest().length} skills to ${dest}\n`);
|
|
166
|
+
if (key) {
|
|
167
|
+
process.stdout.write(`Wrote GEO_API_KEY to ${path.join(dest, '.env')}\n`);
|
|
168
|
+
} else {
|
|
169
|
+
process.stdout.write(
|
|
170
|
+
`No API key configured yet. Set one, then re-run install (or edit ${path.join(dest, '.env')}):\n` +
|
|
171
|
+
` adgine-geo config set-key geo_sk_live_xxx\n`
|
|
172
|
+
);
|
|
173
|
+
}
|
|
174
|
+
return 0;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
async function main() {
|
|
178
|
+
const argv = process.argv.slice(2);
|
|
179
|
+
|
|
180
|
+
if (argv.length === 0 || HELP_COMMANDS.has(argv[0])) {
|
|
181
|
+
process.stdout.write(topLevelHelp() + '\n');
|
|
182
|
+
return 0;
|
|
183
|
+
}
|
|
184
|
+
if (argv[0] === '--version' || argv[0] === '-V') {
|
|
185
|
+
process.stdout.write(version() + '\n');
|
|
186
|
+
return 0;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
const [command, ...rest] = argv;
|
|
190
|
+
|
|
191
|
+
switch (command) {
|
|
192
|
+
case 'list':
|
|
193
|
+
return cmdList();
|
|
194
|
+
case 'config':
|
|
195
|
+
return cmdConfig(rest);
|
|
196
|
+
case 'skills':
|
|
197
|
+
return cmdSkills(rest);
|
|
198
|
+
case 'doctor':
|
|
199
|
+
return doctor.run({ installAudit: rest.includes('--install-audit-deps') });
|
|
200
|
+
default: {
|
|
201
|
+
// Treat as: <skill> <action> [passthrough args]
|
|
202
|
+
const entry = manifest.findSkill(command);
|
|
203
|
+
if (!entry) {
|
|
204
|
+
process.stderr.write(
|
|
205
|
+
`ERROR: unknown command or skill '${command}'.\n` +
|
|
206
|
+
" Run 'adgine-geo list' to see available skills, or 'adgine-geo --help'.\n"
|
|
207
|
+
);
|
|
208
|
+
return 127;
|
|
209
|
+
}
|
|
210
|
+
const action = rest[0];
|
|
211
|
+
if (!action || HELP_COMMANDS.has(action)) {
|
|
212
|
+
return skillHelp(entry);
|
|
213
|
+
}
|
|
214
|
+
return runner.runSkillAction(entry.skill, action, rest.slice(1));
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
main()
|
|
220
|
+
.then((code) => process.exit(code || 0))
|
|
221
|
+
.catch((err) => {
|
|
222
|
+
process.stderr.write(`ERROR: ${err && err.stack ? err.stack : err}\n`);
|
|
223
|
+
process.exit(1);
|
|
224
|
+
});
|
package/package.json
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@adgine/geo-cli",
|
|
3
|
+
"publishConfig": {
|
|
4
|
+
"access": "public"
|
|
5
|
+
},
|
|
6
|
+
"version": "1.2.8",
|
|
7
|
+
"description": "Adgine GEO skills as a CLI — run the full adgine-geo skill suite from your terminal or install them into an AI agent. Wraps the Python skills; bring your own GEO_API_KEY.",
|
|
8
|
+
"keywords": [
|
|
9
|
+
"adgine",
|
|
10
|
+
"geo",
|
|
11
|
+
"aeo",
|
|
12
|
+
"ai-visibility",
|
|
13
|
+
"cli",
|
|
14
|
+
"skills",
|
|
15
|
+
"ai-agent",
|
|
16
|
+
"generative-engine-optimization"
|
|
17
|
+
],
|
|
18
|
+
"homepage": "https://platform.adgine.ai",
|
|
19
|
+
"license": "MIT",
|
|
20
|
+
"type": "commonjs",
|
|
21
|
+
"bin": {
|
|
22
|
+
"adgine-geo": "bin/adgine-geo.js"
|
|
23
|
+
},
|
|
24
|
+
"files": [
|
|
25
|
+
"bin/",
|
|
26
|
+
"src/",
|
|
27
|
+
"skills/",
|
|
28
|
+
"README.md"
|
|
29
|
+
],
|
|
30
|
+
"scripts": {
|
|
31
|
+
"sync-skills": "node scripts/sync-skills.js",
|
|
32
|
+
"sync-version": "node scripts/sync-version.js",
|
|
33
|
+
"prepublishOnly": "node scripts/sync-skills.js && node scripts/sync-version.js"
|
|
34
|
+
},
|
|
35
|
+
"engines": {
|
|
36
|
+
"node": ">=18"
|
|
37
|
+
}
|
|
38
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
# GEO Skills — Environment Variables
|
|
2
|
+
# Copy this file to .env and fill in your values.
|
|
3
|
+
# See SETUP.md for detailed instructions per agent tool.
|
|
4
|
+
|
|
5
|
+
# Required: Your GEO Platform API Key (user-level, grants access to ALL your projects)
|
|
6
|
+
# Get it at: https://platform.adgine.ai
|
|
7
|
+
GEO_API_KEY=geo_sk_live_YOUR_KEY_HERE
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
# 可选:自定义 API 端点(默认生产环境)
|
|
11
|
+
# GEO_API_BASE_URL=https://platform.adgine.ai
|
package/skills/README.md
ADDED
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
# adgine-geo-skills
|
|
2
|
+
|
|
3
|
+
Agent Skills are folders of instructions, scripts, and resources that AI agents load to perform specialized tasks in a repeatable way. This repository packages the full [Adgine GEO platform](https://platform.adgine.ai) workflow as a set of skills — from setting up a project and measuring AI visibility, to generating optimized content and publishing it to WordPress.
|
|
4
|
+
|
|
5
|
+
**Works with all mainstream AI agents.** Supports [WorkBuddy](https://workbuddy.ai), [Codex](https://openai.com/codex), [OpenClaw](https://github.com/openclaw/openclaw), and [Hermes](https://github.com/hermes-agent/hermes).
|
|
6
|
+
|
|
7
|
+
**Current version:** [`v1.0.2`](VERSION) · [All releases](https://github.com/adgine-ai/adgine-geo-skills/releases)
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## Install
|
|
12
|
+
|
|
13
|
+
The install prompt is the same for every supported agent — send it directly to your agent of choice:
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
Install skills from https://github.com/adgine-ai/adgine-geo-skills
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Known compatible agents:
|
|
20
|
+
|
|
21
|
+
- **[WorkBuddy](https://workbuddy.ai)**
|
|
22
|
+
- **[Codex](https://openai.com/codex)**
|
|
23
|
+
- **[OpenClaw](https://github.com/openclaw/openclaw)**
|
|
24
|
+
- **[Hermes](https://github.com/hermes-agent/hermes)**
|
|
25
|
+
|
|
26
|
+
After the agent finishes installing, paste your GEO API key in chat (e.g. *"my GEO API key is geo_sk_live_xxx, please configure it"*). The agent will run the included `setup.py` helper to write the key to a local, gitignored `.env` file at the skills repo root — not to your shell rc, not to the agent's global config.
|
|
27
|
+
|
|
28
|
+
### Manual install (advanced)
|
|
29
|
+
|
|
30
|
+
Clone the repo and run the setup helper yourself:
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
git clone https://github.com/adgine-ai/adgine-geo-skills.git
|
|
34
|
+
cd adgine-geo-skills
|
|
35
|
+
|
|
36
|
+
# One-shot setup — writes your API key to a local .env (gitignored):
|
|
37
|
+
python3 setup.py <YOUR_GEO_API_KEY>
|
|
38
|
+
# ...or run the interactive wizard:
|
|
39
|
+
python3 setup.py
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
All scripts auto-load `GEO_API_KEY` from `.env` on import — no `export`, no shell rc edits, no terminal restart needed.
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Updates
|
|
47
|
+
|
|
48
|
+
The installed version is recorded in the [`VERSION`](VERSION) file at the repo root. Releases are published at [github.com/adgine-ai/adgine-geo-skills/releases](https://github.com/adgine-ai/adgine-geo-skills/releases).
|
|
49
|
+
|
|
50
|
+
### For AI agents — how to check and apply updates
|
|
51
|
+
|
|
52
|
+
Use the following steps whenever the user asks whether skills are up to date, or to update skills:
|
|
53
|
+
|
|
54
|
+
**Step 1 — Read the installed version**
|
|
55
|
+
|
|
56
|
+
```bash
|
|
57
|
+
cat "$(find ~ -name VERSION -path '*/adgine-geo-skills/VERSION' 2>/dev/null | head -1)"
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
**Step 2 — Fetch the latest release from GitHub**
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
curl -s https://api.github.com/repos/adgine-ai/adgine-geo-skills/releases/latest
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
Key fields to read from the response:
|
|
67
|
+
- `tag_name` — latest version (e.g. `v1.3.0`)
|
|
68
|
+
- `name` — release title
|
|
69
|
+
- `body` — changelog / release notes
|
|
70
|
+
- `published_at` — release date
|
|
71
|
+
|
|
72
|
+
Alternatively, fetch just the raw version string (no JSON parsing needed):
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
curl -s https://raw.githubusercontent.com/adgine-ai/adgine-geo-skills/main/VERSION
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
**Step 3 — Present result to user**
|
|
79
|
+
|
|
80
|
+
- If versions match: report that skills are up to date and show the current version.
|
|
81
|
+
- If behind: show the current version, the latest version, and the release notes from `body`. Ask the user if they want to update.
|
|
82
|
+
|
|
83
|
+
**Step 4 — Apply update (if requested)**
|
|
84
|
+
|
|
85
|
+
```bash
|
|
86
|
+
cd <skills-repo-path>
|
|
87
|
+
git pull
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
The `.env` file (API key) is gitignored and is never modified by `git pull`. No reconfiguration needed after updating.
|
|
91
|
+
|
|
92
|
+
### User-facing prompt
|
|
93
|
+
|
|
94
|
+
Users can trigger a version check or update with natural language:
|
|
95
|
+
|
|
96
|
+
> *"Are my Adgine skills up to date?"*
|
|
97
|
+
> *"Check for skill updates."*
|
|
98
|
+
> *"Update my Adgine skills to the latest version."*
|
|
99
|
+
|
|
100
|
+
---
|
|
101
|
+
|
|
102
|
+
## What is GEO?
|
|
103
|
+
|
|
104
|
+
**Generative Engine Optimization (GEO)** is the practice of optimizing your brand and content to be cited, referenced, and recommended by AI search engines — ChatGPT, Perplexity, Google AI Overviews, Gemini, and more. These skills give you programmatic access to the full GEO workflow through natural language, with your agent as the interface.
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
## Skills
|
|
109
|
+
|
|
110
|
+
| Skill | What it does |
|
|
111
|
+
|---|---|
|
|
112
|
+
| [`adgine-geo-projects`](adgine-geo-projects/) | List, create, update, delete projects; manage competitors; verify auth; configure API key |
|
|
113
|
+
| [`adgine-geo-dashboard`](adgine-geo-dashboard/) | Project snapshot — visibility score, aggregate metrics, 7-day trend, integration health |
|
|
114
|
+
| [`adgine-geo-analytics`](adgine-geo-analytics/) | Traffic overview — GA4 sessions, active users, source breakdown, AI referral summary |
|
|
115
|
+
| [`adgine-geo-aiagent`](adgine-geo-aiagent/) | AI bot & human traffic deep drill-down — 27 endpoints: per-bot KPIs, platform rankings, Sankey flows, raw event logs, per-page deep dives (KPI / logs / platforms / PageSpeed) |
|
|
116
|
+
| [`adgine-geo-visibility`](adgine-geo-visibility/) | Deep AI visibility analytics — Visibility Score, Share of Voice, Average Position, competitor matrix, topic/prompt-level metrics, historical AI execution details & full responses |
|
|
117
|
+
| [`adgine-geo-citation`](adgine-geo-citation/) | Citation tests across ChatGPT / Perplexity / Google AIO / Gemini; brand mention rates, cited URLs, full AI reply text |
|
|
118
|
+
| [`adgine-geo-brand`](adgine-geo-brand/) | Generate and manage AI-facing brand profiles — intro, ICP, competitor analysis, author persona, voice & tone, writing rules; list/inspect/retry brand generation jobs |
|
|
119
|
+
| [`adgine-geo-topics`](adgine-geo-topics/) | Create and manage topics & AI search prompts; batch-generate prompts with AI; cross-topic prompt listing |
|
|
120
|
+
| [`adgine-geo-content`](adgine-geo-content/) | Full content pipeline — generate titles, outlines, and full GEO-optimized articles; manage content library; inspect and retry background jobs |
|
|
121
|
+
| [`adgine-geo-performance`](adgine-geo-performance/) | Per-page AI crawlability, optimization scores, and content health checks (mobile/desktop) |
|
|
122
|
+
| [`adgine-geo-opportunities`](adgine-geo-opportunities/) | AI-discovered content gaps and optimization opportunities ranked by impact — relevance, traffic, competition, urgency, AI citation scores |
|
|
123
|
+
| [`adgine-geo-integrations`](adgine-geo-integrations/) | Connect GA4 (OAuth) and Cloudflare; deploy AI crawler tracking Worker; sync traffic data; query integration-specific data |
|
|
124
|
+
| [`adgine-geo-wordpress`](adgine-geo-wordpress/) | Publish GEO articles to WordPress; manage credentials & categories; track publish history; update existing posts |
|
|
125
|
+
| [`adgine-geo-saas`](adgine-geo-saas/) | Check subdomain availability; create and track SaaS-hosted website deployments |
|
|
126
|
+
| [`adgine-geo-billing`](adgine-geo-billing/) | View plan, status, renewal date, remaining credits, and credits pricing |
|
|
127
|
+
| [`adgine-geo-docs`](adgine-geo-docs/) | Adgine platform user manual (使用手册) — hosted PDF, no API key required |
|
|
128
|
+
| [`adgine-geo-site-audit`](adgine-geo-site-audit/) | **Standalone** GEO technical audit for any public URL — 5-dimension 30-item checklist, local crawl, PDF report export. No API key required |
|
|
129
|
+
|
|
130
|
+
Each skill is self-contained in its own folder with a `SKILL.md` file containing the instructions and metadata that agents use for tool routing and intent matching.
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## Repository Structure
|
|
135
|
+
|
|
136
|
+
```
|
|
137
|
+
adgine-geo-skills/
|
|
138
|
+
├── VERSION # Current release version
|
|
139
|
+
├── setup.py # API key configuration helper
|
|
140
|
+
├── .env.example # Environment variable template
|
|
141
|
+
├── adgine-geo-<domain>/
|
|
142
|
+
│ ├── SKILL.md # Agent skill definition — YAML frontmatter (name, description) + usage instructions
|
|
143
|
+
│ ├── WORKFLOW.md # (some skills) End-to-end workflow guide
|
|
144
|
+
│ └── scripts/
|
|
145
|
+
│ ├── _client.py # Shared API client for the domain
|
|
146
|
+
│ └── *.py # One script per operation
|
|
147
|
+
├── adgine-geo-site-audit/
|
|
148
|
+
│ ├── SKILL.md
|
|
149
|
+
│ ├── README.md # Site audit-specific docs
|
|
150
|
+
│ ├── requirements.txt # Standalone dependencies (curl_cffi, bs4, reportlab, etc.)
|
|
151
|
+
│ ├── scripts/ # geo_collect, geo_score, geo_visibility, render_report_pdf, etc.
|
|
152
|
+
│ └── tests/ # Unit tests for site audit modules
|
|
153
|
+
└── ref/ # Reference documentation (Chinese)
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
---
|
|
157
|
+
|
|
158
|
+
## Setup
|
|
159
|
+
|
|
160
|
+
### 1. Get your API key
|
|
161
|
+
|
|
162
|
+
Sign in at [platform.adgine.ai](https://platform.adgine.ai) and generate an API key.
|
|
163
|
+
|
|
164
|
+
### 2. Configure environment
|
|
165
|
+
|
|
166
|
+
Use the included setup helper — it writes the key to `<repo>/.env` and verifies it:
|
|
167
|
+
|
|
168
|
+
```bash
|
|
169
|
+
python3 setup.py <YOUR_GEO_API_KEY> # non-interactive (good for AI agents)
|
|
170
|
+
python3 setup.py # interactive wizard
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
Prefer to do it manually? Copy the template and edit:
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
cp .env.example .env
|
|
177
|
+
# then edit .env and set GEO_API_KEY=geo_sk_live_YOUR_KEY_HERE
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
All scripts read `.env` automatically on import — no `export` needed.
|
|
181
|
+
|
|
182
|
+
### 3. Find your project ID
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
python3 adgine-geo-projects/scripts/list_projects.py
|
|
186
|
+
export GEO_PROJECT_ID=<your-project-id>
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
### 4. Ask your agent
|
|
190
|
+
|
|
191
|
+
Once the skills are loaded, use natural language:
|
|
192
|
+
|
|
193
|
+
> *"What's my AI visibility score this week?"*
|
|
194
|
+
> *"Generate a brand profile for my project."*
|
|
195
|
+
> *"Which AI platforms are crawling my site the most?"*
|
|
196
|
+
> *"Publish article 123 to my WordPress site."*
|
|
197
|
+
> *"Audit example.com for GEO score and export a PDF."*
|
|
198
|
+
> *"What optimization opportunities does my project have?"*
|
|
199
|
+
|
|
200
|
+
Or run scripts directly:
|
|
201
|
+
|
|
202
|
+
```bash
|
|
203
|
+
# Dashboard snapshot
|
|
204
|
+
python3 adgine-geo-dashboard/scripts/get_overview.py
|
|
205
|
+
|
|
206
|
+
# AI visibility score
|
|
207
|
+
python3 adgine-geo-visibility/scripts/get_visibility.py score
|
|
208
|
+
|
|
209
|
+
# AI bot traffic platform ranking
|
|
210
|
+
python3 adgine-geo-aiagent/scripts/bot_traffic.py platforms
|
|
211
|
+
|
|
212
|
+
# Generate article outline
|
|
213
|
+
python3 adgine-geo-content/scripts/generate_outline.py --topic-id <id> --prompt-ids <id1,id2>
|
|
214
|
+
|
|
215
|
+
# Standalone site audit (no API key needed)
|
|
216
|
+
python3 adgine-geo-site-audit/scripts/geo_collect.py https://example.com --max-subpages 20
|
|
217
|
+
|
|
218
|
+
# Check credits balance
|
|
219
|
+
python3 adgine-geo-billing/scripts/get_credits.py
|
|
220
|
+
```
|
|
221
|
+
|
|
222
|
+
---
|
|
223
|
+
|
|
224
|
+
## Authentication
|
|
225
|
+
|
|
226
|
+
All scripts read from the `GEO_API_KEY` environment variable. Never hardcode your key or commit it to version control. The `.env` file is gitignored by default.
|
|
227
|
+
|
|
228
|
+
---
|
|
229
|
+
|
|
230
|
+
## Requirements
|
|
231
|
+
|
|
232
|
+
- Python 3.9+
|
|
233
|
+
- `requests` (`pip install requests`)
|
|
234
|
+
- An [Adgine GEO](https://platform.adgine.ai) account with an active API key (not required for `adgine-geo-site-audit` and `adgine-geo-docs`)
|
|
235
|
+
- **Site audit only:** additional packages — run `pip install -r adgine-geo-site-audit/requirements.txt`
|
|
236
|
+
|
|
237
|
+
---
|
|
238
|
+
|
|
239
|
+
## Disclaimer
|
|
240
|
+
|
|
241
|
+
These skills are provided for use with the Adgine GEO platform API. Always test in your own environment before relying on them for critical workflows.
|
|
242
|
+
|
|
243
|
+
---
|
|
244
|
+
|
|
245
|
+
## License
|
|
246
|
+
|
|
247
|
+
See [LICENSE](LICENSE) for details.
|