Compare commits

..

No commits in common. "prod-hotfixes-20260523" and "main" have entirely different histories.

3 changed files with 5 additions and 37 deletions

View file

@ -2,7 +2,6 @@
import json
import logging
import os
import time
from datetime import datetime
from typing import List, Dict, Any, Optional
@ -10,8 +9,7 @@ from contextlib import asynccontextmanager
from fastapi import FastAPI, HTTPException, BackgroundTasks, Depends, Security, Request
from fastapi.middleware.cors import CORSMiddleware
from fastapi.responses import JSONResponse, StreamingResponse, FileResponse
from fastapi.staticfiles import StaticFiles
from fastapi.responses import JSONResponse, StreamingResponse
import structlog
import asyncio
from slowapi import Limiter, _rate_limit_exceeded_handler
@ -918,29 +916,6 @@ except Exception as e:
logger.error(f"Failed to mount MCP server: {e}")
# Serve frontend static files
# This must be AFTER all API routes to avoid catching API requests
FRONTEND_DIR = "/app/frontend"
@app.get("/")
async def serve_frontend_root():
"""Serve the frontend application."""
index_path = os.path.join(FRONTEND_DIR, "index.html")
if os.path.exists(index_path):
return FileResponse(index_path)
return JSONResponse(
status_code=404,
content={"error": "Frontend not found", "path": index_path}
)
# Mount static files for any assets in the frontend directory (CSS, JS, images, etc.)
if os.path.exists(FRONTEND_DIR):
app.mount("/static", StaticFiles(directory=FRONTEND_DIR), name="static")
logger.info(f"Frontend static files mounted from {FRONTEND_DIR}")
else:
logger.warning(f"Frontend directory not found at {FRONTEND_DIR}")
if __name__ == "__main__":
import uvicorn

View file

@ -82,11 +82,10 @@ class Mem0Manager:
},
},
"embedder": {
"provider": "openai",
"provider": "ollama",
"config": {
"model": settings.embedding_model,
"api_key": settings.openai_api_key,
"openai_base_url": settings.openai_base_url,
"ollama_base_url": settings.ollama_base_url,
"embedding_dims": settings.embedding_dims,
},
},

View file

@ -20,7 +20,7 @@ services:
# Neo4j with APOC for graph relationships
neo4j:
image: neo4j:latest
image: neo4j:5.26.4
container_name: mem0-neo4j
environment:
NEO4J_AUTH: ${NEO4J_AUTH:-neo4j/mem0_neo4j_password}
@ -82,12 +82,6 @@ services:
condition: service_healthy
neo4j:
condition: service_healthy
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
interval: 30m
timeout: 30s
retries: 3
start_period: 10s
restart: unless-stopped
volumes:
- ./backend:/app
@ -102,6 +96,6 @@ volumes:
neo4j_plugins:
networks:
mem0_network:
npm_network:
external: true
mem0_network: