新功能: - 创建AI聊天助手组件(AIChatWidget) - 支持文字+图片多模态对话 - 集成Gemini AI API - 支持图片编辑和内容生成 - 实时对话历史管理 - 优雅的UI设计,支持黑夜模式 技术实现: - 后端API代理Gemini API(/api/ai-chat) - 支持最多5张图片上传 - 流式响应处理 - 对话历史管理 - Base64图片处理 配置: - 在.env中添加Gemini API配置 - GEMINI_API_KEY - GEMINI_API_BASE_URL - GEMINI_MODEL 替换原弹幕功能,提供更强大的AI助手体验!
63 lines
1.6 KiB
ReStructuredText
Executable File
63 lines
1.6 KiB
ReStructuredText
Executable File
.. bioos documentation master file, created by
|
||
sphinx-quickstart on Thu Mar 16 15:15:05 2023.
|
||
You can adapt this file completely to your liking, but it should at least
|
||
contain the root `toctree` directive.
|
||
|
||
Welcome to bioos's documentation!
|
||
=================================
|
||
|
||
.. toctree::
|
||
:maxdepth: 2
|
||
:caption: Contents:
|
||
|
||
bioos <bioos.rst>
|
||
|
||
Installation
|
||
==================
|
||
|
||
Python 版本需要不低于2.7,可以直接通过pip进行安装
|
||
|
||
Example
|
||
------------------
|
||
::
|
||
|
||
pip install volcengine
|
||
|
||
Quickstart
|
||
==================
|
||
|
||
密钥使用授权
|
||
------------------
|
||
*仅子账号需要关注*
|
||
|
||
1. 登录控制台,点击右上角头像,在下拉菜单中选择「访问控制」。
|
||
|
||
2. 点击左侧边的「策略管理」,确认本子账户拥有「AccessKeyFullAccess」权限或包含此权限的更高级权限,例如「AdministratorAccess」,若没有则用 主账号 登录控制台为子账户添加相关权限。
|
||
|
||
Example
|
||
------------------
|
||
::
|
||
|
||
from __future__ import print_function
|
||
|
||
from volcengine.bioos.BioOsService import BioOsService
|
||
|
||
if __name__ == '__main__':
|
||
# set endpoint/region here if the default value is unsatisfied
|
||
bioos_service = BioOsService(endpoint='endpoint', region='region')
|
||
|
||
# call below method if you don't set ak and sk in $HOME/.volc/config
|
||
bioos_service.set_ak('ak')
|
||
bioos_service.set_sk('sk')
|
||
|
||
params = {}
|
||
|
||
resp = bioos_service.list_workspaces(params)
|
||
print(resp)
|
||
|
||
Indices and tables
|
||
==================
|
||
|
||
* :ref:`genindex`
|
||
* :ref:`search`
|