@clickminded/coauthor-cli 0.0.85 → 0.0.86
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/dist/commands.d.ts
CHANGED
|
@@ -17,6 +17,11 @@ export declare function openBrowser(url: string, spawnImpl?: typeof spawn, warn?
|
|
|
17
17
|
* reported as completed *with items to review*, never as plainly done.
|
|
18
18
|
*/
|
|
19
19
|
export declare function draftCompletionMessage(base: string, status: JsonValue): string;
|
|
20
|
+
/**
|
|
21
|
+
* "Where AI search mentions you" in `seo-plan show`: mentions per platform, the comparison leader and the top
|
|
22
|
+
* question. Nothing when the plan has no AI search data.
|
|
23
|
+
*/
|
|
24
|
+
export declare function seoPlanAiSearchLines(value: unknown): string[];
|
|
20
25
|
/**
|
|
21
26
|
* `--cta save,follow,custom:Join the webinar` -> the web app's cta_variants
|
|
22
27
|
* list (at most 4 endings, at most one custom).
|
package/dist/commands.js
CHANGED
|
@@ -2494,6 +2494,38 @@ function seoPlanItemLine(item) {
|
|
|
2494
2494
|
hint ? ` ${hint}` : null,
|
|
2495
2495
|
].filter(Boolean).join('\n');
|
|
2496
2496
|
}
|
|
2497
|
+
/**
|
|
2498
|
+
* "Where AI search mentions you" in `seo-plan show`: mentions per platform, the comparison leader and the top
|
|
2499
|
+
* question. Nothing when the plan has no AI search data.
|
|
2500
|
+
*/
|
|
2501
|
+
export function seoPlanAiSearchLines(value) {
|
|
2502
|
+
if (!value || typeof value !== 'object')
|
|
2503
|
+
return [];
|
|
2504
|
+
const visibility = planRecord(value);
|
|
2505
|
+
const platform = (key, label) => {
|
|
2506
|
+
if (visibility[key] === null || visibility[key] === undefined)
|
|
2507
|
+
return null;
|
|
2508
|
+
const row = planRecord(visibility[key]);
|
|
2509
|
+
const mentions = typeof row.mentions === 'number' ? row.mentions : 0;
|
|
2510
|
+
const cited = typeof row.cited === 'number' ? row.cited : 0;
|
|
2511
|
+
return `${label} ${mentions.toLocaleString('en-US')} ${mentions === 1 ? 'answer' : 'answers'}${mentions > 0 ? ` (${cited.toLocaleString('en-US')} cite you)` : ''}`;
|
|
2512
|
+
};
|
|
2513
|
+
const parts = [platform('google', 'Google AI answers'), platform('chat_gpt', 'ChatGPT')].filter((part) => part !== null);
|
|
2514
|
+
if (parts.length === 0)
|
|
2515
|
+
return [];
|
|
2516
|
+
const lines = [`AI search mentions: ${parts.join('; ')}.${visibility.chat_gpt_available === false ? ' ChatGPT data covers the United States in English only.' : ''}`];
|
|
2517
|
+
const competitors = Array.isArray(visibility.competitors) ? visibility.competitors.map(planRecord) : [];
|
|
2518
|
+
const leader = competitors.find((row) => typeof row.mentions === 'number' && row.mentions > 0);
|
|
2519
|
+
if (leader)
|
|
2520
|
+
lines.push(` Top competitor in Google AI answers: ${planString(leader, 'domain')} (${leader.mentions.toLocaleString('en-US')}).`);
|
|
2521
|
+
const questions = Array.isArray(planRecord(visibility.google).questions) ? planRecord(visibility.google).questions.map(planRecord) : [];
|
|
2522
|
+
const top = questions[0];
|
|
2523
|
+
if (top) {
|
|
2524
|
+
const url = Array.isArray(top.own_urls) && typeof top.own_urls[0] === 'string' ? top.own_urls[0] : null;
|
|
2525
|
+
lines.push(` Top question: "${planString(top, 'question')}"${url ? ` -> ${url}` : ''}.`);
|
|
2526
|
+
}
|
|
2527
|
+
return lines;
|
|
2528
|
+
}
|
|
2497
2529
|
function seoPlanShowMessage(data, kind) {
|
|
2498
2530
|
const view = planRecord(data);
|
|
2499
2531
|
const plan = view.plan === null || view.plan === undefined ? null : planRecord(view.plan);
|
|
@@ -2534,6 +2566,9 @@ function seoPlanShowMessage(data, kind) {
|
|
|
2534
2566
|
const competitors = planString(plan, 'competitors_line');
|
|
2535
2567
|
if (competitors)
|
|
2536
2568
|
lines.push(`Competitors: ${competitors}`);
|
|
2569
|
+
const aiSearch = seoPlanAiSearchLines(plan.ai_visibility);
|
|
2570
|
+
if (aiSearch.length > 0)
|
|
2571
|
+
lines.push(...aiSearch);
|
|
2537
2572
|
const doNext = Array.isArray(view.do_next) ? view.do_next.map(planRecord) : [];
|
|
2538
2573
|
if (doNext.length > 0) {
|
|
2539
2574
|
lines.push('', 'Do next:');
|
package/package.json
CHANGED
|
@@ -72,6 +72,16 @@ Other fields to use when you recommend an idea:
|
|
|
72
72
|
- `do_next_rank` (1 to 5) marks the plan's own top moves.
|
|
73
73
|
- Alternatives, comparison and best-of posts place the user's product on merit, as one fairly judged option with its limits, and carry a one-line disclosure ("We make <product>"). Competitor prices and features come from fetched pages and are dated. Do not ask CoAuthor to put the product first, and do not remove the disclosure in edits.
|
|
74
74
|
|
|
75
|
+
### Where AI search mentions the site
|
|
76
|
+
|
|
77
|
+
`data.plan.ai_visibility` says how often stored AI answers mention the site, from DataForSEO's saved answers (no live prompting). It is `null` when the plan has none (plans made before it, or when the lookup did not run). When present:
|
|
78
|
+
|
|
79
|
+
- `google`: Google AI answers (AI Overviews and AI Mode) in the plan's market. `mentions` counts answers that used one of the site's pages, `cited` the ones that link to it as a source, and `questions` lists up to 8 questions answered with its pages (`own_urls`, `cited`).
|
|
80
|
+
- `chat_gpt`: the same for ChatGPT. It is `null` outside the United States in English (`chat_gpt_available: false`): ChatGPT answers are only stored for that market.
|
|
81
|
+
- `competitors`: the plan's competitors with their Google AI `mentions`, most first.
|
|
82
|
+
|
|
83
|
+
A mention is not a citation: most mentions mean the AI read the page while answering. Report both numbers as they are, and do not promise that writing a post will change them. The human output of `show` prints one summary line. The web app shows a "Where AI search mentions you" section.
|
|
84
|
+
|
|
75
85
|
## Write this
|
|
76
86
|
|
|
77
87
|
`coauthor seo-plan write <item-id> --json` opens a project for a `post` item and returns `data.project_id`, `data.created` and `data.start_prompt`. The project is already set up from the plan: the keyword, the post format, where the product goes, the related searches, and the posts it should link to. You do not need a brief interview or a keyword step.
|
|
@@ -677,6 +677,16 @@ Other fields to use when you recommend an idea:
|
|
|
677
677
|
- `do_next_rank` (1 to 5) marks the plan's own top moves.
|
|
678
678
|
- Alternatives, comparison and best-of posts place the user's product on merit, as one fairly judged option with its limits, and carry a one-line disclosure ("We make <product>"). Competitor prices and features come from fetched pages and are dated. Do not ask CoAuthor to put the product first, and do not remove the disclosure in edits.
|
|
679
679
|
|
|
680
|
+
#### Where AI search mentions the site
|
|
681
|
+
|
|
682
|
+
`data.plan.ai_visibility` says how often stored AI answers mention the site, from DataForSEO's saved answers (no live prompting). It is `null` when the plan has none (plans made before it, or when the lookup did not run). When present:
|
|
683
|
+
|
|
684
|
+
- `google`: Google AI answers (AI Overviews and AI Mode) in the plan's market. `mentions` counts answers that used one of the site's pages, `cited` the ones that link to it as a source, and `questions` lists up to 8 questions answered with its pages (`own_urls`, `cited`).
|
|
685
|
+
- `chat_gpt`: the same for ChatGPT. It is `null` outside the United States in English (`chat_gpt_available: false`): ChatGPT answers are only stored for that market.
|
|
686
|
+
- `competitors`: the plan's competitors with their Google AI `mentions`, most first.
|
|
687
|
+
|
|
688
|
+
A mention is not a citation: most mentions mean the AI read the page while answering. Report both numbers as they are, and do not promise that writing a post will change them. The human output of `show` prints one summary line. The web app shows a "Where AI search mentions you" section.
|
|
689
|
+
|
|
680
690
|
### Write this
|
|
681
691
|
|
|
682
692
|
`coauthor seo-plan write <item-id> --json` opens a project for a `post` item and returns `data.project_id`, `data.created` and `data.start_prompt`. The project is already set up from the plan: the keyword, the post format, where the product goes, the related searches, and the posts it should link to. You do not need a brief interview or a keyword step.
|