Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -32,10 +32,12 @@ def process_input(user_input, history):
|
|
| 32 |
return history
|
| 33 |
|
| 34 |
def visualize_memory():
|
| 35 |
-
relationships = reasoner.infer_relationships(memory.memories, model)
|
| 36 |
output_html = visualize_reasoned_graph(memory.memories, relationships)
|
| 37 |
-
|
| 38 |
-
|
|
|
|
|
|
|
|
|
|
| 39 |
# --- UI Layout ---
|
| 40 |
with gr.Blocks(title="Aventra OS — Memory Engine") as demo:
|
| 41 |
gr.Markdown("## 🧠 Aventra Memory Interface")
|
|
|
|
| 32 |
return history
|
| 33 |
|
| 34 |
def visualize_memory():
|
|
|
|
| 35 |
output_html = visualize_reasoned_graph(memory.memories, relationships)
|
| 36 |
+
print(f"✅ Visualization created at: {output_html}")
|
| 37 |
+
if os.path.exists(output_html):
|
| 38 |
+
return f"✅ Memory graph generated successfully!\n\nYou can open it here: {output_html}"
|
| 39 |
+
else:
|
| 40 |
+
return "⚠️ Visualization failed — file not found."
|
| 41 |
# --- UI Layout ---
|
| 42 |
with gr.Blocks(title="Aventra OS — Memory Engine") as demo:
|
| 43 |
gr.Markdown("## 🧠 Aventra Memory Interface")
|