diff --git a/web/README_WGU.org b/web/README_WGU.org index 55142d1..0409538 100644 --- a/web/README_WGU.org +++ b/web/README_WGU.org @@ -812,10 +812,25 @@ With this precaution in place, attackers will not be able to snoop the content t - Script to auto-update SSL cert -** TODO A User-Friendly, Functional Dashboard That Includes At Least Three Visualization Types +** A User-Friendly, Functional Dashboard That Includes At Least Three Visualization Types -- oz graph of perplexity/rhyme quality -- tables (sortable?) +You can access an example of the user interface at https://darklimericks.com/wgu. + +You'll see 3 input fields. + +The first input field is for a word or phrase for which you wish to find a rhyme. Submitting that field will return three visualizations to help you pick a rhyme. + +The first visualization is a scatter plot of rhyming words with the "quality" of the rhyme on the Y axis and the number of times that rhyming word/phrase occurrs in the training corpus on the X axis. + +[[file:resources/images/wgu-vis.png]] + +The second visualization is a word cloud where the size of each word is based on the frequency with which the word appears in the training corpus. + +[[file:resources/images/wgu-vis-cloud.png]] + +The third visualization is a table that lists all of the rhymes, their pronunciations, the rhyme quality, and the frequency. The table is sorted first by the rhyme quality then by the frequency. + +[[file:resources/images/wgu-vis-table.png]] * D. Documentation :PROPERTIES: diff --git a/web/resources/images/wgu-vis-cloud.png b/web/resources/images/wgu-vis-cloud.png new file mode 100644 index 0000000..3e929ab Binary files /dev/null and b/web/resources/images/wgu-vis-cloud.png differ diff --git a/web/resources/images/wgu-vis-table.png b/web/resources/images/wgu-vis-table.png new file mode 100644 index 0000000..730e210 Binary files /dev/null and b/web/resources/images/wgu-vis-table.png differ diff --git a/web/resources/images/wgu-vis.png b/web/resources/images/wgu-vis.png new file mode 100644 index 0000000..81c6616 Binary files /dev/null and b/web/resources/images/wgu-vis.png differ diff --git a/web/src/com/darklimericks/server/handlers.clj b/web/src/com/darklimericks/server/handlers.clj index 7bd1589..ef8b0b4 100644 --- a/web/src/com/darklimericks/server/handlers.clj +++ b/web/src/com/darklimericks/server/handlers.clj @@ -48,8 +48,8 @@ artists-by-album))}))) (def resource-handler (ring/create-resource-handler {:allow-symlinks? true})) -(def file-handler (ring/create-file-handler {:allow-symlinks? true - :root "resources/public"})) +(def file-handler (ring/create-resource-handler {:allow-symlinks? true + :root "public"})) (defn limerick-generation-post-handler [db cache] diff --git a/web/src/com/darklimericks/server/views.clj b/web/src/com/darklimericks/server/views.clj index 7b1ae51..fa50f0f 100644 --- a/web/src/com/darklimericks/server/views.clj +++ b/web/src/com/darklimericks/server/views.clj @@ -421,7 +421,7 @@ prefixes to that rhyming phrase."] request {:rhymes [:div - [:h1 ("Rhymes for \"%S\"" (-> request))] + [:h1 (format "Rhymes for \"%S\"" (-> request :params :rhyme-target))] [:h2 "Visualization 1 - Word by rhyme quality/frequency"] [:p.tl "Hover over a point in the graph below to see the word. The higher the word on the Y axis, the higher the rhyme quality. The further right the word on the X axis, the