Update app.py
Browse files
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(
|
| 55 |
-
|
| 56 |
-
|
| 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 |
|