Voting Module

class Voting(*args: Any, **kwargs: Any)

Bases: Cog

Module to handle Featured Idol voting during LLR streams and other various tasks.

See also

Module is locked to the Love Live Radio (LLR) server.

Attention

All commands assume minimum bot permissions: View Channel, Send Messages.

async update_all_songs(ctx)

Updates the song list in Chiito with new data. Runs automatically before each stream.

Syntax:

!!update_all_songs
Returns:

An embed with the details of the updated song list.

Return type:

discord.Embed

Permissions

Author: LLR Admin

async send_all_songs(ctx, option: int = None)

Show all unique songs in database, or ALL songs if option = 1.

Syntax:

!!send_all_songs [option]

Example:

!!send_all_songs
!!send_all_songs 1
Returns:

A list of all songs Chii uses for slash command requests. Provide option 1 for no variation version.

Return type:

discord.Message

Permissions

Author: LLR Admin

async movevoting(ctx)

Move all votes from live_data to records. Runs automatically during win.

Syntax:

!!movevoting
Returns:

Confirmation message

Return type:

discord.Message

Permissions

Author: LLR Admin

async get_leader(ctx)

Get the current Leader including their debug details. Runs automatically during stream operations without debug details.

Syntax:

!!get_leader
Returns:

Information about the current Leader.

Return type:

discord.Message

Permissions

Author: LLR Admin

async get_idol(ctx)

Show the last Featured Idol. Runs automatically during stream operations.

Aliases: lfi

Syntax:

!!get_idol
Returns:

The name and portrait of the last featured idol.

Return type:

discord.Message

Permissions

Author: LLR

async set_idol(ctx, name: str)

Overwrite the current LFI.

Syntax:

!!set_idol [name]

Example:

!!set_idol Chika
Parameters:
  • name – The name of the idol to set as the last featured idol.

  • type – str, required

Returns:

Confirmation message of the updated last featured idol.

Return type:

discord.Message

Permissions

Author: LLR Admin

async vote(ctx, idol: str | None)

Vote for our next Featured Idol. Can only be run during an active LLR stream.

Syntax:

!!vote [idol]

Example:

!!vote kotori
Parameters:
  • idol – The name of the idol you wish to vote for. Must be the first name (e.g., mari, eli, kotori).

  • type – str, required

Returns:

Confirmation message of the vote and the result.

Return type:

discord.Embed

Permissions

Author: LLR

Bot: Manage Messages

async leaderboard(ctx, er=None)

Show the current Top 10 Idol Leaderboard for the LLR Stream in progress.

Can only be run during an active LLR stream.

LLR Admin automatically bypasses checks.

Aliases: lb

Syntax:

!!leaderboard
Returns:

The current leaderboard showing the top idols and their vote counts.

Return type:

discord.Embed

Permissions

Author: LLR

async leaderboard_graphic(ctx)

Ask Manmaru to render the current featured-idol pie chart (HTML) as a cropped transparent WebP and post it in this channel.

Same channel / stream gates as !!lb. Unavailable while results are hidden for the first 15 minutes.

Permissions

Author: Love Live Radio guild

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async force_vote(ctx, idol: str = None)

Bypass all checks and force a valid vote.

Aliases: fv

Syntax:

!!force_vote <idol>

Example:

!!force_vote yoshiko
Returns:

Sends a confirmation message with the new vote details. Embed footer will confirm it has been a forced vote and the LLR Admin who issued it.

Return type:

discord.Embed

Permissions

Author: LLR Admin

async staminajson(ctx)

Upload JSON files into Idol_Stamina database

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async top_idols(ctx)

Get the user’s top voted idols for the current year.

Syntax:

!!top_idols
Returns:

Message showing the user’s top idols and vote counts for the current year.

Return type:

discord.Message

Permissions

Author: LLR Admin

async votecount(ctx)

Get the user’s total vote count for the current year.

Syntax:

!!votecount
Returns:

Message showing the user’s total vote count for the current year.

Return type:

discord.Message

Permissions

Author: LLR Admin

async featured_results(ctx)

Get the user’s Featured User Raffle results for the current year and lifetime.

Syntax:

!!featured_results
Returns:

Message showing the user’s Featured User Raffle wins for the current year and lifetime percentage.

Return type:

discord.Message

Permissions

Author: LLR Admin

Debug command to examine the Featured User data structure.

Syntax:

!!debug_featured_data
Returns:

Debug information about the Featured User data structure.

Return type:

discord.Message

Permissions

Author: LLR Admin

async clear_vote_memory(ctx)

Clear all vote memory for Discord and Twitch users for testing purposes.

Syntax:

!!clear_vote_memory
Returns:

Confirmation message with counts of cleared votes.

Return type:

discord.Message

Permissions

Author: LLR Admin

async toggledevvotelimits(ctx)

Toggle vote limits for testing purposes. When enabled, users will be added to vote lists even in debug mode.

Syntax:

!!toggledevvotelimits
Returns:

Confirmation message showing the current state of dev vote limits.

Return type:

discord.Message

Permissions

Author: LLR Admin

async mywrapped(ctx, member: Member = None)

Generate a personalized LLR Wrapped summary for the current year for a user.

Syntax:

!!mywrapped [member]

Parameters:

member (discord.Member, optional)

The member to generate the wrapped for. If not provided, uses the command author.

Returns:

Embed showing the user’s current year LLR statistics and achievements.

Return type:

discord.Embed

Note

Currently restricted to LLR Admin for testing. Note: Instant Request count and Chiipoints data shown are lifetime totals, not year-specific.

Permissions

Author: Everyone (subject to channel/guild command restrictions)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async wrappedset(ctx, user_id: int, field: str, *, value: str = None)

Set a test override for a user’s wrapped data.

Syntax:

!!wrappedset <user_id> <field> <value>

Field Types and Formatting:

Integer Fields (just enter the number): - vote_count - Number of votes this year

Example: !!wrappedset 123456789 vote_count 50

  • featured_wins - Featured wins this year Example: !!wrappedset 123456789 featured_wins 3

  • featured_lifetime - Total featured wins (lifetime) Example: !!wrappedset 123456789 featured_lifetime 12

  • ir_count - Instant request count Example: !!wrappedset 123456789 ir_count 25

  • chiipoints_lifepoints - Total lifepoints earned Example: !!wrappedset 123456789 chiipoints_lifepoints 5000

  • points_spent - Total points spent Example: !!wrappedset 123456789 points_spent 2000

String Field: - user_name - Display name (no quotes needed, just the name)

Example: !!wrappedset 123456789 user_name TestUser

JSON Array Fields (must be valid JSON, use quotes around the entire array):

  • top_idols - List of top 3 idols with vote counts Format (array style): [["IdolName", votes], ["IdolName2", votes2], ["IdolName3", votes3]] Format (object style): [{"name": "IdolName", "votes": votes}, {"name": "IdolName2", "votes": votes2}] Example (array style): !!wrappedset 123456789 top_idols [["Honoka", 15], ["Eli", 12], ["Kotori", 10]] Example (object style): !!wrappedset 123456789 top_idols [{"name": "Honoka", "votes": 15}, {"name": "Eli", "votes": 12}] Note: Both formats are accepted. Array format ["Name", votes] will be automatically converted to object format {"name": "Name", "votes": votes}

  • top_songs - List of top songs with request counts Format: [{"name": "Song Name", "count": number}, ...] Example: !!wrappedset 123456789 top_songs [{"name": "Snow halation", "count": 10}, {"name": "START:DASH!!", "count": 8}] Note: Each song is an object with “name” (string) and “count” (integer) Important: Use double quotes for JSON, and escape any quotes in song names

Detailed Examples:

# Set vote count
!!wrappedset 123456789 vote_count 50

# Set top 3 idols (with vote counts)
!!wrappedset 123456789 top_idols [["Honoka", 15], ["Eli", 12], ["Kotori", 10]]

# Set top songs (with request counts)
!!wrappedset 123456789 top_songs [{"name": "Snow halation", "count": 10}, {"name": "START:DASH!!", "count": 8}]

# Set featured wins
!!wrappedset 123456789 featured_wins 3
!!wrappedset 123456789 featured_lifetime 12

# Set instant requests
!!wrappedset 123456789 ir_count 25

# Set chiipoints
!!wrappedset 123456789 chiipoints_lifepoints 5000
!!wrappedset 123456789 points_spent 2000

# Set display name
!!wrappedset 123456789 user_name MyTestAccount

Important Notes: - For JSON arrays (top_idols, top_songs), the entire value must be in quotes - Use double quotes (”) for JSON strings, not single quotes (‘) - For song names with special characters, they should work as-is in JSON - The override persists until you clear it with !!wrappedclear - Only the fields you set will be overridden; others use real data

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async wrappedsetsongs(ctx, user_id: int = None)

Set 5 random songs from the song list as top songs override for a user.

Syntax:

!!wrappedsetsongs [user_id]

Examples:

# Set random songs for yourself (uses command author's ID)
!!wrappedsetsongs

# Set random songs for a specific user
!!wrappedsetsongs 123456789

Notes: - If no user_id is provided, uses the command author’s ID - Randomly selects 5 songs from the unique songs list - Assigns random request counts between 5 and 20 - The override persists until cleared with !!wrappedclear

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async wrappedrandom(ctx, user_id: int = None)

Set completely random wrapped data for a user (all fields randomized).

Syntax:

!!wrappedrandom [user_id]

Examples:

# Set random data for yourself (uses command author's ID)
!!wrappedrandom

# Set random data for a specific user
!!wrappedrandom 123456789

What gets randomized: - Streams attended: 1-20 (20% chance of 0) - Top 5 songs: Random songs with random play counts - Featured idol votes: 1-30 (20% chance of 0) - Top 3 idols: Random idols with random vote counts - Featured wins: 1-4 (30% chance of 0) - Instant requests: 1-30 (20% chance of 0) - Chiipoints acquired: 1000-200000 - Chiipoints spent: 100-20000 (always less than acquired) - Nations: 3-15 random nations with random days (20% chance for up to 7 to have 365 days) - Custom role: Always set to True (uses your actual role if available, otherwise generates a random one)

Notes: - If no user_id is provided, uses the command author’s ID - The override persists until cleared with !!wrappedclear

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async wrappedclear(ctx, user_id: int, field: str = None)

Clear test override(s) for a user’s wrapped data.

Syntax:

!!wrappedclear <user_id> [field]

If field is not provided, clears all overrides for the user.

Examples:

!!wrappedclear 123456789 vote_count
!!wrappedclear 123456789  (clears all)

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)

async wrappedview(ctx, user_id: int = None)

View test overrides for a user (or all users if user_id not provided).

Syntax:

!!wrappedview [user_id]

Permissions

Author: LLR Admin (server owner / bot owner)

Bot: View Channel, Send Messages (plus Connect/Speak for voice commands)