Manasa1 commited on
Commit
718cf9c
·
verified ·
1 Parent(s): dcc13e8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -1
app.py CHANGED
@@ -91,7 +91,13 @@ if user_input:
91
  st.markdown(user_input)
92
 
93
  # Add prompt for style adaptation
94
- style_prompt = f"Answer in a similar style as the person in the document: {user_input}"
 
 
 
 
 
 
95
  response = st.session_state.conversation_chain({"question": style_prompt})
96
 
97
  assistant_response = response["answer"]
 
91
  st.markdown(user_input)
92
 
93
  # Add prompt for style adaptation
94
+ style_prompt = (
95
+ f"Respond in the same style as the person in the uploaded document. "
96
+ f"Analyze the PDF to understand the author's writing style, tone, and phrasing. "
97
+ f"Craft your response to mimic the author's unique voice based on these observations. "
98
+ f"Answer the question below as if you were the author, capturing their personality and style:\n\n{user_input}"
99
+ )
100
+
101
  response = st.session_state.conversation_chain({"question": style_prompt})
102
 
103
  assistant_response = response["answer"]