@algorisys/tinyfly 0.116.0 → 0.117.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.
@@ -0,0 +1,58 @@
1
+ import { type RandomSource } from '../../engine/authoring/random';
2
+ /**
3
+ * Probability distributions as plain data, `{ kind, …parameters }`, with
4
+ * their density (or mass), mean, spread and a seeded sampler. Discrete ones
5
+ * take whole-number values. Pure: samples come from a seed, never from
6
+ * Math.random, so a histogram fills the same way every time it plays.
7
+ */
8
+ export type Distribution = {
9
+ kind: 'normal';
10
+ mean?: number;
11
+ sd?: number;
12
+ } | {
13
+ kind: 'uniform';
14
+ min?: number;
15
+ max?: number;
16
+ } | {
17
+ kind: 'exponential';
18
+ rate?: number;
19
+ } | {
20
+ kind: 'binomial';
21
+ n: number;
22
+ p: number;
23
+ } | {
24
+ kind: 'poisson';
25
+ rate: number;
26
+ }
27
+ /** The number of heads in `count` fair coin tosses is binomial; this is the total of `count` fair dice */
28
+ | {
29
+ kind: 'dice';
30
+ count?: number;
31
+ sides?: number;
32
+ }
33
+ /** The mean of `count` draws of another distribution: the central limit theorem's subject */
34
+ | {
35
+ kind: 'mean';
36
+ of: Distribution;
37
+ count: number;
38
+ };
39
+ export type DistributionKind = Distribution['kind'];
40
+ export declare const DISTRIBUTION_KINDS: readonly DistributionKind[];
41
+ /** The whole numbers a discrete distribution can take, [low, high] (high may be Infinity). */
42
+ export declare function supportOf(d: Distribution): [number, number];
43
+ /** True for distributions on whole numbers (drawn as bars, not a curve). */
44
+ export declare function isDiscrete(d: Distribution): boolean;
45
+ /** The density (continuous) or probability mass (discrete) at x. */
46
+ export declare function density(d: Distribution, x: number): number;
47
+ export declare function meanOf(d: Distribution): number;
48
+ export declare function sdOf(d: Distribution): number;
49
+ /** One draw. */
50
+ export declare function sample(d: Distribution, source: RandomSource): number;
51
+ /**
52
+ * The first `count` draws from `d` with `seed`. Asking for more continues
53
+ * the same sequence, so a histogram that grows from 10 to 1000 samples keeps
54
+ * its first 10. Cached by distribution and seed.
55
+ */
56
+ export declare function samples(d: Distribution, seed: number | string, count: number): number[];
57
+ /** Checks a distribution's parameters; returns a message, or undefined when it is fine. */
58
+ export declare function distributionProblem(d: Distribution): string | undefined;
@@ -0,0 +1,18 @@
1
+ /**
2
+ * A Galton board's balls: each bounces left or right at each row of pegs, by
3
+ * its own seeded coin flips, and lands in the bin numbered by its rights.
4
+ * Pure geometry in "peg units": row i of pegs sits at depth i, its pegs at
5
+ * x = j − i / 2 (j = 0..i); bin b sits at x = b − rows / 2.
6
+ */
7
+ export declare function ballPath(seed: number | string, ball: number, rows: number): boolean[];
8
+ /** The bin a ball lands in: how many times it went right. */
9
+ export declare const binOf: (path: boolean[]) => number;
10
+ /**
11
+ * Where a ball is, part way down (`progress` 0 at the top peg, 1 when it
12
+ * reaches the bins), in peg units: x across, depth down. Between rows it
13
+ * hops in a small arc, as balls on a real board do.
14
+ */
15
+ export declare function ballAt(path: boolean[], progress: number): {
16
+ x: number;
17
+ depth: number;
18
+ };
@@ -0,0 +1,20 @@
1
+ import { type Distribution } from './distributions';
2
+ export interface Bin {
3
+ left: number;
4
+ right: number;
5
+ count: number;
6
+ /** count, or count / (total × width) when scaled as a density */
7
+ height: number;
8
+ }
9
+ /**
10
+ * The default bins for a distribution: one per whole number for discrete
11
+ * ones (centred on it), else 30 across mean ± 4 sd.
12
+ */
13
+ export declare function defaultBins(d: Distribution): [number, number, number];
14
+ /** Samples counted into `bins`; heights as counts or as a density (total area 1). */
15
+ export declare function binSamples(values: number[], [from, to, count]: [number, number, number], scale: 'density' | 'count'): Bin[];
16
+ /** Sample mean and standard deviation (0 and 0 for no samples). */
17
+ export declare function summary(values: number[]): {
18
+ mean: number;
19
+ sd: number;
20
+ };
@@ -0,0 +1,24 @@
1
+ import type { Vec2 } from '../linear/vec2';
2
+ export type PointsSpec = {
3
+ kind: 'uniform';
4
+ x: [number, number];
5
+ y: [number, number];
6
+ } | {
7
+ kind: 'linear';
8
+ slope: number;
9
+ intercept: number;
10
+ noise: number;
11
+ x: [number, number];
12
+ };
13
+ /**
14
+ * `count` random points from a seed. Each point draws the same random numbers
15
+ * whatever the parameters, so moving the slope or the noise moves every
16
+ * point smoothly instead of reshuffling them.
17
+ */
18
+ export declare function scatterPoints(spec: PointsSpec, seed: number | string, count: number): Vec2[];
19
+ /** The least-squares line through points, and the correlation r. Undefined for fewer than two distinct x. */
20
+ export declare function leastSquares(points: Vec2[]): {
21
+ slope: number;
22
+ intercept: number;
23
+ r: number;
24
+ } | undefined;
package/llms-full.txt CHANGED
@@ -591,7 +591,7 @@ with a GSAP-style call (durations are in seconds here):
591
591
  ```html
592
592
  <div class="box" style="width:60px;height:60px;background:#4a9eff"></div>
593
593
 
594
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly.iife.js"></script>
594
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly.iife.js"></script>
595
595
  <script>
596
596
  tinyfly.to('.box', { x: 200, duration: 1 })
597
597
  </script>
@@ -799,7 +799,7 @@ Without a build step, the all-in-one bundle exposes the same functions on a
799
799
  global — `tinyfly.to()`, `tinyfly.timeline()` and so on:
800
800
 
801
801
  ```html
802
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly.iife.js"></script>
802
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly.iife.js"></script>
803
803
  <script>
804
804
  tinyfly.to('.box', { x: 200, duration: 1 })
805
805
  </script>
@@ -2714,7 +2714,7 @@ For simple website embedding without a build system.
2714
2714
  </html>
2715
2715
  ```
2716
2716
 
2717
- Build the player with `npm run build:player` to generate `lib/player/tinyfly-player.iife.js`, or load it from the CDN: `https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly-player.iife.js`.
2717
+ Build the player with `npm run build:player` to generate `lib/player/tinyfly-player.iife.js`, or load it from the CDN: `https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly-player.iife.js`.
2718
2718
 
2719
2719
  ---
2720
2720
 
@@ -7068,7 +7068,7 @@ The dialog shows the generated HTML/JavaScript code with a **Copy Code** button.
7068
7068
  **Steps to embed:**
7069
7069
  1. Build the player: `npm run build:player`
7070
7070
  2. Copy `lib/player/tinyfly-player.iife.js` to your project (or load
7071
- `https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly-player.iife.js`
7071
+ `https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly-player.iife.js`
7072
7072
  instead; see [Deployment](DEPLOYMENT.md))
7073
7073
  3. Copy the generated code into your HTML
7074
7074
  4. Adjust the script `src` path if needed
@@ -8493,7 +8493,9 @@ or `scale`: those belong to the figure's target. The same figure plays in a
8493
8493
  lesson page (`<figure data-tinyfly-math>`), an explorable and a video
8494
8494
  (`mathTarget`). Calculus items (`tangent`, `riemann`, `area`, `taylor`, a
8495
8495
  `point` with `on` and `x`) take numbers or number-value names for `at`, `n`,
8496
- `to`, `order`, and publish `\\val{ID.slope}`, `ID.sum`, `ID.value` for TeX. See `docs/math.md`.
8496
+ `to`, `order`, and publish `\\val{ID.slope}`, `ID.sum`, `ID.value` for TeX. Probability items
8497
+ (`histogram`, `distribution`, `galton`, `scatter`, `bayes`) take a distribution as data
8498
+ (`{ kind: 'normal', mean: 'mu', sd: 1 }`) and draw seeded samples, never `Math.random`. See `docs/math.md`.
8497
8499
 
8498
8500
  ## Your own behaviours
8499
8501
 
@@ -8680,7 +8682,7 @@ path for all of that:
8680
8682
  </figure>
8681
8683
 
8682
8684
  <!-- once, anywhere on the page (a site-wide footer is fine) -->
8683
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly-embed.iife.js" data-tinyfly-auto></script>
8685
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly-embed.iife.js" data-tinyfly-auto></script>
8684
8686
  ```
8685
8687
 
8686
8688
  Every `[data-tinyfly-embed]` mounts when the page is ready, with no per-post
@@ -9086,6 +9088,12 @@ Some names are reserved, because a track on them would move the whole figure:
9086
9088
  | `area` | `expr`, `from`, `to`, `lower?` (another function), `negativeColor?`, `fillOpacity?` |
9087
9089
  | `taylor` | `expr`, `at`, `order` (0–20; a fractional order grows the next term in), `domain?` |
9088
9090
 
9091
+ | `histogram` | `distribution`, `count` (samples so far), `bins?: [from, to, n]`, `scale?: 'density' \| 'count'`, `curve?`, `seed?` |
9092
+ | `distribution` | `distribution`, `shade?: [a, b]` (P(a ≤ X ≤ b)), `domain?` |
9093
+ | `galton` | `rows?`, `balls` (fractional: the next ball on its way), `spacing?`, `top?`, `seed?` |
9094
+ | `scatter` | `points: { kind: 'uniform', x, y }` or `{ kind: 'linear', slope, intercept, noise, x }`, `count`, `inside?` (an expression in x and y, true when ≤ 0), `fit?`, `seed?` |
9095
+ | `bayes` | `prior`, `truePositive`, `falsePositive`, `at?`, `size?`, `labels?` |
9096
+
9089
9097
  `point` also rides a curve: `{ on: 'sin(x)', x: 'p' }` is the point (p, sin p), and
9090
9098
  `hollow: true` draws an open circle for a hole or a limit. `function` takes
9091
9099
  `derivative: n` to plot f′, f″ … and `dashed: true`.
@@ -9105,6 +9113,25 @@ Items work out numbers that TeX can show with `\val{…}`:
9105
9113
  | `area` | `ID.value` (the signed integral) |
9106
9114
  | `point` on a curve | `ID.x`, `ID.y` |
9107
9115
  | `taylor` | `ID.order`, `ID.degree` (its whole part) |
9116
+ | `histogram` | `ID.count`, `ID.mean`, `ID.sd` (of the samples so far) |
9117
+ | `distribution` | `ID.p` (the shaded probability), `ID.mean`, `ID.sd` |
9118
+ | `galton` | `ID.landed` |
9119
+ | `scatter` | `ID.count`, `ID.inside`, `ID.ratio`, `ID.slope`, `ID.intercept`, `ID.r` |
9120
+ | `bayes` | `ID.prior`, `ID.posterior`, `ID.positive`, `ID.truePositive`, `ID.falsePositive` |
9121
+
9122
+ ### Distributions and randomness
9123
+
9124
+ A distribution is data: `{ kind: 'normal', mean, sd }`, `uniform` (`min`,
9125
+ `max`), `exponential` (`rate`), `binomial` (`n`, `p`), `poisson` (`rate`),
9126
+ `dice` (`count`, `sides`), or `{ kind: 'mean', of, count }`, the average of
9127
+ `count` draws (what the central limit theorem is about). Any of its numbers
9128
+ may be a value name, so a slider moves the mean or n. `density`, `meanOf`,
9129
+ `sdOf`, `sample` and `samples` work on them directly.
9130
+
9131
+ Every sample comes from a seed (the item id unless `seed` is given), through
9132
+ the engine's `createRandom`, `randomNormal` and `shuffled`. A histogram that
9133
+ grows from 10 to 1000 samples keeps its first 10, and every render, video and
9134
+ reader sees the same draws.
9108
9135
 
9109
9136
  Slopes, derivative plots and Taylor coefficients come from symbolic
9110
9137
  differentiation of the expression (`differentiate`, `compileDerivative`), so
@@ -9170,7 +9197,7 @@ lesson's step options (`duration`, `easing`, `delay`).
9170
9197
  <figcaption>The determinant is the area of the unit square after the map.</figcaption>
9171
9198
  </figure>
9172
9199
 
9173
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly-math.iife.js" data-tinyfly-auto></script>
9200
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly-math.iife.js" data-tinyfly-auto></script>
9174
9201
  ```
9175
9202
 
9176
9203
  The figure draws itself into an SVG and redraws from the timeline whenever the
@@ -9269,6 +9296,13 @@ their own.
9269
9296
  | `areaFigure({ expr, from, to })` | The area up to `b`, its value shown |
9270
9297
  | `taylorFigure({ expr, at, order })` | Taylor polynomials of degree `order` |
9271
9298
  | `limitFigure({ expr, at, limit })` | A point `p` sliding toward a hole |
9299
+ | `normalFigure({ mean, sd, shade })` | The normal curve with P(a ≤ X ≤ b) shaded (`mu`, `sigma`, `a`, `b`) |
9300
+ | `binomialFigure({ n, p })` | Binomial bars |
9301
+ | `cltFigure({ of, k, samples })` | Means of `k` draws piling into a normal curve |
9302
+ | `galtonFigure({ rows, balls })` | A Galton board |
9303
+ | `monteCarloPiFigure({ count })` | Points in a square; the share inside the circle ≈ π/4 |
9304
+ | `regressionFigure({ slope, intercept, noise, count })` | Noisy points and the least-squares line |
9305
+ | `bayesFigure({ prior, sensitivity, falsePositive })` | A medical test as areas: P(condition given a positive) |
9272
9306
 
9273
9307
  Each returns a plain figure to change or extend. In each, `M` starts at the
9274
9308
  identity unless `matrix` is given.
@@ -9276,15 +9310,16 @@ identity unless `matrix` is given.
9276
9310
  ## Examples
9277
9311
 
9278
9312
  - Gallery: **Linear Map**, **Eigenvectors**, **Equation Steps**, **Matrix Lesson**,
9279
- **Derivative**, **Riemann Sums** and **Taylor Series**.
9280
- - Videos: `linear-map-short.mjs` and `riemann-short.mjs` (9:16), `eigen-explainer.mjs`
9281
- and `taylor-explainer.mjs` (16:9), in `examples/headless-video/`.
9313
+ **Derivative**, **Riemann Sums**, **Taylor Series**, **Galton Board**, **Central Limit
9314
+ Theorem**, **Monte Carlo π** and **Bayes: a Positive Test**.
9315
+ - Videos: `linear-map-short.mjs`, `riemann-short.mjs` and `galton-short.mjs` (9:16);
9316
+ `eigen-explainer.mjs`, `taylor-explainer.mjs` and `clt-explainer.mjs` (16:9), in
9317
+ `examples/headless-video/`.
9282
9318
 
9283
9319
  ## Next
9284
9320
 
9285
- Probability and statistics (sampling, histograms, the Galton board), discrete
9286
- maths (graphs, trees, sets) and AI/ML (networks, gradient descent on a loss
9287
- surface) build on the same figure model.
9321
+ Discrete maths (graphs, trees, sets) and AI/ML (networks, gradient descent on
9322
+ a loss surface) build on the same figure model.
9288
9323
  See `todo.md` for their status.
9289
9324
 
9290
9325
  ---
@@ -10237,8 +10272,8 @@ On a page with no build step, load the maps add-on after the browser bundle; it
10237
10272
  adds to the same `tinyfly` global:
10238
10273
 
10239
10274
  ```html
10240
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly.iife.js"></script>
10241
- <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.116.0/cdn/tinyfly-maps.iife.js"></script>
10275
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly.iife.js"></script>
10276
+ <script src="https://cdn.jsdelivr.net/gh/algorisys-oss/tinyfly@v0.117.0/cdn/tinyfly-maps.iife.js"></script>
10242
10277
  ```
10243
10278
 
10244
10279
  It is a separate script because the offline world map it carries adds about
@@ -15467,7 +15502,7 @@ magnet.addEventListener('pointerleave', () => {
15467
15502
 
15468
15503
  <!-- capabilities: generated from the library -->
15469
15504
 
15470
- # tinyfly capabilities (v0.116.0)
15505
+ # tinyfly capabilities (v0.117.0)
15471
15506
 
15472
15507
  Generated from the library itself: every name below is accepted, and names not listed are rejected (beat scripts, code panels and `checkTracks` say which name was probably meant).
15473
15508
 
@@ -15954,6 +15989,8 @@ A figure is JSON: a plane and items. Tracks on its target animate values by name
15954
15989
  - `linearMapFigure, determinantFigure, eigenFigure, vectorSumFigure, spanFigure`: ready linear algebra figures; the matrix is the value M
15955
15990
  - `tangentFigure, secantFigure, riemannFigure, areaFigure, taylorFigure, limitFigure`: ready calculus figures; their moving parts are number values (a, h, n, b, order, p)
15956
15991
  - `differentiate / compileDerivative / integrate`: exact symbolic derivatives of expressions; Simpson integration
15992
+ - `normalFigure, binomialFigure, cltFigure, galtonFigure, monteCarloPiFigure, regressionFigure, bayesFigure`: ready probability and statistics figures
15993
+ - `distributions`: { kind: normal | uniform | exponential | binomial | poisson | dice | mean, …numbers or value names }; density, meanOf, sdOf, samples (seeded)
15957
15994
  - `layoutTex(tex) / morphEquation(a, b, t)`: the built-in TeX subset, and term-by-term transitions
15958
15995
  - `vec2, mat2`: 2D vectors and 2×2 matrices (apply, multiply, determinant, inverse, eigen)
15959
15996
 
@@ -15974,6 +16011,11 @@ Items (each has `id`, `kind`, and optional `color`, `draw`, `opacity`):
15974
16011
  - `riemann` { expr, from, to, n, rule?: left | right | midpoint | trapezoid }: \val{ID.sum}, \val{ID.exact}
15975
16012
  - `area` { expr, from, to, lower? }: signed, coloured by sign; \val{ID.value}
15976
16013
  - `taylor` { expr, at, order }: exact Taylor polynomials; a fractional order grows the next term in
16014
+ - `histogram` { distribution, count, bins?, scale?, curve?, seed? }: seeded samples, binned; fills as count grows
16015
+ - `distribution` { distribution, shade?: [a, b] }: a density curve (bars when discrete); \val{ID.p}
16016
+ - `galton` { rows?, balls, spacing?, top?, seed? }: a Galton board; fractional balls = the next one falling
16017
+ - `scatter` { points: uniform | linear, count, inside?, fit?, seed? }: Monte Carlo and regression; \val{ID.ratio}, \val{ID.r}
16018
+ - `bayes` { prior, truePositive, falsePositive }: Bayes as areas; \val{ID.posterior}
15977
16019
 
15978
16020
  Props a timeline animates:
15979
16021
 
package/llms.txt CHANGED
@@ -13,49 +13,49 @@ Key facts:
13
13
  - For language models: read the capability catalog first (`npx @algorisys/tinyfly capabilities`, or the end of llms-full.txt). It is generated from the library, so every name in it (poses, expressions, gags, gaits, beat actions, canvas properties, code-panel edits) is accepted, and names not in it are rejected with the name probably meant. Check beat scripts with `npx @algorisys/tinyfly check beats.json`, tracks with `checkTracks(tracks, targets)`, and ask any target what it animates with `describeTarget(target)`. The npm package ships `docs/`, `llms.txt`, `llms-full.txt` and an agent skill (`skills/tinyfly/SKILL.md`); `docs/llm-guide.md` describes the workflow.
14
14
  - Source: https://github.com/algorisys-oss/tinyfly. License: MIT.
15
15
 
16
- All documentation and the interactive course in a single file: [llms-full.txt](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/llms-full.txt)
16
+ All documentation and the interactive course in a single file: [llms-full.txt](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/llms-full.txt)
17
17
 
18
18
  ## Start here
19
19
 
20
- - [Getting Started](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/getting-started.md): What tinyfly is, making a first animation in the editor, and using it from code, a script tag or the CDN.
21
- - [GSAP Compatibility](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/gsap-compat.md): The GSAP-style API (`live.to`, `tf.timeline`): supported vars, motion paths, morphSVG, text, inertia, Draggable, Flip, and where it differs from GSAP.
22
- - [Code Examples](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/examples.md): Recipes with the engine API: fades, loops, colour and bezier easing, loading JSON, canvas and SVG rendering, multi-scene sequences, motion paths and script-tag embeds; a festive garba/dandiya scene with partner contacts, circle travel and spins, also rendered to video.
23
- - [Building Animations with an LLM](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/llm-guide.md): For assistants and the people setting them up: read the capability catalog (`tinyfly capabilities`), ask targets what they animate (`describeTarget`), check beats and tracks with did-you-mean errors (`tinyfly check`, `checkTracks`), render stills to look at, and the agent skill shipped in the package.
20
+ - [Getting Started](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/getting-started.md): What tinyfly is, making a first animation in the editor, and using it from code, a script tag or the CDN.
21
+ - [GSAP Compatibility](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/gsap-compat.md): The GSAP-style API (`live.to`, `tf.timeline`): supported vars, motion paths, morphSVG, text, inertia, Draggable, Flip, and where it differs from GSAP.
22
+ - [Code Examples](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/examples.md): Recipes with the engine API: fades, loops, colour and bezier easing, loading JSON, canvas and SVG rendering, multi-scene sequences, motion paths and script-tag embeds; a festive garba/dandiya scene with partner contacts, circle travel and spins, also rendered to video.
23
+ - [Building Animations with an LLM](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/llm-guide.md): For assistants and the people setting them up: read the capability catalog (`tinyfly capabilities`), ask targets what they animate (`describeTarget`), check beats and tracks with did-you-mean errors (`tinyfly check`, `checkTracks`), render stills to look at, and the agent skill shipped in the package.
24
24
 
25
25
  ## Reference
26
26
 
27
- - [API Reference](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/api-reference.md): Every public engine, player and adapter API: Timeline, tracks, keyframes, easing, drivers, serialization and exports.
28
- - [File Format](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/file-format.md): The JSON animation format: timelines, every track kind, keyframes, easing and the project file — for generating or consuming animations.
27
+ - [API Reference](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/api-reference.md): Every public engine, player and adapter API: Timeline, tracks, keyframes, easing, drivers, serialization and exports.
28
+ - [File Format](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/file-format.md): The JSON animation format: timelines, every track kind, keyframes, easing and the project file — for generating or consuming animations.
29
29
 
30
30
  ## Editor features
31
31
 
32
- - [Editor Guide](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/editor-guide.md): Every panel and feature of the visual editor, from elements and keyframes to text and inertia tracks, preview and export.
33
- - [Shape Morphing](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/shape-morph.md): Tweening one path into another, including shapes with different point counts and several subpaths.
34
- - [Pen Tool](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/pen-tool.md): Drawing custom paths point by point with straight segments and bezier curves.
35
- - [Polygons & Stars](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/polygon-star.md): Parametric polygon and star shapes that stay editable while animating like any path.
36
- - [Grid & Snapping](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/grid-and-snapping.md): The grid overlay, snapping to grid, elements and artboard centre, and alignment guides.
37
- - [Onion Skinning](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/onion-skinning.md): Ghost frames before and after the playhead for judging arcs and easing.
38
- - [Sprite-sheet Export](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/sprite-sheet-export.md): Exporting frames as a PNG grid plus JSON metadata for game engines and canvas players.
32
+ - [Editor Guide](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/editor-guide.md): Every panel and feature of the visual editor, from elements and keyframes to text and inertia tracks, preview and export.
33
+ - [Shape Morphing](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/shape-morph.md): Tweening one path into another, including shapes with different point counts and several subpaths.
34
+ - [Pen Tool](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/pen-tool.md): Drawing custom paths point by point with straight segments and bezier curves.
35
+ - [Polygons & Stars](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/polygon-star.md): Parametric polygon and star shapes that stay editable while animating like any path.
36
+ - [Grid & Snapping](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/grid-and-snapping.md): The grid overlay, snapping to grid, elements and artboard centre, and alignment guides.
37
+ - [Onion Skinning](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/onion-skinning.md): Ghost frames before and after the playhead for judging arcs and easing.
38
+ - [Sprite-sheet Export](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/sprite-sheet-export.md): Exporting frames as a PNG grid plus JSON metadata for game engines and canvas players.
39
39
 
40
40
  ## Guides
41
41
 
42
- - [Cricket Stories](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/cricket.md): Reusable sports APIs, organic adult/child players, sixteen cricket plays, Test/ODI/T20 facts, contact-keyed JSON, captions, headless video and a 360° ground camera.
43
- - [Scroll Animation](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/scroll-animation.md): Scroll-driven and play-when-visible animation with ScrollDriver and VisibilityDriver.
44
- - [Props: Everyday Objects with Behaviours](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/props.md): Cars, trucks, buses, tractors, carts, train carriages, bikes, motorbikes, trees, houses, a helicopter and a plane: 3D rigs drawn with the characters’ pens (clean, pencil) that turn toward the camera, with beats acted through the 12 principles (anticipation, squash and stretch, follow-through, an exaggeration dial), wheels that roll exactly, effects, and figures riding them.
45
- - [Teaching Animations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/teaching.md): Step-through explanatory figures: markers, captions in several languages, the teaching player, step controls, one-script declarative embeds, tinyfly/teach diagram primitives, and validate / render for build pipelines.
46
- - [Maths Animations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/math.md): tinyfly/math: figures as JSON (grids a matrix warps, vectors, function plots, polygons, eigenlines, TeX labels and equations that rewrite step by step), animated by plain tracks, played in lesson-page embeds, explorables and videos from one layout; a built-in TeX subset and ready linear algebra figures.
47
- - [Rendering Video from Code](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/video-rendering.md): Rendering a scene to MP4 without a browser: `tinyfly video`, custom canvas targets drawn by code, timing from narration and recorded voice-over, the stick-figure character, SRT/WebVTT captions, stills, porting Cairo scripts, and a benchmark against pycairo.
48
- - [Animated Maps](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/maps.md): Maps that animate: a camera that flies in to a city, pins that drop in, routes that draw themselves while a marker travels them, on OpenStreetMap tiles or an offline world outline (also in pencil), in the browser and in headless video.
49
- - [Cartoon Hands](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/cartoon-hands.md): A hand you can pose: a palm and five fingers in 3D, posed by numbers (curls, thumb, spread, wrist turn), ready-made shapes from a fist to a pencil grip, left and right, four or five fingers, in clean, pencil and silhouette looks; the animator's hand and character gloves are built on it.
50
- - [Character Appearance](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/character-appearance.md): Hair (34 styles), facial hair (20), glasses, hats and ears for the v2 character as plain data on the head, so they turn with it through all eight views; builds (child, tall, short…), a recurring cast (castMember), expressions with blush, tears and sweat, everyday poses, held items (mug, phone, bags, umbrella, parcel) and two characters’ hands meeting (meetHands: handshake, high five, hand-over).
51
- - [Cartoon Acting](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/acting.md): actTracks(): the same key poses, acted: anticipation, overshoot and settle, overlapping joints, eyes that lead and blink, moving holds and jump squash, in full, snappy or limited styles; gags as data (take, double take, wind-up); a line of action (bend); gaits with personality; lip-sync from text (Latin and Devanagari); beat scripts compiled to acted tracks; your own actions (defineAction), gaits (defineGait) and personas (persona()); acting on code (codePanel lines and words as anchors: leap onto a line, point at it, swipe it away wiped, knocked off or blurred; grab, throw, kick, carry and drop words, push them along their line, write new text in by hand; ride a line as gaps close); camera shots (push in, cut, shake, follow); the cartoon zip; speed lines, dust puffs and impact stars; drawing on twos (a timeline setting); acting, gags, walks and lines in the editor.
52
- - [Dance and Flips](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/dance.md): The stick figure dances disco, hip hop, breaking, jazz, K-pop, Bollywood, Bhangra, Bharatanatyam (with mudras), the Charleston, tap and popping, and does flips, leaps and splits; native v2 garba (two/three clap) and dandiya add body-local routines, circle formations, world foot plants, paired stick-tip contacts and signed spins; JSON bakes, timing, contact limits and editor menus.
53
- - [3D Scenes](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/scene-3d.md): @algorisys/tinyfly/scene-3d: cameras, lights and meshes as JSON, in metres, animated by tracks at <scene>/<object> (cuts with activeCamera), drawn on a 2D canvas with flat, smooth or toon shading, ink outlines and fog, in browsers, Workers and Node (MP4 with tinyfly video); v2 characters in pen or solid looks, scripted native dances, timed signed spins and circle formations with foot contacts.
54
- - [3D Transforms and Rotations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/3d-rotations.md): CSS-style 3D for flat elements in every renderer (rotateX, rotateY, z, perspective, backface visibility; true perspective on Canvas and WebGL, matching CSS within a pixel), one documented transform order, the editor's 3D fields; smooth quaternion rotations with interpolation: "slerp"; the vec3, quat and mat4 helpers; format version 2.
55
- - [Extending tinyfly](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/extending.md): Writing a render adapter, animating any object with live and the ticker, custom and parametric eases, stagger offsets, adding a track kind, and contributing gallery examples.
56
- - [Deployment](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/docs/DEPLOYMENT.md): Building and hosting the editor, and serving the player bundles.
42
+ - [Cricket Stories](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/cricket.md): Reusable sports APIs, organic adult/child players, sixteen cricket plays, Test/ODI/T20 facts, contact-keyed JSON, captions, headless video and a 360° ground camera.
43
+ - [Scroll Animation](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/scroll-animation.md): Scroll-driven and play-when-visible animation with ScrollDriver and VisibilityDriver.
44
+ - [Props: Everyday Objects with Behaviours](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/props.md): Cars, trucks, buses, tractors, carts, train carriages, bikes, motorbikes, trees, houses, a helicopter and a plane: 3D rigs drawn with the characters’ pens (clean, pencil) that turn toward the camera, with beats acted through the 12 principles (anticipation, squash and stretch, follow-through, an exaggeration dial), wheels that roll exactly, effects, and figures riding them.
45
+ - [Teaching Animations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/teaching.md): Step-through explanatory figures: markers, captions in several languages, the teaching player, step controls, one-script declarative embeds, tinyfly/teach diagram primitives, and validate / render for build pipelines.
46
+ - [Maths Animations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/math.md): tinyfly/math: figures as JSON (grids a matrix warps, vectors, function plots, polygons, eigenlines, TeX labels and equations that rewrite step by step), animated by plain tracks, played in lesson-page embeds, explorables and videos from one layout; a built-in TeX subset and ready linear algebra figures.
47
+ - [Rendering Video from Code](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/video-rendering.md): Rendering a scene to MP4 without a browser: `tinyfly video`, custom canvas targets drawn by code, timing from narration and recorded voice-over, the stick-figure character, SRT/WebVTT captions, stills, porting Cairo scripts, and a benchmark against pycairo.
48
+ - [Animated Maps](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/maps.md): Maps that animate: a camera that flies in to a city, pins that drop in, routes that draw themselves while a marker travels them, on OpenStreetMap tiles or an offline world outline (also in pencil), in the browser and in headless video.
49
+ - [Cartoon Hands](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/cartoon-hands.md): A hand you can pose: a palm and five fingers in 3D, posed by numbers (curls, thumb, spread, wrist turn), ready-made shapes from a fist to a pencil grip, left and right, four or five fingers, in clean, pencil and silhouette looks; the animator's hand and character gloves are built on it.
50
+ - [Character Appearance](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/character-appearance.md): Hair (34 styles), facial hair (20), glasses, hats and ears for the v2 character as plain data on the head, so they turn with it through all eight views; builds (child, tall, short…), a recurring cast (castMember), expressions with blush, tears and sweat, everyday poses, held items (mug, phone, bags, umbrella, parcel) and two characters’ hands meeting (meetHands: handshake, high five, hand-over).
51
+ - [Cartoon Acting](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/acting.md): actTracks(): the same key poses, acted: anticipation, overshoot and settle, overlapping joints, eyes that lead and blink, moving holds and jump squash, in full, snappy or limited styles; gags as data (take, double take, wind-up); a line of action (bend); gaits with personality; lip-sync from text (Latin and Devanagari); beat scripts compiled to acted tracks; your own actions (defineAction), gaits (defineGait) and personas (persona()); acting on code (codePanel lines and words as anchors: leap onto a line, point at it, swipe it away wiped, knocked off or blurred; grab, throw, kick, carry and drop words, push them along their line, write new text in by hand; ride a line as gaps close); camera shots (push in, cut, shake, follow); the cartoon zip; speed lines, dust puffs and impact stars; drawing on twos (a timeline setting); acting, gags, walks and lines in the editor.
52
+ - [Dance and Flips](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/dance.md): The stick figure dances disco, hip hop, breaking, jazz, K-pop, Bollywood, Bhangra, Bharatanatyam (with mudras), the Charleston, tap and popping, and does flips, leaps and splits; native v2 garba (two/three clap) and dandiya add body-local routines, circle formations, world foot plants, paired stick-tip contacts and signed spins; JSON bakes, timing, contact limits and editor menus.
53
+ - [3D Scenes](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/scene-3d.md): @algorisys/tinyfly/scene-3d: cameras, lights and meshes as JSON, in metres, animated by tracks at <scene>/<object> (cuts with activeCamera), drawn on a 2D canvas with flat, smooth or toon shading, ink outlines and fog, in browsers, Workers and Node (MP4 with tinyfly video); v2 characters in pen or solid looks, scripted native dances, timed signed spins and circle formations with foot contacts.
54
+ - [3D Transforms and Rotations](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/3d-rotations.md): CSS-style 3D for flat elements in every renderer (rotateX, rotateY, z, perspective, backface visibility; true perspective on Canvas and WebGL, matching CSS within a pixel), one documented transform order, the editor's 3D fields; smooth quaternion rotations with interpolation: "slerp"; the vec3, quat and mat4 helpers; format version 2.
55
+ - [Extending tinyfly](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/extending.md): Writing a render adapter, animating any object with live and the ticker, custom and parametric eases, stagger offsets, adding a track kind, and contributing gallery examples.
56
+ - [Deployment](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/docs/DEPLOYMENT.md): Building and hosting the editor, and serving the player bundles.
57
57
 
58
58
  ## Optional
59
59
 
60
- - [README](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/README.md): Feature overview, project layout and development setup.
61
- - [Release notes](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.116.0/release-notes/README.md): What changed in each version.
60
+ - [README](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/README.md): Feature overview, project layout and development setup.
61
+ - [Release notes](https://raw.githubusercontent.com/algorisys-oss/tinyfly/v0.117.0/release-notes/README.md): What changed in each version.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@algorisys/tinyfly",
3
- "version": "0.116.0",
3
+ "version": "0.117.0",
4
4
  "type": "module",
5
5
  "description": "Lightweight, API-driven animation engine and editor. The engine is framework-agnostic and runs in browsers, Web Workers, and Node.",
6
6
  "license": "MIT",
@@ -174,7 +174,9 @@ names.
174
174
  `opacity` or `scale`. Lesson pages: `<figure data-tinyfly-math>` with
175
175
  `tinyfly-math.iife.js`; videos: `mathTarget(figure)`. Calculus: `tangent`
176
176
  (`h` makes a secant), `riemann`, `area`, `taylor`; animate `at` / `n` / `to` /
177
- `order` through number values. See `docs/math.md`.
177
+ `order` through number values. Probability: `histogram`, `distribution`,
178
+ `galton`, `scatter`, `bayes`; distributions are data and samples are seeded.
179
+ See `docs/math.md`.
178
180
 
179
181
  ## 3. Check
180
182