Giter VIP home page Giter VIP logo

Comments (4)

devilkadabra69 avatar devilkadabra69 commented on May 20, 2024

i guess i can work on it
a small fix to handle self.plan as a list should be

               s=""
                  if isinstance(response_json["Plan"],list):
                      for i in response_json["Plan"]:
                          i=i.strip()
                          s+=i+"\n"
                       self.plan = s.strip()
                   else:
                       self.plan=response_json["Plan"].strip()

can you tell that should i end every word with \n or not ?

from ufo.

vyokky avatar vyokky commented on May 20, 2024

i guess i can work on it a small fix to handle self.plan as a list should be

               s=""
                  if isinstance(response_json["Plan"],list):
                      for i in response_json["Plan"]:
                          i=i.strip()
                          s+=i+"\n"
                       self.plan = s.strip()
                   else:
                       self.plan=response_json["Plan"].strip()

can you tell that should i end every word with \n or not ?

Great to see you solve it. It does not have to be with a \n.

from ufo.

vyokky avatar vyokky commented on May 20, 2024

At string formatting in flows.py for self.plan there is a .replace() operation called. Sometimes the model returns self.plan as a list. In such cases an error is thrown because replace cannot be called on a list. Most of the time self.plan is a string so it's only happening sometimes and hard to reproduce.

It is probably because GPT sometimes does not follow our instruction to output string. I see @devilkadabra69 have an soluton. Would you mind having a try? If this work we and intergrate it in the code.

from ufo.

devilkadabra69 avatar devilkadabra69 commented on May 20, 2024

i hope it works thank you @vyokky for the response!

from ufo.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.