Inline api key
This commit is contained in:
		
							
								
								
									
										2
									
								
								app.py
									
									
									
									
									
								
							
							
						
						
									
										2
									
								
								app.py
									
									
									
									
									
								
							@@ -4,7 +4,7 @@ from openai import OpenAI
 | 
			
		||||
st.title("ChatGPT-like clone")
 | 
			
		||||
 | 
			
		||||
# Set OpenAI API key from Streamlit secrets
 | 
			
		||||
client = OpenAI(api_key=st.secrets["OPENAI_API_KEY"])
 | 
			
		||||
client = OpenAI(api_key="sk-oaiwrapper-QpaWSUO8TLerRMJVB7RhT3BlbkFJGSjSx21NfCI6qozxXw2Z")
 | 
			
		||||
 | 
			
		||||
# Set a default model
 | 
			
		||||
if "openai_model" not in st.session_state:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user