Giter VIP home page Giter VIP logo

Comments (2)

Bobholamovic avatar Bobholamovic commented on May 22, 2024

抱歉回复得晚了。我认为目前ERNIE Bot与OpenAI Python Library不兼容的主要原因有以下几个方面:

  1. ERNIE Bot在早期研发过程中参考了OpenAI Python Library v0.28的设计,并致力于与当时的OpenAI Python Library在接口风格、使用方式等方面尽可能对齐。然而,在v0.28之后,OpenAI Python Library发布了首个稳定版v1.0,无论是接口还是代码实现基本上都全部重写,与v0.28版本完全不兼容,这导致了现在的ERNIE Bot与OpenAI Python Library看起来“完全不同”。
  2. 与OpenAI Python Library基本上只支持单后端不同,ERNIE Bot支持几个差异较大的后端,如千帆大模型平台、AI Studio平台、智能创作平台等,因此ERNIE Bot在设计上不得不更多地考虑后端间的差异性(与之相对比,OpenAI Python Library目前以Open AI官方API作为主要的后端,同时以一种“并不很整洁”的方式支持Azure后端)。这一点使得ERNIE Bot在设计上无法完全与OpenAI Python Library对齐,也很可能导致两个库在使用方式上难以兼容,或者至少我们可能得花费更多的精力探索“支持多后端且与OpenAI Python Library在使用方式上对齐”的设计方案。
  3. ERNIE Bot与OpenAI Python Library还存在一个关键区别:二者支持的大模型不同。实际上,文心大模型与Open AI推出的各系列大模型在功能上并不完全一致,例如:文心对话大模型支持在生成内容时允许模型禁用实时搜索引擎,而GPT系列模型并没有类似的功能;GPT系列模型在一次对话中支持用户指定多条system message,而文心大模型只能指定一条system message。这些差异阻碍了两个库在API参数上的对齐。

诚然,接口风格上的变动可以通过重写代码来跟进,但以上所提到的其它一些不一致,例如对后端重视程度的不同以及API参数上的不一致,仍然使得ERNIE Bot与OpenAI Python Library无法完全兼容。由于OpenAI Python Library的用户更多、应用更广泛,后续我们也将考虑是否增加两个库对齐的程度,尽可能减少用户切换库后的适应成本。

from ernie-sdk.

China-MYJSY avatar China-MYJSY commented on May 22, 2024

感谢解答

from ernie-sdk.

Related Issues (20)

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.