-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Added new notebook Basic_Code_Review to examples #689
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
@@ -0,0 +1,268 @@ | |||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be better to move the imports closer to where they are first used, ideally placing them in the same cell where they're invoked
Reply via ReviewNB
@@ -0,0 +1,268 @@ | |||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line #14. programmer_response = client.models.generate_content(
The string formatting in this block could be improved for better readability. Here’s an example of a cleaner format that aligns with common conventions:
programmer_response = client.models.generate_content( model=MODEL_ID, contents= """ Write code to take a list of integers, remove any duplicates, filter out all numbers less than 30, and return the remaining numbers sorted in descending order. """, config=types.GenerateContentConfig( system_instruction=buggy_code_prompt ), )
Reply via ReviewNB
Integrated Gemini API to assist with code reviews and optimization.
Added Python SDK functionality for code quality feedback and suggesting improvements.
Example included demonstrating the use of the Gemini model to enhance code quality.