Thanks to visit codestin.com
Credit goes to github.com

Skip to content

response is not readable #166

@Andy963

Description

@Andy963

Description of the bug:

sometime's the gemini-pro resoponse is not readable, for example:

ofscrollingscrolling,makingitcompatiblewithvariousdevicesandinputmethods.\nExampleUsage:\n\n//Assuming"dom"isaDOMelementand"card"isanobjectwitha"value"propertyrepresentingthecontainer.\ncheckAndScrollToDiv(dom,card.value);\n\nInthiscontext,whenyoucallcheckAndScrollToDiv(dom,card.value),thefunctionwillcheckifthespecifiedDOMelement(dom)ispositionedoutofthevisibleareawithinthecontainer(card.value)and,ifso,scrollsthecontainertobringtheelementopintoviewatthetop.\nConclusion:\nThecheckAndScrollToDivfunctionplaysacrucialroleinimprovinguserexperienceandaccessibilitybyensuringthatelementsarevisiblewithinthecontainer.Itscompatibilitywithvariousdevicesandinputmethodsmakesitavaluabletoolforcreatinguser-friendlyapplications.

this is stream mode, and use: print(repr(resp.text))
there was no space between words, and not readable, even i add a note at the last of my question:

question += 'please return a formatted and human readable answer.'

but sometimes, i asked gemini-pro to return a readable string again, it works, sometimes not word.

Actual vs expected behavior:

actual: ihaveaquesiton
expected response; i have a qeustion

Any other information you'd like to share?

python 3.9
google-ai-generativelanguage 0.4.0
google-api-core 2.15.0
google-auth 2.25.2
google-generativeai 0.3.2
googleapis-common-protos 1.62.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions