P.S.: Meso is live!

Woo-hoo! I got my mesostic generator up & running on Django at PythonAnywhere, and it does its thing. Rock that mesostic! 🙂

Here’s a sample, read through Django’s template language introduction with “Django” as the spine:

                      Document this
explains the language Just
        xml/html templAtes.
                     oNe more

                althouGh that has a
           special belOw.
                      Dot (.)
                    obJects
                    thAt
                dictioNary
                 throuGh
                     lOwer filter, which text
               “chaineD.” the output
                      Join
                      A list with
              list|joiN:", " }}. provides about thirty
                      Give

                     yOu

…hee, I like how it threw “chained” in there. Get it? 😛 Go on now, pull the other one–it has got bells on. Make your own mesostic here: P.S.: Meso.

Side-note: I am posting this in the middle of the night because I thought it was working four hours ago (and wrote the post up to this paragraph then), but apparently when you import a module, its global variables aren’t global for its functions anymore–if program X imports program Y, program X’s global variables are the only global variables, looks like. So I had to figure that out, which took a long time because I thought it was a problem with the textarea widget or Django forms in general, rather than a plain ‘ole Python noob error. Once I found the problem, two lines fixed it up. Shiny. Don’t worry if you didn’t follow that; I had to write it out for me.

Point being, it works! Go! Allez! Make poetic nonsense!

Advertisements

P.S.: Meso

…is the tentative, extremely dorky,* name of my mesostic generator, which now works!

It takes either a plain text file or pasted plain text as input; strips the punctuation if you tell it to; takes the seed (spine) text that you give it; asks how many times the spine should appear; and rocks your mesostic. 😀

The result is not exactly a true mesostic – which would use a word no more times than it appears in the source text – because it can repeat a word too many times if it has to loop back through. That happens more the shorter the source text is or the more times you repeat the spine. But on the plus side, as long as it can make a mesostic with one copy of the spine (plus the first letter again), it can make as many copies as you want! For now, I’ve set a limit of 20 copies, but I can easily increase that; it’s just in case some fool tries to run the thing a million times or something. 😉

The program also handles cases where it can’t create the full mesostic pretty gracefully – instead of just throwing a nasty error, it prints a message that says it couldn’t complete the request, then prints as much of the mesostic as it was able to make. Much nicer, right?

Now, if I can learn a bit of Django, I should be able to get the Python code working online — no JavaScript necessary (though I’d still like to rewrite it in that for my hosted site that doesn’t allow server-side code).

* “P.S.” stands for “poesis spinea” – which I hope is Latin for “spiny poetry.” You know, a poem with a spine. Bad, I know. Pretend I only meant “post-script” if you must. 😉

Beginnings of a mesostic generator

I may or may not be making good progress on a mesostic generator (I really need a good name for this thing, like the Mesostisaur or Poeticus mesosticii or…um, something even geekier…? 😛

I think my read function is good — it takes the text from a txt file and cleans it up nicely (it does remove punctuation; hyphens within words are ok, but anything between words gets stripped away).

But I don’t have a good idea how to test the other subfunctions individually, so I’m trying to do the whole thing and then give it a go. I’m trying to make it so that it loops back to the beginning if it hits the end of the oracle (source text) before it’s done. That may mean that words get used more than once, although hopefully they won’t be repeated excessively or in the same part of the mesostic every time.

It will also abort and print the partially completed mesostic if it can’t finish with the oracle, seed (spine), and number of iterations requested. I didn’t like that the mesostomatic just threw an error…not very polite, right? 😉

I should (fingers crossed) be able to get it printed as text in a way that you can just copy & paste it and have it look right as long as you’re in a monospace font.

This is all in Python; I have no idea how much of it I can do in JavaScript, even assuming I get this version going flawlessly. But there you go – some progress, and hope of a mesostic generator that takes plain text input instead of webpages, so you don’t get all the html tags mixed in to your “poem”!

Wunderkind Shelley

Do you know this poem?:

I met a traveller from an antique land
Who said: Two vast and trunkless legs of stone
Stand in the desert. Near them on the sand,
Half sunk, a shattered visage lies, whose frown
And wrinkled lip and sneer of cold command
Tell that its sculptor well those passions read
Which yet survive, stamped on these lifeless things,
The hand that mocked them and the heart that fed.
And on the pedestal these words appear:
‘My name is Ozymandias, King of Kings:
Look on my works, ye mighty, and despair!’
Nothing beside remains. Round the decay
Of that colossal wreck, boundless and bare,
The lone and level sands stretch far away.

Percy Bysshe Shelley, that is. I read it for a correspondence course in my senior year of high school, and I love it–brilliant, searingly ironic, beautifully lyric. I think I’ve posted it before – back when this blog was new and I posted a poem each Wednesday.

Did you know he also wrote this?:

Why do we admit design in any machine of human contrivance? Simply, because innumerable instances of machines having been contrived by human art are present to our mind, because we are acquainted with persons who could construct such machines; but if, having no previous knowledge of any artificial contrivance, we had accidentally found a watch upon the ground, we should have been justified in concluding that it was a thing of Nature, that it was a combination of matter with whose cause we were unacquainted, and that any attempt to account for the origin of its existence would be equally presumptuous and unsatisfactory.

and this?:

It is vain philosophy that supposes more causes than are exactly adequate to explain the phenomena of things.

You assert that the construction of the animal machine, the fitness of certain animals to certain situations, the connexion between the organs of perception and that which is perceived; the relation between every thing which exists, and that which tends to preserve it in its existence, imply design. It is manifest that if the eye could not see, nor the stomach digest, the human frame could not preserve its present mode of existence. It is equally certain, however, that the elements of its composition, if they did not exist in one form, must exist in another; and that the combinations which they would form, must so long as they endured, derive support for their peculiar mode of being from their fitness to the circumstances of their situation.

and this?:

That certain animals exist in certain climates, results from the consentaneity of their frames to the circumstances of their situation: let these circumstances be altered to a sufficient degree, and the elements of their composition must exist in some new combination no less resulting than the former from those inevitable laws by which the Universe is governed….

and this?:

If we found our belief in the existence of God on the universal consent of mankind, we are duped by the most palpable of sophisms. The word God cannot mean at the same time an ape, a snake, a bone, a calabash, a Trinity, and a Unity. Nor can that belief be accounted universal against which men of powerful intellect and spotless virtue have in every age protested….

Turns out he got expelled from Oxford for writing a tract advocating atheism, and wikipedia claims that publishers were afraid to print his writing, throughout his life, lest they be punished for it. Oh yeah, and Shelley wrote the work these quotes are from in 1814. He was a little ahead of the curve, you might say.

…Also, seriously? Shelley was arguing 200 years ago against the very same design arguments that are still trying to insinuate themselves into classrooms today? (sigh)

Meaning Is in the I (fourth ModPo essay)

(The week’s topic was aleatory, or chance, poetry. Bonus points if you recognize all of the hat-tips in the title; I intended three of them.)

  peW
    Announces
   oNly
  baD
wintEr
  woRd
    Is
 sceNes
    Gasp

Here I have created a mesostic using the seed word “wandering” with Rae Armantrout’s “The Way”* as my oracle. I chose this combination because I would describe my own mind as peregrine, and “wandering” links that with the shifting “I” in Armantrout’s poem. I didn’t want to add deliberate meaning to the experiment, so this is the unedited result from the mesostomatic.

The resulting grammar is unconventional but not nonsensical. “Pew announces only bad winter” reads like the clipped syntax of news headlines – a bad winter is the only forecast we get from the pew. And “word is scenes gasp,” with a comma after “is,” acquires a conversational tone; “scenes gasp” could indicate the bad winter – a season of “scenes” where everything holds its breath, waiting for the spring. We could even read “pew” as the research group, suggesting a prediction of a chilly post-election civil/political climate.

More interesting than a particular meaning is that we can find meaning at all in a poem that came about through a pseudorandom, deterministic process where no specific meaning could have been intended. This reminds us what pattern detectors we humans are – we seek patterns and meaning everywhere, so much so that we often see them where they aren’t (both for good reason, ask any evolutionist). Finding meaning in chance poems shows that this applies to language as much as anything else, and it also invites us to ask what meaning really is.

Douglas Hofstadter wrote in Gödel, Escher, Bach that “meaning is an automatic by-product of our recognition of any isomorphism.” A heady statement, but he was discussing the way that no message comes through as uncoded, pure meaning (e.g., this essay is coded in English); an isomorphism is a relationship between two things, “mapping” one onto the other (like a translation). Meaning happens when you make the connection between them. There are all kinds of things (objects, ideas, experiences) that bear a relationship to each other without anyone intending it. The “code” of chance poems may not be organized and deliberate, but if something in it makes sense to you, then you’ve recognized a relationship – meaning has happened. In this sense, chance poems have whatever meaning their readers find in them.

But I think it’s more than that. That they have whatever meaning readers find is itself a (meta) meaning of the chance poem – the fact that meaning belongs to each person who encounters the poem. In a traditional poem, the poet tries to control what meaning the reader sees, but if the readers don’t recognize the intended meaning in it, it’s unsuccessful; that meaning isn’t there. The fact that language is such that it can so often be non-intentionally arranged into something that seems meaningful and, conversely, that we are such that we can find meaning in such arrangements of words may be another meaning.

Finally, there are the questions themselves: what does this mean? how do I find meaning in this noise? if something non-intentional can have meaning, then what is meaning?

We are all too familiar with these questions in another context: faced with the claim that the universe and life and we came about through non-intentional, deterministic processes, the religious ask, “Then what’s the point? What value or meaning can there be in life if everything exists by coincidence?” Atheists seem to have little trouble finding these things. Indeed, many exclaim that it is all the more wonderful that there is such order and complexity in the universe, and that we are here, if no one has been there deliberately making it so. And it is up to us to determine or create meaning in our lives.

Some people will find meaning in chance poems; some will not. Either way, art demands we look at its objects in new ways, and here, the object most in question is meaning itself.

* Read Armantrout’s poem here, and find a PoemTalk discussion of it here. We read this in the second week of the course, when we saw a variety of Dickinsonian and Whitmanian poets (she is Dickinsonian).