wt002 commited on
Commit
b6f660f
·
verified ·
1 Parent(s): 10353d5

Update agent.py

Browse files
Files changed (1) hide show
  1. agent.py +3 -2
agent.py CHANGED
@@ -398,6 +398,7 @@ def create_documents(data_source: str, data: List[dict]) -> List[Document]:
398
  return docs
399
 
400
 
 
401
 
402
  # 4. Vector Store Integration
403
 
@@ -419,8 +420,8 @@ class MyVector_Store:
419
  # -----------------------------
420
  # Process JSON data and create documents
421
  # -----------------------------
422
- with open("/home/wendy/my_hf_agent_course_projects/data.json", "r", encoding="utf-8") as f:
423
- json_data = json.load(f)
424
 
425
  docs = create_documents("json", json_data)
426
  texts = [doc.page_content for doc in docs]
 
398
  return docs
399
 
400
 
401
+
402
 
403
  # 4. Vector Store Integration
404
 
 
420
  # -----------------------------
421
  # Process JSON data and create documents
422
  # -----------------------------
423
+ with open("data.json", "r", encoding="utf-8") as f:
424
+ data = json.load(f)
425
 
426
  docs = create_documents("json", json_data)
427
  texts = [doc.page_content for doc in docs]