[package] name = "babel_nar" version = "0.26.3" edition = "2021" description = """ Implementation and application supports of the NAVM model """ readme = "README.md" # ! ⚠️↓crates.io的每个关键词长度不能超过20字符 keywords = ["NARS", "Non-Axiomatic-Logic", "NAVM"] license = "MIT OR Apache-2.0" categories = [ "parser-implementations", # 解析器实现 | 各CIN方言 "development-tools", # 开发工具 "command-line-utilities", # CLI应用 ] # 🔗 repository = "https://github.com/ARCJ137442/BabelNAR.rs" # Cargo文档参考: ## 必要的依赖 ## [dependencies] # 用于错误处理 thiserror = "1.0.63" anyhow = "1.0.88" [dependencies.nar_dev_utils] # 【2024-03-13 21:17:55】实用库现在独立为`nar_dev_utils` version = "0.42" # * ✅现已发布至`crates.io` # *🚩【2024-03-21 09:26:38】启用所有 # path = "../NAR-dev-util" # git = "https://github.com/ARCJ137442/NAR-dev-util" # ! 【2024-03-23 19:19:01】似乎Rust-Analyzer无法获取私有仓库数据 features = [ "bundled" ] # 启用所有特性 [dependencies.narsese] # ! 本地依赖可以不添加版本 # 载入Narsese API,引入其中所有部分 version = "0.21" # * ✅现已发布至`crates.io` # path = "../Narsese.rs" # git = "https://github.com/ARCJ137442/Narsese.rs" # ! 【2024-03-23 19:19:01】似乎Rust-Analyzer无法获取私有仓库数据 features = [ # * 🚩【2024-03-29 09:52:56】在「方言词法折叠」中,需要使用其中的常量 "enum_narsese", # * 📌承继NAVM "lexical_narsese", ] [dependencies.navm] # ! 本地依赖可以不添加版本 # 载入NAVM API,引入「非公理虚拟机」模型 # path = "../NAVM.rs" version = "0.17" # 现已发布于`crates.io` # git = "https://github.com/ARCJ137442/NAVM.rs" # ! 【2024-03-23 19:19:01】似乎Rust-Analyzer无法获取私有仓库数据 features = [] # ! 【2024-03-21 09:24:51】暂时没有特性 ## 依赖特性的可选依赖 ## # Rust版本的正则表达式 # * 🎯用于解析提取NARS输出 # * 📄OpenNARS、ONA、PyNARS [dependencies.regex] version = "1.10.6" optional = true # 用于实现「静态含闭包常量」 # * 🎯初次引入:NARS-Python 方言格式 # * 🔗:https://stackoverflow.com/questions/73260997/rust-boxed-closure-in-global-variable [dependencies.lazy_static] version = "1.4.0" optional = true # Rust版本的PEG解析器 # * 🎯用于对接一些NARS方言的解析 # * 📄OpenNARS(操作语法)、ONA(中缀语法) [dependencies.pest] version = "2.7.12" optional = true # Rust版本的PEG解析器(派生宏) [dependencies.pest_derive] version = "2.7.12" optional = true # 命令行支持/JSON「原生」转译器解析 # [dependencies.serde] # version = "1.0.210" # features = ["derive"] [dependencies.serde_json] version = "1.0.128" ### 定义库的特性 ### [features] ## 默认启用的特性 ## default = [ "bundled" ] # * 默认启用所有(可选禁用) ## 大杂烩 ## bundled = [ "cin_implements", # 各大CIN的NAVM实现 "test_tools", # 测试工具集 ] ## 各个独立的特性 ## # 测试工具集 # test_tools = [ # 统一`.nal`格式 "pest", "pest_derive", ] # 具体接口实现(虚拟机启动器) # # * 📌若支持「NAVM指令-NAVM输出JSON」语法,则直接使用「原生转译器」而无需在此定义 # ✅OpenNARS # ✅ONA # ✅PyNARS # ✅NARS-Python(不稳定) # ✅OpenJunars(不稳定) cin_implements = [ "opennars", "ona", "pynars", "nars_python", "openjunars", ] # ✅OpenNARS接口 opennars = [ "regex", "pest", "pest_derive", ] # ✅ONA接口 ona = [ "regex", "pest", "pest_derive", ] # ✅PyNARS接口 pynars = [ "regex", # "pest", # ! 【2024-03-27 20:52:17】无需特别解析方言:其输出即为CommonNarsese ] # ✅NARS-Python接口(不稳定) nars_python = [ "lazy_static", # 这个「词法Narsese」也在用 ] # ✅OpenJunars接口(不稳定) openjunars = [] ## 配置编译检查 ## # 有关Clippy的参考: # * 🔗 [lints.clippy] # 📌【2024-08-25 00:31:01】允许文档注释中出现以下情况 # ```markdown # * 📝这是一个笔记 # ? 💭这是一个问题 # * 📍这是问题下的一个小点 # ``` doc_lazy_continuation = "allow"