-
Notifications
You must be signed in to change notification settings - Fork 16
Docs/add: Documents of how Xpaint is powered by AIGC #50
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
base: main
Are you sure you want to change the base?
Conversation
🔍 PR Review: Documents of how Xpaint is powered by AIGCReview Progress:
📋 Review SummaryThis PR adds comprehensive documentation about integrating AI capabilities into Xbuilder's drawing functionality. The document provides valuable insights into AI integration best practices for game development platforms.
|
Summary of ChangesHello @petezhuang, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! 本次拉取请求引入了一份详细文档,阐述了将AIGC(AI生成内容)集成到Xbuilder平台Xpaint绘图功能中的策略和实现。该文档解释了将AI深度嵌入用户创作工作流的理念,选择专业AI模型进行矢量图生成的原因,以及为赋能缺乏艺术和提示词构建技能的年轻创作者而设计的复杂提示词工程系统。它涵盖了用户可见的交互元素和强大的后端自动化流程,这些流程将用户简单的想法转化为高质量、符合技术规范的矢量游戏素材。 Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
The pull request introduces a new markdown document detailing how AI is integrated into the Xpaint product. The document covers various aspects, including AI interaction within the user interface, AI model selection, and prompt engineering techniques. The review focuses on identifying potential areas for improvement in clarity and technical accuracy, as well as highlighting areas where the document could be more informative.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
|
||
**引言:** | ||
|
||
> 笔者作为前端工程师,目前的工作主要是在为开源游戏平台Xbuilder编写其精灵创作时的绘图功能。这个功能的基础是一个浏览器端编辑矢量图的功能。在此基础上,我们为其赋予了AI生成游戏素材的能力,让AI交互融入用户创作的过程中。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Xbuilder -> XBuilder
|
||
2. **AI模型的选择** | ||
|
||
现在的通用大语言模型(如chatgpt, google gemini)的性能是非常强大的,但是,他们能否胜任我们的需求呢?必须明确,我们的需求区别于传统的文生图,传统的文生图是生成png图像,或者说,生成位图。而我们的需求是生成矢量图(SVG)。这二者可谓天差地别。通用大语言模型生成位图的能力非常强,但是生成矢量图的能力则不一定了。所以,我们针对openAi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
名词的格式需要跟官方的一致,比如 ChatGPT 而不是 chatgpt,OpenAI 而不是 openAi
可以本地让 Copilot 之类的工具先帮助校正一遍名词的书写以及格式的细节。
gpt4, Claude 4, Google Gemini 2.5 pro, 以及专业绘图模型Recraft v3/v2, | ||
svgio等多家模型商进行了测试。最终的结果表明,通用大模型在矢量绘图领域的能力是非常糟糕的。为了我们预期的用户体验,我们必须使用专业的生图模型。所以我们最后选择了recraft作为主要的供应商来进行图片生成。笔者认为,很多业务上盲目的追求通用大模型,对话式帮助,其实是一种"偷懒"的行为。因为引入LLM,拉一个对话框,其实是在产品和交互上偷了懒。一个优秀的产品必须从用户需求出发,我们作为开发者必须反思:新增的功能到底能不能解决用户的痛点需求? | ||
|
||
**三、Prompt构建体系** |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
跟上边 1、2 一致的话,这里应该是
**三、Prompt构建体系** | |
3. **Prompt构建体系** |
另外标题尽量用 markdown 的标题来体现层级关系?
|
||
**3.1.2提示词** | ||
|
||
我们构建了类IDE模式的提示词补全体系。我们预期的用户输入是简单的,基础的。对于一个6岁的孩子而言,他可能只能输出1-2个单词,你不可能指望孩子输出规范优雅的提示词。于是,我们在输入框中引入了补全体系。这个补全系统会根据用户的项目信息,结合小型大语言模型,对提示词进行强化和补全,从而在用户输入的过程动态的获取到更强大,规范,优雅的提示词。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: 说提示词是“优雅的”有点奇怪..一般的描述似乎是“清晰、准确、详细”之类
No description provided.