{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/evaluating-diversity-in-automatic-poetry","title":"Evaluating Diversity in Automatic Poetry Generation","arxiv_id":"2406.15267","date":"2024-06-21","proceeding":null,"authors":["Yanran Chen","Hannes Gröner","Sina Zarrieß","Steffen Eger"],"abstract":"Natural Language Generation (NLG), and more generally generative AI, are among the currently most impactful research fields. Creative NLG, such as automatic poetry generation, is a fascinating niche in this area. While most previous research has focused on forms of the Turing test when evaluating automatic poetry generation -- can humans distinguish between automatic and human generated poetry -- we evaluate the diversity of automatically generated poetry (with a focus on quatrains), by comparing distributions of generated poetry to distributions of human poetry along structural, lexical, semantic and stylistic dimensions, assessing different model types (word vs. character-level, general purpose LLMs vs. poetry-specific models), including the very recent LLaMA3-8B, and types of fine-tuning (conditioned vs. unconditioned). We find that current automatic poetry systems are considerably underdiverse along multiple dimensions -- they often do not rhyme sufficiently, are semantically too uniform and even do not match the length distribution of human poetry. Our experiments reveal, however, that style-conditioning and character-level modeling clearly increases diversity across virtually all dimensions we explore. Our identified limitations may serve as the basis for more genuinely diverse future poetry generation models.","url_abs":"https://arxiv.org/abs/2406.15267v2","url_pdf":"https://arxiv.org/pdf/2406.15267v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"evaluating-diversity-in-automatic-poetry","repo_url":"https://github.com/hgroener/diversity_in_poetry_generation","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":0,"framework":"none","reach":{"status":"ok","spdx":"GPL-3.0"}}],"tasks":[{"task_slug":"diversity","task_name":"Diversity"},{"task_slug":"text-generation","task_name":"Text Generation"}],"methods":[{"method_slug":"focus","method_name":"Focus"}],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2406.15267","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2406.15267"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/hgroener/diversity_in_poetry_generation","reach":{"status":"ok","spdx":"GPL-3.0"}}],"summary":{"ran":8,"unverified":6},"by_repo_kind":{"official":{"samples":14,"ran":8,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":14,"samples":[{"code_sha256_prefix":"58f88b7ed149b0f4","entry":"chi2_test","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/meter_rhyme.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/meter_rhyme.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"58f88b7ed149b0f4"}},{"code_sha256_prefix":"e24a0f7cee08a0d6","entry":"flatten_list","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/helper_functions.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/helper_functions.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":true,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"e24a0f7cee08a0d6"}},{"code_sha256_prefix":"2ec743297576d834","entry":"format_func","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/topic_modeling.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/topic_modeling.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"2ec743297576d834"}},{"code_sha256_prefix":"63f09d7aaebf6c14","entry":"get_contigents_len","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/length.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/length.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"63f09d7aaebf6c14"}},{"code_sha256_prefix":"873b466167adf60b","entry":"get_dataset","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/helper_functions.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/helper_functions.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"873b466167adf60b"}},{"code_sha256_prefix":"d2f5b927b2ba7d06","entry":"histogram_intersection","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/length.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/length.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"d2f5b927b2ba7d06"}},{"code_sha256_prefix":"2f3a197c01bcd196","entry":"join","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/helper_functions.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/helper_functions.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"2f3a197c01bcd196"}},{"code_sha256_prefix":"3d7c3b1d3cd1f421","entry":"split_sonnets","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/training_data/parse_sonnets.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/training_data/parse_sonnets.py","link_basis":"first_harvest_node","language":"python","status":"ran","verification_level":1,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"3d7c3b1d3cd1f421"}},{"code_sha256_prefix":"741b08fb3bb70955","entry":"chi_square_len","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/length.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/length.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"741b08fb3bb70955"}},{"code_sha256_prefix":"3231ddbd7853c739","entry":"memorization","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/memorization.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/memorization.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"3231ddbd7853c739"}},{"code_sha256_prefix":"519524442639ccf7","entry":"meter_rhyme_metrics","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/meter_rhyme.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/meter_rhyme.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"519524442639ccf7"}},{"code_sha256_prefix":"9ccad04d5816cb53","entry":"plot_stacked","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/analysis/meter_rhyme.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/analysis/meter_rhyme.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"9ccad04d5816cb53"}},{"code_sha256_prefix":"54e9c411dfa41569","entry":"process_ds","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/sampling/process_deepspeare_sample.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/sampling/process_deepspeare_sample.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"54e9c411dfa41569"}},{"code_sha256_prefix":"c414508a819b535d","entry":"process_sa","repo":"hgroener/diversity_in_poetry_generation","repo_kind":"official","path":"diversity-in-poetry-generation/sampling/process_structured_adversary_sample.py","file_url":"https://github.com/hgroener/diversity_in_poetry_generation/blob/HEAD/diversity-in-poetry-generation/sampling/process_structured_adversary_sample.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"GPL-3.0","inline_ok":false,"mcp_get_code":{"code_sha256":"c414508a819b535d"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}