Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds type annotation to a method parameter and standardizes the metadata title across bot implementations. The main changes involve improving type safety in the BareGeminiBot class and aligning the PrettyGeminiBot metadata title format with its parent class.
- Added type annotation
types.GenerateContentResponseUsageMetadatato theusage_metadataparameter in_format_usage_logmethod - Changed the metadata title in
PrettyGeminiBotfrom a dynamic expression-based emoji to a static "💡 Answer"
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
mini_ema/bot/bare_gemini_bot.py |
Added type annotation to _format_usage_log method's usage_metadata parameter for improved type safety |
mini_ema/bot/pretty_gemini_bot.py |
Changed metadata title from dynamic emoji based on character expression to static "💡 Answer" label |
Comments suppressed due to low confidence (1)
mini_ema/bot/pretty_gemini_bot.py:46
- This class does not call BareGeminiBot.init during initialization. (PrettyGeminiBot.init may be missing a call to a base class init)
class PrettyGeminiBot(BareGeminiBot):
| "content": content, | ||
| "metadata": { | ||
| "title": f"{self._get_emoji(ema_message.expression)} Ema", | ||
| "title": "💡 Answer", |
There was a problem hiding this comment.
The title has been changed from a dynamic expression-based title using f"{self._get_emoji(ema_message.expression)} Ema" to a static "💡 Answer". This removes the dynamic emoji functionality that reflected the character's expression (smile, confused, sad, etc.) and the character name "Ema". This makes the _get_emoji method unused and reduces the information conveyed to users about the bot's emotional state. Consider whether this loss of functionality is intentional.
| "title": "💡 Answer", | |
| "title": f"{self._get_emoji(ema_message.expression)} Ema", |
No description provided.