@comment-io/cli 0.1.10-alpha.272 → 0.1.10-alpha.274
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.
|
Binary file
|
|
Binary file
|
package/dist/comment-linux-amd64
CHANGED
|
Binary file
|
package/dist/comment-linux-arm64
CHANGED
|
Binary file
|
package/mcp/comment-mcp.mjs
CHANGED
|
@@ -27044,6 +27044,7 @@ var agentRules = [
|
|
|
27044
27044
|
{ id: "agent-role", severity: "must", summary: "Create and work with Comment.io documents when asked." },
|
|
27045
27045
|
{ id: "fetch-current-docs", severity: "must", summary: "Fetch the current agent docs at the start of each session." },
|
|
27046
27046
|
{ id: "bearer-token-is-identity", severity: "must", summary: "Treat the Bearer token as the actor identity." },
|
|
27047
|
+
{ id: "markdown-line-breaks", severity: "must", summary: "Do not hard-wrap ordinary prose; use single newlines only for semantic line breaks." },
|
|
27047
27048
|
{ id: "never-send-by", severity: "must", summary: "Never send a client-authored by field." },
|
|
27048
27049
|
{ id: "always-get-before-editing", severity: "must", summary: "Read the current document before editing." },
|
|
27049
27050
|
{ id: "per-doc-token-identify", severity: "must", summary: "Identify anonymous per-document tokens before writing." },
|
|
@@ -27055,6 +27056,7 @@ var coreAgentRuleIds = agentRules.map((rule) => rule.id);
|
|
|
27055
27056
|
var mcpServerRuleIds = [
|
|
27056
27057
|
"fetch-current-docs",
|
|
27057
27058
|
"bearer-token-is-identity",
|
|
27059
|
+
"markdown-line-breaks",
|
|
27058
27060
|
"never-send-by",
|
|
27059
27061
|
"always-get-before-editing",
|
|
27060
27062
|
"per-doc-token-identify",
|
|
@@ -27071,6 +27073,8 @@ function formatAgentRuleLine(id, context) {
|
|
|
27071
27073
|
return `**Memory:** Save doc URLs and tokens the user gives you. Fetch ${llmsUrl} each session for the latest API.`;
|
|
27072
27074
|
case "bearer-token-is-identity":
|
|
27073
27075
|
return "**Identity:** Your Bearer token is your identity. Do **not** send a `by` field - it is rejected with `400 UNEXPECTED_FIELD`. Registered agents (`as_...` tokens) are identified automatically from their handle. Per-doc tokens must register a display name once with `POST /agents/identify { display_name, slug }` before writing, or writes return `412 IDENTIFY_REQUIRED`. The raw query token on a share URL is read-only: call `GET /docs/{slug}?token={share_token}` to mint your personal `your_token`, then use that as your Bearer token.";
|
|
27076
|
+
case "markdown-line-breaks":
|
|
27077
|
+
return "**Markdown line breaks:** When creating or editing docs, do not hard-wrap ordinary prose at 80 columns. Send each prose paragraph as one line with a blank line between paragraphs. Use single newlines only when line breaks are semantically meaningful, such as poems, addresses, short outlines, Markdown table/list syntax, code blocks, or intentional hard-break content.";
|
|
27074
27078
|
case "never-send-by":
|
|
27075
27079
|
return "- **Identity is derived from your Bearer token.** Do **not** send a `by` field - requests that include it are rejected with `400 UNEXPECTED_FIELD`. If this is a per-doc token, register a display name once with `POST /agents/identify` (see below) before writing.";
|
|
27076
27080
|
case "always-get-before-editing":
|
|
@@ -27092,6 +27096,9 @@ function formatAgentRuleBullet(id, context) {
|
|
|
27092
27096
|
if (id === "report-api-bugs") {
|
|
27093
27097
|
return "- **Report API bugs while you work.** If a response includes a `feedback` URL and the API behavior looks wrong, contradicts these docs, or documented recovery fails once, POST to that URL with the method, endpoint, request/response summary, `request_id`, what you expected, and what recovery you tried. Report potentially wrong 409/422 responses this way; do not report the same issue twice.";
|
|
27094
27098
|
}
|
|
27099
|
+
if (id === "markdown-line-breaks") {
|
|
27100
|
+
return "- **Markdown line breaks:** When creating or editing docs, do not hard-wrap ordinary prose at 80 columns. Send each prose paragraph as one line with a blank line between paragraphs. Use single newlines only when line breaks are semantically meaningful, such as poems, addresses, short outlines, Markdown table/list syntax, code blocks, or intentional hard-break content.";
|
|
27101
|
+
}
|
|
27095
27102
|
return formatAgentRuleLine(id, context);
|
|
27096
27103
|
}
|
|
27097
27104
|
function buildMcpServerInstructions(baseUrl = "https://comment.io", sid) {
|
|
@@ -27170,6 +27177,7 @@ function apiReference(baseUrl, slug, token, sid) {
|
|
|
27170
27177
|
`### Key rules`,
|
|
27171
27178
|
formatAgentRuleBullet("always-get-before-editing", { baseUrl }),
|
|
27172
27179
|
formatAgentRuleBullet("bearer-token-is-identity", { baseUrl }),
|
|
27180
|
+
formatAgentRuleBullet("markdown-line-breaks", { baseUrl }),
|
|
27173
27181
|
`- **The document title is derived from the first non-empty markdown line.** Do **not** send a \`title\` field to \`POST /docs\` or \`PATCH /docs/:slug\`; those requests return \`400 UNEXPECTED_FIELD\`. To rename a doc, edit the first heading/line in \`markdown\`. \`POST /docs\` also accepts optional \`library_target\` for v1 My Files, Team Wiki, or Botlets brain placement; Botlets targets accept stable \`botId\`, optionally paired with \`botSlug\` as a guard/alias, mismatches return \`409 BOT_TARGET_MISMATCH\`, and successful placements return \`library_target_resolution.bot_id\`, \`requested_bot_slug\`, \`canonical_bot_slug\`, and \`slug_resolution\`.`,
|
|
27174
27182
|
formatAgentRuleBullet("report-api-bugs", { baseUrl }),
|
|
27175
27183
|
`- **\`quote\` is required** for suggestions and text-selected comments. Plain comments can instead target a durable block with \`block_id\` from \`content_blocks[].id\`; responses include a read-only \`anchor.version=2\` canonical mark anchor, and plain comments may also include \`anchor_block_id\`. Replies use \`reply_to\` and inherit the parent block. Chronological order within the block is the thread.`,
|
|
@@ -27640,6 +27648,7 @@ function buildCompleteAgentDocs(baseUrl = "https://comment.io", sid) {
|
|
|
27640
27648
|
formatAgentRuleLine("agent-role", { baseUrl }),
|
|
27641
27649
|
formatAgentRuleLine("fetch-current-docs", { baseUrl }),
|
|
27642
27650
|
formatAgentRuleLine("bearer-token-is-identity", { baseUrl }),
|
|
27651
|
+
formatAgentRuleLine("markdown-line-breaks", { baseUrl }),
|
|
27643
27652
|
formatAgentRuleLine("report-api-bugs", { baseUrl }),
|
|
27644
27653
|
``,
|
|
27645
27654
|
`## How agents work with Comment Docs`,
|
|
@@ -28187,6 +28196,7 @@ function buildHomeDocs(baseUrl = "https://comment.io", sid) {
|
|
|
28187
28196
|
formatAgentRuleLine("agent-role", { baseUrl, llmsUrl }),
|
|
28188
28197
|
formatAgentRuleLine("fetch-current-docs", { baseUrl, llmsUrl }),
|
|
28189
28198
|
formatAgentRuleLine("bearer-token-is-identity", { baseUrl, llmsUrl }),
|
|
28199
|
+
formatAgentRuleLine("markdown-line-breaks", { baseUrl, llmsUrl }),
|
|
28190
28200
|
formatAgentRuleLine("report-api-bugs", { baseUrl, llmsUrl }),
|
|
28191
28201
|
``,
|
|
28192
28202
|
`## How agents work with Comment Docs`,
|