-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgptstudio.py
54 lines (48 loc) · 1.19 KB
/
gptstudio.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
from dotenv import load_dotenv
load_dotenv()
import streamlit as st
from common.models import get_db_session, get_user_by_usercode
import os
st.set_page_config(
page_title="GPTStudio",
page_icon=":material/two_pager:",
initial_sidebar_state="expanded",
layout="wide",
)
st.logo("assets/gptstudio-logo.png", icon_image="assets/gptstudio-icon.png", size="large")
pages = {}
gpt_pages = [
st.Page(
"gptstudio/PDFReading.py",
title="PDF 处理",
icon=":material/two_pager:",
default=True,
),
st.Page(
"gptstudio/ImageTools.py",
title="图像工具",
icon=":material/psychology:",
),
st.Page(
"gptstudio/TextToSpeech.py",
title="文本转语音",
icon=":material/two_pager:",
),
st.Page(
"gptstudio/SpeechToText.py",
title="语音转文本",
icon=":material/two_pager:",
),
st.Page(
"gptstudio/RagSubmit.py",
title="RAG 数据提交",
icon=":material/two_pager:",
),
st.Page(
"gptstudio/RagSearch.py",
title="RAG 数据检索",
icon=":material/two_pager:",
)
]
pgm = st.navigation(gpt_pages)
pgm.run()