yonikremer commited on
Commit
872c462
1 Parent(s): a0ace1a

bug fix: wrong directory for user instructions

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -3,6 +3,7 @@ The Streamlit app for the project demo.
3
  In the demo, the user can write a prompt
4
  and the model will generate a response using the grouped sampling algorithm.
5
  """
 
6
 
7
  import streamlit as st
8
  from torch.cuda import CudaError
@@ -58,6 +59,10 @@ with st.form("request_form"):
58
  st.write(f"Generated text: {output}")
59
 
60
 
61
- with open("user_instructions_hebrew.md", "r") as fh:
 
 
 
 
62
  long_description = fh.read()
63
  st.markdown(long_description)
 
3
  In the demo, the user can write a prompt
4
  and the model will generate a response using the grouped sampling algorithm.
5
  """
6
+ import os
7
 
8
  import streamlit as st
9
  from torch.cuda import CudaError
 
59
  st.write(f"Generated text: {output}")
60
 
61
 
62
+ user_instructions_file = os.path.join(
63
+ os.path.dirname(__file__),
64
+ "user_instructions_hebrew.md",
65
+ )
66
+ with open(user_instructions_file, "r") as fh:
67
  long_description = fh.read()
68
  st.markdown(long_description)