@jerryjiao/knowflow 0.3.0

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/CHANGELOG.md ADDED
@@ -0,0 +1,89 @@
1
+ # Changelog
2
+
3
+ All notable changes to KnowFlow are documented here. This project follows
4
+ [Semantic Versioning](https://semver.org/).
5
+
6
+ ## [Unreleased]
7
+
8
+ ### Added
9
+
10
+ - Bilingual documentation website (Astro + Starlight) under `site/`, deployed to
11
+ GitHub Pages via GitHub Actions. English landing at `/`, Chinese at `/zh/`,
12
+ docs under `/en/` and `/zh/` with browser-language auto-switch.
13
+
14
+ ## [0.3.0] - 2026-08-18
15
+
16
+ ### Added
17
+
18
+ - First npm release, published as the scoped package `@jerryjiao/knowflow`
19
+ (npm considers the bare name too similar to the existing `know-flow`
20
+ package). Install with `npm install -g @jerryjiao/knowflow`; the CLI
21
+ command is still `knowflow`.
22
+ - `knowflow tags` builds and prunes `tag/<name>.md` hub pages from `[[tag/<name>]]`
23
+ links, linking back to every tagged page. Re-running is idempotent.
24
+ - `health.excludeOrphanDirs` configuration lists directories whose pages are
25
+ expected to be unreferenced (daily-sync feeds, inboxes) and should not count
26
+ as isolated pages.
27
+
28
+ ### Fixed
29
+
30
+ - Link extraction missed every wikilink after the first one on a line, so
31
+ index-style pages that put dozens of links on a single line silently dropped
32
+ most of their references and produced mass false orphan reports.
33
+ - Markdown link extraction captured a leading `(` into the target path.
34
+ - `knowflow health` exited with code 0 even when it found issues, hiding
35
+ failures from cron and CI wrappers.
36
+
37
+ ### Changed
38
+
39
+ - Both READMEs make the source checkout the primary install path until the
40
+ npm package is published, instead of an `npx` command that 404s.
41
+
42
+ ## [0.2.1] - 2026-08-10
43
+
44
+ ### Added
45
+
46
+ - `knowflow fix [--dry-run]` repairs issues the health check surfaces: cleans empty
47
+ `[[entities/,]]` / `[[concepts/,]]` links, creates missing entity/concept pages,
48
+ pads files below the minimum size, and auto-links orphan pages to `index.md`.
49
+ `--dry-run` reports what would change without writing.
50
+
51
+ ### Fixed
52
+
53
+ - `wiki-auto-fix.sh` (now backing `knowflow fix`) honored `--dry-run` for the
54
+ empty-link cleanup but still created, padded, and orphan-linked files in
55
+ dry-run mode because shell redirections ran before the dry-run guard. All
56
+ three write paths now short-circuit under `--dry-run` and `\n` escapes in the
57
+ pad suffix render as real newlines.
58
+
59
+ ## [0.2.0] - 2026-07-17
60
+
61
+ ### Added
62
+
63
+ - `knowflow init [directory]` now creates a standalone project, its JSON configuration,
64
+ Wiki/raw/graph directories, starter index, and editable templates.
65
+ - Core CLI tests using Node's built-in test runner and a GitHub Actions workflow.
66
+ - npm publishing metadata and an explicit package file allowlist.
67
+ - English and Simplified Chinese project guides, a runnable text-to-graph example,
68
+ contributor and security policies, and structured GitHub issue forms.
69
+
70
+ ### Changed
71
+
72
+ - Commands resolve project paths from the nearest `.knowflowrc` and support custom
73
+ Wiki, raw, and graph locations.
74
+ - External commands use argument arrays instead of interpolated shell strings.
75
+ - Graph, ingestion, bookmark, health, and vector scripts use portable project paths.
76
+
77
+ ### Fixed
78
+
79
+ - Fixed the undefined graph Wiki path and browser launcher in the CLI.
80
+ - Fixed a syntax error and ESM compatibility in `enrich-wiki.js`.
81
+ - Removed machine-specific paths from graph scripts.
82
+
83
+ ## [0.1.0] - 2026-04-28
84
+
85
+ - Initial open-source release.
86
+
87
+ [0.2.1]: https://github.com/jerryjiao/knowflow/compare/v0.2.0...v0.2.1
88
+ [0.2.0]: https://github.com/jerryjiao/knowflow/compare/d0ff6f4...v0.2.0
89
+ [0.1.0]: https://github.com/jerryjiao/knowflow/commit/d0ff6f4
@@ -0,0 +1,41 @@
1
+ # Contributing to KnowFlow
2
+
3
+ Thanks for helping make agent-native knowledge work more practical. Focused bug fixes, documentation improvements, new source adapters, templates, and reproducible workflow examples are all welcome.
4
+
5
+ ## Before opening a pull request
6
+
7
+ 1. Check existing issues and explain the user problem your change solves.
8
+ 2. Keep capture and Wiki synthesis conceptually separate: `ingest` saves raw material; a human or agent organizes structured pages.
9
+ 3. Preserve portable project paths and existing Markdown/configuration formats.
10
+ 4. Add or update tests for observable CLI behavior.
11
+ 5. Run the complete local verification suite:
12
+
13
+ ```bash
14
+ npm install
15
+ npm run check
16
+ npm test
17
+ npm pack --dry-run
18
+ ```
19
+
20
+ ## Project conventions
21
+
22
+ - Node.js code uses ES modules unless a script has an explicit compatibility reason.
23
+ - Python targets 3.10+ and should include type annotations for new public functions.
24
+ - Shell scripts use `set -euo pipefail` and quote path/input variables.
25
+ - Commit messages should follow Conventional Commits, such as `feat:`, `fix:`, or `docs:`.
26
+ - Never commit API keys, `.env` files, captured private content, or machine-specific absolute paths.
27
+
28
+ ## Useful starting points
29
+
30
+ | Goal | File or directory |
31
+ | --- | --- |
32
+ | Change CLI behavior | `bin/knowflow.js` |
33
+ | Change capture behavior | `scripts/ingest.sh` |
34
+ | Change graph generation | `scripts/graph_builder.py` |
35
+ | Change Wiki templates | `templates/` |
36
+ | Understand the architecture | `docs/architecture/system-architecture.md` |
37
+ | Understand the data model | `docs/reference/data-model.md` |
38
+
39
+ For the longer Chinese contributor guide, see [docs/contributing.md](docs/contributing.md). Please report vulnerabilities according to [SECURITY.md](SECURITY.md), not in a public issue.
40
+
41
+ By contributing, you agree that your contribution will be licensed under the repository's [MIT License](LICENSE).
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 KnowFlow Contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,177 @@
1
+ # KnowFlow
2
+
3
+ <p align="left"><img src="docs/assets/logo.png" width="120" alt="KnowFlow logo"></p>
4
+
5
+ [English](README.md) | [简体中文](README.zh-CN.md) | [Website & docs](https://jerryjiao.github.io/knowflow/)
6
+
7
+ [![CI](https://github.com/jerryjiao/knowflow/actions/workflows/ci.yml/badge.svg)](https://github.com/jerryjiao/knowflow/actions/workflows/ci.yml)
8
+ [![Node.js 18+](https://img.shields.io/badge/Node.js-18%2B-339933?logo=node.js&logoColor=white)](https://nodejs.org/)
9
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
10
+
11
+ ![KnowFlow — an agent-native Markdown knowledge workspace](docs/assets/knowflow-social-preview.png)
12
+
13
+ > An agent-native Markdown knowledge workspace for capturing sources, organizing linked wiki pages, and exploring what you know.
14
+
15
+ KnowFlow keeps the workflow inspectable: URLs and notes land in `raw/`, you or an AI agent turn them into structured Markdown pages, and local tools build a knowledge graph, check wiki health, and report project status. Optional semantic search is available when you configure an embedding API key.
16
+
17
+ - **Own the knowledge layer** — plain Markdown, editable templates, and `[[wikilinks]]` instead of a closed database.
18
+ - **Work with any agent** — keep capture deterministic, then use the agent or workflow you trust for synthesis.
19
+ - **See structure, not just search results** — generate an interactive graph and catch broken or isolated pages.
20
+
21
+ > **Demo:** [Run the text-to-graph walkthrough](examples/quickstart.md), then explore the generated graph in your browser.
22
+
23
+ ![KnowFlow interactive knowledge graph](docs/assets/knowflow-graph-demo.png)
24
+
25
+ ## Quick start
26
+
27
+ Requires Node.js 18+, Python 3.10+, Bash, and curl.
28
+
29
+ Install from npm — or [install from source](#install-from-source) if you prefer:
30
+
31
+ ```bash
32
+ npm install -g @jerryjiao/knowflow
33
+ knowflow init my-wiki
34
+ cd my-wiki
35
+ knowflow ingest "LLM Wikis turn notes into linked knowledge." --source text
36
+ knowflow status
37
+ knowflow graph --no-open
38
+ ```
39
+
40
+ This creates a standalone project, captures one note in `raw/`, and builds a graph from the starter Wiki. **`ingest` does not automatically generate structured Wiki pages.** Organize captured material manually or with an AI agent/workflow before rebuilding the graph.
41
+
42
+ One-off usage without a global install also works: `npx @jerryjiao/knowflow@latest <command>`.
43
+
44
+ ## The workflow
45
+
46
+ ```text
47
+ URL or note
48
+
49
+
50
+ raw/ Markdown ──► you, an AI agent, or a custom workflow
51
+
52
+
53
+ linked Wiki pages
54
+ │ │
55
+ ▼ ▼
56
+ knowledge graph optional semantic search
57
+ ```
58
+
59
+ KnowFlow is inspired by [Andrej Karpathy's LLM Wiki](https://karpathy.github.io/llm-wiki/): knowledge becomes more useful when it is curated into durable, connected pages instead of being left in a pile of saved links.
60
+
61
+ ## What is included
62
+
63
+ - Capture plain text and supported URLs as raw Markdown.
64
+ - Initialize portable projects with JSON configuration and editable page templates.
65
+ - Organize source, entity, concept, and comparison pages with `[[wikilinks]]`.
66
+ - Generate `graph.html` and `graph.json` without an API key.
67
+ - Check broken links, undersized files, and isolated pages.
68
+ - Repair empty links, create missing pages, pad small files, and link orphans.
69
+ - Query a previously built vector index with optional Zhipu AI embeddings.
70
+
71
+ ## Commands
72
+
73
+ | Command | What it does |
74
+ | --- | --- |
75
+ | `knowflow init [directory]` | Create a standalone project; defaults to the current directory |
76
+ | `knowflow ingest <url-or-text>` | Capture a URL or text in `raw/` |
77
+ | `knowflow graph [--no-open]` | Generate `graph.html` and `graph.json` from Wiki pages |
78
+ | `knowflow fix [--dry-run]` | Repair empty links, missing pages, small files, and orphans |
79
+ | `knowflow health` | Check broken links, small files, and isolated pages |
80
+ | `knowflow tags` | Build `tag/<name>.md` hub pages from `[[tag/<name>]]` links |
81
+ | `knowflow status` | Show raw, Wiki, graph, vector-index, and API-key status |
82
+ | `knowflow query <text>` | Query an existing vector index |
83
+
84
+ KnowFlow searches upward from the current directory for the nearest `.knowflowrc`, so commands also work inside project subdirectories.
85
+
86
+ ## Install from source
87
+
88
+ ```bash
89
+ git clone https://github.com/jerryjiao/knowflow.git
90
+ cd knowflow
91
+ npm install
92
+ npm link
93
+ knowflow init ../my-wiki
94
+ ```
95
+
96
+ Running `init` again preserves existing configuration, the starter index, and customized templates.
97
+
98
+ ## Project layout
99
+
100
+ ```text
101
+ my-wiki/
102
+ ├── .knowflowrc
103
+ ├── raw/ # captured source material
104
+ ├── wiki/
105
+ │ ├── index.md
106
+ │ ├── sources/
107
+ │ ├── entities/
108
+ │ ├── concepts/
109
+ │ └── comparisons/
110
+ ├── graph/ # generated graph.html and graph.json
111
+ └── templates/ # editable Markdown templates
112
+ ```
113
+
114
+ ## Configuration
115
+
116
+ `knowflow init` writes a JSON `.knowflowrc`. Relative paths resolve from the directory containing that file.
117
+
118
+ ```json
119
+ {
120
+ "wiki": {
121
+ "root": "./wiki",
122
+ "rawDir": "./raw"
123
+ },
124
+ "graph": {
125
+ "output": "./graph/graph.html"
126
+ },
127
+ "health": {
128
+ "minFileSize": 100,
129
+ "excludeOrphanDirs": ["sources/"]
130
+ }
131
+ }
132
+ ```
133
+
134
+ `health.excludeOrphanDirs` lists directories whose pages are expected to be unreferenced (daily-sync feeds, inboxes) and should not count as isolated pages. `knowflow tags` regenerates every hub page under `wiki/tag/`, so re-running it after new tagged pages arrive is safe and idempotent.
135
+
136
+ Graph generation, health checks, capture, and status do not require an API key. Semantic search requires `ZHIPUAI_API_KEY` in the project environment or a project-root `.env` file:
137
+
138
+ ```bash
139
+ ZHIPUAI_API_KEY=your-key-here
140
+ ```
141
+
142
+ The current CLI can query an existing vector index but does not yet expose a standalone `index` command. See [Current limitations](#current-limitations) before relying on search.
143
+
144
+ ## Current limitations
145
+
146
+ - `ingest` captures raw material; structured Wiki synthesis is a separate human or agent step.
147
+ - URL capture uses Jina Reader. YouTube and some logged-in platforms may also require `yt-dlp` or an authenticated browser workflow.
148
+ - `query` needs a prebuilt vector index and a [Zhipu AI API key](https://open.bigmodel.cn/). Until an `index` CLI command is added, advanced users can run `node <knowflow-install>/scripts/vector-store.mjs build`.
149
+ - `bookmark_sync.sh` depends on the optional third-party `ft` command.
150
+ - Generated graph HTML loads vis-network from a CDN when opened.
151
+
152
+ ## Roadmap
153
+
154
+ - [x] Standalone project initialization and portable paths
155
+ - [x] Raw URL/text capture, Wiki health checks, and interactive graphs
156
+ - [x] CLI tests and CI across supported Node.js versions
157
+ - [ ] A first-class agent workflow from raw capture to reviewed Wiki pages
158
+ - [ ] Incremental ingestion and duplicate-source detection
159
+ - [ ] `knowflow index` and pluggable embedding providers
160
+ - [ ] Extractor/plugin system and a local Web UI
161
+
162
+ Ideas and focused pull requests are welcome. Start with the [contribution guide](CONTRIBUTING.md), run the [text-to-graph example](examples/quickstart.md), or propose a use case in [GitHub Issues](https://github.com/jerryjiao/knowflow/issues).
163
+
164
+ ## Development
165
+
166
+ ```bash
167
+ npm install
168
+ npm run check
169
+ npm test
170
+ npm pack --dry-run
171
+ ```
172
+
173
+ See the [changelog](CHANGELOG.md) for release notes and the [security policy](SECURITY.md) for responsible disclosure.
174
+
175
+ ## License
176
+
177
+ [MIT](LICENSE) © [Jerry Jiao](https://github.com/jerryjiao)
@@ -0,0 +1,176 @@
1
+ # KnowFlow
2
+
3
+ <p align="left"><img src="docs/assets/logo.png" width="120" alt="KnowFlow logo"></p>
4
+
5
+ [English](README.md) | [简体中文](README.zh-CN.md) | [官网与文档](https://jerryjiao.github.io/knowflow/)
6
+
7
+ [![CI](https://github.com/jerryjiao/knowflow/actions/workflows/ci.yml/badge.svg)](https://github.com/jerryjiao/knowflow/actions/workflows/ci.yml)
8
+ [![Node.js 18+](https://img.shields.io/badge/Node.js-18%2B-339933?logo=node.js&logoColor=white)](https://nodejs.org/)
9
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)
10
+
11
+ ![KnowFlow — 面向 AI Agent 的 Markdown 知识工作区](docs/assets/knowflow-social-preview.png)
12
+
13
+ > 一个面向 AI Agent 的 Markdown 知识工作区:采集来源、整理互联 Wiki,并看见知识之间的关系。
14
+
15
+ KnowFlow 让整个流程保持透明、可检查:URL 和笔记先进入 `raw/`,再由你或 AI Agent 整理为结构化 Markdown 页面;本地工具负责生成知识图谱、检查 Wiki 健康度和显示项目状态。配置嵌入 API Key 后,还可启用语义检索。
16
+
17
+ - **知识层归你所有** — 使用普通 Markdown、可编辑模板和 `[[wikilinks]]`,不被封闭数据库锁定。
18
+ - **适配任意 Agent** — 采集保持确定性,知识提炼则交给你信任的 Agent 或工作流。
19
+ - **看见结构,而不只是搜索结果** — 生成交互式图谱,并发现断链和孤立页面。
20
+
21
+ > **Demo:** [运行从文本到图谱的完整演示](examples/quickstart.md),然后在浏览器中探索生成的图谱。
22
+
23
+ ![KnowFlow 交互式知识图谱](docs/assets/knowflow-graph-demo.png)
24
+
25
+ ## 快速开始
26
+
27
+ 需要 Node.js 18+、Python 3.10+、Bash 和 curl。
28
+
29
+ 从 npm 安装——想从源码装也行([见下文](#从源码安装)):
30
+
31
+ ```bash
32
+ npm install -g @jerryjiao/knowflow
33
+ knowflow init my-wiki
34
+ cd my-wiki
35
+ knowflow ingest "LLM Wiki 把零散笔记整理成互联知识。" --source text
36
+ knowflow status
37
+ knowflow graph --no-open
38
+ ```
39
+
40
+ 这会创建一个独立项目、在 `raw/` 采集一条笔记,并根据初始 Wiki 生成图谱。**`ingest` 不会自动生成结构化 Wiki 页面。** 请先手动或通过 AI Agent / 自定义工作流整理原始素材,再重新生成图谱。
41
+
42
+ 不想全局安装也可以直接跑:`npx @jerryjiao/knowflow@latest <命令>`。
43
+
44
+ ## 工作流
45
+
46
+ ```text
47
+ URL 或笔记
48
+
49
+
50
+ raw/ Markdown ──► 你、AI Agent 或自定义工作流
51
+
52
+
53
+ 互联 Wiki 页面
54
+ │ │
55
+ ▼ ▼
56
+ 知识图谱 可选语义检索
57
+ ```
58
+
59
+ KnowFlow 的灵感来自 [Andrej Karpathy 的 LLM Wiki](https://karpathy.github.io/llm-wiki/):知识经过整理,成为持久、互联的页面,才会比一堆从未再打开的收藏更有价值。
60
+
61
+ ## 已包含的能力
62
+
63
+ - 将纯文本和支持的 URL 采集为原始 Markdown。
64
+ - 使用 JSON 配置和可编辑页面模板初始化可移植项目。
65
+ - 通过 `[[wikilinks]]` 组织来源、实体、概念和对比页面。
66
+ - 无需 API Key 即可生成 `graph.html` 和 `graph.json`。
67
+ - 检查断链、过小文件和孤立页面。
68
+ - 配置智谱 AI 嵌入后,查询已构建的向量索引。
69
+
70
+ ## 命令
71
+
72
+ | 命令 | 作用 |
73
+ | --- | --- |
74
+ | `knowflow init [directory]` | 创建独立项目,默认使用当前目录 |
75
+ | `knowflow ingest <url-or-text>` | 将 URL 或文本采集到 `raw/` |
76
+ | `knowflow graph [--no-open]` | 根据 Wiki 页面生成 `graph.html` 和 `graph.json` |
77
+ | `knowflow fix [--dry-run]` | 修复空链接、缺失页面、过小文件和孤儿页 |
78
+ | `knowflow health` | 检查断链、小文件和孤立页面 |
79
+ | `knowflow tags` | 根据 `[[tag/<名称>]]` 链接生成 `tag/<名称>.md` 聚合页 |
80
+ | `knowflow status` | 显示原始素材、Wiki、图谱、向量索引和 API Key 状态 |
81
+ | `knowflow query <text>` | 查询已有向量索引 |
82
+
83
+ KnowFlow 会从当前目录向上查找最近的 `.knowflowrc`,因此也可以在项目子目录中运行命令。
84
+
85
+ ## 从源码安装
86
+
87
+ ```bash
88
+ git clone https://github.com/jerryjiao/knowflow.git
89
+ cd knowflow
90
+ npm install
91
+ npm link
92
+ knowflow init ../my-wiki
93
+ ```
94
+
95
+ 再次运行 `init` 会保留已有配置、初始首页和已经自定义的模板。
96
+
97
+ ## 项目目录
98
+
99
+ ```text
100
+ my-wiki/
101
+ ├── .knowflowrc
102
+ ├── raw/ # 采集的原始素材
103
+ ├── wiki/
104
+ │ ├── index.md
105
+ │ ├── sources/
106
+ │ ├── entities/
107
+ │ ├── concepts/
108
+ │ └── comparisons/
109
+ ├── graph/ # 生成的 graph.html 和 graph.json
110
+ └── templates/ # 可编辑 Markdown 模板
111
+ ```
112
+
113
+ ## 配置
114
+
115
+ `knowflow init` 会创建 JSON 格式的 `.knowflowrc`,所有相对路径都以该文件所在目录为基准解析。
116
+
117
+ ```json
118
+ {
119
+ "wiki": {
120
+ "root": "./wiki",
121
+ "rawDir": "./raw"
122
+ },
123
+ "graph": {
124
+ "output": "./graph/graph.html"
125
+ },
126
+ "health": {
127
+ "minFileSize": 100,
128
+ "excludeOrphanDirs": ["sources/"]
129
+ }
130
+ }
131
+ ```
132
+
133
+ `health.excludeOrphanDirs` 列出预期不会被引用的目录(每日同步流水页、收件箱等),其中的页面不计入孤立页面。`knowflow tags` 每次都会全量重建 `wiki/tag/` 下的聚合页,新增带标签页面后重跑即可,幂等安全。
134
+
135
+ 图谱生成、健康检查、内容采集和状态查看均不需要 API Key。语义检索需要在项目环境变量或项目根目录 `.env` 中设置 `ZHIPUAI_API_KEY`:
136
+
137
+ ```bash
138
+ ZHIPUAI_API_KEY=your-key-here
139
+ ```
140
+
141
+ 当前 CLI 可以查询已有向量索引,但尚未提供独立的 `index` 命令。依赖搜索功能前,请先阅读[当前限制](#当前限制)。
142
+
143
+ ## 当前限制
144
+
145
+ - `ingest` 只采集原始素材;将其提炼为结构化 Wiki 是独立的人工或 Agent 步骤。
146
+ - URL 采集依赖 Jina Reader;YouTube 和部分需要登录的平台可能还需要 `yt-dlp` 或带登录态的浏览器工作流。
147
+ - `query` 需要预先构建的向量索引和[智谱 AI API Key](https://open.bigmodel.cn/)。在加入 `index` 命令前,高级用户可运行 `node <knowflow-install>/scripts/vector-store.mjs build`。
148
+ - `bookmark_sync.sh` 依赖可选的第三方 `ft` 命令。
149
+ - 生成的图谱 HTML 打开时会从 CDN 加载 vis-network。
150
+
151
+ ## 路线图
152
+
153
+ - [x] 独立项目初始化和可移植路径
154
+ - [x] URL / 文本原始采集、Wiki 健康检查和交互式图谱
155
+ - [x] CLI 自动化测试与多 Node.js 版本 CI
156
+ - [ ] 从原始素材到已审核 Wiki 页面的一等 Agent 工作流
157
+ - [ ] 增量采集和重复来源检测
158
+ - [ ] `knowflow index` 与可插拔嵌入提供商
159
+ - [ ] 提取器 / 插件系统和本地 Web UI
160
+
161
+ 欢迎提交想法和范围清晰的 PR。你可以先阅读[贡献指南](CONTRIBUTING.md)、运行[从文本到图谱的示例](examples/quickstart.md),或在 [GitHub Issues](https://github.com/jerryjiao/knowflow/issues) 中提出使用场景。
162
+
163
+ ## 开发
164
+
165
+ ```bash
166
+ npm install
167
+ npm run check
168
+ npm test
169
+ npm pack --dry-run
170
+ ```
171
+
172
+ 版本变化见[更新日志](CHANGELOG.md),漏洞披露方式见[安全策略](SECURITY.md)。
173
+
174
+ ## 许可证
175
+
176
+ [MIT](LICENSE) © [Jerry Jiao](https://github.com/jerryjiao)
package/SECURITY.md ADDED
@@ -0,0 +1,18 @@
1
+ # Security Policy
2
+
3
+ ## Supported versions
4
+
5
+ Security fixes are applied to the latest released minor version.
6
+
7
+ | Version | Supported |
8
+ | --- | --- |
9
+ | 0.2.x | Yes |
10
+ | < 0.2 | No |
11
+
12
+ ## Reporting a vulnerability
13
+
14
+ Please do not open a public issue for a suspected vulnerability.
15
+
16
+ Use GitHub's **Report a vulnerability** flow in the repository's [Security tab](https://github.com/jerryjiao/knowflow/security/advisories/new). Include the affected command or script, reproduction steps, impact, and any suggested mitigation. Remove API keys, private captured content, and other secrets from the report.
17
+
18
+ You should receive an acknowledgement within seven days. We will validate the report, coordinate a fix and disclosure timeline, and credit you if requested.