Back to Home
jeffgreendesign icon

textrawl

Verified Safe

by jeffgreendesign

Overview

Serves as a personal knowledge base allowing AI models (e.g., Claude) to search, retrieve, and add documents, emails, notes, and web pages from a user's collection.

Installation

Run Command
npx tsx watch --env-file=.env src/index.ts

Environment Variables

  • SUPABASE_URL
  • SUPABASE_SERVICE_KEY
  • OPENAI_API_KEY
  • OLLAMA_BASE_URL
  • OLLAMA_MODEL
  • API_BEARER_TOKEN
  • PORT
  • NODE_ENV
  • LOG_LEVEL
  • ALLOWED_ORIGINS
  • ENABLE_MEMORY
  • COMPACT_RESPONSES
  • UI_PORT

Security Notes

The server demonstrates strong security practices including `timingSafeEqual` for bearer token comparison to prevent timing attacks, robust rate limiting across API endpoints to prevent DoS, and careful sanitization of user-provided filenames and output paths to mitigate path traversal and injection risks. Configuration is loaded from environment variables, with a production check for `API_BEARER_TOKEN`. Error handling avoids leaking stack traces in production. Input validation (file types, tag limits) is implemented for uploads. The `validateOutputDir` function is a good example of defense-in-depth against directory traversal by ensuring paths are within allowed base directories. Database interactions rely on the Supabase client and RPCs, which are generally safe against SQL injection if the underlying functions are parameterized.

Similar Servers

Stats

Interest Score31
Security Score9
Cost ClassMedium
Avg Tokens3000
Stars1
Forks0
Last Update2026-01-19

Tags

knowledge basesemantic searchRAGdocument processingAI toolsMCPembeddings