tonus 0.8.0 → 0.9.1

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.
Files changed (34) hide show
  1. package/CHANGELOG.md +275 -1
  2. package/README.md +3 -3
  3. package/dist/engines/chant/attest.js +8 -8
  4. package/dist/engines/chant/hour.js +3 -3
  5. package/dist/engines/chant/intone.js +7 -1
  6. package/dist/engines/score/cadence.d.ts +10 -4
  7. package/dist/engines/score/cadence.js +10 -4
  8. package/dist/engines/score/emitters/accidentals.d.ts +9 -0
  9. package/dist/engines/score/emitters/accidentals.js +76 -13
  10. package/dist/engines/score/emitters/atramentum.js +1 -1
  11. package/dist/engines/score/emitters/breaking.d.ts +2 -2
  12. package/dist/engines/score/emitters/breaking.js +2 -2
  13. package/dist/engines/score/emitters/moderna.js +165 -17
  14. package/dist/engines/score/emitters/svg.d.ts +16 -0
  15. package/dist/engines/score/emitters/svg.js +19 -12
  16. package/dist/engines/score/emitters/tracks.js +29 -10
  17. package/dist/engines/score/ir.js +24 -4
  18. package/dist/engines/score/neume.d.ts +19 -0
  19. package/dist/engines/score/neume.js +35 -0
  20. package/dist/engines/score/parse.js +4 -1
  21. package/dist/engines/score/types.d.ts +6 -0
  22. package/dist/engines/temper/data/guido.js +4 -2
  23. package/dist/engines/temper/gabc.d.ts +12 -0
  24. package/dist/engines/temper/gabc.js +51 -18
  25. package/dist/engines/temper/neume.d.ts +1 -1
  26. package/dist/engines/temper/neume.js +24 -3
  27. package/docs/api/calendar.md +4 -4
  28. package/docs/api/census.md +20 -20
  29. package/docs/api/chant.md +27 -27
  30. package/docs/api/heavens.md +7 -7
  31. package/docs/api/index.md +5 -5
  32. package/docs/api/score.md +191 -138
  33. package/docs/api/tuning.md +31 -23
  34. package/package.json +4 -3
@@ -267,15 +267,23 @@ t.neuma(["D4", "F4", "E4"]);
267
267
 
268
268
  Shapes that match no simple figure classify as `"compound"`.
269
269
 
270
- | `shape` | figure | `shape` | figure |
271
- | ----------- | ------------------ | -------------------- | --------------------------- |
272
- | `punctum` | a single note | `torculus resupinus` | torculus, then rising |
273
- | `pes` | two notes, rising | `porrectus flexus` | porrectus, then falling |
274
- | `clivis` | two notes, falling | `scandicus flexus` | scandicus, then falling |
275
- | `torculus` | three: up, down | `climacus resupinus` | climacus, then rising |
276
- | `porrectus` | three: down, up | `pes subpunctis` | pes, then descending points |
277
- | `scandicus` | three, rising | `compound` | any figure not above |
278
- | `climacus` | three, falling | | |
270
+ | `shape` | figure | `shape` | figure |
271
+ | ----------- | ------------------ | ---------------------- | ------------------------------- |
272
+ | `punctum` | a single note | `torculus resupinus` | torculus, then rising |
273
+ | `pes` | two notes, rising | `porrectus flexus` | porrectus, then falling |
274
+ | `clivis` | two notes, falling | `scandicus flexus` | scandicus, then falling |
275
+ | `torculus` | three: up, down | `climacus resupinus` | climacus, then rising |
276
+ | `porrectus` | three: down, up | `pes subpunctis` | pes, then descending points |
277
+ | `scandicus` | three, rising | `scandicus subpunctis` | two rising, then descending |
278
+ | `climacus` | three, falling | `salicus` | rising, next-to-last an oriscus |
279
+
280
+ The repercussive figures restate a pitch rather than leave it.
281
+
282
+ | `shape` | figure | `shape` | figure |
283
+ | ------------------ | ------------------- | --------------- | ---------------------- |
284
+ | `distropha` | two on one pitch | `pressus` | restated, then falling |
285
+ | `tristropha` | three on one pitch | `pressus maior` | falling in, then out |
286
+ | `tristropha flexa` | three, then falling | `compound` | any figure not above |
279
287
 
280
288
  ```ts
281
289
  interface Neume {
@@ -335,11 +343,11 @@ interface GamutOptions {
335
343
  `modus` returns the full profile of one of the eight modes, as the
336
344
  medieval tonaries describe them:
337
345
 
338
- - its identity — Latin name, modern alias, _maneria_ (the family: Protus,
346
+ - its identity: Latin name, modern alias, _maneria_ (the family: Protus,
339
347
  Deuterus, Tritus, Tetrardus), and authentic or plagal type;
340
- - its structure — finalis, tenor, scale degrees, ambitus, and the species
348
+ - its structure: finalis, tenor, scale degrees, ambitus, and the species
341
349
  of fifth and fourth that build it;
342
- - its practice — hexachords in rank order, melodic profile, its cadence
350
+ - its practice: hexachords in rank order, melodic profile, its cadence
343
351
  figures, and permitted modulations.
344
352
 
345
353
  Each mode also carries its traditional **ethos** (the character medieval theory
@@ -357,7 +365,7 @@ data, in [`temper/data/modes.ts`](https://github.com/jeffreypierce/tonus/blob/ma
357
365
  temperamentum: the **finalis** and **reciting** tone as tuned notes (pitch +
358
366
  Guidonian step), and **ambitusNotes**, the mode's diatonic range walked out
359
367
  note by note. The raw `ModeData` fields (`final`, `tenor`, `cadences`, …)
360
- remain alongside — `Modus` extends `ModeData`.
368
+ remain alongside, because `Modus` extends `ModeData`.
361
369
 
362
370
  ```js
363
371
  t.modus(1);
@@ -428,7 +436,7 @@ interface Modus extends ModeData {
428
436
  ### Cadence figures
429
437
 
430
438
  Each mode carries the melodic figures its phrases characteristically close
431
- on, in `modus(n).cadences` — the shapes by which a chant comes to rest, stored
439
+ on, in `modus(n).cadences`, the shapes by which a chant comes to rest, stored
432
440
  as diatonic steps relative to the final. The score engine reads them to name a
433
441
  phrase's cadence ([score.md](score.md#cadences)).
434
442
 
@@ -441,10 +449,10 @@ phrase's cadence ([score.md](score.md#cadences)).
441
449
 
442
450
  The catalogue is an editorial synthesis covering the final cadences; its step
443
451
  encoding, sources, and known gaps (medial cadences are not yet included) are
444
- documented at the data — see `CadenceFigure` in
452
+ documented at the data. See `CadenceFigure` in
445
453
  [`temper/data/modes.ts`](https://github.com/jeffreypierce/tonus/blob/main/src/engines/temper/data/modes.ts).
446
454
 
447
- This is the **tradita** half — what the treatises say. Its counterpart is the
455
+ This is the **tradita** half, what the treatises say. Its counterpart is the
448
456
  corpus tally below, and they are not interchangeable: see [one spine, two
449
457
  annotations](score.md#one-spine-two-annotations).
450
458
 
@@ -452,8 +460,8 @@ annotations](score.md#one-spine-two-annotations).
452
460
 
453
461
  Where the figures above are received, [`CADENTIAE`](index.md#the-appendix) is
454
462
  **mined**: every phrase-end in the sung corpus, grouped into families by what
455
- the melody actually did. A family is a **shape** — the closing tail's
456
- successive semitone intervals — and an **arrival**, where it landed relative
463
+ the melody actually did. A family is a **shape** (the closing tail's
464
+ successive semitone intervals) and an **arrival**, where it landed relative
457
465
  to the chant's own closing note. Together they are the key, `"2,0,-2 @0"`, and
458
466
  the key is the family's whole name.
459
467
 
@@ -497,14 +505,14 @@ lift(fam, 6); // 2.15
497
505
  lift(fam, 4); // 0.07
498
506
  ```
499
507
 
500
- The commonest family in the corpus — about 1,100 occurrences, about 4% of all
501
- phrase-ends, closing a little under half the time — is not reached for evenly.
508
+ The commonest family in the corpus (about 1,100 occurrences, about 4% of all
509
+ phrase-ends, closing a little under half the time) is not reached for evenly.
502
510
  Mode 6 reaches for this close more than twice as often as the corpus does;
503
511
  mode 4 almost never. That is the figure the tonarium prints under a cadence
504
512
  ([score.md](score.md#the-analysis-tracks)).
505
513
 
506
- **The ratio is not baked.** The table exports the vocabulary — counts and
507
- their denominators — and leaves the arithmetic to the caller. Two cautions when
514
+ **The ratio is not baked.** The table exports the vocabulary (counts and
515
+ their denominators) and leaves the arithmetic to the caller. Two cautions when
508
516
  you take it: below roughly ten in-mode occurrences the ratio is one or two
509
517
  chants deciding a number that reads like a measurement, and a mode-less chant
510
518
  (`"?"`) has no denominator at all. In both cases fall back to `share`.
@@ -516,7 +524,7 @@ pitches: the **intonatio** (the opening rise), the **mediatio** (the
516
524
  cadence at the verse's colon), and the **terminatio** (the closing
517
525
  cadence). The termination varies by **differentia**, the cadential variant
518
526
  chosen to lead back into the antiphon; the mode's default differentia is
519
- used when none is given. The mode must be set explicitly — with mode
527
+ used when none is given. The mode must be set explicitly, because with mode
520
528
  `"auto"`, `tonus()` throws.
521
529
 
522
530
  ```js
package/package.json CHANGED
@@ -1,15 +1,15 @@
1
1
  {
2
2
  "name": "tonus",
3
- "version": "0.8.0",
3
+ "version": "0.9.1",
4
4
  "type": "module",
5
- "description": "Medieval music analysis and performance: GABC plainchant exports, liturgical calendar, tuning systems, ephemeris, and the harmony of the spheres",
5
+ "description": "Medieval music analysis: GABC plainchant exports, liturgical calendar, tuning systems, ephemeris, and the harmony of the spheres",
6
6
  "author": "Jeffrey Pierce <jeffrey@jeffreypierce.net>",
7
7
  "license": "PolyForm-Noncommercial-1.0.0",
8
8
  "repository": {
9
9
  "type": "git",
10
10
  "url": "git+https://github.com/jeffreypierce/tonus.git"
11
11
  },
12
- "homepage": "https://jeffreypierce.github.io/tonus/",
12
+ "homepage": "https://orreliquum.com/",
13
13
  "bugs": "https://github.com/jeffreypierce/tonus/issues",
14
14
  "keywords": [
15
15
  "gregorian-chant",
@@ -36,6 +36,7 @@
36
36
  },
37
37
  "main": "./dist/index.js",
38
38
  "types": "./dist/index.d.ts",
39
+ "sideEffects": false,
39
40
  "files": [
40
41
  "dist",
41
42
  "docs/api",