hadith-mcp

hadith-mcp

An MCP server for retrieving hadith text and metadata from auditable sources, providing exact references, Arabic text, English translations, and source-attributed grading.

Category
访问服务器

README

hadith-mcp

hadith-mcp is a Model Context Protocol server for retrieving hadith text and metadata from auditable sources.

The project goal is to give AI assistants and developer tools a strict source layer for the Sunnah: exact references, Arabic text, available English translations, source-attributed grading, and clear provenance. The MCP server should retrieve and cite source material; it should not act as a mufti or generate unsupported religious claims.

V1 Direction

  • TypeScript MCP server distributed as a local npm package.
  • Read-only SQLite database with FTS5 search.
  • Initial target scope: the Six Books.
  • Arabic text required for imported hadith.
  • English text included when the selected source provides it.
  • Grades exposed only when they are source-attributed.
  • No model-generated explanation or interpretation returned by MCP tools.

Implemented MCP Tools

  • list_collections
  • fetch_hadith
  • search_hadith
  • validate_hadith_reference
  • get_hadith_metadata
  • get_hadith_grade

See docs/mcp-tools.md for the implemented interface.

See docs/client-setup.md for local MCP client configuration examples.

See docs/v1-build-plan.md for the implementation plan, release gates, and first sprint.

See docs/future-product-plan.md for how this MCP should support a later Quran/Hadith AI product in a separate repository.

Local Development

npm install
npm run typecheck
npm test
npm run build
npm run audit:meeatif-hadith-datasets
npm run build:fixture-sqlite
npm run build:meeatif-sqlite
npm run docs:dev
node packages/hadith-mcp/dist/cli.js
HADITH_MCP_DB_PATH=data/generated/hadith-meeatif.sqlite node packages/hadith-mcp/dist/cli.js

Without HADITH_MCP_DB_PATH, the MCP server runs against synthetic fixture records for schema and client integration tests. The fixture records are not real hadith text and must not be used for religious claims.

The meeAtif audit command writes the active candidate-source report to data/generated/.

The fixture SQLite command writes a synthetic non-release database to data/generated/hadith-fixture.sqlite.

The meeAtif SQLite command writes a local candidate database to data/generated/hadith-meeatif.sqlite and import reports to data/generated/hadith-meeatif-import-report.{json,md} after the project owner accepted the source-chain risk for local v1 import work. Set HADITH_MCP_DB_PATH to this database path to run SQLite-backed MCP tools locally. Generated SQLite artifacts remain ignored by git until a later release decision includes the required data-license notice.

The meeAtif importer uses in-book references as canonical hadith_number values, such as 10:1, rather than simple collection-wide numbers. SQLite-backed lookup also accepts collection-prefixed references such as bukhari:10:1 and source references such as https://sunnah.com/bukhari:603 or bukhari:603 when the source row provides them. Use validate_hadith_reference for suggestions when an exact lookup misses.

The docs website lives in apps/docs and is built with Next.js and Tailwind CSS. During development it runs at http://127.0.0.1:3000 by default. Arabic is the default page at /, with English at /en.

Future Product Direction

The Hadith MCP is intended to become one source layer for a broader Islamic source retrieval product that should live in a separate repository:

  • Tafsir MCP handles Quran and tafsir retrieval.
  • Hadith MCP handles Sunnah retrieval.
  • A public web app can orchestrate both.
  • An open-source/open-weight model can provide retrieval-grounded cited answers, using the MCPs as the source of truth.

Current Status

This repository currently contains the project plan, source policy, v1 build plan, a TypeScript MCP server with fixture and SQLite-backed modes, and a local meeAtif import path for candidate SQLite builds.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选