@vasm/cli 0.5.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/LICENSE +21 -0
- package/README.md +39 -0
- package/dist/index.js +472 -0
- package/package.json +63 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Glen Li
|
|
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,39 @@
|
|
|
1
|
+
# VASMC
|
|
2
|
+
|
|
3
|
+
去中心化的 LLM Prompt 编译器 — 模块化导入、交叉编译、AI 原生的 Agent 编排。
|
|
4
|
+
|
|
5
|
+
在大语言模型时代,Markdown 已经演变为**源代码** — System Prompt、技能包、指令集全部用 Markdown 编写。VASMC 将它们视为一等编译目标:解析 `@import` 依赖、跨语种交叉编译,并编排 AI 编辑器处理那些属于智能而非工具的语义任务。
|
|
6
|
+
|
|
7
|
+
👉 [阅读完整的设计规范](DESIGN.md)
|
|
8
|
+
|
|
9
|
+
### 📦 核心特性
|
|
10
|
+
|
|
11
|
+
* **去中心化包管理**: 直接通过 URL 拉取 Markdown 模块 — 无注册表,无中间人。
|
|
12
|
+
* **确定性构建**: SHA-256 锁文件 (`vasmc-lock.yaml`) 确保构建可复现。
|
|
13
|
+
* **交叉编译**: AST 级语言块过滤 (`<!-- lang:xx -->`) 生成各语种产物;未覆盖语种可自动唤起 LLM 交叉编译回译。
|
|
14
|
+
* **双模式引入**:
|
|
15
|
+
* `@import:link` — 别名重写为本地相对路径(保留超链接结构)。
|
|
16
|
+
* `@import:inline` — 内联展开远程内容(组装大型 Prompt 上下文)。
|
|
17
|
+
|
|
18
|
+
### 🛠️ CLI 命令架构 (v3.0)
|
|
19
|
+
|
|
20
|
+
| 命令 | 分类 | 说明 |
|
|
21
|
+
|------|------|------|
|
|
22
|
+
| `vasmc build` | 确定性工具 | 纯编译器 — AST 组装 + 交叉编译 |
|
|
23
|
+
| `vasmc agent` | Agent 工具 | 零 LLM 编译 + 生成 AI 编辑器编排指令 |
|
|
24
|
+
| `vasmc lint` | LLM 增强工具 | 对编译产物进行语义冲突检测 |
|
|
25
|
+
| `vasmc diff` | LLM 增强工具 | 版本间语义差异分析 |
|
|
26
|
+
| `vasmc graph` | 确定性工具 | ASCII 依赖图谱可视化 |
|
|
27
|
+
| `vasmc seal` | 确定性工具 | 为普通 Markdown 注入 Frontmatter |
|
|
28
|
+
| `vasmc sync` | 确定性工具 | 安装并锁定所有依赖 |
|
|
29
|
+
|
|
30
|
+
### 🚀 快速上手
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
npm install -g @vasm/cli
|
|
34
|
+
vasmc init # 生成 vasmc-build.yaml
|
|
35
|
+
vasmc add https://example.com/skill.md --alias my-skill
|
|
36
|
+
vasmc build # 编译工作区
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
完整 CLI 用法请参阅 **[帮助与用法文档](HELP.md)**。
|