Skip to content
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

Fix value in generation configuration step #315

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hackerpro536
Copy link

Description of the change

The error in your code is that the max_output_tokens parameter in the GenerationConfig is set to 20. This restricts the story to a very short length.

Motivation

User will got issue when run this block because max_output_tokens currently version is 20 so too small. I just change this value to better.

ValueError: The response.text' quick accessor only worlks for simple (single-'Part') text responses. This response
is not simple text.Use the result.parts' accessor or the full result.candidates[index].content.parts`lookup
instead.

Type of change

Bug fix

Checklist

  • I have performed a self-review of my code.
  • I have added detailed comments to my code where applicable.
  • I have verified that my change does not break existing code.
  • My PR is based on the latest changes of the main branch (if unsure, please run git pull --rebase upstream main).
  • I am familiar with the Google Style Guide for the language I have coded in.
  • I have read through the Contributing Guide and signed the Contributor License Agreement.

@hackerpro536 hackerpro536 requested a review from a team as a code owner March 20, 2024 10:23
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@github-actions github-actions bot added status:awaiting review PR awaiting review from a maintainer component:documentation Update docs labels Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:documentation Update docs status:awaiting review PR awaiting review from a maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant