# @creator-notes/cnotes 中文文档

规范地址：https://npmcn.com/package/%40creator-notes/cnotes/

版本：0\.125\.5
npm 元数据更新时间：2026-11-09T10:49:12.653Z
中文译文更新时间：2026-11-11T00:04:31.913Z
软件包许可：MIT

本文由上游 README 翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/%40creator-notes/cnotes
原文对照：https://npmcn.com/package/%40creator-notes/cnotes/?lang=original
项目主页：https://github.com/creatornotes/pm-notes/tree/main/cli#readme
源码仓库：https://github.com/creatornotes/pm-notes

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：5.4 MB，151 个文件
- 模块格式：ES Module
- TypeScript 类型：未声明
- Node.js 要求：\>=18
- 运行依赖：6 个
- 首次发布：2026-06-07T08:49:25.946Z
- 最新版本发布：2026-11-09T10:49:12.423Z
- 近 30 天下载量：16487（2026-10-11 至 2026-11-09，npm 官方下载统计）
- 已发布版本数：178（近 12 个月 178 个）

## 中文简介

CLI for Creator Notes – 创建笔记,构建画布,搜索终端的知识

## 安装

```sh
npm install @creator-notes/cnotes
```

也可以使用：`pnpm add @creator-notes/cnotes`、`yarn add @creator-notes/cnotes`、`bun add @creator-notes/cnotes`

## README

# @ creator-notes/ 注释

CLI 用于 [创建者注释](https://creatornotes.app/)。创建笔记、构建画布、搜索知识和管理终端的工作空间.

Npm 软件包是 `@creator-notes/cnotes`。未扫描的软件包 `cnotes` 属于别人的 不要安装它.

作为独立的CLI(`cnotes`作为 MCP 服务器 ()`cnotes-mcp`为克劳德这样的AI助手.

## 快速启动

一个指令设置了一切——认证、工作空间、克洛德代码技能以及(可选的)全球 `cnotes` 快捷键 :

```bash
npx @creator-notes/cnotes@latest init
```

在终端上,向导打开浏览器以登录(唯一的手工步骤),然后提议安装 Claude 代码技能和 `cnotes` 因此,未来的呼吁是即时的。 没有终点站, `cnotes init` 不打开浏览器:它打印一个登录的 URL并退出 2 . `cnotes init --help` 显示要随键运行的异端文件.

输入后 :

```bash
cnotes notes list            # Browse your notes
cnotes notes create --notes '{"key":"A","type":"Meeting","markdown":"# Standup\nAgenda…"}'
cnotes search semantic "onboarding flow"
```

> 更喜欢全球安装在前面? `npm install -g @creator-notes/cnotes && cnotes init` 还行.

## 图标

| 命令 | 别名 | 说明 |
| --- | --- | --- |
| `cnotes init` |  | 签名,选择工作空间,安装代理技能. 无浏览器: 退出 2 并打印 a `--token-stdin` 语录 |
| `cnotes auth login` |  | 通过浏览器认证,或 `--token-stdin` aPI 密钥 |
| `cnotes auth status` |  | 显示谁签入 。 0号出口签名,2号出口签名 |
| `cnotes whoami` |  | 与 `cnotes auth status` |
| `cnotes notes list|get|create|update|delete` | `cnotes n` | 管理注释( 创建接受一个或许多项) |
| `cnotes notes bulk-retype` |  | 将多笔记重排为新类型 |
| `cnotes notes move` |  | 将注释移动到另一个工作空间(复制内容、档案来源、交叉链接) |
| `cnotes versions list|create` | `cnotes v` | 注释版本历史 |
| `cnotes canvas list|get|create|delete` | `cnotes c` | 管理画布 |
| `cnotes canvas place` |  | 声明式布局——服务器包件无重叠 |
| `cnotes canvas milestone create|list|show|rename` |  | 保存、 读取并重命名画布里程碑( git- style 消息, 动词首标题需要; 附加到活动操作运行中) |
| `cnotes canvas add-node|add-text|add-list|add-link` |  | 明确时添加单个节点 `--x`编号 :`--y` (单位:千美元)`add-richtext` 是一个已贬值的别名,其名称是: `add-text`(中文(简体) ) |
| `cnotes canvas bulk-add|bulk-move` |  | 散装帆布作业——需要明确的坐标 |
| `cnotes canvas bulk-remove` |  | 从画布上取出节点/指针(纸条本身没有触动) |
| `cnotes canvas from-template` |  | 从模板创建画布 |
| `cnotes review request|get|list|complete` | `cnotes reviews` | 正式审查请求:询问(成员、本人或外部电子邮件)作为结构化工作接收(`list --assigned-to me`,获取信封,记录一个结果 |
| `cnotes review send-again|revoke` |  | 问别人同样的问题; 收回一个未回答的问题 |
| `cnotes draft open|status|propose|edits|ask|checkout|dismiss` |  | 私人草稿:将许多笔记和画布建出视线外,向共享笔记提议编辑,并分出共享的棋盘(`open --from-canvas CANVAS-n`)来重修自己抄本. 运行 `status` 直到没有检查块,那么 `ask --reviewer <person>` 并停止: 只有那个人在浏览器中接受; 没有密钥可以合并它 |
| `cnotes focus plan|list|cancel` |  | 计划受保护的重点块; `--canvas` + 键 `--target` 在它工作的卡片上划出一个街区 |
| `cnotes search semantic` | `cnotes s` | 语义跨音符搜索 |
| `cnotes query` | `cnotes q` | 过滤、 组合或运行 SELECT , 覆盖来自本地 SQLite 工作空间的每个音符元数据, 并同步到每个调用 |
| `cnotes timeline` | `cnotes tl` | 最近的活动种子 |
| `cnotes relationships list` | `cnotes rel` | 备注关系 |
| `cnotes brief` |  | 工作空间已经知道的任务:最相关的笔记、画布和最近的修改,以及早先对每个笔记所做的操作 |
| `cnotes lessons record|list` |  | 说明你所读的注释是有用的,是死胡同还是改正的(也有) `operations end --useful`),接下来的跑步简报从他们开始 |
| `cnotes types list|create|update` | `cnotes t` | 管理音符类型( 超级标签) |
| `cnotes workspace list|select|current` |  | 工作空间管理 |
| `cnotes config get-server|set-server` |  | CLI 配置 |
| `cnotes config get-local-db|set-local-db` |  | 允许或拒绝此机上的工作空间注释元数据本地副本( 默认关闭; 删除副本) |
| `cnotes mcp setup` |  | 打印 Claude MCP 服务器配置 |

## 全球旗帜

```
--json              Output raw JSON (for piping / scripting)
-q, --quiet         Minimal output (IDs only)
-w, --workspace <id>   Override active workspace
--server <url>         Override server URL
```

## 产出合同

每个命令都有一个合同:

-   **成功是退出代码,不是体域.** 退出 `0` 是成功的; 永远不要寻找 `ok` 键。 失败使用打入的表格 : `2` 认证, `3` 审定, `4` 没有找到, `5` 冲突, `6` 费率限额, `7` 允许, `8` 需要订阅, `9` 网络(请求从未到达服务器—— DNS/TCP/TLS 失败; JSON 携带低级 `cause`,比如说. `ENOTFOUND`) (中文(简体) ). 重运行一个写入, 因为一个键看起来是空的会重复它 .
-   **读取返回一个赤色阵列;写出返回一个信封.** `notes list/get/search --json` 管道到 `jq '.[0]'`。 。 。 . `notes create --json` 返回时 `{ results, relationshipsCreated, relationshipTypesCreated, rubrics? }`; 从 `.results` (无) `notes`编号 :`ok`) (中文(简体) ). 每个结果都包含 `displayId`, (中文(简体) ), `title`, (中文(简体) ), `type`,以及 `rubric`。 。 。 .
-   **错误教.** A 类 `--json` 失败打印 `{ error, code, exitCode, hint }` 改为 stderr, 在哪里 `hint` 命名修正它的命令( 错误的工作空间 id 返回一个 404 与 `resource: "workspace"` (单位:千美元) `cnotes workspace list` 暗示,不是赤裸的500.

## 认证

```bash
# Browser sign-in
cnotes auth login

# API key. The key stays on stdin, off `ps` and out of shell history.
cnotes auth login --token-stdin <<'EOF'
cn_...
EOF

# Who is signed in. Exit 0 when a token is stored, exit 2 when signed out.
cnotes auth status
cnotes whoami
```

## 页:1

`cnotes notes create` 接受一个或许多项——通过 `--notes` 或作为单一 JSON对象或一系列对象. 使用 `[@key: Title](relationship:references)` 在下划线内,以相互参照同一批中的另一个项目 `@key` 实值 创建后替换为新注释的显示ID.

```bash
# Single note (object form)
cnotes notes create --notes '{"key":"A","type":"Insight","markdown":"# Quick idea","tags":["ux","onboarding"]}'

# Multiple interlinked notes (array form)
cnotes notes create --notes '[
  {"key":"A","type":"PainPoint","markdownFile":"./problem.md"},
  {"key":"B","type":"Insight","markdown":"# Solution\nFixes [@A: Problem](relationship:references)."}
]'

# List with filters
cnotes notes list --type Meeting --pinned --limit 10

# Get one or many by display ID (single round-trip, always returns array in input order)
cnotes notes get MEETING-42
cnotes notes get MEETING-42 PRD-3 IDEA-7

# The note plus every note it links to (outgoing rows and [[rel::ID]] / [[ID]])
cnotes notes get DECISION-6KN --expand
cnotes notes get DECISION-6KN --expand --depth 2 --rel assumes,depends-on --summary

# Partial reads set truncated and notice: 40 output notes, 40 candidates per
# direction/inline body per note, and 512 candidates across the whole walk.

# Update metadata
cnotes notes update MEETING-42 --pin --tags "important,q2"
```

如果任何项目有错误, 命令退出非零并列出每个坏项目 一起来.. `item <index> (<key>): <field>: <reason>` - 这样你就可以修复整个 一枪毙命 与 `--json`,同样的每个项目错误 回到下 `details.items` 方案分析.

### 批量重排类型

一次更改多笔记的类型 :

```bash
cnotes notes bulk-retype --ids '["NOTE-1","NOTE-3","NOTE-5"]' --type Insight --json
```

### 内容更新

内容和元数据是单独的操作:

```bash
# Update content -> create a new version. First line is the timeline headline
# (verb-first, at most 110 characters). A blank line, then the body. The
# platform may rewrite an agent headline. The body is kept.
cnotes versions create MEETING-42 --description "Added the action items from the review" --markdown-file ./updated.md

# Update metadata (type, tags, pin, archive). Title is read-only —
# change it by creating a new version with a different # h1 heading.
cnotes notes update MEETING-42 --type Insight --tags "auth,security" --pin
```

## 帆布

数值 `<angle-brackets>` 是占位符 —— 以您工作空间的真实身份代替.

```bash
# Create a canvas
cnotes canvas create "Sprint Review"

# Read every note on a canvas as one concatenated markdown document, in
# display order — for thinking across a canvas in a single round-trip
cnotes canvas read <canvasId>

# Recent activity on a canvas: edits, agent runs, gestures, restores —
# newest first. Use this to see what changed (and who changed it) before
# editing, or to confirm a previous agent run actually applied.
cnotes canvas activity <canvasId> [--limit 50]

# Save a milestone. First line is the timeline headline: it must start with a
# past-tense verb and name a specific object ("Shipped the public comic canvas",
# never "V1"), at most 110 characters; anything else is rejected. A blank line,
# then the body. The platform may tidy an agent headline. The body is kept.
# An active operations run is stamped on.
cnotes canvas milestone create <canvasId> --message "Opened pricing question: charge for agents or the workspace?"
cnotes canvas milestone list <canvasId>
cnotes canvas milestone show <milestoneId>
cnotes canvas milestone rename <milestoneId> -m "Shipped the public comic canvas"

# Place items with a declarative layout (preferred — no x/y math)
cnotes canvas place <canvasId> --spec ./layout.json

# Add nodes with explicit coordinates (escape hatch — pixel-perfect templates only)
cnotes canvas bulk-add <canvasId> --notes '[{"noteId":"NOTE-1","x":100,"y":100},{"noteId":"NOTE-2","x":500,"y":100}]'
cnotes canvas add-edge <canvasId> --source <nodeId> --target <nodeId> --label "blocks"

# Create from template
cnotes canvas from-template sprint-retrospective --populate
```

可用的模板 : `sprint-retrospective`, (中文(简体) ), `swot-analysis`, (中文(简体) ), `kanban-board`, (中文(简体) ), `feature-prioritization`, (中文(简体) ), `meeting-notes`, (中文(简体) ), `product-roadmap`

### 代理运行的生命周期

当一个AI代理对单个用户请求进行多个画布修改时,将整个序列包入 `cnotes canvas agent-run wrap`。服务器会捕捉围绕工作的自动检查点,将每次突变组合成单一的可回转操作,并将提示作为意图元数据.

```bash
cnotes canvas agent-run wrap \
  --canvas <canvasId> \
  --prompt "Reorganize roadmap into Q1/Q2 clusters" \
  -- bash -c '
    cnotes canvas add-text "$CANVAS" --content "# Q1" --x 100 --y 100
    cnotes canvas add-edge "$CANVAS" --source <id1> --target <id2>
  '
```

包装表单确实开始 ^ 运行命令 → 自动结束, 即使命令失败 。 详细情况 `agent-run begin` 编号 : `end` 模式(当无法切换外壳时使用)见 `SKILL.md`。 。 。 .

### 声明式布局`cnotes canvas place`(中文(简体) )

大多数时候你不应该用手计算像素坐标——特工和人类都对此不好. `cnotes canvas place` 使用描述 **结构** 服务器对每个项目进行测量,将它们装入一个批次中,没有重叠。 该调用是最佳的:在响应中报告每个项目失败(HTTP 207),但成功的项目留在画布上.

四个组成部分:

-   **`stack`** 沿一轴流动的项目(`vertical` 或者说 `horizontal`),像 CSS 弹性框
-   **`grid`** ——N列,项目被包裹到新行上,如CSS网格自动流量
-   **`anchor`** 设置相对于现有帆布节点的子树
-   **`item`** 叶子: `note`, (中文(简体) ), `richtext` (正文元素——一个无锡的下标正文,是一个正文), `list`, (中文(简体) ), `canvas` (链接),或 `section` (范围)

示例——3行网格上方的丰富文本标题:

```json
{
  "root": {
    "kind": "stack", "axis": "vertical", "gap": "medium",
    "items": [
      { "kind": "item", "type": "richtext",
        "content": "# Goals\nQ2 commitments.", "size": "medium" },
      { "kind": "grid", "columns": 3, "gap": "tight",
        "items": [
          { "kind": "item", "type": "note", "noteId": "GOAL-1" },
          { "kind": "item", "type": "note", "noteId": "GOAL-2" },
          { "kind": "item", "type": "note", "noteId": "GOAL-3" }
        ] }
    ]
  }
}
```

```bash
cnotes canvas place <canvasId> --spec ./goals.json --json
```

`gap` 接受 `"tight"`, (中文(简体) ), `"medium"`, (中文(简体) ), `"spacious"`,或原始像素编号。 项目之间的边缘可用顶级添加 `"edges"` 数组引用项 `key` 字段。 见 [技能/说明/技能](https://npmcn.com/package/%40creator-notes/cnotes/skills/cnotes/SKILL.md) 用于完整的 DSL 参考和更多实例.

## AI 一体化

### 克洛德代码(建议)

最简单的路径:运行 `npx @creator-notes/cnotes@latest init` 并接受"加入克洛德密码的技巧"? 巫师将技能复制到 `~/.claude/skills/cnotes/SKILL.md` 所以,每一次克劳德代码会 学习完整的 `cnotes` 自动引用命令.

之后,克劳德将使用 `cnotes` 当您询问有关笔记、画布或工作空间的任务时—— 不再设置 .

或以 Claude 代码插件安装所有设备: `cnotes` 技能,下面的可选技能,以及远程的MCP服务器,在新版本发货时更新. 运行 `/mcp` 一次之后,签署连接.

```bash
claude plugin marketplace add https://cnotes.dev/marketplace.json
claude plugin install creator-notes-cli@cnotes
```

可选技能( 非自动安装) :

```bash
cnotes skills list
cnotes skills install fat-marker-flows     # Shape Up sketch journeys
cnotes skills install howto-filmstrips     # live UI screenshot how-tos
cnotes skills install wayfind              # decision maps for multi-session work
cnotes skills install shaping              # requirements, shapes, fit check, slices
cnotes skills install attention-planner    # one answerable card a day, loop closed by the agent
cnotes skills install transcript-timeline  # one interview, themes as rows, quotes on a timeline
cnotes skills install teach-workspace      # a course taught from the notes, one cited lesson a session
```

### Claude 桌面( MCP 服务器)

将 Claude Desktop 添加为工具服务器,以便直接读取和写出您的笔记 .

**1\. 认证和选择工作空间:**

```bash
cnotes init
```

**2\. 生成 MCP 配置 :**

```bash
cnotes mcp setup --json
```

**3\. 将输出复制到您的 Claude 桌面配置文件 :**

| 监督办 | 配置路径 |
| --- | --- |
| 马科斯 | `~/Library/Application Support/Claude/claude_desktop_config.json` |
| 窗口 | `%APPDATA%\Claude\claude_desktop_config.json` |
| 链接 | `~/.config/Claude/claude_desktop_config.json` |

输出看起来是这样的——将其合并到您现有的配置中:

```json
{
  "mcpServers": {
    "cnotes": {
      "command": "node",
      "args": ["/path/to/dist/mcp-server.js"],
      "env": {
        "CNOTES_SERVER": "https://creatornotes.app",
        "CNOTES_TOKEN": "<your-token>",
        "CNOTES_WORKSPACE": "<your-workspace-id>"
      }
    }
  }
}
```

**4\. 重新启动克洛德桌面.** Creator Notes MCP 工具将出现在工具拾取器中.

### 手动安装

`cnotes init` 安装用户级技能( e)`~/.claude/skills/cnotes/SKILL.md`为了你 如果您想要将技能范围扩大到单个项目:

```bash
mkdir -p .claude/skills/cnotes
cp $(npm root -g)/@creator-notes/cnotes/skills/cnotes/SKILL.md .claude/skills/cnotes/SKILL.md
```

## 查询本地副本( Q)`cnotes query`(中文(简体) )

`cnotes query` 将工作空间的注释元数据(标题、类型、标记、画布、每张注释的制作人、判断的答案;从未是注释体)的 SQLite 副本保存在下面 `~/.cnotes/local-db/`,同步上次通话以来的变化,并从副本中回答。 查询本身以毫秒为单位运行;每次通话首先读取工作空间头和所变化的东西,在5000个注的工作空间上一秒或两秒,第一个拷贝在那个尺寸上大约需要一分钟. 网络app的查询面板使用相同的复制格式,因此两者从未有异议.

磁盘上的复制品是个人的决定,就像在网络应用中:它关闭直到 `cnotes config set-local-db on` (或 `CNOTES_LOCAL_DB=on` 以复制当前工作空间。 直到那个时候 `cnotes query`,则 `cnotes_query` MCP工具,拒绝并说. `set-local-db off` 删除每份副本; `cnotes query --forget` 删除一个工作空间.

拷贝上, `cnotes notes list` 编辑 `cnotes_notes_list` MCP工具解答类型,标记,标题-文本,指针和无扫描列表也从中取出,以同一行形状,计出每个音符. 在同步后30秒之内的列表, 从此之后没有从此机器中写入文件, 只读文件; 否则它首先同步, 所以您刚刚写的注释总是在那里 。 尺寸过滤器会询问服务器,当复制件无法回答时,任何列表也会如此(还没有该工作空间的复制件,是另一个注解版本的复制件). 一行铁线说 `From the local copy, synced 12 s ago.` 或者说 `From the server: <why>.`

```bash
cnotes query pricing --type Decision,Insight      # words in the title, AND across fields
cnotes query --canvas CANVAS-12 --group-by tag    # notes on one canvas, grouped by tag
cnotes query --made-by api --group-by month       # what agents wrote through a cn_ key, by month
cnotes query --sql "SELECT type, COUNT(*) AS n FROM notes GROUP BY type ORDER BY n DESC"
cnotes query --rebuild                            # drop this workspace's copy and copy it again
```

`--group-by` 带 `type`, (中文(简体) ), `canvas`, (中文(简体) ), `tag`, (中文(简体) ), `month`, (中文(简体) ), `person`, (中文(简体) ), `made-by`, (中文(简体) ), `none`,或 `<Type>:<dimension>` 为了一个判断的维度. `--sql` 运行一个只读的 SELECT(`--sql tables` 打印表格。 需要22.13节点或更新.

## 脚本

```bash
# Chain commands with quiet mode (--quiet emits one display ID per line)
NOTE_ID=$(cnotes notes create --notes '{"key":"A","type":"Note","markdown":"# Quick note"}' -q)
cnotes canvas add-node <canvasId> --note "$NOTE_ID"

# JSON output for parsing
cnotes notes list --json | jq '.[0].displayId'

# Several interlinked notes with @key placeholders
cnotes notes create --json --notes '[
  {"key":"A","type":"PainPoint","markdownFile":"./problem.md"},
  {"key":"B","type":"Insight","markdown":"# Solution\nFixes [@A: Problem](relationship:references)."}
]'
```

## 所需资源

-   节点.js 18
-   A 类 [创建者注释](https://creatornotes.app/) 账户

## 许可证

麻省理工学院

## 常见问题

### @creator-notes/cnotes 是什么？

CLI for Creator Notes – 创建笔记,构建画布,搜索终端的知识

### 如何安装 @creator-notes/cnotes？

在项目目录运行 npm install @creator-notes/cnotes，或使用 pnpm add / yarn add / bun add。它还提供命令行工具 cnotes、cnotes-mcp，可以用 npx cnotes 直接运行。

### @creator-notes/cnotes 支持 TypeScript 吗？

该包的 package\.json 没有声明类型入口。需要类型提示时，可以在 npm 上查找社区维护的 @types/creator-notes\_\_cnotes 是否存在。

### @creator-notes/cnotes 支持 ESM 还是 CommonJS？

以 ES Module 形式发布，推荐使用 import 引入。在 CommonJS 项目中，Node\.js 20\.19\+ / 22\.12\+ 可以直接 require\(\) 不含顶层 await 的 ES Module，更早的版本需要改用动态 import\(\)。

### @creator-notes/cnotes 需要什么版本的 Node\.js？

package\.json 的 engines 字段要求 Node\.js \>=18。版本不符时 npm 默认只给出警告，开启 engine-strict 后会拒绝安装。

### @creator-notes/cnotes 可以商用吗？

@creator-notes/cnotes 使用 MIT 许可。宽松许可：允许商业使用、修改和再分发，通常只需在分发时保留原版权与许可声明。以上为概括，不构成法律意见，请以许可原文为准。

### @creator-notes/cnotes 的下载量有多少？

根据 npm 官方下载统计，@creator-notes/cnotes 在 2026/10/11 – 2026/11/09 这 30 天内被下载 16,487 次，日均约 550 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入，适合横向比较热度，不能直接等同于使用人数。

### @creator-notes/cnotes 还在维护吗？

最新版本 0\.125\.5 发布于 2026/11/09（1 天前）；至今共发布 178 个版本，其中过去 12 个月发布了 178 个；首次发布于 2026/06/07。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

