A robust, multi-tenant Smart Assistant backend powered by RAG (Retrieval-Augmented Generation) technology. This service provides intelligent chat interfaces with advanced knowledge retrieval, user authentication, document management, and tenant isolation.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Frontend Application β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β
HTTP/REST (CORS)
β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Express.js Backend (Port 8000) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β ββββββββββββββββββββ ββββββββββββββββββββ β
β β Auth Routes β β Chat Routes β β
β β (Auth/Roles) β β (RAG Pipeline) β β
β ββββββββββββββββββββ ββββββββββββββββββββ β
β ββββββββββββββββββββ ββββββββββββββββββββ β
β β Document Routes β β Session Routes β β
β β (Upload/Parse) β β (Chat History) β β
β ββββββββββββββββββββ ββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β Services Layer β
β ββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β RAG Service β Embedding β Tool Service β β
β β (Main Logic) β Service β (Extensible) β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
βββββββββββββΌββββββββββββ¬ββββββββ΄βββββββββββ
β β β β
MongoDB ChromaDB Ollama Groq API
(Metadata) (Vectors) (Local LLM) (Fallback)
1. User Query (Text)
β
βββ Embedding Service (Generate vector embedding)
β
βββ ChromaDB Query (Retrieve relevant chunks)
β
βββ Adaptive Filtering (Threshold validation)
β
βββ Deduplication (Remove near-duplicates)
β
βββ Context Selection (Diversity & relevance)
β
βββ System Prompt Builder (Domain guidance)
β
βββ Ollama/Groq (Generate answer)
β
βββ Response with Sources + Logging
| Layer | Technology | Purpose |
|---|---|---|
| Runtime | Node.js v20 | JavaScript runtime |
| Framework | Express.js | REST API framework |
| Database | MongoDB | Metadata storage |
| Vector DB | Chroma | Semantic search |
| LLM (Local) | Ollama | Local language model |
| LLM (Cloud) | Groq API | Fallback LLM |
| Auth | JWT | Token-based authentication |
| Hashing | bcryptjs | Password hashing |
| Document Parse | Mammoth, pdf-parse | Document extraction |
| File Upload | Multer | File handling |
| Containerization | Docker | Deployment |
| Dev Tools | Nodemon | Live reload |
git clone https://github.com/sanudasandipa/MarketMatic-Smart-Assistant-backend.git
cd MarketMatic-Smart-Assistant-backend
npm install
Create a .env file in the root directory:
cp .env.example .env
Configure the following variables (see Configuration section).
# Start MongoDB (if local)
mongod
# Seed superadmin user
npm run seed
npm run dev
Visit http://localhost:8000/health to confirm the backend is running.
Create a .env file with the following configuration:
# βββ Server ββββββββββββββββββββββββββββββββββββββββββββββββββββ
NODE_ENV=development
PORT=8000
FRONTEND_URL=http://localhost:3000
# βββ Database ββββββββββββββββββββββββββββββββββββββββββββββββββ
MONGODB_URI=mongodb://localhost:27017/smart-assistant
# OR for cloud:
# MONGODB_URI=mongodb+srv://username:password@cluster.mongodb.net/smart-assistant
# βββ ChromaDB (Vector Database) ββββββββββββββββββββββββββββββββ
CHROMA_HOST=localhost
CHROMA_PORT=8000
CHROMA_COLLECTION_PREFIX=smart_assistant
# βββ Embedding Service ββββββββββββββββββββββββββββββββββββββββ
EMBEDDING_MODEL=sentence-transformers/all-MiniLM-L6-v2
EMBEDDING_DIMENSION=384
# βββ LLM Configuration ββββββββββββββββββββββββββββββββββββββββ
# Ollama (Local)
OLLAMA_URL=http://localhost:11434
OLLAMA_CHAT_MODEL=llama3.1:8b
OLLAMA_TIMEOUT_MS=60000
# Groq API (Fallback/Cloud)
GROQ_API_KEY=your_groq_api_key_here
GROQ_MODEL=llama-3.1-8b-instant
# βββ RAG Configuration ββββββββββββββββββββββββββββββββββββββββ
RAG_RELEVANCE_THRESHOLD=0.35
RAG_CONTEXT_BUDGET_CHARS=8000
RAG_NEAR_DUPLICATE_OVERLAP=0.88
RAG_MAX_HISTORY=10
# βββ JWT βββββββββββββββββββββββββββββββββββββββββββββββββββββββ
JWT_SECRET=your_super_secret_jwt_key_change_in_production
JWT_EXPIRY=7d
# βββ File Upload βββββββββββββββββββββββββββββββββββββββββββββββ
MAX_FILE_SIZE=52428800 # 50MB
UPLOAD_DIR=./uploads
# βββ Optional: Reranking Service ββββββββββββββββββββββββββββββ
# RERANKER_URL=http://localhost:8090
# RERANKER_MODEL=cross-encoder/ms-marco-MiniLM-L-12-v2
# βββ Optional: Domain Configuration βββββββββββββββββββββββββββ
BUSINESS_DOMAIN=pharmacy # pharmacy, electronics, clothing, etc.
Pre-configured domain guidance for:
pharmacy - Medicine availability, health productselectronics - Specs, compatibility, troubleshootingclothing - Sizing, style, care instructionsrestaurant - Menu, hours, reservationsgrocery - Availability, prices, promotionsreal_estate - Listings, inquiries, bookingsautomotive - Specs, servicing, partseducation - Courses, enrollment, feesnpm run dev
The backend will start on http://localhost:8000
npm start
npm run seed
This creates an initial superadmin account. Review the script for credentials.
POST /api/auth/register β Create new user account
POST /api/auth/login β Authenticate user, return JWT
POST /api/auth/logout β Invalidate session
GET /api/auth/verify β Verify JWT token
POST /api/admin/chat β RAG chat (Admin/Auth required)
POST /api/chat β Public chat (Tenant ID required)
POST /api/admin/documents β Upload document
GET /api/admin/documents β List documents
DELETE /api/admin/documents/:id β Delete document
POST /api/admin/documents/reindex β Re-embed all documents
GET /api/admin/sessions β List chat sessions
GET /api/admin/sessions/:id β Get session details
DELETE /api/admin/sessions/:id β Delete session
GET /api/admin/gaps β Get knowledge gaps
POST /api/admin/gaps β Record knowledge gap
GET /api/user/profile β Get user profile
PUT /api/user/profile β Update profile
GET /api/user/memory β Get user memory
POST /api/user/memory β Update user preferences
GET /api/admin/users β List all users
GET /api/admin/stats β Get platform statistics
DELETE /api/admin/users/:id β Remove user
POST /api/superadmin/tenants β Create tenant
GET /api/superadmin/tenants β List tenants
PUT /api/superadmin/tenants/:id β Update tenant
DELETE /api/superadmin/tenants/:id β Delete tenant
GET /api/superadmin/analytics β System analytics
GET /health β Service health status
{
email: String (unique),
password: String (hashed),
firstName: String,
lastName: String,
tenantId: ObjectId,
serviceId: ObjectId,
role: Enum ['user', 'admin', 'superadmin'],
isActive: Boolean,
lastLogin: Date,
createdAt: Date,
updatedAt: Date
}
{
name: String,
description: String,
domain: String,
apiKey: String,
isActive: Boolean,
documentCount: Number,
chatCount: Number,
settings: Object,
createdAt: Date,
updatedAt: Date
}
{
serviceId: ObjectId,
fileName: String,
filePath: String,
fileSize: Number,
fileType: String,
chunkCount: Number,
embeddingComplete: Boolean,
uploadedAt: Date,
updatedAt: Date
}
{
userId: ObjectId,
serviceId: ObjectId,
title: String,
messages: [{
role: 'user' | 'assistant',
content: String,
timestamp: Date
}],
metadata: Object,
createdAt: Date,
updatedAt: Date
}
{
userId: ObjectId,
serviceId: ObjectId,
query: String,
response: String,
retrievedChunks: [String],
relevanceScores: [Number],
responseTime: Number,
model: String,
timestamp: Date
}
{
serviceId: ObjectId,
query: String,
context: String,
frequency: Number,
firstOccurrence: Date,
lastOccurrence: Date,
resolved: Boolean
}
{
userId: ObjectId,
preferences: Object,
history: [Object],
notes: String,
updatedAt: Date
}
MarketMatic-Smart-Assistant-backend/
βββ src/
β βββ server.js # Entry point
β βββ config/
β β βββ database.js # MongoDB connection
β βββ middleware/
β β βββ auth.js # JWT verification, role checks
β βββ models/ # Mongoose schemas
β β βββ User.js
β β βββ Service.js
β β βββ Document.js
β β βββ ChatSession.js
β β βββ RagLog.js
β β βββ KnowledgeGap.js
β β βββ UserMemory.js
β βββ routes/ # Express route handlers
β β βββ auth.js
β β βββ admin.js
β β βββ superadmin.js
β β βββ user.js
β β βββ documents.js
β β βββ chat.js # RAG chat endpoints
β β βββ sessions.js
β βββ services/ # Business logic
β β βββ ragService.js # Core RAG pipeline
β β βββ chromaService.js # Vector DB operations
β β βββ embeddingService.js # Embeddings
β β βββ toolService.js # Tool execution
β β βββ rerankerService.js # Reranking (optional)
β β βββ insightsService.js # Analytics
β βββ scripts/ # Utility scripts
β β βββ seedSuperadmin.js
β β βββ reEmbed.js
β β βββ reUpload.js
β βββ utils/
β βββ chromaManager.js # Chroma connectivity
β βββ tokenHelper.js # JWT utilities
βββ scripts/
β βββ reEmbedAll.js # Batch re-embedding
βββ docker-compose.yml # Multi-container orchestration
βββ Dockerfile # Container image
βββ package.json # Dependencies & scripts
βββ .env.example # Environment template
βββ README.md # This file
# Build and start all services
docker-compose up -d
# Stop services
docker-compose down
# View logs
docker-compose logs -f backend
Services:
- backend (Node.js backend on port 8000)
- mongodb (MongoDB on port 27017, internal only)
- chroma (ChromaDB on port 8000, internal only)
docker build -t smart-assistant-backend:1.0 .
# Run container
docker run -p 8000:8000 \
--env-file .env \
-v smart-assistant-data:/app/chroma_data \
smart-assistant-backend:1.0
See AZURE_DEPLOYMENT.md for detailed Azure VM setup instructions.
# Install ESLint (optional)
npm install --save-dev eslint
# Run linter
npm run lint
npm run dev
Uses Nodemon to automatically restart on file changes.
npm test
For schema changes:
src/scripts/migrations/node src/scripts/migrations/migrate-name.jsSolution:
# Check MongoDB is running
mongod
# Or update MONGODB_URI in .env
MONGODB_URI=mongodb+srv://user:pass@cluster.mongodb.net/db
Solution:
# Ensure ChromaDB is running
# If using Docker Compose:
docker-compose up -d chroma
# Or manually:
chroma run --host localhost --port 8000
Solution:
# Reduce timeout or use Groq API:
OLLAMA_TIMEOUT_MS=30000
# Enable Groq fallback:
GROQ_API_KEY=your_key
Solution:
# Verify JWT_SECRET is set correctly
echo $JWT_SECRET
# Regenerate token by logging in again
curl -X POST http://localhost:8000/api/auth/login \
-H "Content-Type: application/json" \
-d '{"email":"admin@example.com","password":"password"}'
Solution:
# Increase Node.js heap size
export NODE_OPTIONS=--max-old-space-size=4096
npm start
# Or in Docker:
docker run -e NODE_OPTIONS="--max-old-space-size=4096" ...
Solution:
# Update FRONTEND_URL in .env
FRONTEND_URL=http://your-frontend-domain.com
curl http://localhost:8000/health
# Response:
# {
# "status": "ok",
# "service": "smart-assistant-backend",
# "timestamp": "2025-05-08T10:30:00.000Z"
# }
# View all services
docker-compose logs -f
# View specific service
docker-compose logs -f backend
# Follow with timestamps
docker-compose logs -f --timestamps
git checkout -b feature/your-featuregit commit -am 'Add feature'git push origin feature/your-featureThis project is licensed under the MIT License β see LICENSE file for details.
Built with β€οΈ by MarketMatic Team
Last Updated: May 8, 2026
29 commits
JavaScript
83.6%
Shell
12.8%
Python
2.9%
A robust, multi-tenant Smart Assistant backend powered by RAG (Retrieval-Augmented Generation) technology. This service provides intelligent chat interfaces with advanced knowledge retrieval, user authentication, document management, and tenant isolation.
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Frontend Application β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β
HTTP/REST (CORS)
β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Express.js Backend (Port 8000) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β ββββββββββββββββββββ ββββββββββββββββββββ β
β β Auth Routes β β Chat Routes β β
β β (Auth/Roles) β β (RAG Pipeline) β β
β ββββββββββββββββββββ ββββββββββββββββββββ β
β ββββββββββββββββββββ ββββββββββββββββββββ β
β β Document Routes β β Session Routes β β
β β (Upload/Parse) β β (Chat History) β β
β ββββββββββββββββββββ ββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β Services Layer β
β ββββββββββββββββββββββββββββββββββββββββββββββββββ β
β β RAG Service β Embedding β Tool Service β β
β β (Main Logic) β Service β (Extensible) β β
β ββββββββββββββββββββββββββββββββββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
βββββββββββββΌββββββββββββ¬ββββββββ΄βββββββββββ
β β β β
MongoDB ChromaDB Ollama Groq API
(Metadata) (Vectors) (Local LLM) (Fallback)
1. User Query (Text)
β
βββ Embedding Service (Generate vector embedding)
β
βββ ChromaDB Query (Retrieve relevant chunks)
β
βββ Adaptive Filtering (Threshold validation)
β
βββ Deduplication (Remove near-duplicates)
β
βββ Context Selection (Diversity & relevance)
β
βββ System Prompt Builder (Domain guidance)
β
βββ Ollama/Groq (Generate answer)
β
βββ Response with Sources + Logging
| Layer | Technology | Purpose |
|---|---|---|
| Runtime | Node.js v20 | JavaScript runtime |
| Framework | Express.js | REST API framework |
| Database | MongoDB | Metadata storage |
| Vector DB | Chroma | Semantic search |
| LLM (Local) | Ollama | Local language model |
| LLM (Cloud) | Groq API | Fallback LLM |
| Auth | JWT | Token-based authentication |
| Hashing | bcryptjs | Password hashing |
| Document Parse | Mammoth, pdf-parse | Document extraction |
| File Upload | Multer | File handling |
| Containerization | Docker | Deployment |
| Dev Tools | Nodemon | Live reload |
git clone https://github.com/sanudasandipa/MarketMatic-Smart-Assistant-backend.git
cd MarketMatic-Smart-Assistant-backend
npm install
Create a .env file in the root directory:
cp .env.example .env
Configure the following variables (see Configuration section).
# Start MongoDB (if local)
mongod
# Seed superadmin user
npm run seed
npm run dev
Visit http://localhost:8000/health to confirm the backend is running.
Create a .env file with the following configuration:
# βββ Server ββββββββββββββββββββββββββββββββββββββββββββββββββββ
NODE_ENV=development
PORT=8000
FRONTEND_URL=http://localhost:3000
# βββ Database ββββββββββββββββββββββββββββββββββββββββββββββββββ
MONGODB_URI=mongodb://localhost:27017/smart-assistant
# OR for cloud:
# MONGODB_URI=mongodb+srv://username:password@cluster.mongodb.net/smart-assistant
# βββ ChromaDB (Vector Database) ββββββββββββββββββββββββββββββββ
CHROMA_HOST=localhost
CHROMA_PORT=8000
CHROMA_COLLECTION_PREFIX=smart_assistant
# βββ Embedding Service ββββββββββββββββββββββββββββββββββββββββ
EMBEDDING_MODEL=sentence-transformers/all-MiniLM-L6-v2
EMBEDDING_DIMENSION=384
# βββ LLM Configuration ββββββββββββββββββββββββββββββββββββββββ
# Ollama (Local)
OLLAMA_URL=http://localhost:11434
OLLAMA_CHAT_MODEL=llama3.1:8b
OLLAMA_TIMEOUT_MS=60000
# Groq API (Fallback/Cloud)
GROQ_API_KEY=your_groq_api_key_here
GROQ_MODEL=llama-3.1-8b-instant
# βββ RAG Configuration ββββββββββββββββββββββββββββββββββββββββ
RAG_RELEVANCE_THRESHOLD=0.35
RAG_CONTEXT_BUDGET_CHARS=8000
RAG_NEAR_DUPLICATE_OVERLAP=0.88
RAG_MAX_HISTORY=10
# βββ JWT βββββββββββββββββββββββββββββββββββββββββββββββββββββββ
JWT_SECRET=your_super_secret_jwt_key_change_in_production
JWT_EXPIRY=7d
# βββ File Upload βββββββββββββββββββββββββββββββββββββββββββββββ
MAX_FILE_SIZE=52428800 # 50MB
UPLOAD_DIR=./uploads
# βββ Optional: Reranking Service ββββββββββββββββββββββββββββββ
# RERANKER_URL=http://localhost:8090
# RERANKER_MODEL=cross-encoder/ms-marco-MiniLM-L-12-v2
# βββ Optional: Domain Configuration βββββββββββββββββββββββββββ
BUSINESS_DOMAIN=pharmacy # pharmacy, electronics, clothing, etc.
Pre-configured domain guidance for:
pharmacy - Medicine availability, health productselectronics - Specs, compatibility, troubleshootingclothing - Sizing, style, care instructionsrestaurant - Menu, hours, reservationsgrocery - Availability, prices, promotionsreal_estate - Listings, inquiries, bookingsautomotive - Specs, servicing, partseducation - Courses, enrollment, feesnpm run dev
The backend will start on http://localhost:8000
npm start
npm run seed
This creates an initial superadmin account. Review the script for credentials.
POST /api/auth/register β Create new user account
POST /api/auth/login β Authenticate user, return JWT
POST /api/auth/logout β Invalidate session
GET /api/auth/verify β Verify JWT token
POST /api/admin/chat β RAG chat (Admin/Auth required)
POST /api/chat β Public chat (Tenant ID required)
POST /api/admin/documents β Upload document
GET /api/admin/documents β List documents
DELETE /api/admin/documents/:id β Delete document
POST /api/admin/documents/reindex β Re-embed all documents
GET /api/admin/sessions β List chat sessions
GET /api/admin/sessions/:id β Get session details
DELETE /api/admin/sessions/:id β Delete session
GET /api/admin/gaps β Get knowledge gaps
POST /api/admin/gaps β Record knowledge gap
GET /api/user/profile β Get user profile
PUT /api/user/profile β Update profile
GET /api/user/memory β Get user memory
POST /api/user/memory β Update user preferences
GET /api/admin/users β List all users
GET /api/admin/stats β Get platform statistics
DELETE /api/admin/users/:id β Remove user
POST /api/superadmin/tenants β Create tenant
GET /api/superadmin/tenants β List tenants
PUT /api/superadmin/tenants/:id β Update tenant
DELETE /api/superadmin/tenants/:id β Delete tenant
GET /api/superadmin/analytics β System analytics
GET /health β Service health status
{
email: String (unique),
password: String (hashed),
firstName: String,
lastName: String,
tenantId: ObjectId,
serviceId: ObjectId,
role: Enum ['user', 'admin', 'superadmin'],
isActive: Boolean,
lastLogin: Date,
createdAt: Date,
updatedAt: Date
}
{
name: String,
description: String,
domain: String,
apiKey: String,
isActive: Boolean,
documentCount: Number,
chatCount: Number,
settings: Object,
createdAt: Date,
updatedAt: Date
}
{
serviceId: ObjectId,
fileName: String,
filePath: String,
fileSize: Number,
fileType: String,
chunkCount: Number,
embeddingComplete: Boolean,
uploadedAt: Date,
updatedAt: Date
}
{
userId: ObjectId,
serviceId: ObjectId,
title: String,
messages: [{
role: 'user' | 'assistant',
content: String,
timestamp: Date
}],
metadata: Object,
createdAt: Date,
updatedAt: Date
}
{
userId: ObjectId,
serviceId: ObjectId,
query: String,
response: String,
retrievedChunks: [String],
relevanceScores: [Number],
responseTime: Number,
model: String,
timestamp: Date
}
{
serviceId: ObjectId,
query: String,
context: String,
frequency: Number,
firstOccurrence: Date,
lastOccurrence: Date,
resolved: Boolean
}
{
userId: ObjectId,
preferences: Object,
history: [Object],
notes: String,
updatedAt: Date
}
MarketMatic-Smart-Assistant-backend/
βββ src/
β βββ server.js # Entry point
β βββ config/
β β βββ database.js # MongoDB connection
β βββ middleware/
β β βββ auth.js # JWT verification, role checks
β βββ models/ # Mongoose schemas
β β βββ User.js
β β βββ Service.js
β β βββ Document.js
β β βββ ChatSession.js
β β βββ RagLog.js
β β βββ KnowledgeGap.js
β β βββ UserMemory.js
β βββ routes/ # Express route handlers
β β βββ auth.js
β β βββ admin.js
β β βββ superadmin.js
β β βββ user.js
β β βββ documents.js
β β βββ chat.js # RAG chat endpoints
β β βββ sessions.js
β βββ services/ # Business logic
β β βββ ragService.js # Core RAG pipeline
β β βββ chromaService.js # Vector DB operations
β β βββ embeddingService.js # Embeddings
β β βββ toolService.js # Tool execution
β β βββ rerankerService.js # Reranking (optional)
β β βββ insightsService.js # Analytics
β βββ scripts/ # Utility scripts
β β βββ seedSuperadmin.js
β β βββ reEmbed.js
β β βββ reUpload.js
β βββ utils/
β βββ chromaManager.js # Chroma connectivity
β βββ tokenHelper.js # JWT utilities
βββ scripts/
β βββ reEmbedAll.js # Batch re-embedding
βββ docker-compose.yml # Multi-container orchestration
βββ Dockerfile # Container image
βββ package.json # Dependencies & scripts
βββ .env.example # Environment template
βββ README.md # This file
# Build and start all services
docker-compose up -d
# Stop services
docker-compose down
# View logs
docker-compose logs -f backend
Services:
- backend (Node.js backend on port 8000)
- mongodb (MongoDB on port 27017, internal only)
- chroma (ChromaDB on port 8000, internal only)
docker build -t smart-assistant-backend:1.0 .
# Run container
docker run -p 8000:8000 \
--env-file .env \
-v smart-assistant-data:/app/chroma_data \
smart-assistant-backend:1.0
See AZURE_DEPLOYMENT.md for detailed Azure VM setup instructions.
# Install ESLint (optional)
npm install --save-dev eslint
# Run linter
npm run lint
npm run dev
Uses Nodemon to automatically restart on file changes.
npm test
For schema changes:
src/scripts/migrations/node src/scripts/migrations/migrate-name.jsSolution:
# Check MongoDB is running
mongod
# Or update MONGODB_URI in .env
MONGODB_URI=mongodb+srv://user:pass@cluster.mongodb.net/db
Solution:
# Ensure ChromaDB is running
# If using Docker Compose:
docker-compose up -d chroma
# Or manually:
chroma run --host localhost --port 8000
Solution:
# Reduce timeout or use Groq API:
OLLAMA_TIMEOUT_MS=30000
# Enable Groq fallback:
GROQ_API_KEY=your_key
Solution:
# Verify JWT_SECRET is set correctly
echo $JWT_SECRET
# Regenerate token by logging in again
curl -X POST http://localhost:8000/api/auth/login \
-H "Content-Type: application/json" \
-d '{"email":"admin@example.com","password":"password"}'
Solution:
# Increase Node.js heap size
export NODE_OPTIONS=--max-old-space-size=4096
npm start
# Or in Docker:
docker run -e NODE_OPTIONS="--max-old-space-size=4096" ...
Solution:
# Update FRONTEND_URL in .env
FRONTEND_URL=http://your-frontend-domain.com
curl http://localhost:8000/health
# Response:
# {
# "status": "ok",
# "service": "smart-assistant-backend",
# "timestamp": "2025-05-08T10:30:00.000Z"
# }
# View all services
docker-compose logs -f
# View specific service
docker-compose logs -f backend
# Follow with timestamps
docker-compose logs -f --timestamps
git checkout -b feature/your-featuregit commit -am 'Add feature'git push origin feature/your-featureThis project is licensed under the MIT License β see LICENSE file for details.
Built with β€οΈ by MarketMatic Team
Last Updated: May 8, 2026
29 commits
JavaScript
83.6%
Shell
12.8%
Python
2.9%