The damn thing is more or less implemented:
perl drhino.pl scene_i-iii rnd_456
- perl neopro.pl < txt$ID > pasyz
- neopro does not use files, but must be called as above
- input: txt$ID — in this case txti-iii
- output: pasyz
- perl neofit.pl @ARGV > fit$ID
- input: pasyz
- output: rhy$ID
- _________________________________________ copies pasyz to pas$ID
- perl filbar.pl @ARGV > fb$ID
- input: rhy$ID
- output: bar$ID
- perl rhyno.pl @ARGV > mrj$ID
- input:
pas$ID ( general info, parsed from the raw data txt$ID )
bar$ID (rhythm)- output: mer$ID
- perl sigseg.pl @ARGV > seg$ID
- input: mer$ID
- auxiliary input: pcharmo.txt (for harmony) , cadosh.txt (for cadences)
- output: prescore$ID
- perl maxco.pl @ARGV > max$ID
- input: prescore$ID
- auxiliary input: pcharmo.txt (for harmony) , tritra.txt (for trills)
- output: ......................
e.g. rhy u/rhy as a a separate word
u means unstressed, / means stressed:
iamb u/
trochee /u
dactyl /uu
or a more complex rhythm: /u/uu/uu
etc...
MACBETH. Where`fore that cry? DOCTOR. The Queen, my lord, is dead. {cada}| {mot macbeth_doom} MACBETH. She should have +died here`+af`ter; {+cada} |
seg1, from the sequence cada, +cada motif: macbeth_doom motifs from the text: death |
To`+mor`row, and to`+mor`row, and to`+mor`row {cadc} +Creeps in this +pet`ty pace from day to day To the +last syl`lable of re`+cor`ded time; {+cadc} And all our +yes`ter`days have ligh`ted +fools The way to dus`ty +death.{++cadc} Out, out, brief +candle!{+++cadc} |
seg2, from the sequence cadc, +cadc ... +++cadc motif: macbeth_doom motifs from the text: death |
Life's but a wal`king +sha`dow, a poor +pla`yer That +struts and +frets his hour up`on the +stage |
seg3, between specified cadences cadc and cadd motif: macbeth_doom no motifs from the text |
And then is heard no +more.{cadd} It is a +tale Told by an +i`diot, full of +sound and +fu`ry, RHY /u Sig`ni`+fy`ing +no`thing.{+cadd} |
seg4, from the sequence cadd, +cadd motif: macbeth_doom no motifs from the text |
In particular, while between cadences, ( e.g. seg3 above ) end each verse with a weak cadence, and each second verse with a little stronger cadence. Or, to complicate life, end verses with cadences and sentences with stronger cadences. Anyway, let's call this making couplets.
Then create rhythm, based on accented syllables and sprung rhythm stress groups.
Some comments are meaningful, the program should recognize:
e.g. {=== ACT II. SCENE V.}The program will create the identifier ii-v .
e.g. ++cadbThat means a cadence in the same scale as +cadb, stronger than +cadb ; +cadb itself is a cadence in the same scale as cadb, stronger than cadb.
There should be some cadence specified near the beginning of the scene, and another near the end.
e.g. muz choirmusic not created from the current text.
e.g.: MACDUFF. Gen`tle +hea`vens, Bring thou this +fiend of +Scot`land and my`+self Wi`thin my +sword's length set him; {rst} if he +'scape, +Hea`ven for`+give him +too!{inc} {rst} MALCOLM. This tune goes +man`ly.
e.g. mot macbeth_hope upThe hash of motives is searched using the key macbethhope, and if a motive is found, it is used (how, exactly?). Even if a mot-comment is not used, every complete word in the text is used as a search key for motives. Nonletters in such a word (e.g. the underscore in macbeth_hope) are ignored.
If min or maj are found, this is a request for this musical mode, minor or major. If up or down are found, this is the mood of the music: happy or sad, upbeat or downbeat (as if I knew how to program that!)
Notice where {inc} appears, till the verse ends with " Our castle's strength ".Hang out our +ban`ners on the out`ward walls; The cry is still, "They come!" { cadz} {inc} {muz male choir ; march ; soldiers pick up the tune above }{inc} Our cas`tle's strength Will +laugh a siege to scorn. Here let them lie
{=== ACT V. SCENE V.} {=================================} {--- Dunsinane. Within the castle.} {mot lady_macbeth min down} {--- A cry of women within.} {muz women choir} {--- enter Doctor.} RHY u/ MACBETH. Where`fore that cry? DOCTOR. The Queen, my lord, is dead. {cada} {mot macbeth_doom} MACBETH. She should have died here`af`ter; {+cada} To`+mor`row, and to`+mor`row, and to`+mor`row {cadc} Creeps in this pet`ty pace from day to day To the +last syl`lable of re`+cor`ded time; {+cadc} And all our +yes`ter`days have ligh`ted +fools The way to dus`ty +death.{++cadc} Out, out, brief candle!{+++cadc} Life's but a wal`king +sha`dow, a poor +pla`yer That +struts and +frets his hour up`on the stage And then is heard no more.{cadd} It is a tale Told by an +i`diot, full of +sound and +fu`ry, RHY /u +Sig`ni`fy`ing +no`thing.{+cadd} {--- resolute} {mot macbeth_hope up} RHY u/ I will not be a`fraid of +death and +bane {cadb} Till +Bir`nam Fo`rest come to +Dun`si`nane. {+cadb} {muz male choir, march; soldiers pick up the music above }
becomes:{=== ACT IV. SCENE I.} {=========================} {--- A cavern. In the middle, a boiling cauldron. Thunder.} {--- Enter the three Witches.} RHY /u FIRST_WITCH. Round a`bout the +caul`dron go;{cada} In the +poi`son'd en`trails throw.{+cada} +Toad, that un`der +cold +stone Days and nights has thir`ty`+one;{++cada} THREE_WITCHES. Dou`ble, dou`ble, +toil and trou`ble;{cadz} +Fire burn and +caul`dron bub`ble.{+cadz}
iv-i104adk <seg cada iv-i104adp inp FIRST_WITCH. Round about the cauldron go;{cada} iv-i104adu line 4 iv-i104adv mot cauldron iv-i104adz role FIRST_WITCH iv-i104aee syl _Round iv-i104aej syl a- iv-i104aeo syl _bout iv-i104aet syl the iv-i104aey syl +caul- iv-i104afd syl dron iv-i104afi syl _go iv-i104afn cad {cada} | line 4 : 1 stress | start seg cada | motif: cauldron |
iv-i105afs inp In the poison'd entrails throw.{cada} iv-i105afx line 5 iv-i105agc syl _In iv-i105agh syl the iv-i105agm syl +poi- iv-i105agr syl son'd iv-i105agw syl _en- iv-i105ahb syl trails iv-i105ahg syl _throw iv-i105ahl cad {+cada} | line 5 : 1 stress | ||
iv-i106ahq inp Toad, that under cold stone iv-i106ahv line 6 iv-i106aia syl +Toad iv-i106aif syl that iv-i106aik syl _un- iv-i106aip syl der iv-i106aiu syl +cold iv-i106aiz syl +stone | line 6 : 3 stresses | ||
iv-i107aje inp Days and nights has thirtyone;{cada} iv-i107ajj line 7 iv-i107ajo syl _Days iv-i107ajt syl and iv-i107ajy syl _nights iv-i107akd syl has iv-i107aki syl _thir- iv-i107akn syl ty- iv-i107aks syl +one iv-i107akx cad {++cada} iv-i107alc seg> cada | line 7 : 1 stress | end seg cada | |
iv-i108alh <seg cadz iv-i108alm inp THREE_WITCHES. Double, double, toil and trouble;{cadz} iv-i108alr line 8 iv-i108alw role THREE_WITCHES iv-i108amb syl _Dou- iv-i108amg syl ble iv-i108aml syl _dou- iv-i108amq syl ble iv-i108amv syl +toil iv-i108ana syl and iv-i108anf syl _trou- iv-i108ank syl ble iv-i108anp cad {cadz} | line 8 | start seg cadz | |
iv-i109anu inp Fire burn and cauldron bubble.{cadz} iv-i109anz line 9 iv-i109aoe syl +Fire iv-i109aoj syl burn iv-i109aoo syl _and iv-i109aot syl +caul- iv-i109aoy syl _dron iv-i109apd syl bub- iv-i109api syl _ble iv-i109apn cad {+cadz} iv-i109aps seg> cadz | line 9 : 2 stresses | end seg cadz |
One can see the regular trochaic rhythm, verses of 7-8 syllables dum-ta, dum-ta, ..., and the irregular "feet" pattern; each line has a different number of stresses. I call feet, for short, the sprung rhythm groups containing precisely one stress each – this is my idea about English stress-timed prosody. One may force all the verses to the same number of feet, using repetition (so common in librettos; but to do this to Shakespeare, and automatically!) or add non-vocal musical items to make all verses last the same, or ... On the other hand, if we deal with English prosody, all feet should last the same.
After a time signature is chosen, the lines above provide a complete recipe for rhythm.
I have now ( 3/29/2013 ) a full conversion from text to rhythm to chords, e.g.
which actually means, after some interpretation:iv-i103ada rhy /u iv-i104adg ttl best of 13, 2 cadences STRICT iv-i104adh gra grade 140 tonality 4015, cminx iv-i104adu role FIRST_WITCH iv-i104adz pros _Round a- bout the +caul- dron#go ter 12/8 8 to 12 units iv-i104aee syl Round 0,11,2,7 2 units acc 3 iv-i104aej syl a 1 1 units acc 0 iv-i104aeo syl bout 0,2,7,8 2 units acc 1 iv-i104aet syl the 1,7 1 units acc 0 iv-i104aey syl caul 0,3,7 2 units acc 2 iv-i104afd syl dron 1,11,5,8 1/2 units acc 0 iv-i104afe syl go 0,7 1/2 units acc 0 iv-i104afk cad 126 0;11;0 ROOT 0 1 0 CHORDS 0 3 7;1 5 8 11;0 3 7 ASUBV melcad iv-i105afz pros _In the +poi- son'd _en- trails _throw ter 12/8 8 to 12 units iv-i105age syl In 7,8 2 units acc 3 iv-i105agj syl the 1,7 1 units acc 0 iv-i105ago syl poi 0,7,8 2 units acc 1 iv-i105agt syl son'd 0,11,7 1 units acc 0 iv-i105agy syl en 0,7 2 units acc 2 iv-i105ahd syl trails 1,11,5,8 1 units acc 0 iv-i105ahi syl throw 0,3,7 1 units acc 1 iv-i105ahn cad 126 0;11;0 ROOT 0 1 0 CHORDS 0 3 7;1 5 8 11;0 3 7 ASUBV melcad iv-i106aic pros +Toad that _un- der +cold +stone ter 12/8 8 to 12 units iv-i106aih syl Toad 0,1,11,7 2 units acc 3 iv-i106aim syl that 1,7 1 units acc 0 iv-i106air syl un 2,7 2 units acc 1 iv-i106aiw syl der 0,11,7 1 units acc 0 iv-i106ajb syl cold 0,11,3,5 2 units acc 2 iv-i106ajg syl stone 0,11,7 1 units acc 0 iv-i107ajv pros _Days and _nights has _thir- ty- one ter 12/8 8 to 12 units iv-i107aka syl Days 1,11,2 2 units acc 3 iv-i107akf syl and 1,11,7 1 units acc 0 iv-i107akk syl nights 1,11,5,7,8 2 units acc 1 iv-i107akp syl has 1,11 1 units acc 0 iv-i107aku syl thir 0,1,7,8 2 units acc 2 iv-i107akz syl ty 5,7 1 units acc 0 iv-i107ale syl one 0,7 1 units acc 1 iv-i107alj cad 128 11;0 ROOT 7 0 CHORDS 7 11 2 5;0 3 7 AUTHENTIC melcad
For instance, the line:
assigns to the syllable Days the chord 1,11,2 = C#,B,D lasting two units. To see what the units are, look above at the line:iv-i107aka syl Days 1,11,2 2 units acc 3
which shows the time signature 12/8, so two units = two eights = one quarter. These units are just the denominator in the signature. There are also 1/2 units,iv-i107ajv pros _Days and _nights has _thir- ty- one ter 12/8 8 to 12 units
in this case sixteenths.iv-i104afd syl dron 1,11,5,8 1/2 units acc 0
It can be seen that the lines usually end with tame cadences, but the harmony is quite dissonant.
This example is unretouched, so I am now ( 3/29/2013, somewhere) on my way to the silly goal.
The prosody program neopro.pl automatically builds couplets, i.e. two lines segments besides the segments from cadences.
Very important:
for the couplet algorithm to work, enter
Couplets
{cada}
near the beginning
and
...
{+cada} {cadz}
near the end of every scene.
The couplets are only created between cadences, so these two are the minimum required.
The commands {cada}, {cadz} may stand on any lines that rhyme, or complete each other by sense ; when the melody is composed,
there will be "answering" phrases.
...
{+cadz}