Price Per TokenPrice Per Token
Ziwei & Bazi Astrology

Ziwei & Bazi Astrology

by spyfree

GitHub 2 2,006 uses Remote
0

About

Mingli (命理) is a traditional Chinese astrology and destiny analysis service that generates detailed fortune charts using Ziwei Doushu (紫微斗数) and Bazi (八字/Four Pillars) systems based on birth date, time, and gender. Key features: - Ziwei Doushu chart generation with 12 palaces, main stars, auxiliary stars, and transformation indicators - Bazi/Four Pillars analysis with heavenly stems, earthly branches, Ten Gods, and hidden stems - Fortune predictions across multiple time scales: decades (大限), years (流年), months (流月), days (流日), and hours (流时) - Five Elements (五行) analysis with scoring, balance assessment, and missing element identification - Palace-specific analysis for destiny, career, wealth, relationships, health, and more - True solar time correction supporting 200+ cities worldwide for precise hour determination - Multi-language output: Simplified Chinese, Traditional Chinese, English, Japanese, Korean, and Vietnamese - Multiple calendar support: solar and lunar date inputs - Output formats: JSON and Markdown

Tools 7

get_ziwei_chart

获取紫微斗数排盘信息,包含命盘十二宫、主星、辅星、四化等详细信息

get_ziwei_fortune

获取紫微斗数运势信息,包含大限、流年、流月、流日、流时的运势详情

analyze_ziwei_palace

分析紫微斗数特定宫位的详细信息

list_fortune_systems

列出所有可用的命理系统(紫微斗数、八字、占星等)

get_bazi_chart

获取八字(四柱)排盘信息,包含年月日时四柱、十神、五行、地支藏干等详细信息

get_bazi_fortune

获取八字运势信息,包含大运、流年等详情

analyze_bazi_element

分析八字五行强弱,包含五行分数、平衡度、缺失五行等

README

命理MCP服务 (Mingli MCP Server)

一个支持多种命理系统(紫微斗数、八字、占星等)的 Model Context Protocol (MCP) 服务器,专为 AI 工具(如 Cursor IDE)设计。

✨ 特性

🎯 核心特性

  • 多命理系统支持: 采用插件化架构,轻松扩展新的命理系统
  • - ✅ 紫微斗数(已实现) - ✅ 八字(已实现)⭐ 新增 - 🔄 西方占星(预留接口)
  • 多语言支持: 支持6种语言输出 ⭐ 新增
  • - 🇨🇳 简体中文 (zh-CN) - 🇹🇼 繁体中文 (zh-TW) - 🇺🇸 English (en-US) - 🇯🇵 日本語 (ja-JP) - 🇰🇷 한국어 (ko-KR) - 🇻🇳 Tiếng Việt (vi-VN)
  • 多传输方式: 支持stdio、HTTP、WebSocket等多种传输协议
  • MCP标准兼容: 完全兼容 MCP 协议规范
  • 易于扩展: 清晰的抽象层设计,添加新系统只需3步
  • 🔮 紫微斗数功能

  • 完整排盘: 十二宫、主星、辅星、杂耀、四化等
  • 运势查询: 大限、流年、流月、流日、流时
  • 宫位分析: 深度分析特定宫位的星曜配置
  • 多种历法: 支持阳历和农历输入
  • 格式化输出: JSON和Markdown两种输出格式
  • 真太阳时: 支持全球200+城市的精确时辰修正 新功能
  • 🎴 八字功能 ⭐ 新增

  • 四柱排盘: 年月日时四柱、天干地支详细信息
  • 十神分析: 比肩、劫财、食神、伤官、偏财、正财、七杀、正官、偏印、正印
  • 五行分析: 金木水火土分数、百分比、平衡度
  • 地支藏干: 详细的地支藏干信息
  • 运势查询: 大运、流年分析
  • 缺失分析: 自动识别五行缺失并给出建议
  • 多种历法: 支持阳历和农历输入
  • 真太阳时: 支持全球200+城市的精确时辰修正 新功能
  • ---

    📚 文档导航

    新用户推荐阅读路径

    1. 快速开始指南 ⭐ - 5分钟快速上手 - 安装方法(uvx、pip、Docker) - IDE配置示例 - 第一次排盘体验

    2. 用户指南 - 完整功能说明 - 所有工具详解 - 参数说明 - 输出格式对比 - 使用限制

    3. 真太阳时使用指南 ⭐ - 精确时辰修正(新功能) - 200+全球城市支持 - 自动时辰修正 - 适用于西北地区

    4. API使用示例 - 17个实用代码示例 - 基础用法 - 紫微斗数、八字示例 - 高级模式(批量处理、错误处理)

    5. 故障排查指南 - 16个常见问题解决方案 - 安装问题 - 配置问题 - 运行时错误 - 调试技巧

    开发者文档

  • CLAUDE.md - Claude Code开发指南
  • 更多文档 - 完整文档索引
  • ---

    📋 可用工具

    1. get_ziwei_chart

    获取紫微斗数完整排盘信息

    参数:

  • date (string, 必需): 出生日期 YYYY-MM-DD,如 "2000-08-16"
  • time_index (integer, 必需): 时辰序号 0-12
  • - 0=早子时(23-01), 1=丑时(01-03), 2=寅时(03-05), 3=卯时(05-07) - 4=辰时(07-09), 5=巳时(09-11), 6=午时(11-13), 7=未时(13-15) - 8=申时(15-17), 9=酉时(17-19), 10=戌时(19-21), 11=亥时(21-23) - 12=晚子时(23-01)
  • gender (string, 必需): 性别 "男" 或 "女"
  • calendar (string, 可选): 历法 "solar"(阳历) 或 "lunar"(农历), 默认 "solar"
  • is_leap_month (boolean, 可选): 是否闰月,默认 false
  • format (string, 可选): 输出格式 "json" 或 "markdown", 默认 "markdown"
  • language (string, 可选): 输出语言,可选 "zh-CN", "zh-TW", "en-US", "ja-JP", "ko-KR", "vi-VN",默认 "zh-CN" ⭐ 新增
  • 示例:

    {
      "date": "2000-08-16",
      "time_index": 2,
      "gender": "女",
      "calendar": "solar"
    }
    

    2. get_ziwei_fortune

    获取紫微斗数运势信息

    参数:

  • birth_date (string, 必需): 出生日期
  • time_index (integer, 必需): 时辰序号
  • gender (string, 必需): 性别
  • calendar (string, 可选): 历法类型
  • query_date (string, 可选): 查询日期,不填则为今天
  • format (string, 可选): 输出格式
  • language (string, 可选): 输出语言,默认 "zh-CN" ⭐ 新增
  • 3. analyze_ziwei_palace

    分析紫微斗数特定宫位

    参数:

  • birth_date (string, 必需): 出生日期
  • time_index (integer, 必需): 时辰序号
  • gender (string, 必需): 性别
  • palace_name (string, 必需): 宫位名称,可选值:
  • - 命宫、兄弟、夫妻、子女、财帛、疾厄 - 迁移、仆役、官禄、田宅、福德、父母
  • calendar (string, 可选): 历法类型
  • format (string, 可选): 输出格式
  • language (string, 可选): 输出语言,默认 "zh-CN" ⭐ 新增
  • 4. list_fortune_systems

    列出所有可用的命理系统

    5. get_bazi_chart ⭐ 新增

    获取八字(四柱)排盘信息

    参数:

  • date (string, 必需): 出生日期 YYYY-MM-DD
  • time_index (integer, 必需): 时辰序号 0-12
  • gender (string, 必需): 性别 "男" 或 "女"
  • calendar (string, 可选): 历法 "solar"(阳历) 或 "lunar"(农历), 默认 "solar"
  • is_leap_month (boolean, 可选): 是否闰月,默认 false
  • format (string, 可选): 输出格式 "json" 或 "markdown", 默认 "markdown"
  • 示例:

    {
      "date": "2000-08-16",
      "time_index": 2,
      "gender": "女"
    }
    

    输出包含:

  • 四柱八字(年月日时)
  • 天干地支详细信息
  • 十神分析(比肩、劫财等)
  • 五行分数统计
  • 地支藏干信息
  • 生肖、日主等基本信息
  • 6. get_bazi_fortune ⭐ 新增

    获取八字运势信息

    参数:

  • birth_date (string, 必需): 出生日期
  • time_index (integer, 必需): 时辰序号
  • gender (string, 必需): 性别
  • calendar (string, 可选): 历法类型
  • query_date (string, 可选): 查询日期,不填则为今天
  • format (string, 可选): 输出格式
  • 输出包含:

  • 当前年龄
  • 大运信息(年龄范围、干支)
  • 流年信息(年份、干支、生肖)
  • 本命八字
  • 7. analyze_bazi_element ⭐ 新增

    分析八字五行强弱

    参数:

  • birth_date (string, 必需): 出生日期
  • time_index (integer, 必需): 时辰序号
  • gender (string, 必需): 性别
  • calendar (string, 可选): 历法类型
  • format (string, 可选): 输出格式
  • 输出包含:

  • 日主及其五行属性
  • 五行分数和百分比
  • 最旺/最弱五行
  • 缺失五行
  • 平衡度评价
  • 补救建议
  • 🚀 快速开始

    在线体验

  • Smithery 部署: https://server.smithery.ai/@spyfree/mingli-mcp/mcp
  • 添加到 Cursor: [](https://cursor.com/install-mcp?name=mingli&config=eyJjb21tYW5kIjoidXZ4IiwiYXJncyI6WyJtaW5nbGktbWNwIl19)
  • 添加到 Claude Code: claude mcp add mingli -- uvx mingli-mcp
  • 添加到 OpenAI CodeX: codex mcp add mingli -- uvx mingli-mcp
  • ---

    📦 安装方式

    方式1: uvx (推荐)

    使用 uvx 是最简单的安装方式,无需手动管理依赖:

    ~/.cursor/mcp.json 或对应IDE的MCP配置文件中添加:

    {
      "mcpServers": {
        "mingli": {
          "command": "uvx",
          "args": ["mingli-mcp"],
          "env": {
            "LOG_LEVEL": "INFO"
          }
        }
      }
    }
    

    方式2: Docker

    使用 Docker 部署,适合服务器环境或需要隔离的场景:

    ```bash

    下载配置文件

    mkdir -p /opt/mingli-mcp cd /opt/mingli-mcp

    Related MCP Servers

    AI Research Assistant

    AI Research Assistant

    hamid-vakilzadeh

    AI Research Assistant provides comprehensive access to millions of academic papers through the Semantic Scholar and arXiv databases. This MCP server enables AI coding assistants to perform intelligent literature searches, citation network analysis, and paper content extraction without requiring an API key. Key features include: - Advanced paper search with multi-filter support by year ranges, citation thresholds, field of study, and publication type - Title matching with confidence scoring for finding specific papers - Batch operations supporting up to 500 papers per request - Citation analysis and network exploration for understanding research relationships - Full-text PDF extraction from arXiv and Wiley open-access content (Wiley TDM token required for institutional access) - Rate limits of 100 requests per 5 minutes with options to request higher limits through Semantic Scholar

    Web & Search
    12 8
    Math-MCP

    Math-MCP

    EthanHenrickson

    Math-MCP is a computation server that enables Large Language Models (LLMs) to perform accurate numerical calculations through the Model Context Protocol. It provides precise mathematical operations via a simple API to overcome LLM limitations in arithmetic and statistical reasoning. Key features of Math-MCP: - Basic arithmetic operations: addition, subtraction, multiplication, division, modulo, and bulk summation - Statistical analysis functions: mean, median, mode, minimum, and maximum calculations - Rounding utilities: floor, ceiling, and nearest integer rounding - Trigonometric functions: sine, cosine, tangent, and their inverses with degrees and radians conversion support

    Developer Tools
    22 81
    Saju Insights

    Saju Insights

    hjsh200219

    Saju Insights provides personalized Korean traditional Four Pillars of Destiny (Saju) fortune-telling based on birth data. It calculates destiny charts using the eight characters (four heavenly stems and four earthly branches) derived from birth year, month, day, and hour. Key capabilities include: - Birth chart calculation with automatic True Solar Time adjustment (Jintaeyangsi -30min correction) - Fortune analysis covering personality, career, wealth, health, and love prospects - Relationship compatibility analysis comparing two people's Saju charts - 10-year luck cycle (Daewon) predictions for long-term planning - Yongsin (favorable element) guidance on lucky colors, directions, and career paths - Lunar-solar calendar conversion supporting 1900-2200 with leap month handling - Daily fortune readings and seasonal power calculations - Multiple interpretation schools including Ziping, DTS, and modern methodologies

    Entertainment
    7 11