hula0627 commited on
Commit
66cc8f3
·
1 Parent(s): 030ee29

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -51,10 +51,10 @@ def get_json_file(json_docs):
51
  temp_filepath = os.path.join(temp_dir.name, json_docs.name)
52
  with open(temp_filepath, "wb") as f:
53
  f.write(json_docs.getvalue())
54
- json_loader = JSONLoader(temp_filepath,
55
- jq_schema='.messages[].content',
56
- text_content=False
57
- )
58
  json_doc = json_loader.load()
59
  return json_doc
60
 
 
51
  temp_filepath = os.path.join(temp_dir.name, json_docs.name)
52
  with open(temp_filepath, "wb") as f:
53
  f.write(json_docs.getvalue())
54
+ json_loader = JSONLoader(
55
+ file_path=temp_filepath,
56
+ jq_schema='.messages[].content',
57
+ text_content=False)
58
  json_doc = json_loader.load()
59
  return json_doc
60