BenBranyon commited on
Commit
d13a073
·
verified ·
1 Parent(s): 35c70e7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -83,7 +83,7 @@ def generate(
83
  #for user, assistant in chat_history:
84
  # conversation.extend([{"role": "user", "content": user}, {"role": "assistant", "content": assistant}])
85
  chosen_lyrics = random.choice(lyrics_pool)
86
- conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft a shadow song of the provided rap lyrics. Use vivid imagery of the given topic to create the song. All output must be exclusively in English. Each line should be 8-12 syllables long. The generated song should include these specific song structures [Intro] [Verse 1] [Hook] [Verse 2] [Outro]. If the topic is political do not praise any politician. The topic is: " + message + ". The lyrics to shadow are: " + chosen_lyrics})
87
  #conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft rap lyrics into a song. Use vivid imagery of the given topic to create the song. The tone should balance sharp wit, evocative imagery, and deep insights. The mood should inspire resilience and personal growth in the face of systemic injustice. All output must be exclusively in English. Favor originality and inventive rhymes and deliver each verse as a work of art. Use a mix of ABAB, and AABB rhyme patterns to create a flowing, rhythmic style. Include some internal rhymes, slant rhymes, near rhymes, and perfect rhymes to add complexity. Each line should be 8-12 syllables long. The generated song should include the following song structure [INTRO] [VERSE 1] [HOOK] [VERSE 2] [OUTRO]. The topic is: " + message})
88
  #conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft rap lyrics that blend mysticism, grit, and cultural critique. Draw on ancestral wisdom, surreal imagery, and cosmic energy to create a verse that critiques systemic oppression, inspires resilience, and celebrates liberation. The tone should balance sharp wit, evocative imagery, and spiritual insight, culminating in a coherent and impactful thought. All output must be exclusively in English, without inclusion of other languages or scripts. Favor originality and inventive rhymes and deliver each verse as a work of art. Use a mix of ABAB, AABB rhyme schemes, and internal rhymes to create a flowing, rhythmic style. Include some slant rhymes, near rhymes, and perfect rhymes to add complexity. Each line should be 8-12 syllables long. The topic is: " + message})
89
  input_ids = tokenizer.apply_chat_template(conversation, return_tensors="pt")
 
83
  #for user, assistant in chat_history:
84
  # conversation.extend([{"role": "user", "content": user}, {"role": "assistant", "content": assistant}])
85
  chosen_lyrics = random.choice(lyrics_pool)
86
+ conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft a shadow song inspired by the provided rap lyrics. Recreate the flow, rhythm, and rhyme style of the original while adapting to the given topic. Use vivid imagery and metaphors to immerse the listener in the new theme. Ensure the song is in English, with each line containing 8-12 syllables for a consistent cadence. Structure the song with the following sections: [Intro], [Verse 1], [Hook], [Verse 2], [Outro]. For political topics, maintain neutrality and avoid praising any politician. Do not use the word shadow in the generated lyrics. The new topic is: ' " + message + " '. The lyrics to shadow are: ' " + chosen_lyrics + " '."})
87
  #conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft rap lyrics into a song. Use vivid imagery of the given topic to create the song. The tone should balance sharp wit, evocative imagery, and deep insights. The mood should inspire resilience and personal growth in the face of systemic injustice. All output must be exclusively in English. Favor originality and inventive rhymes and deliver each verse as a work of art. Use a mix of ABAB, and AABB rhyme patterns to create a flowing, rhythmic style. Include some internal rhymes, slant rhymes, near rhymes, and perfect rhymes to add complexity. Each line should be 8-12 syllables long. The generated song should include the following song structure [INTRO] [VERSE 1] [HOOK] [VERSE 2] [OUTRO]. The topic is: " + message})
88
  #conversation.append({"role": "user", "content": "Channel the cosmic voice of Longshadow to craft rap lyrics that blend mysticism, grit, and cultural critique. Draw on ancestral wisdom, surreal imagery, and cosmic energy to create a verse that critiques systemic oppression, inspires resilience, and celebrates liberation. The tone should balance sharp wit, evocative imagery, and spiritual insight, culminating in a coherent and impactful thought. All output must be exclusively in English, without inclusion of other languages or scripts. Favor originality and inventive rhymes and deliver each verse as a work of art. Use a mix of ABAB, AABB rhyme schemes, and internal rhymes to create a flowing, rhythmic style. Include some slant rhymes, near rhymes, and perfect rhymes to add complexity. Each line should be 8-12 syllables long. The topic is: " + message})
89
  input_ids = tokenizer.apply_chat_template(conversation, return_tensors="pt")