gkb-seo-mcp-server
# gkb-seo-mcp-server v7
Data-driven refactor ของ mcp-GKB-SEO — 20 tools (19 เดิม backward-compatible + `gkb_coverage_report`)
- **เริ่มอ่านที่:** `PR_DESCRIPTION.md` (RCA 11 flaws + สถาปัตยกรรม + tool-by-tool)
- **ติดตั้ง/ย้ายระบบ:** `MIGRATION.md`
- **แก้พฤติกรรม matcher:** แก้ `data/*.json` — ไม่ต้องแตะโค้ด แล้วรัน `gkb_coverage_report`
```
npm install && npm run build && npm test # 37/37
node dist/src/index.js # stdio MCP server
```
## HTTP / URL mode
Build first, then start the Streamable HTTP MCP endpoint:
```powershell
cd "D:\develop\mcp-GKB SEO\v7"
$env:GKB_SEO_ROOT="D:\develop\mcp-GKB SEO\v7"
npm run build
npm run start:http
```
URLs:
- Health check: `http://localhost:3000/health`
- MCP endpoint: `http://localhost:3000/mcp`
Use `PORT` to change the port:
```powershell
$env:PORT="3001"
npm run start:http
```
MCP HTTP clients must send:
```http
Accept: application/json, text/event-stream
Content-Type: application/json
```
## Vercel
This project also includes Vercel serverless adapters:
- `GET /health` -> `api/health.js`
- `POST /mcp` -> `api/mcp.js`
Deploy from the project root:
```powershell
cd "D:\develop\mcp-GKB SEO\v7"
npm run build
vercel
```
After deployment:
- Health check: `https://<your-project>.vercel.app/health`
- MCP endpoint: `https://<your-project>.vercel.app/mcp`
The Vercel deployment uses the bundled `KB/`, `data/`, and compiled `dist/` folders declared in `vercel.json`.
TDQS
Scored across 20 tools
Each tool has a clearly distinct purpose: batch generation, batch processing, bulk analysis, coverage reporting, indexing, manifest summary, micro query, multiple presets for different aspects, query, read content, similarity, rule detail, rule filtering, rule index, smart orchestration, and validation. No significant overlap.
All tools follow the `gkb_` prefix with consistent snake_case naming. Most use a verb_noun pattern (e.g., `batch_process`, `read_kb_content`, `smart_orchestrate`). Minor compound names like `rules_by_purpose` are still consistent with the overall style.
20 tools is slightly high but justified by the complexity of the SEO knowledge base domain. Each tool covers a specific function, and there is no redundancy. A few tools could potentially be merged (e.g., the preset tools), but the count is still reasonable.
The tool surface covers core operations: content generation, batch processing, analysis, introspection, indexing, query, validation, and rule management. Minor gaps exist (e.g., no explicit update or delete tools for KB items), but the server's primary purpose is reading/analyzing the KB, and the descriptions imply external editing of data files.