
oscillatelabsllc/kiwix-mcp
Developer tools이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요. 원문 보기
MCP 서버 및 Python 클라이언트 라이브러리 Kiwix HTTP 서버.
개요
MCP 서버 및 Python 클라이언트 라이브러리 Kiwix HTTP 서버. 테스트 (Debian bookworm 패키지) 및 더 새로운 - 기반 배포. 모든 표준 kiwix-serve 배포가 작동해야합니다. - kiwix-serve는 unescaped 및 OPDS 카탈로그 href 속성을 방출합니다. 더 새로운 서버는 라이브러리가 여러 언어에 걸쳐 있을 때 책 범위를 필요로 합니다. 클라이언트는 그 경우 지침에 따라 명확한 오류를 반환합니다. 더 새로운 서버는 path-prefixed URL 계획 (예 : /kiwix/content/book slug) - slug 및 기사 URL 처리가 자동으로 적응시킵니다. Claude 데스크탑 구성 (~/Library/Application Support/Claude/claude desktop config.json): Claude Code — 사용자 범위에 추가하므로 모든 프로젝트에 사용할 수 있습니다. 그런 다음 MCP 클라이언트를 http://localhost:8000/sse.] 그런 다음 MCP 클라이언트를 http://localhost:8000/mcp. 브라우저 기반 MCP 클라이언트 (예: llama-server WebUI)와 HTTP 전송을 사용할 때, CORS 헤더가 자동으로 추가됩니다. 기본적으로 모든 기원이 허용됩니다.
개요(AI 번역)
MCP 서버 및 Python 클라이언트 라이브러리 Kiwix HTTP 서버.
호환성
kiwix-tools (Debian bookworm 패키지) 및 newer libkiwix 기반 배포에 대해 테스트했습니다. 모든 표준 kiwix-serve 배포가 작동해야합니다.
quirks는 투명하게 취급했습니다:
- kiwix-serve는 OPDS 카탈로그에서 unescaped
&을 방출href속성 - Newer 서버는 라이브러리가 여러 언어를 돌릴 때 책 범위를 요구합니다. - 클라이언트는 그 경우의 지시와 명확한 오류를 반환합니다.
- Newer 서버는 path-prefixed URL 계획 (예를들면
/kiwix/content/book_slug])을 사용한다. - slug 및 article URL 처리는 자동으로 적응한다.
도구
| 도구 | 설명 |
|---|---|
| [T5] | ZIM 서적, 선택 제목 필터 |
kiwix_search |
모든 서적 또는 특정 서적의 전체 텍스트 검색 |
kiwix_fetch_article |
URL로 일반 텍스트로 기사를 구합니다 |
설치
또는 uv로:
사용법
stdio (클래드 데스크탑/클래드 부호)
Claude 데스크탑 구성 (~/Library/Application Support/Claude/claude_desktop_config.json):
Claude Code — 사용자 범위에 추가하므로 모든 프로젝트에 사용할 수 있습니다.
# # # SSE # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
이 페이지는 AI로 자동 번역되었습니다. 기술적인 세부 사항은 원문을 확인하세요.
README
원문 README의 일부입니다. 원문 보기.
kiwix-mcp
MCP server and Python client library for Kiwix HTTP servers.
Compatibility
Tested against kiwix-tools (Debian bookworm package) and newer libkiwix-based deployments. Any standard kiwix-serve deployment should work.
Known quirks handled transparently:
- kiwix-serve emits unescaped
&in OPDS cataloghrefattributes - Newer servers require a book scope when the library spans multiple languages — the client returns a clear error with instructions in that case
- Newer servers use a path-prefixed URL scheme (e.g.
/kiwix/content/book_slug) — slug and article URL handling adapts automatically
Tools
| Tool | Description |
|---|---|
kiwix_list_books |
List available ZIM books; optional title filter |
kiwix_search |
Full-text search across all books or a specific book |
kiwix_fetch_article |
Fetch an article as plain text by URL |
Installation
pip install kiwix-mcp
Or with uv:
uv pip install kiwix-mcp
Usage
stdio (Claude Desktop / Claude Code)
kiwix-mcp --base-url http://localhost:8080
# or
KIWIX_BASE_URL=http://localhost:8080 kiwix-mcp
Claude Desktop config (~/Library/Application Support/Claude/claude_desktop_config.json):
{
"mcpServers": {
"kiwix": {
"command": "kiwix-mcp",
"args": ["--base-url", "http://localhost:8080"]
}
}
}
Claude Code — add at user scope so it’s available in all projects:
claude mcp add --scope user --transport http kiwix https://your-kiwix-mcp-host/mcp/
SSE
kiwix-mcp --transport sse --base-url http://localhost:8080
Then point your MCP client at http://localhost:8000/sse.
HTTP (streamable)
kiwix-mcp --transport streamable-http --base-url http://localhost:8080
Then point your MCP client at http://localhost:8000/mcp.
CORS (browser-based clients)
When using HTTP transports with browser-based MCP clients (e.g. llama-server WebUI), CORS headers are added automatically. By default all origins are allowed.
To restrict allowed origins:
kiwix-mcp --transport streamable-http --base-url http://localhost:8080 \
--cors-allow-origins "http://localhost:3000,http://myapp.example.com"
# or
CORS_ALLOW_ORIGINS="http://localhost:3000" kiwix-mcp --transport streamable-http --base-url http://localhost:8080
CORS has no effect on stdio transport.
Docker
설치
docker run -e KIWIX_BASE_URL=http://your-kiwix-server:8080 \설정
{
"mcpServers": {
"kiwix": {
"command": "kiwix-mcp",
"args": ["--base-url", "http://localhost:8080"]
}
}
}