@nudojs/core 1.0.0 → 1.1.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/README.md CHANGED
@@ -1,18 +1,22 @@
1
1
  # @nudojs/core
2
2
 
3
- Core type value primitives and type system for the [Nudo](https://github.com/nudojs/nudo) inference engine.
3
+ > **欢迎重回 JS 世界.** — Nudo 不限制你的 JS 表达,只忠实反映中间量与结果,并提供比类型更精确的契约校验。
4
+ > Welcome back to JavaScript. Your JS stays JS — observe intermediates, enforce contracts sharper than types.
5
+
6
+ Core Abs type system for the [Nudo](https://github.com/nudojs/nudo) analysis engine.
4
7
 
5
8
  ## What is Nudo?
6
9
 
7
- Nudo is a type inference engine for JavaScript. Instead of a separate type system, it runs your code with symbolic type values via abstract interpretation — no TypeScript, no build step.
10
+ Nudo does not restrict how you write JavaScript. It executes code on Abs (`shape × term × pred × conf`) so you can faithfully observe intermediate values and results, and validate them with contracts sharper than ordinary TypeScript types.
8
11
 
9
12
  ## This package
10
13
 
11
14
  `@nudojs/core` provides the foundational type representations and operations:
12
15
 
13
- - **Type values** — `TypeValue`, `LiteralValue`, `Refinement`, and the `T` namespace of built-in types
14
- - **Type operations** — union simplification, subtype checking, narrowing, widening
15
- - **Operators & dispatch** — binary ops, property access, method calls on type values
16
+ - **Abs** — `shape × term × pred × conf`; constraints participate in algebra
17
+ - **Type operations** — union simplification, assignability (`leqAbs`), check/gate
18
+ - **Operators & dispatch** — binary ops, property access, method calls on Abs
19
+ - **Rendering** — `formatShape` / `formatAbs`, one-way projections (`absToTSType`, zod)
16
20
  - **Environment** — scoped variable bindings for the abstract interpreter
17
21
 
18
22
  ## Install