heysho commited on
Commit
4d39100
·
verified ·
1 Parent(s): 55f2531

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -24
app.py CHANGED
@@ -6,15 +6,6 @@ from langchain_openai import ChatOpenAI
6
  from langchain_anthropic import ChatAnthropic
7
  from langchain_google_genai import ChatGoogleGenerativeAI
8
 
9
- ###### dotenv を利用する場合 ######
10
- try:
11
- from dotenv import load_dotenv
12
- load_dotenv()
13
- except ImportError:
14
- import warnings
15
- warnings.warn("dotenv not found. Please make sure to set your environment variables manually.", ImportWarning)
16
- ################################################
17
-
18
 
19
  PROMPT = """
20
  1. Task: Generate a unique motivational or reflective quote that relates directly to the user's reported feeling and plan for the day.
@@ -60,6 +51,10 @@ def init_chain():
60
 
61
  def main():
62
  init_page()
 
 
 
 
63
  chain = init_chain()
64
  if chain:
65
  feeling = st.selectbox(
@@ -77,18 +72,3 @@ def main():
77
  if __name__ == '__main__':
78
  main()
79
 
80
- # Style adjustments (optional, remove if not needed)
81
- st.markdown(
82
- """
83
- <style>
84
- /* Custom style adjustments */
85
- .st-emotion-cache-15ecox0 { display: none !important; }
86
- @media (max-width: 50.5rem) {
87
- .st-emotion-cache-13ln4jf {
88
- max-width: calc(0rem + 100vw);
89
- }
90
- }
91
- </style>
92
- """,
93
- unsafe_allow_html=True,
94
- )
 
6
  from langchain_anthropic import ChatAnthropic
7
  from langchain_google_genai import ChatGoogleGenerativeAI
8
 
 
 
 
 
 
 
 
 
 
9
 
10
  PROMPT = """
11
  1. Task: Generate a unique motivational or reflective quote that relates directly to the user's reported feeling and plan for the day.
 
51
 
52
  def main():
53
  init_page()
54
+ # Style adjustments (optional, remove if not needed)
55
+ st.markdown("""<style>.st-emotion-cache-15ecox0 { display: none !important; }
56
+ @media (max-width: 50.5rem) {.st-emotion-cache-13ln4jf {max-width: calc(0rem + 100vw);}}
57
+ </style>""",unsafe_allow_html=True,)
58
  chain = init_chain()
59
  if chain:
60
  feeling = st.selectbox(
 
72
  if __name__ == '__main__':
73
  main()
74