@balena/sbvr-parser

中文文档
1.4.43发布于 2026/11/07BSDTypeScriptCommonJS构建来源已验证近 30 天下载 1.8万

SBVR to LF parser.

原始使用文档
文档目录3 节
  1. sbvr-parser
  2. Example usage
  3. Tests

sbvr-parser

An SBVR Structured Englished to SBVR Logical Formulation parser.

The SBVR documentation can be found here http://www.omg.org/spec/SBVR/

Example usage

const SBVRParser = require('./sbvr-parser.js').SBVRParser.createInstance()
const rule = 'Term: name'
const LF = SBVRParser.matchAll(rule, 'Process')

console.log(LF)

outputs:

[ 'Model',
  [ 'Vocabulary', 'Default', [ 'Attributes' ] ],
  [ 'Term', 'name', 'Default', [ 'Attributes' ] ] ]

Tests

Tests can be found under the test/ folder, to run the whole suite use npm test

版本与发布记录

@balena/sbvr-parser 共发布 147 个版本,首次发布于 2020/05/09;过去 12 个月发布了 75 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
1.4.43latest2026/11/07今天
1.4.43-build-renovate-chai-6-x-cc5bc82a662b660f6cdceffa2f28242c4305f263-12026/11/07今天
1.4.422026/11/07今天
1.4.42-build-renovate-chai-6-x-f2ba30428baf2accf320c9a22a04827eb45a1873-12026/11/07今天
1.4.42-build-renovate-pin-dependencies-412f838db77b08b8506b1a9951ed3732ed4e26a4-12026/11/07今天
1.4.412026/11/034 天前

其他发布通道:build-joshbwlng-chai → 1.4.7-build-joshbwlng-chai-84c5e0761fd4fec6bd2f9b2dac27dbca958bcd32-1,build-renovate-major-9--balenasbvr-types → 1.4.8-build-renovate-major-9--balenasbvr-types-4adc65de4803853bcabc2f58c29dceca1db7b19c-1,build-renovate-major-11-mocha → 1.4.9-build-renovate-major-11-mocha-2942f2c5888f58699908bd29cd484dd7df0c3b9e-1,build-single-definition → 1.4.10-build-single-definition-ed36e9f54a6e99347010a88e27c877f136ddfe4a-1,build-renovate-major-10--balenasbvr-types → 1.4.11-build-renovate-major-10--balenasbvr-types-550aa8f3885357550e9a1cdc3668f71c22f17540-1,build-renovate-major-11--balenasbvr-types → 1.4.12-build-renovate-major-11--balenasbvr-types-c4efe5a3ea98ba824a0fce85ed48ef298fd94d1c-1。

关于 @balena/sbvr-parser 的常见问题

@balena/sbvr-parser 是什么?

SBVR to LF parser.

如何安装 @balena/sbvr-parser?

在项目目录运行 npm install @balena/sbvr-parser,或使用 pnpm add / yarn add / bun add。

@balena/sbvr-parser 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@balena/sbvr-parser 支持 ESM 还是 CommonJS?

以 CommonJS 形式发布,可以直接 require();在 ES Module 项目中也可以用 import 引入(Node.js 会把 module.exports 作为默认导出)。

@balena/sbvr-parser 可以商用吗?

@balena/sbvr-parser 使用 BSD 许可。声明的许可为 BSD,请阅读许可原文确认使用条件。以上为概括,不构成法律意见,请以许可原文为准。

@balena/sbvr-parser 的下载量有多少?

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

@balena/sbvr-parser 还在维护吗?

最新版本 1.4.43 发布于 2026/11/07(今天);至今共发布 147 个版本,其中过去 12 个月发布了 75 个;首次发布于 2020/05/09。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。