Back to Home
jeremylem icon

mcp_server4j

Verified Safe

by jeremylem

Overview

Provides a local knowledge base using a Model Context Protocol (MCP) server that supports hybrid search (BM25 + vector similarity) over various document formats (PDF, Markdown, TXT).

Installation

Run Command
docker-compose up -d

Environment Variables

  • SERVER_PORT
  • CHROMA_HOST
  • CHROMA_PORT
  • CHROMA_COLLECTION
  • SPRING_PROFILES_ACTIVE
  • RETRIEVAL_BM25_WEIGHT
  • RETRIEVAL_VECTOR_WEIGHT
  • RETRIEVAL_CANDIDATE_POOL_SIZE

Security Notes

The server architecture follows sound security practices for a Java Spring Boot application. It does not use 'eval' or similar dangerous patterns. Input sanitization is applied to Lucene queries to prevent injection. Configuration is externalized through application.yml and environment variables, with no hardcoded secrets found in the provided code. External libraries like Apache Lucene, LangChain4j, Apache Tika, and PDFBox are well-established. The primary security consideration relates to the ingestion of untrusted documents via Apache Tika/PDFBox parsers, which could theoretically expose vulnerabilities in these libraries. However, the ingestion pipeline is designed as a separate CLI tool invoked by the user, implying a controlled and trusted source of documents, rather than direct exposure to untrusted external clients in the running server.

Similar Servers

Stats

Interest Score0
Security Score9
Cost ClassLow
Avg Tokens650
Stars0
Forks0
Last Update2025-11-30

Tags

RAGKnowledge BaseHybrid SearchMCPJavaSpring BootChromaDB