You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I had been considering some techniques I had seen for constructing text that could be rearranged reasonably, and I noticed that one technique was to always split on the division between subject and predicate. (There was a spoken-word poetry album that did this, such that you could play the album on shuffle and get a meaningfully different story each time.)
I figured, you could do this on an existing full-text corpus in an automated way if you were conservative about where you split. The easiest way seemed to be to split on pronouns, performing splits and random rearrangements on different pronouns separately in order to preserve agreement. So, that's what I did.
Essentially, all this code does is perform a sequence of splits, shuffles, and merges -- one for each of he/she/it/I -- and then discards singletons/scraps. The result almost makes sense -- a better result than markov & phrasechain, probably. (I was considering combining this with phrasechain, and maybe in the future I will, but for now shuffles seem to be sufficient.)
The text was updated successfully, but these errors were encountered:
I had been considering some techniques I had seen for constructing text that could be rearranged reasonably, and I noticed that one technique was to always split on the division between subject and predicate. (There was a spoken-word poetry album that did this, such that you could play the album on shuffle and get a meaningfully different story each time.)
I figured, you could do this on an existing full-text corpus in an automated way if you were conservative about where you split. The easiest way seemed to be to split on pronouns, performing splits and random rearrangements on different pronouns separately in order to preserve agreement. So, that's what I did.
Resulting novel (based on Lovecraft): https://raw.githubusercontent.com/enkiv2/misc/master/nanogenmo-2016/lovecraft-split-on-pronouns.md
Code: https://github.com/enkiv2/misc/blob/master/nanogenmo-2016/split-on-pronouns.sh
Essentially, all this code does is perform a sequence of splits, shuffles, and merges -- one for each of he/she/it/I -- and then discards singletons/scraps. The result almost makes sense -- a better result than markov & phrasechain, probably. (I was considering combining this with phrasechain, and maybe in the future I will, but for now shuffles seem to be sufficient.)
The text was updated successfully, but these errors were encountered: