This release is a pre-release and may not be stable for production use.
Dairn
Dairn 是供 AI Agent 调用的开发治理内核,提供项目初始化、确定性检查、工作流状态、影响分析和证据验证。治理逻辑运行于自带的 Cosmopolitan QuickJS APE;Dairn 不调用模型。
安装
npm 包名是 @moorefu/dairn(unscoped dairn 被 npm 以“与既有包过于相似”为由拒绝),PyPI 分发名与模块名是 dairn;包内自带 APE 和校验信息,安装时无需另外下载运行时。CLI 命令名是 dairn。版本由发布标签决定:正式版进入默认通道,预发布进入 npm 的 next dist-tag 与 PyPI 的预发布通道。
| 渠道 | 安装方式 | 环境 |
|---|---|---|
| npm(npmjs.com) | npm install @moorefu/dairn;预发布 npm install @moorefu/dairn@next |
Node.js 18+、npm |
| PyPI(pypi.org) | python -m pip install dairn;预发布 python -m pip install --pre dairn |
Python 3.10+ |
| 离线 tgz(dairn-latest.tgz) | npm install --offline --ignore-scripts ./dairn-latest.tgz |
Node.js 18+、npm |
| 离线 Wheel(安装索引 wheels.html) | python -m pip install --upgrade --pre --no-index --find-links ./wheels.html dairn |
Python 3.10+ |
| 离线 ZIP(dairn-latest.zip) | 解压后使用 dairn.cmd 或 sh dairn.sh |
自带 QuickJS 运行时 |
如果默认通道还没有正式版(例如当前只有预发布版本),上面的 npm install @moorefu/dairn / pip install dairn 会找不到可安装版本,请改用 @next / --pre;也可以固定到具体版本:npm install @moorefu/dairn@<版本>、python -m pip install dairn==<PEP 440 版本>。
npm 本地安装后用 npx dairn 调用,全局安装(npm install -g @moorefu/dairn)后可直接 dairn。latest 是离线下载入口,包内保留真实版本;Wheel 按规范保留版本文件名,下载索引后 pip 会获取其中指定的 Wheel 并校验 SHA256;需要固定版本时使用 历史 Release。
使用
dairn version
dairn init --root "示例 项目" --name demo --stack go --sample
dairn validate --root "示例 项目"
dairn check --root "示例 项目" --all
项目检查需要项目自己的工具链;Go -race 需要 CGO 和 C 编译器。Windows 支持中文和空格路径,拒绝目录联接与符号链接;批处理门禁需显式配置 cmd.exe。POSIX 首次启动 APE 使用系统基础命令初始化加载器,macOS ARM64 还需 Xcode Command Line Tools 的 cc。
构建与维护
python tools/build.py
npm run build
两个入口先按根目录 quickjs.lock.json 获取并校验 moorefu/quickjs-cosmo 的现成 QuickJS,再自举生成 Wheel + ZIP 或 npm + ZIP。生成的运行时位于 runtime/,.com 作为构建产物管理。Windows 的 build.cmd 或 POSIX 的 sh build.sh 通过 QuickJS 自举 ZIP。ZIP 只含启动器、runtime/ 与许可证。Python 包源码位于 src/dairn/,根目录 pyproject.toml 提供标准构建入口。
发布由 v<版本> 标签触发:标签版本会写入三类制品,矩阵验证通过后先发布 GitHub Release,再通过手动工作流把同一套已验证字节发布到 npm 与 PyPI。下载环境、六种平台的制品矩阵和注册表发布步骤见 构建指南;模板、工作流和受保护 CI 见 治理指南。
仓库自身的文档集中在这三处。quickjs/assets/ 下的 Markdown 是分发给目标项目的规则与技能资源。项目目前为 UNLICENSED,第三方声明位于 licenses/。
Metadata
Release files for dairn 0.1.0rc4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| dairn-0.1.0rc4-py3-none-any.whl | Python 3 | none | any | Details |
Release files / dairn-0.1.0rc4-py3-none-any.whl
| Download URL | dairn-0.1.0rc4-py3-none-any.whl |
|---|---|
| Size | 1.7 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
89bd4a98812d4d017c24364a36aa817101216540f853f90d468619e649ee7e12
|
|
BLAKE2b-256 checksum How to use checksums |
a2b432290712ddb2ae55eee4621d6d3c3066250a2ba66e90e5621d8414d0e956
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Security for dairn 0.1.0rc4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.