GPT 4o Image 采用 Python 作为后端

根据对OpenAI工程团队副总裁Srinivas Narayanan和ChatGPT工程团队负责人Sulman Choudhry 的 采访,ChatGPT Image全球风靡的吉卜力风格,采用了 Python 和 FastAPI 作为后端支持。

GPT 4o Image图像生成功能,凭借吉卜力风格的图像在社交媒体平台刷屏,在一周时间内吸引了超过1亿新用户,用户生成了超过7亿张图片,高峰期一个小时就有超过100万用户。然而,ChatGPT在图像功能推出后,并未经历重大的宕机。

工程团队披露,采用了Python作为大部分产品代码,FastAPI进行定制,关键高性能部分采用了C语言底层编码,并采用Temporal进行非同步工作流管理。

  • Python: most of the product’s code is written in this language.
  • FastAPI: the Pythonframeworkused for building APIs quickly, using standard Python type hints. As the name suggests, FastAPI’s strength is that it takes less effort to create functional, production-ready APIs to be consumed by other services.
  • C: for parts of the code that need to be highly optimized, the team uses the lower-level C programming language
  • Temporal: used for asynchronous workflows and operations inside OpenAI. Temporal is a neat workflow solution that makes multi-step workflows reliable even when individual steps crash, without much effort by developers. It’s particularly useful for longer-running workflows like image generation at scale

事实上,尽管很多人抱怨Python性能低、不适合大规模生产场景采用,但OpenAI能够使用Python作为后端支持Image图像生成上亿用户,充分证明了Python的可靠性。


已发布

分类

,

来自

评论

发表评论

了解 AI前哨 的更多信息

立即订阅以继续阅读并访问完整档案。

继续阅读