Spaces:
Sleeping
Sleeping
text, csv, json add
Browse files
app.py
CHANGED
@@ -47,7 +47,7 @@ def get_json_file(json_docs):
|
|
47 |
temp_filepath = os.path.join(temp_dir.name, json_docs.name)
|
48 |
with open(temp_filepath, "wb") as f:
|
49 |
f.write(json_docs.getvalue())
|
50 |
-
json_loader = JSONLoader(temp_filepath, jq_schema='.messages[].content', text_content=False)
|
51 |
json_doc = json_loader.load()
|
52 |
return json_doc
|
53 |
|
|
|
47 |
temp_filepath = os.path.join(temp_dir.name, json_docs.name)
|
48 |
with open(temp_filepath, "wb") as f:
|
49 |
f.write(json_docs.getvalue())
|
50 |
+
json_loader = JSONLoader(file_path=temp_filepath, jq_schema='.messages[].content', text_content=False)
|
51 |
json_doc = json_loader.load()
|
52 |
return json_doc
|
53 |
|