|
| 1 | +# MeTTa TS 1.3.0 |
| 2 | + |
| 3 | +MeTTa TS 1.3.0 moves the standard libraries and the debugger engine out of the |
| 4 | +core into their own packages. The interpreter behaves exactly as in 1.2.0: the |
| 5 | +conformance oracle is byte-identical and every library returns the same results. |
| 6 | +This is a structural release, so there are no new language features. |
| 7 | + |
| 8 | +## `@metta-ts/libraries` |
| 9 | + |
| 10 | +The eight standard libraries (`vector`, `roman`, `combinatorics`, `patrick`, |
| 11 | +`datastructures`, `spaces`, `nars`, `pln`) moved out of `@metta-ts/core` into a |
| 12 | +new `@metta-ts/libraries` package, one folder and one `.metta` file per library, |
| 13 | +so the engine no longer ships library source it does not run. |
| 14 | + |
| 15 | +`@metta-ts/node`, `@metta-ts/hyperon`, and `@metta-ts/browser` depend on the new |
| 16 | +package and register it when they load, so `(import! &self pln)` and the other |
| 17 | +library imports keep working with no change. The one behavior change is that bare |
| 18 | +`@metta-ts/core` no longer resolves the libraries on its own. A program run |
| 19 | +through `runProgram` from core alone registers them first: |
| 20 | + |
| 21 | +```ts |
| 22 | +import { registerLibraries } from "@metta-ts/libraries"; |
| 23 | +registerLibraries(); |
| 24 | +``` |
| 25 | + |
| 26 | +The libraries are ports of Patrick Hammer's PeTTa `lib/lib_*.metta` set, with |
| 27 | +`roman` from Roman Treutlein's PeTTa prelude; the extraction now credits them. |
| 28 | + |
| 29 | +## `@metta-ts/debug` |
| 30 | + |
| 31 | +The `metta-debug` engine moved into a new `@metta-ts/debug` package. It holds the |
| 32 | +execution-trace summary behind `why` and the `explainCall`, `collectTrace`, and |
| 33 | +`summarize` helpers, depends only on `@metta-ts/core`, and uses no Node APIs, so |
| 34 | +an editor or tool can drive it directly. The `metta-debug` command still ships in |
| 35 | +`@metta-ts/node` and works exactly as before, now a thin wrapper over the shared |
| 36 | +engine. |
| 37 | + |
| 38 | +## Verification |
| 39 | + |
| 40 | +Checked on Linux with Node and pnpm. |
| 41 | + |
| 42 | +- Build, type check, lint, and format checks pass across all twelve packages. |
| 43 | +- `pnpm test` passes: 1,218 tests across 126 files, with 38 optional live |
| 44 | + integration tests (7 files) skipped. |
| 45 | +- The oracle passes all 23 corpus files, byte-identical to 1.2.0: the extraction |
| 46 | + moves the library source without changing it. |
| 47 | +- The repository is REUSE 3.3 compliant. |
| 48 | + |
| 49 | +## Packages |
| 50 | + |
| 51 | +All public packages use version `1.3.0`: |
| 52 | + |
| 53 | +```bash |
| 54 | +npm install @metta-ts/core@1.3.0 |
| 55 | +npm install -g @metta-ts/node@1.3.0 |
| 56 | +``` |
| 57 | + |
| 58 | +The standard libraries and the debugger engine are available on their own: |
| 59 | + |
| 60 | +```bash |
| 61 | +npm install @metta-ts/libraries@1.3.0 |
| 62 | +npm install @metta-ts/debug@1.3.0 |
| 63 | +``` |
| 64 | + |
1 | 65 | # MeTTa TS 1.2.0 |
2 | 66 |
|
3 | 67 | MeTTa TS 1.2.0 adds eight importable standard libraries and makes the core list |
|
0 commit comments