2023最新AI创作系统ChatGPT网站源码+Midjourney绘画+支持GPT-4-Turbo模型+即将支持TSS语音对话功能模块

一、AI创作系统

SparkAi创作系统是基于ChatGPT进行开发的Ai智能问答系统和Midjourney绘画系统,支持OpenAI-GPT全模型+国内AI全模型。本期针对源码系统整体测试下来非常完美,可以说SparkAi是目前国内一款的ChatGPT对接OpenAI软件系统。那么如何搭建部署AI创作ChatGPT?小编这里写一个详细图文教程吧!本系统使用Nestjs+Vue+Typescript框架技术,持续集成AI能力到本系统。支持GPT-4-Turbo模型、支持DALL-E3文生图,支持最新GPT-4-Turbo模型、GPT-4-1106-Preview多模态模型。支持GPT-4图片对话能力上传图片并识图理解对话。

《SparkAi系统详情及搭建部署文档》:

https://www.yuque.com/yuqueyonghutq9yt2/egy0d0/ah9sq89lgl6b7s4w

OpenAI GPT全模型+国内AI全模型

新增Dall-E3绘画(可直接对话文生图)

新增已支持GPT-4图片对话能力(上传图片并识图理解对话)

可同时支持5张图同时上传对话

AI模型提问

AI绘画

新增Midjourney局部重绘(Vary Region)在线编辑功能

1.1 程序核心功能

已支持OpenAI GPT全模型+国内AI全模型+Midjourney绘画池系统!

  1. AI提问:程序已支持GPT3.5,GPT4.0提问、OpenAIGPT全模型+国内AI全模型、支持GPT联网提问

  2. 已支持OpenAIGPT全模型+国内AI全模型,已支持国内AI模型 百度文心一言、微软Azure、阿里云通义千问模型、清华智谱AIChatGLM、科大讯飞星火大模型、腾讯混元大模型等!

  3. AI绘画:Midjourney绘画(全自定义调参)、Midjourney以图生图、Dall-E3绘画

  4. 支持最新GPT-4多模态模型、OpenAI GPT-4-Turbo-With-Vision-128K模型

  5. 支持GPT-4图片对话能力(上传图片并识图理解对话)

  6. 新增支持对话插件系统,后续逐步增加插件功能,扩展AI能力

  7. 新增KEY支持单独配置消耗费率,比如GPT4-32K比GPT4成本更高应该消耗更多的额度次数

  8. 微信公众号+邮箱+手机号注册登录

  9. 一键智能思维导图生成

  10. 应用广场,支持用户前台自定义添加私密或共享

  11. AI绘画广场(画廊)

  12. 邀请+代理分销模式、用户每日签到功能

  13. 会话记录同步保存

  14. 支持对接微信官方支付、易支付、码支付、虎皮椒支付等

  15. 自定义聚合会员套餐、卡密系统

  16. 其他核心功能

  17. 后续其他免费版本功能更新

1.2 更新日志

SparkAi最近大版本更新日志:

【V3.3.1】更新功能(2023.11.24号更新)

  1. 新增支持GPT-4-Turbo-Vision插件

  2. 新增已支持GPT-4图片对话能力(上传图片并识图理解对话)可同时支持5张图同时上传对话

  3. OpenAI DALL-E3文生图对话形式及图片大小占比优化,效果与OpenAI PLUS一致

  4. 优化合并DALL-E3和GPT-4-Turbo-Vision的计费方式为GPT-4-Turbo,只需配置gpt-4-1106-Preview模型即可

  5. 新增MJ绘画系统并发执行数量设置,可后台设置系统并发数量

  6. 新增阿里云OSS存储可配置自定义域名,实现用户可以直接预览图片

  7. 新增大模型Agent代理多插件调用处理任务并总结返回结果

  8. 修复GPT联网提问失效和不稳定问题(后期将开发新的联网功能,可控制联网模块)

  9. 优化MJ单次绘画查询的超时时间为4分钟,应对MJ官方慢速绘画太慢可能导致绘画失败的问题

  10. 修复绘画存储不走绘画池Discord-CND代理,导致部分时候存储失败问题

  11. 新增DALL-E3文生图连续对话可对同一张图提出修改意见,DALL-E3文生图插件的调用时机由大模型理解用户提问动态择机调用。与OpenAI同步,支持gpt-4、gpt-4-1106-preview、gpt-4-0613、gpt-3.5-turbo、gpt-3.5-turbo-1106、gpt-3.5-turbo-0613模型调用。

二、系统模块演示

SparkAi官方演示站:

https://ai.sparkaigf.com

管理后端:

https://ai.sparkaigf.com/sparkai/admin

测试账号:admin、123456

如不能访问请查看《SparkAi系统详情及搭建部署文档》获取最新地址。

三、系统功能模块

3.1 ChatGPT模型提问

支持GPT联网提问提问

3.2 Prompt应用

3.2.1 Prompt应用

3.2.2 自定义Prompt应用

支持用户自定义Prompt应用

3.3 支持Midjourney绘画

  • 支持同步官方图片重新生成指令

  • 同步官方 Vary 指令 单张图片对比加强 Vary(Strong) | Vary(Subtle)

  • 同步官方 Zoom 指令 单张图片无限缩放 Zoom out 2x | Zoom out 1.5x

  • 新增 Midjourney局部重绘(Vary Region)在线编辑功能

3.3.2 以图生图

3.4 Dall-E3绘画(可直接对话文生图)

3.5 Mind思维导图生成

3.6 AI画廊

其他和后台页面太多功能,就不展示了,直接访问演示站点和演示后台。

四、搭建部署教程

4.1 基础env环境配置

在代码中我们提供了基础 环境变量文件配置文件 env.example ,使用前先去掉后缀改为 .env 文件即可,我们在env环境配置文件只需要配置如下东西。

  • 授权码授权ip配置

  • 邮件服务配置

  • mysql数据库 这三项是基础配置、mysql与授权是必须的、在配置mysql与授权的情况下项目才可以启动成功、邮件服务可以后续追加。

4.2 env文件代码

# 服务器ip
SPARK_AI_HOST=
# 授权码
SPARK_AI_KEY=

# mysql
DB_HOST=localhost
DB_PORT=3306
DB_USER=数据库用户名
DB_PASS=数据库密码
DB_DATABASE=数据库名
DB_LOG=false
DB_SYNC=true

#  mailer 邮件服务
MAILER_HOST=smtp.163.com
MAILER_PORT=465
MAILER_USER=发信邮箱
MAILER_PASS=邮箱发信密钥
MAILER_FROM=发信邮箱

# Redis
REDIS_PORT=6379
REDIS_HOST=127.0.0.1
REDIS_PASSWORD=
REDIS_DB=0

# jwt token
JWT_SECRET=chat-spark
# jwt token 过期时间
JWT_EXPIRESIN=7d
# 接口文档前缀
SWAGGERPREFIX=/docs
# 自定义端口
PORT=9520

五、环境安装

前置条件:

  1. 国内或者海外服务器均可,最低配置2H2G起,建议2H4G甚至更高

  2. 宝塔安装成功

 所需环境:

  • Nginx >= 1.19.8

  • MySQL >= 5.7MySQL 8.0

  • PHP-7.4(非必须)

  • PM2管理器 >=5.5

  • Redis 7.0.11

  • Node版本:>=16.19.1

5.1 Node版本

使用PM2切换Node版本(必须)

切换Node版本为:v16.19.1

5.2 安装pnpm模块

5.3 安装Redis

六、部署跑起来

6.1 新建站点

进入宝塔 - > 网站 -> 添加站点

6.2 开启HTTPS

6.2.1使用自己的ssl证书

6.2.2 Let's Encrypt 证书申请

If you don’t have a certificate, use the Pagoda free certificate and apply for it Let's Encrypt

6.3 Upload system source code

Delete the default files generated by the pagoda creation site

Upload and unzip the program to the root directory of the website

6.3.1 Configure .env file

Double-click the .env.example file directly in the Pagoda to edit it, or edit it in the terminal vim

After the configuration is completed, delete the file suffix and the file name is .env

6.3.2 Check and verify Node related environment

At this time, open the terminal again and determine whether we need a node-related environment.

node -v
npm -v
pnpm -v

6.4 Start the project

6.4.1 Open port

Pagoda panel security open9520 port and3306 port

6.4.2 Install dependencies

Use the terminal to switch to the website directory

cd /www/wwwroot/网站目录

Or enter the ssh terminal directly in the root directory of the website

Use pnpm i command to install dependencies

pnpm i

6.4.3 Start the project

Start the project using the pnpm start command

pnpm start

6.4.4 View startup log

Enter pm2 log to view the detailed log. If you see the picture below, it means success!

pm2 log

6.4.5 Add reverse proxy

Add 9520 port reverse proxy. Pagoda Security needs to open this port, otherwise it will not be accessible

7. Use the system

Deployment completed! Now you can access the system through the domain name

7.1 Management background

The default front-end address is the domain name address. The default back-end address is: https://domain name address/sparkai/admin

The default super administrator account is super, spark123

7.2 Modify the default password of the super administrator

After logging in, please change the default password of the super administrator first.

7.3 Construction completed

8. Backend configuration & system version update

8.1 Backend configuration

For system configuration tutorials and other tutorials, please go to the system details deployment document or the original blog tutorial.

https://www.idcyli.com

8.2 System version update

For system version update tutorials, please go to the system details deployment document or the original tutorial on the blog.​  

Guess you like

Origin blog.csdn.net/weixin_43227851/article/details/134680683