@clickminded/coauthor-cli 0.0.87 → 0.0.89
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
|
@@ -22,6 +22,8 @@ export declare function draftCompletionMessage(base: string, status: JsonValue):
|
|
|
22
22
|
* question. Nothing when the plan has no AI search data.
|
|
23
23
|
*/
|
|
24
24
|
export declare function seoPlanAiSearchLines(value: unknown): string[];
|
|
25
|
+
/** "AI search mentions since 2026-11-18: Google AI answers 482 (up 12), ChatGPT 37 (down 3)." Null without a comparison. */
|
|
26
|
+
export declare function seoPlanAiTrendLine(value: unknown): string | null;
|
|
25
27
|
/**
|
|
26
28
|
* `--cta save,follow,custom:Join the webinar` -> the web app's cta_variants
|
|
27
29
|
* list (at most 4 endings, at most one custom).
|
package/dist/commands.js
CHANGED
|
@@ -2554,6 +2554,9 @@ function seoPlanShowMessage(data, kind) {
|
|
|
2554
2554
|
lines.push(`This is a free preview of the plan (the first posts and a few pages to improve). \`coauthor seo-plan generate --wait\` finishes it into the full plan${firstPlanFree ? ', which is free (your first plan)' : ''}.`);
|
|
2555
2555
|
if (view.stale === true)
|
|
2556
2556
|
lines.push('The profile\'s website or market changed since this plan was made. `coauthor seo-plan generate` updates it.');
|
|
2557
|
+
if (view.ai_search_update_available === true) {
|
|
2558
|
+
lines.push(`New: AI search ideas. This plan was made before CoAuthor checked AI answers. \`coauthor seo-plan generate\` updates it to add the searches where Google's AI answers recommend competitors instead of this site${estimate ? ` (about ${estimate} credits)` : ''}.`);
|
|
2559
|
+
}
|
|
2557
2560
|
const monthly = view.monthly_check === null || view.monthly_check === undefined ? null : planRecord(view.monthly_check);
|
|
2558
2561
|
if (monthly) {
|
|
2559
2562
|
if (monthly.enabled === true) {
|
|
@@ -2705,11 +2708,32 @@ function seoPlanResultsMessage(data) {
|
|
|
2705
2708
|
if (missing.length > RESULT_ROWS_SHOWN)
|
|
2706
2709
|
lines.push(` and ${missing.length - RESULT_ROWS_SHOWN} more (see --json data.missing_urls).`);
|
|
2707
2710
|
}
|
|
2711
|
+
const aiTrend = seoPlanAiTrendLine(lastCheck?.ai_visibility);
|
|
2712
|
+
if (aiTrend)
|
|
2713
|
+
lines.push('', aiTrend);
|
|
2708
2714
|
const reason = seoPlanCheckReason(lastCheck);
|
|
2709
2715
|
if (reason)
|
|
2710
2716
|
lines.push('', reason);
|
|
2711
2717
|
return lines.join('\n');
|
|
2712
2718
|
}
|
|
2719
|
+
/** "AI search mentions since 2026-11-18: Google AI answers 482 (up 12), ChatGPT 37 (down 3)." Null without a comparison. */
|
|
2720
|
+
export function seoPlanAiTrendLine(value) {
|
|
2721
|
+
if (!value || typeof value !== 'object')
|
|
2722
|
+
return null;
|
|
2723
|
+
const trend = planRecord(value);
|
|
2724
|
+
const since = planString(trend, 'previous_at');
|
|
2725
|
+
if (!since)
|
|
2726
|
+
return null;
|
|
2727
|
+
const parts = [];
|
|
2728
|
+
for (const [key, label] of [['google', 'Google AI answers'], ['chat_gpt', 'ChatGPT']]) {
|
|
2729
|
+
const row = trend[key] && typeof trend[key] === 'object' ? planRecord(trend[key]) : null;
|
|
2730
|
+
if (!row || typeof row.mentions !== 'number' || typeof row.change !== 'number')
|
|
2731
|
+
continue;
|
|
2732
|
+
const change = row.change === 0 ? 'no change' : `${row.change > 0 ? 'up' : 'down'} ${Math.abs(row.change)}`;
|
|
2733
|
+
parts.push(`${label} ${row.mentions} (${change})`);
|
|
2734
|
+
}
|
|
2735
|
+
return parts.length > 0 ? `AI search mentions since ${since.slice(0, 10)}: ${parts.join(', ')}.` : null;
|
|
2736
|
+
}
|
|
2713
2737
|
function seoPlanWaitFailure(status) {
|
|
2714
2738
|
const code = planString(status, 'error_code');
|
|
2715
2739
|
const message = planString(status, 'error_message') ?? 'The plan run failed.';
|
package/package.json
CHANGED
|
@@ -92,6 +92,8 @@ Some plans tag ideas whose searches are ones where Google AI answers cite a comp
|
|
|
92
92
|
|
|
93
93
|
An AI gap idea went through the same checks as every other idea; the tag explains why it matters, it does not mean the idea is more likely to rank. The human output of `show` prefixes it with `[AI gap]` and names the competitors. When you write one, `seo-plan write` puts its questions into the post's brief, and the outline answers them.
|
|
94
94
|
|
|
95
|
+
`ai_search_update_available` (top level of `show --json`) is `true` for a full plan made before AI search ideas went live on 2026-11-18. That plan has no `ai_visibility` and no AI gap ideas. Running `coauthor seo-plan generate` updates it and adds them, using the user's credits (`estimate_credits`). Mention it once when it is `true`, and do not update the plan without the user's go-ahead. It turns `false` after an update, and it is always `false` for previews and stale plans.
|
|
96
|
+
|
|
95
97
|
## Write this
|
|
96
98
|
|
|
97
99
|
`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.
|
|
@@ -126,7 +128,8 @@ Posts written without a target search (mostly drafted before SEO mode) are track
|
|
|
126
128
|
|
|
127
129
|
- `data.results` has one row per tracked post (a live address and a search), best news first (moved up, then page one by position, then the rest, then posts no check has read yet): `project_id`, `title`, `keyword`, `tracked_url`, `position`, `previous_position`, `movement`, `ranking_url`, `checked_at` and `tracking`. `tracking` is `null` for a post written for a target search; for a post written without one it is `{keyword, source}`: the search tracked now (`keyword` is `""` while the next check will pick one; it can differ from the row's `keyword`, which is what the last reading used) and who chose it (`source`: `ranked` or `suggested` = CoAuthor picked it, `manual` = the user did, `null` = not picked yet). `position` is Google's organic position; page one means 10 or better. It is `null` when the post's address is not within the top results the check looked at (`data.last_check.depth`, 30 by default), and `movement` is then `not_found`; if `ranking_url` is set, another page of the same site ranks for that search instead, which is worth telling the user. `movement` is `up` or `down` only for a move of 3 places or more, or a move onto or off page one; `same` is steady; `new` means the first reading of that search and address, so there is nothing to compare with yet; `pending` means the post went live after the last check and has no reading yet (`position` and `checked_at` are `null`; the next check reads it).
|
|
128
130
|
- `data.missing_urls` lists posts that have no live address (`project_id`, `title`, `keyword`, `needs_search`, `publication_status`: `needs_search` is `true`, with `keyword` `""`, for a post written without a target search that has no search to track yet, so the next check picks one; `publication_status`: `published`, `submitted`, or `null` when nobody marked the post); only posts explicitly marked as still being edited are left out. Most posts are unmarked, so a `null` post may not be live yet: ask the user before setting an address. They are not tracked until you set one with `coauthor post-details set <project-id> --live-url <url>` (add `--track-search "<search>"` to choose the search for a post without a target search); the next check picks it up.
|
|
129
|
-
- `data.last_check` is `{status, finished_at, partial, partial_reason, plan_refresh_skipped, error_code, credits_charged, free, depth}`. `partial` means the check stopped early (for example credits ran out); `plan_refresh_skipped` (`stale` or `failed`) means the plan's own chances were not refreshed because the plan needs updating, so run `coauthor seo-plan generate`. `status` `skipped` with `error_code` `insufficient_credits` means the account had too few credits and nothing was spent.
|
|
131
|
+
- `data.last_check` is `{status, finished_at, partial, partial_reason, plan_refresh_skipped, error_code, credits_charged, free, depth, ai_visibility}`. `partial` means the check stopped early (for example credits ran out); `plan_refresh_skipped` (`stale` or `failed`) means the plan's own chances were not refreshed because the plan needs updating, so run `coauthor seo-plan generate`. `status` `skipped` with `error_code` `insufficient_credits` means the account had too few credits and nothing was spent.
|
|
132
|
+
- `data.last_check.ai_visibility` is how many AI answers mentioned the site at that check, next to the previous reading: `{fetched_at, previous_at, google, chat_gpt}`. Each platform is `{mentions, cited, previous_mentions, change}` or `null` (`chat_gpt` is `null` outside United States / English). `previous_at` is `null` on the first reading, and `change` is then `null`. The previous reading is the last check's, or the plan's when the plan was updated since. The whole field is `null` when the check did not read AI mentions. Report the change as it is. A change of a few mentions is normal month to month, so don't explain it as the effect of a post. The human output of `results` prints one line for it.
|
|
130
133
|
- Everything is empty or `null` while monthly checks are not switched on for the account, and before the first check has run.
|
|
131
134
|
|
|
132
135
|
When you report results, lead with what moved up and what reached page one, then name any posts without a live address. Do not call a `same` post a failure: one monthly reading is noisy.
|
|
@@ -697,6 +697,8 @@ Some plans tag ideas whose searches are ones where Google AI answers cite a comp
|
|
|
697
697
|
|
|
698
698
|
An AI gap idea went through the same checks as every other idea; the tag explains why it matters, it does not mean the idea is more likely to rank. The human output of `show` prefixes it with `[AI gap]` and names the competitors. When you write one, `seo-plan write` puts its questions into the post's brief, and the outline answers them.
|
|
699
699
|
|
|
700
|
+
`ai_search_update_available` (top level of `show --json`) is `true` for a full plan made before AI search ideas went live on 2026-11-18. That plan has no `ai_visibility` and no AI gap ideas. Running `coauthor seo-plan generate` updates it and adds them, using the user's credits (`estimate_credits`). Mention it once when it is `true`, and do not update the plan without the user's go-ahead. It turns `false` after an update, and it is always `false` for previews and stale plans.
|
|
701
|
+
|
|
700
702
|
### Write this
|
|
701
703
|
|
|
702
704
|
`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.
|
|
@@ -731,7 +733,8 @@ Posts written without a target search (mostly drafted before SEO mode) are track
|
|
|
731
733
|
|
|
732
734
|
- `data.results` has one row per tracked post (a live address and a search), best news first (moved up, then page one by position, then the rest, then posts no check has read yet): `project_id`, `title`, `keyword`, `tracked_url`, `position`, `previous_position`, `movement`, `ranking_url`, `checked_at` and `tracking`. `tracking` is `null` for a post written for a target search; for a post written without one it is `{keyword, source}`: the search tracked now (`keyword` is `""` while the next check will pick one; it can differ from the row's `keyword`, which is what the last reading used) and who chose it (`source`: `ranked` or `suggested` = CoAuthor picked it, `manual` = the user did, `null` = not picked yet). `position` is Google's organic position; page one means 10 or better. It is `null` when the post's address is not within the top results the check looked at (`data.last_check.depth`, 30 by default), and `movement` is then `not_found`; if `ranking_url` is set, another page of the same site ranks for that search instead, which is worth telling the user. `movement` is `up` or `down` only for a move of 3 places or more, or a move onto or off page one; `same` is steady; `new` means the first reading of that search and address, so there is nothing to compare with yet; `pending` means the post went live after the last check and has no reading yet (`position` and `checked_at` are `null`; the next check reads it).
|
|
733
735
|
- `data.missing_urls` lists posts that have no live address (`project_id`, `title`, `keyword`, `needs_search`, `publication_status`: `needs_search` is `true`, with `keyword` `""`, for a post written without a target search that has no search to track yet, so the next check picks one; `publication_status`: `published`, `submitted`, or `null` when nobody marked the post); only posts explicitly marked as still being edited are left out. Most posts are unmarked, so a `null` post may not be live yet: ask the user before setting an address. They are not tracked until you set one with `coauthor post-details set <project-id> --live-url <url>` (add `--track-search "<search>"` to choose the search for a post without a target search); the next check picks it up.
|
|
734
|
-
- `data.last_check` is `{status, finished_at, partial, partial_reason, plan_refresh_skipped, error_code, credits_charged, free, depth}`. `partial` means the check stopped early (for example credits ran out); `plan_refresh_skipped` (`stale` or `failed`) means the plan's own chances were not refreshed because the plan needs updating, so run `coauthor seo-plan generate`. `status` `skipped` with `error_code` `insufficient_credits` means the account had too few credits and nothing was spent.
|
|
736
|
+
- `data.last_check` is `{status, finished_at, partial, partial_reason, plan_refresh_skipped, error_code, credits_charged, free, depth, ai_visibility}`. `partial` means the check stopped early (for example credits ran out); `plan_refresh_skipped` (`stale` or `failed`) means the plan's own chances were not refreshed because the plan needs updating, so run `coauthor seo-plan generate`. `status` `skipped` with `error_code` `insufficient_credits` means the account had too few credits and nothing was spent.
|
|
737
|
+
- `data.last_check.ai_visibility` is how many AI answers mentioned the site at that check, next to the previous reading: `{fetched_at, previous_at, google, chat_gpt}`. Each platform is `{mentions, cited, previous_mentions, change}` or `null` (`chat_gpt` is `null` outside United States / English). `previous_at` is `null` on the first reading, and `change` is then `null`. The previous reading is the last check's, or the plan's when the plan was updated since. The whole field is `null` when the check did not read AI mentions. Report the change as it is. A change of a few mentions is normal month to month, so don't explain it as the effect of a post. The human output of `results` prints one line for it.
|
|
735
738
|
- Everything is empty or `null` while monthly checks are not switched on for the account, and before the first check has run.
|
|
736
739
|
|
|
737
740
|
When you report results, lead with what moved up and what reached page one, then name any posts without a live address. Do not call a `same` post a failure: one monthly reading is noisy.
|