poefy 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +74 -0
- data/.rspec +2 -0
- data/Gemfile +2 -0
- data/LICENSE +13 -0
- data/README.md +522 -0
- data/Rakefile +6 -0
- data/bin/poefy +205 -0
- data/data/emily_dickinson.txt +9942 -0
- data/data/english_as_she_is_spoke.txt +647 -0
- data/data/shakespeare_sonnets.txt +2618 -0
- data/data/spec_test_tiny.txt +12 -0
- data/data/st_therese_of_lisieux.txt +3700 -0
- data/data/whitman_leaves.txt +17815 -0
- data/lib/poefy/conditional_satisfaction.rb +208 -0
- data/lib/poefy/database.rb +252 -0
- data/lib/poefy/generation.rb +268 -0
- data/lib/poefy/handle_error.rb +27 -0
- data/lib/poefy/poefy_gen_base.rb +124 -0
- data/lib/poefy/poetic_forms.rb +330 -0
- data/lib/poefy/self.rb +21 -0
- data/lib/poefy/string_manipulation.rb +81 -0
- data/lib/poefy/version.rb +29 -0
- data/lib/poefy.rb +49 -0
- data/poefy.gemspec +33 -0
- data/spec/poefy_spec.rb +464 -0
- data/spec/spec_helper.rb +9 -0
- metadata +175 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 42c9b9aed17a520bca45c074ceb06f6e797dd082
|
4
|
+
data.tar.gz: 3920e82bb6324eaf83f61091602e3c2398db4d42
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: be56e85cacb37a40c48995c7f032f1f5d12c396a69f317db12a17e401bcde8d3bbcc1f37c375aebf3b7e2aa164184d40c12e6d8481ff4ff70a634ab0bbf67e59
|
7
|
+
data.tar.gz: 6508356de1969dcfafa22b3f141f280c23c872bc9ca89ba4d9f066fb68981e24232d592cc412e593243489256b1265eb3e2347f47cf04b97009ba0676adb5ceb
|
data/.gitignore
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
|
2
|
+
################################################################################
|
3
|
+
# Ruby specific files
|
4
|
+
|
5
|
+
*.gem
|
6
|
+
*.rbc
|
7
|
+
/.config
|
8
|
+
/coverage/
|
9
|
+
/InstalledFiles
|
10
|
+
/pkg/
|
11
|
+
/spec/reports/
|
12
|
+
/test/tmp/
|
13
|
+
/test/version_tmp/
|
14
|
+
/tmp/
|
15
|
+
|
16
|
+
## Specific to RubyMotion:
|
17
|
+
.dat*
|
18
|
+
.repl_history
|
19
|
+
build/
|
20
|
+
|
21
|
+
## Documentation cache and generated files:
|
22
|
+
/.yardoc/
|
23
|
+
/_yardoc/
|
24
|
+
/doc/
|
25
|
+
/rdoc/
|
26
|
+
|
27
|
+
## Environment normalisation:
|
28
|
+
/.bundle/
|
29
|
+
/vendor/bundle
|
30
|
+
/lib/bundler/man/
|
31
|
+
|
32
|
+
# for a library or gem, you might want to ignore these files since the code is
|
33
|
+
# intended to run in multiple environments; otherwise, check them in:
|
34
|
+
Gemfile.lock
|
35
|
+
.ruby-version
|
36
|
+
.ruby-gemset
|
37
|
+
|
38
|
+
# unless supporting rvm < 1.11.0 or doing something fancy, ignore this:
|
39
|
+
.rvmrc
|
40
|
+
|
41
|
+
################################################################################
|
42
|
+
# Rails stuff
|
43
|
+
|
44
|
+
# Ignore all logfiles and tempfiles.
|
45
|
+
/log/*
|
46
|
+
/tmp/*
|
47
|
+
!/log/.keep
|
48
|
+
!/tmp/.keep
|
49
|
+
|
50
|
+
# Ignore Byebug command history file.
|
51
|
+
.byebug_history
|
52
|
+
|
53
|
+
# Ignore application configuration
|
54
|
+
/config/application.yml
|
55
|
+
|
56
|
+
################################################################################
|
57
|
+
# System and config files
|
58
|
+
desktop.ini
|
59
|
+
.agignore
|
60
|
+
.ignore
|
61
|
+
*.lnk
|
62
|
+
|
63
|
+
################################################################################
|
64
|
+
# App specific files
|
65
|
+
|
66
|
+
# Development files
|
67
|
+
work*.rb
|
68
|
+
/~/
|
69
|
+
|
70
|
+
# Data files
|
71
|
+
/data/
|
72
|
+
|
73
|
+
# Output files
|
74
|
+
/output/
|
data/.rspec
ADDED
data/Gemfile
ADDED
data/LICENSE
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
Copyright (C) 2017 Paul Thompson
|
2
|
+
|
3
|
+
This program is free software: you can redistribute it and/or modify
|
4
|
+
it under the terms of the GNU General Public License as published by
|
5
|
+
the Free Software Foundation, either version 3 of the License, or
|
6
|
+
(at your option) any later version.
|
7
|
+
|
8
|
+
This program is distributed in the hope that it will be useful,
|
9
|
+
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
10
|
+
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
11
|
+
GNU General Public License for more details.
|
12
|
+
|
13
|
+
Full text of this licence: <https://www.gnu.org/licenses/gpl.html>.
|
data/README.md
ADDED
@@ -0,0 +1,522 @@
|
|
1
|
+
# Poefy
|
2
|
+
|
3
|
+
by [Paul Thompson](https://tilde.town/~nossidge) - nossidge@gmail.com
|
4
|
+
|
5
|
+
Create poems from an input text file, by generating and querying a SQLite database that describes each line.
|
6
|
+
|
7
|
+
Poems are created using a template to select lines from the database, according to closing rhyme, syllable count, and regex matching.
|
8
|
+
|
9
|
+
I wrote this because I was banging my head against a wall trying to use [Tracery](https://github.com/galaxykate/tracery) to generate villanelles. Then I remembered that I know how to program computers. Lucky!
|
10
|
+
|
11
|
+
|
12
|
+
## Installation
|
13
|
+
|
14
|
+
Add this line to your application's Gemfile:
|
15
|
+
|
16
|
+
```ruby
|
17
|
+
gem 'poefy'
|
18
|
+
```
|
19
|
+
|
20
|
+
And then execute:
|
21
|
+
|
22
|
+
$ bundle
|
23
|
+
|
24
|
+
Or install it yourself as:
|
25
|
+
|
26
|
+
$ gem install poefy
|
27
|
+
|
28
|
+
The repo comes with some text files included. To generate databases for these files, execute special `make_dbs` command:
|
29
|
+
|
30
|
+
$ poefy make_dbs
|
31
|
+
|
32
|
+
The code rather hackily uses system to call `sqlite3`, so make sure you have that installed and in your PATH.
|
33
|
+
|
34
|
+
|
35
|
+
## Usage
|
36
|
+
|
37
|
+
### From the Command Line
|
38
|
+
|
39
|
+
Make a poefy database from a text file:
|
40
|
+
|
41
|
+
$ poefy shakespeare < shakespeare_sonnets.txt
|
42
|
+
|
43
|
+
Now, whenever you want to make poems using Shakespeare's lines, you can just use `poefy shakespeare` and it will read from the already created database:
|
44
|
+
|
45
|
+
$ poefy shakespeare sonnet
|
46
|
+
$ poefy shakespeare limerick
|
47
|
+
$ poefy shakespeare.db villanelle
|
48
|
+
|
49
|
+
The file extension `.db` is assumed for all databases. You can leave it out if you want.
|
50
|
+
|
51
|
+
If you later want to remake the database, for example to add new lines, you can use the `-o` option and the existing database will be overwritten.
|
52
|
+
|
53
|
+
$ cat shakespeare_sonnets.txt shakespeare_plays.txt | poefy shakespeare -o
|
54
|
+
|
55
|
+
This database is stored in the same directory as the gem, so it can be accessed by all users on your system. To store a database in a different directory, you can use the `-l` or `--local` option:
|
56
|
+
|
57
|
+
$ poefy -l path/to/eliot.db < eliot.txt
|
58
|
+
|
59
|
+
You then need to use the `-l` option when generating poems:
|
60
|
+
|
61
|
+
$ poefy -l path/to/eliot.db rondeau
|
62
|
+
$ poefy -l path/to/eliot ballade
|
63
|
+
$ cd path/to
|
64
|
+
$ poefy -l eliot.db ballata
|
65
|
+
|
66
|
+
You can use the `-h` or `--help` option to view available databases.
|
67
|
+
|
68
|
+
|
69
|
+
#### Option `-f` or `--form`
|
70
|
+
|
71
|
+
The `-f` option is used to specify a chosen poetic form, which sets the rhyme, syllable, and/or indent options to a predefined setting.
|
72
|
+
|
73
|
+
The option switch is not mandatory; if not specified the second argument will be used. The below examples are identical:
|
74
|
+
|
75
|
+
$ poefy shakespeare sonnet
|
76
|
+
$ poefy shakespeare -f sonnet
|
77
|
+
|
78
|
+
For forms where the syllables are constant through the poem, the syllable has not been specified. This is so you can use the `-s` option to set this. Syllables are only specified in forms where the syllable is a major factor of the form. At the moment these are: limerick, haiku, common, ballad.
|
79
|
+
|
80
|
+
To view and amend these definitions, the code is in `lib/poefy/poetic_forms.rb`. Some examples:
|
81
|
+
|
82
|
+
```ruby
|
83
|
+
{
|
84
|
+
sonnet: {
|
85
|
+
rhyme: 'ababcdcdefefgg',
|
86
|
+
indent: '',
|
87
|
+
syllable: ''
|
88
|
+
},
|
89
|
+
villanelle: {
|
90
|
+
rhyme: 'A1bA2 abA1 abA2 abA1 abA2 abA1A2',
|
91
|
+
indent: '010 001 001 001 001 0011',
|
92
|
+
syllable: ''
|
93
|
+
},
|
94
|
+
haiku: {
|
95
|
+
rhyme: 'abc',
|
96
|
+
indent: '',
|
97
|
+
syllable: '[5,7,5]'
|
98
|
+
},
|
99
|
+
limerick: {
|
100
|
+
rhyme: 'aabba',
|
101
|
+
indent: '',
|
102
|
+
syllable: '{1:[8],2:[8],3:[4,5],4:[4,5],5:[8]}'
|
103
|
+
}
|
104
|
+
}
|
105
|
+
```
|
106
|
+
|
107
|
+
You can use the `-h` or `--help` option to view available forms.
|
108
|
+
|
109
|
+
|
110
|
+
#### Option `-r` or `--rhyme`
|
111
|
+
|
112
|
+
Specifies a rhyme structure that the poem must follow. This is the most important argument; the whole poem is based on this.
|
113
|
+
|
114
|
+
Each token in the rhyme string represents a line in the poem. Letters indicate rhymes, so all 'a' or 'A' lines have the same rhyme. Example, sonnet:
|
115
|
+
|
116
|
+
$ poefy whitman -r'ababcdcdefefgg'
|
117
|
+
|
118
|
+
Uppercase letter lines will be duplicated exactly. This is used to create refrain lines. Example, rondeau:
|
119
|
+
|
120
|
+
$ poefy whitman -r'aabba aabC aabbaC'
|
121
|
+
|
122
|
+
Numbers after a capital letter indicate which specific line to repeat. This is so you can have repeated lines that use the same rhyme scheme. Example, villanelle:
|
123
|
+
|
124
|
+
$ poefy whitman -r'A1bA2 abA1 abA2 abA1 abA2 abA1A2'
|
125
|
+
|
126
|
+
|
127
|
+
#### Option `-i` or `--indent`
|
128
|
+
|
129
|
+
Indent each line by a certain number of spaces. Examples:
|
130
|
+
|
131
|
+
$ poefy shakespeare sonnet -i'01010101010101'
|
132
|
+
$ poefy shakespeare -r'abcba abcdcba' -i'01210 0123210'
|
133
|
+
$ poefy shakespeare ballade -i'00000001 00000001 00000001 0001'
|
134
|
+
|
135
|
+
Use zero `-i0` to specify no indentation.
|
136
|
+
|
137
|
+
|
138
|
+
#### Option `-s` or `--syllable`
|
139
|
+
|
140
|
+
Specify syllable count allowed for each line. There's a few valid forms it can take.
|
141
|
+
|
142
|
+
If the string is just one number, all lines will be that number of syllables long.
|
143
|
+
|
144
|
+
$ poefy whitman -s'10'
|
145
|
+
|
146
|
+
If the string is comma delimited, all lines will be any of those numbers of syllables long.
|
147
|
+
|
148
|
+
$ poefy whitman -s'9,10,11'
|
149
|
+
|
150
|
+
If the string is an array, each element corresponds to a line in the output. This will skip blank lines.
|
151
|
+
|
152
|
+
Both of the below will generate limericks, with the second more permissive than the first.
|
153
|
+
|
154
|
+
$ poefy whitman -r'aabba' -s'[8,8,5,5,8]'
|
155
|
+
$ poefy whitman -r'aabba' -s'[[8,9],[8,9],[4,5,6],[4,5,6],[8,9]]'
|
156
|
+
|
157
|
+
If the string is a hash, the key will be used to match the line number.
|
158
|
+
|
159
|
+
$ poefy whitman -r'aabba' -s'{1:8,2:8,3:5,4:5,5:8}'
|
160
|
+
$ poefy whitman -r'aabba' -s'{1:[8,9],2:[8,9],3:[4,5,6],4:[4,5,6],5:[8,9]}'
|
161
|
+
$ poefy whitman -r'aabba' -s'{0:[8,9],3:[4,5,6],4:[4,5,6]}'
|
162
|
+
|
163
|
+
In the hash form, any lines not explicitly specified will use the value of the '0' key. If there is no '0' key, the lines will be ignored.
|
164
|
+
|
165
|
+
The below example will have 8 syllables for the first and fifth lines, but any number for the rest.
|
166
|
+
|
167
|
+
$ poefy whitman -r'aabba' -s'{1:8,5:8}'
|
168
|
+
|
169
|
+
The key of the hash can take the form of negative numbers. In that case, they will refer to lines from the end of the poem. Any duplicated keys will be overwritten by the latest one.
|
170
|
+
|
171
|
+
$ poefy whitman -r'aabba' -s'{1:8,2:8,3:5,-2:5,-1:8}'
|
172
|
+
|
173
|
+
Use zero `-s0` to specify no syllable matching.
|
174
|
+
|
175
|
+
|
176
|
+
#### Option `-x` or `--regex`
|
177
|
+
|
178
|
+
Specify a regular expression for lines to follow.
|
179
|
+
|
180
|
+
If the string is just one regex, all lines will be forced to match that regex.
|
181
|
+
|
182
|
+
$ poefy whitman sonnet -x'^[A-Z].*$'
|
183
|
+
$ poefy whitman sonnet -x'^[^e]*$' -s0
|
184
|
+
|
185
|
+
If the string is a hash, the key will be used to match the line number. Unlike in the `syllable` string, you must use ruby's `=>` key identifier. Also, you must put the regex inside `/slashes/`.
|
186
|
+
|
187
|
+
Example, to ensure the first line always starts with capitalisation:
|
188
|
+
|
189
|
+
$ poefy whitman sonnet -x'{1=>/^[A-Z].*$/}'
|
190
|
+
|
191
|
+
Use a space `-x' '` to specify no regex matching.
|
192
|
+
|
193
|
+
|
194
|
+
#### Option `-a` or `--acrostic`
|
195
|
+
|
196
|
+
Since there's a regular expression matcher it's pretty trivial to use it to generate acrostics. This option just creates regexes for the first character of each line, either upper or lowercase. Works best if you remove any indentation of lines.
|
197
|
+
|
198
|
+
They need to include spaces where blank lines would normally go, for example a Petrarchan with rhyme 'abba abba cde cde':
|
199
|
+
|
200
|
+
$ poefy therese -r'abba abba cde cde' -i0 -a'stop that fat cat' -s10
|
201
|
+
$ poefy whitman -r'abba abba cde cde' -i0 -a'such good bum fun'
|
202
|
+
|
203
|
+
You must also beware of repeated lines (uppercase letters in the rhyme string). For example, a rondeau uses the rhyme form 'aabba aabR aabbaR', so the acrostic needs to have the same letter for both 'R' repeated lines.
|
204
|
+
|
205
|
+
$ poefy therese rondeau -a'grown ever softer'
|
206
|
+
|
207
|
+
|
208
|
+
#### Option `-p` or `--proper`
|
209
|
+
|
210
|
+
This is used to ensure that the first word in the first line is not 'and but or nor yet', and the final line ends with closing punctuation (full stop, exclamation, or question mark). The default for this is `true`, but you can set it to `false` if necessary, for example if your input lines do not use punctuation.
|
211
|
+
|
212
|
+
To clarify: using the `-p` or `--proper` option will DISABLE this functionality.
|
213
|
+
|
214
|
+
|
215
|
+
#### Special case: `rhyme` command
|
216
|
+
|
217
|
+
If the second argument is `rhyme`, then output all lines that rhyme with the word.
|
218
|
+
|
219
|
+
This gives a basic look into the database contents.
|
220
|
+
|
221
|
+
````
|
222
|
+
$ poefy dickinson rhyme confuse
|
223
|
+
{"rhyme"=>"7d", "final_word"=>"choose", "syllables"=>6, "line"=>"As if for you to choose,"}
|
224
|
+
{"rhyme"=>"7d", "final_word"=>"dews", "syllables"=>6, "line"=>"The debauchee of dews!"}
|
225
|
+
{"rhyme"=>"7d", "final_word"=>"dews", "syllables"=>9, "line"=>"Like flowers that heard the tale of dews,"}
|
226
|
+
{"rhyme"=>"7d", "final_word"=>"hues", "syllables"=>6, "line"=>"Of independent hues,"}
|
227
|
+
{"rhyme"=>"7d", "final_word"=>"news", "syllables"=>8, "line"=>"The intuition of the news"}
|
228
|
+
{"rhyme"=>"7d", "final_word"=>"screws", "syllables"=>6, "line"=>"It is the gift of screws."}
|
229
|
+
{"rhyme"=>"7d", "final_word"=>"shoes", "syllables"=>8, "line"=>"Upon my ankle, -- then my shoes"}
|
230
|
+
````
|
231
|
+
|
232
|
+
You can select just the lines by using the hash key `line`:
|
233
|
+
|
234
|
+
````
|
235
|
+
$ poefy dickinson rhyme confuse line
|
236
|
+
As if for you to choose,
|
237
|
+
The debauchee of dews!
|
238
|
+
Like flowers that heard the tale of dews,
|
239
|
+
Of independent hues,
|
240
|
+
The intuition of the news
|
241
|
+
It is the gift of screws.
|
242
|
+
Upon my ankle, -- then my shoes
|
243
|
+
````
|
244
|
+
|
245
|
+
You can do the same thing for the other keys: `rhyme`, `final_word`, and `syllables`.
|
246
|
+
|
247
|
+
|
248
|
+
### As a Ruby Gem
|
249
|
+
|
250
|
+
To make a poefy database and generate poems from it:
|
251
|
+
|
252
|
+
```ruby
|
253
|
+
require 'poefy'
|
254
|
+
poefy = Poefy::PoefyGen.new('shakespeare')
|
255
|
+
poefy.make_database('shakespeare_sonnets.txt')
|
256
|
+
```
|
257
|
+
|
258
|
+
`make_database` will accept a filename string, an array of lines, or a long string delimited by newlines.
|
259
|
+
|
260
|
+
You only have to make the database once. And then to generate poems:
|
261
|
+
|
262
|
+
```ruby
|
263
|
+
# Different ways to generate sonnets
|
264
|
+
poefy = Poefy::PoefyGen.new('shakespeare')
|
265
|
+
puts poefy.poem ({ rhyme: 'ababcdcdefefgg' })
|
266
|
+
puts poefy.poem ({ rhyme: 'abab cdcd efef gg', indent: '0101 0101 0011 01' })
|
267
|
+
puts poefy.poem ({ form: 'sonnet' })
|
268
|
+
puts poefy.poem ({ form: :sonnet, syllable: 0 })
|
269
|
+
puts poefy.poem ({ form: :sonnet, syllable: 10 })
|
270
|
+
puts poefy.poem ({ form: :sonnet, regex: poefy.acrostic('pauldpthompson') })
|
271
|
+
puts poefy.poem ({ form: 'sonnet', indent: '01010101001101' })
|
272
|
+
puts poefy.poem ({ form: 'sonnet', proper: false })
|
273
|
+
```
|
274
|
+
|
275
|
+
All options can be specified at object initialisation, and subsequent poems will use those options as default:
|
276
|
+
|
277
|
+
```ruby
|
278
|
+
# Default to use rondeau poetic form, and proper sentence validation
|
279
|
+
poefy = Poefy::PoefyGen.new('shakespeare', { form: 'rondeau', proper: true })
|
280
|
+
|
281
|
+
# Generate a properly sentenced rondeau
|
282
|
+
puts poefy.poem
|
283
|
+
|
284
|
+
# Generate a rondeau without proper validation
|
285
|
+
puts poefy.poem ({ proper: false })
|
286
|
+
|
287
|
+
# Generate a proper rondeau with a certain indentation
|
288
|
+
puts poefy.poem ({ indent: '01012 0012 010112' })
|
289
|
+
```
|
290
|
+
|
291
|
+
|
292
|
+
## Some tips
|
293
|
+
|
294
|
+
### Make a database from a delimited file
|
295
|
+
|
296
|
+
Databases are created using data piped into poefy, so you can do any pre-processing before piping.
|
297
|
+
|
298
|
+
Use awk to get final field from tab delimited IRC logs.
|
299
|
+
|
300
|
+
$ awk -F$'\t' '{print $NF}' irc_log_20170413.txt | poefy -o irc
|
301
|
+
|
302
|
+
|
303
|
+
### Make a database, ignoring short lines
|
304
|
+
|
305
|
+
Use sed to filter out lines that are too short:
|
306
|
+
|
307
|
+
$ sed -r '/^.{,20}$/d' st_therese_of_lisieux.txt | poefy -o therese
|
308
|
+
|
309
|
+
|
310
|
+
### Make a database, ignoring uppercase lines
|
311
|
+
|
312
|
+
Use sed to filter out lines that only contain uppercase lines:
|
313
|
+
|
314
|
+
$ sed -r 'sed '/[a-z]/!d' shakespeare_sonnets.txt | poefy -o shakespeare
|
315
|
+
|
316
|
+
|
317
|
+
### Problem: it won't output lines that I know are valid
|
318
|
+
|
319
|
+
This code uses a gem called `wordfilter` that will automatically filter out lines that contain [grotty words](https://github.com/dariusk/wordfilter/blob/master/lib/badwords.json). If you really definitely truly don't want to exclude a certain word, you can remove them from the blacklist. For example, if your input lines are from a dissertation on the dance styles of the ska and reggae music scenes, you can call:
|
320
|
+
|
321
|
+
```ruby
|
322
|
+
Wordfilter.remove_word('skank')
|
323
|
+
```
|
324
|
+
|
325
|
+
|
326
|
+
### Problem: no seriously, it just won't work.
|
327
|
+
|
328
|
+
Remember that the `proper` option is `true` by default. Maybe try setting this to `false` with the `-p` option?
|
329
|
+
|
330
|
+
|
331
|
+
## Sample output
|
332
|
+
|
333
|
+
### William Shakespeare, villanelle
|
334
|
+
|
335
|
+
$ poefy shakespeare villanelle
|
336
|
+
|
337
|
+
````
|
338
|
+
How many a holy and obsequious tear
|
339
|
+
Whilst many nymphs that vowed chaste life to keep
|
340
|
+
From thee, the pleasure of the fleeting year!
|
341
|
+
|
342
|
+
For truth proves thievish for a prize so dear.
|
343
|
+
And his love-kindling fire did quickly steep
|
344
|
+
How many a holy and obsequious tear
|
345
|
+
|
346
|
+
If thy soul check thee that I come so near,
|
347
|
+
Cupid laid by his brand and fell asleep:
|
348
|
+
From thee, the pleasure of the fleeting year!
|
349
|
+
|
350
|
+
Not making worse what nature made so clear,
|
351
|
+
Whilst my poor lips which should that harvest reap,
|
352
|
+
How many a holy and obsequious tear
|
353
|
+
|
354
|
+
Or, if they sing, 'tis with so dull a cheer,
|
355
|
+
Do I envy those jacks that nimble leap,
|
356
|
+
From thee, the pleasure of the fleeting year!
|
357
|
+
|
358
|
+
And even thence thou wilt be stol'n I fear,
|
359
|
+
The world will be thy widow and still weep
|
360
|
+
How many a holy and obsequious tear
|
361
|
+
From thee, the pleasure of the fleeting year!
|
362
|
+
````
|
363
|
+
|
364
|
+
|
365
|
+
### Emily Dickinson, ballads
|
366
|
+
|
367
|
+
$ poefy dickinson ballad
|
368
|
+
|
369
|
+
````
|
370
|
+
Enlarged beyond my utmost scope,
|
371
|
+
It waits upon the lawn;
|
372
|
+
A purple finger on the slope;
|
373
|
+
It wrinkled, and was gone.
|
374
|
+
|
375
|
+
Wisdom is more becoming viewed
|
376
|
+
And yet with amber hands
|
377
|
+
I taste a liquor never brewed,
|
378
|
+
Bound to opposing lands.
|
379
|
+
|
380
|
+
Confided are his projects pink
|
381
|
+
To say good-by to men.
|
382
|
+
And blushing birds go down to drink,
|
383
|
+
Unto the east again.
|
384
|
+
|
385
|
+
You, unsuspecting, wear me too --
|
386
|
+
And yet abide the world!
|
387
|
+
Whose garden wrestles with the dew,
|
388
|
+
The flying tidings whirled.
|
389
|
+
|
390
|
+
We never know how high we are
|
391
|
+
I could not die with you,
|
392
|
+
Past midnight, past the morning star!
|
393
|
+
That maketh all things new.
|
394
|
+
````
|
395
|
+
|
396
|
+
|
397
|
+
### Walt Whitman, Petrarchan sonnet
|
398
|
+
|
399
|
+
$ poefy whitman petrarchan
|
400
|
+
|
401
|
+
````
|
402
|
+
I see the seal-seeker in his boat poising his lance,
|
403
|
+
I am of the same style, for I am their friend,
|
404
|
+
We the youthful sinewy races, all the rest on us depend,
|
405
|
+
Away with old romance!
|
406
|
+
|
407
|
+
O something unprov'd! something in a trance!
|
408
|
+
Listen, lose not, it is toward thee they tend,
|
409
|
+
But I do not talk of the beginning or the end.
|
410
|
+
And the dead advance as much as the living advance,
|
411
|
+
|
412
|
+
I am a dance--play up there! the fit is whirling me fast!
|
413
|
+
I am the credulous man of qualities, ages, races,
|
414
|
+
From the chants of the feudal world, the triumphs of kings, slavery, caste,
|
415
|
+
|
416
|
+
Garrulous to the very last.
|
417
|
+
An old man bending I come among new faces,
|
418
|
+
To justify the past.
|
419
|
+
````
|
420
|
+
|
421
|
+
|
422
|
+
### English As She Is Spoke, haikus
|
423
|
+
|
424
|
+
$ poefy spoke haiku
|
425
|
+
|
426
|
+
````
|
427
|
+
What I may to eat?
|
428
|
+
Vegetables boiled to a pap
|
429
|
+
It is excellent.
|
430
|
+
|
431
|
+
Go through that meadow.
|
432
|
+
I am going to Cadiz.
|
433
|
+
With a inn keeper.
|
434
|
+
|
435
|
+
The gossip mistress
|
436
|
+
You not make who to babble.
|
437
|
+
You interompt me.
|
438
|
+
|
439
|
+
The fat of the Leg
|
440
|
+
This girl have a beauty edge.
|
441
|
+
You shall catch cold one's.
|
442
|
+
|
443
|
+
How the times are changed!
|
444
|
+
We have sung, danced, laugh and played.
|
445
|
+
The curtains let down.
|
446
|
+
````
|
447
|
+
|
448
|
+
|
449
|
+
### St. Therese of Lisieux, villanelle
|
450
|
+
|
451
|
+
$ poefy therese villanelle
|
452
|
+
|
453
|
+
````
|
454
|
+
I shall behold Thy lovely Face once more,
|
455
|
+
And, oh! remember thou thy "little queen," --
|
456
|
+
Joy seems on us to pour.
|
457
|
+
|
458
|
+
Remember Thou that on my native shore,
|
459
|
+
With Him for Guide, the fight I face serene;
|
460
|
+
I shall behold Thy lovely Face once more,
|
461
|
+
|
462
|
+
And for His grace alone implore;
|
463
|
+
And murmuring a prayer for her, "thy queen,"
|
464
|
+
Joy seems on us to pour.
|
465
|
+
|
466
|
+
I come with comfort for sad hearts and sore.
|
467
|
+
Remember thou thy faithful child, Celine,
|
468
|
+
I shall behold Thy lovely Face once more,
|
469
|
+
|
470
|
+
Then angel-hands shall ope the door;
|
471
|
+
Beside her King shall yet be seen.
|
472
|
+
Joy seems on us to pour.
|
473
|
+
|
474
|
+
Comes to my ear sin's wild and blasphemous roar;
|
475
|
+
Remember thou that on the terrace green
|
476
|
+
I shall behold Thy lovely Face once more,
|
477
|
+
Joy seems on us to pour.
|
478
|
+
````
|
479
|
+
|
480
|
+
|
481
|
+
### Walt Whitman, lipogram sonnet on 'e'
|
482
|
+
|
483
|
+
$ poefy whitman sonnet -x'^[^e]*$'
|
484
|
+
|
485
|
+
````
|
486
|
+
Land! land! O land!
|
487
|
+
Boston bay.
|
488
|
+
bright sword in thy hand,
|
489
|
+
on our way?
|
490
|
+
many a star at night,
|
491
|
+
stand fast;)
|
492
|
+
plain sight,
|
493
|
+
In full rapport at last.
|
494
|
+
I wait for a boat,
|
495
|
+
musical rain,
|
496
|
+
ribs and throat,
|
497
|
+
thousands slain,
|
498
|
+
walk hand in hand.
|
499
|
+
Of city for city and land for land.
|
500
|
+
````
|
501
|
+
|
502
|
+
|
503
|
+
### William Shakespeare, acrostic sonnet
|
504
|
+
|
505
|
+
$ poefy shakespeare sonnet -s10 -a'pauldpthompson'
|
506
|
+
|
507
|
+
````
|
508
|
+
Pitiful thrivers, in their gazing spent?
|
509
|
+
And such a counterpart shall fame his wit,
|
510
|
+
Under the blow of thralled discontent,
|
511
|
+
Let him but copy what in you is writ,
|
512
|
+
Death's second self, that seals up all in rest.
|
513
|
+
Past reason hated, as a swallowed bait,
|
514
|
+
Then, in the blazon of sweet beauty's best,
|
515
|
+
Haply I think on thee, and then my state,
|
516
|
+
One blushing shame, another white despair;
|
517
|
+
My heart doth plead that thou in him dost lie,
|
518
|
+
Past cure I am, now Reason is past care,
|
519
|
+
She carved thee for her seal, and meant thereby,
|
520
|
+
Oh sure I am the wits of former days,
|
521
|
+
Nor gates of steel so strong but Time decays?
|
522
|
+
````
|