mcp-file-processor

v0.1.1
io.github.IntelagentStudios/mcp-file-processor Checked 12 hours ago Published 8 months ago

Text extraction, keyword extraction, language detection, and chunking for RAG

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

extract_text

Extract text content from a file. Supports PDF, DOCX, CSV, JSON, Markdown, HTML, and code files. Pass file content as base64 (for binary formats like PDF/DOCX) or raw text (for text formats). Returns extracted text, word count, and processing time.

ParameterTypeDescription
content *stringFile content — base64-encoded for binary formats (PDF, DOCX), raw text for text formats
fileType *stringMIME type (e.g. "application/pdf") or file extension (e.g. ".pdf", "pdf", ".ts")

extract_keywords

Extract ranked keywords from text. Returns keywords sorted by frequency, useful for tagging, search indexing, and topic identification.

ParameterTypeDescription
text *stringText to extract keywords from
limitnumberMaximum number of keywords to return (default: 20)

detect_language

Detect whether content is code, natural language, or mixed. Optionally detects the programming language from file extension. Useful for routing content to appropriate processing pipelines.

ParameterTypeDescription
text *stringText content to analyse
fileNamestringOptional file name for extension-based detection (e.g. "app.ts")

chunk_text

Split text into overlapping chunks suitable for RAG/embedding pipelines. Configurable chunk size and overlap. Returns chunks with positional metadata.

ParameterTypeDescription
text *stringText to split into chunks
chunkSizenumberTarget chunk size in characters (default: 1000)
overlapnumberOverlap between chunks in characters (default: 200)

process_file

All-in-one file processing: extract text, detect content type, extract keywords, and chunk for RAG. Returns the complete processed result in a single call.

ParameterTypeDescription
content *stringFile content — base64-encoded for binary formats (PDF, DOCX), raw text for text formats
fileType *stringMIME type or file extension (e.g. "application/pdf", ".md", "csv")
chunkOverlapnumberOverlap between chunks in characters (default: 200)
chunkSizenumberTarget chunk size in characters (default: 1000)
keywordLimitnumberMaximum keywords to extract (default: 20)

server_info

Returns server metadata: name, version, registered tools, and registered resources. Useful for introspection and health checks.