BaZi, Horoscopes & I Ching Divination: Implementing Structured Numerology and Divination Algorithms in Agents

Introduction

When asking about “Bazi” (Eight Characters), “Chart Casting,” or “Divination” in a conversation, models often give generic answers. They neither cast charts according to the rules of the Four Pillars nor fix details such as the date transition during the “Late Zi Hour” or school-specific validation. If you want the Agent to collect birth information step-by-step, produce a comparable metaphysical report, and generate openable hexagram pages for Zhouyi (I Ching) scenarios, you need to write the workflow into a Skill rather than relying on prompt luck every time.

Below is an introduction to the SkillHub community Skill “Bazi & Horoscope Calculation & Zhouyi Divination”: a reusable workflow chaining together dual-school Bazi calculation, three-stage validation, comprehensive metaphysical reports, Zhouyi HTML divination, and profile memory.

What is this

Bazi & Horoscope Calculation & Zhouyi Divination (Coordinate @user_2cd25b29/bazicesuan-zhouyisuangua, current version 5.0.6) is a life-service category community Skill on SkillHub, maintained by the publisher user_2cd25b29. The page indicates requires_api_key=false, meaning no additional API Key is needed after installation.

Its official positioning is a “One-stop Chinese Metaphysics Consultant”: after the user provides birth information, the Skill guides them through chart casting, school confirmation, and report generation; for Zhouyi (I Ching) related queries, it directly produces HTML viewable in a browser. The SkillHub page currently shows a rating of 100000 and 6327 downloads (data subject to SkillHub).

  • SkillHub Display Page: https://www.skillhub.cn/skills/user_2cd25b29/bazicesuan-zhouyisuangua
  • API Entry: https://api.skillhub.cn/user_2cd25b29/bazicesuan-zhouyisuangua

Core Functions

The following capabilities are derived from the official SkillHub description and page details; they should be understood in execution order.

Dual-School Bazi & Late Zi Hour

The system performs dual-school Bazi calculation. When encountering the Late Zi Hour, it automatically identifies it and provides two sets of schemes: Date-Changing School / No-Date-Changing School, preventing chart casting ambiguities at the time boundary from being ignored.

Three-Gate Validation

Before issuing the formal report, the Skill performs three cross-validations of historical events (“Three-Gate Validation”) to confirm which school to adopt before proceeding with further analysis. This step turns “whether the chart is cast correctly” from a subjective guess into a conversational, verifiable process.

Complete Metaphysical Report

After validation passes, a Complete Metaphysical Report is generated. According to official descriptions, this report is provided via a combination of “Tianji skills,” covering modules such as Bazi, Fortune Weighing (Chengu), Zi Wei Dou Shu (Purple Stars), and Western Astrology (specific chapters depend on the Skill’s runtime output).

Zhouyi Hexagram Casting / Divination

In addition to Bazi, the Skill supports Zhouyi Hexagram Casting and Divination. Results are generated as an HTML webpage and opened in a browser, facilitating the reading of hexagrams and explanations.

Profile Memory

For validated user profiles, the Skill utilizes the memory skill for automatic memorization: the next time the same user interacts, they do not need to re-enter birth information that has already passed the “Three Gates” (this still depends on whether the Agent-side memory capability is enabled).

Trigger & Intent Recognition

The official list of trigger contexts includes: fortune telling, Bazi, fate testing, “my destiny,” calculation, hexagram casting, divination, asking hexagrams, chart casting, fortune, annual cycle, major cycle, birth chart, Zi Wei Dou Shu, fortune for this year, fortune for this month, as well as “help me calculate,” “show me my fate,” “I want to know my destiny,” Zhouyi, Yi Jing, etc. Even if the user merely mentions fortune telling or Bazi without explicitly stating “use skill,” this Skill should be triggered according to the description.

Supplementary trigger words (from Skill metadata English and colloquialisms): calculate Bazi, view Bazi, comment on Bazi, Four Pillars, destiny chart, bazi, bazi analysis, fortune telling, birth chart, cast a hexagram, view fortune, destiny analysis, etc.

Installation & Activation

Install SkillHub CLI (if not installed)

First, check if skillhub is available:

command -v skillhub && skillhub --version

If not installed, follow the SkillHub installation documentation to perform a complete installation (CLI + Default Skill):

curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash

If only the CLI is needed:

curl -fsSL https://skillhub-1388575217.cos.ap-guangzhou.myqcloud.com/install/install.sh | bash -s -- --cli-only

For more complete source priority strategies and initial configuration instructions, see: https://skillhub.cn/install/skillhub.md

Install this Skill

When installing, you must use --dir to point to the current Agent’s skills directory; otherwise, it defaults to ./skills/, which the Agent may not recognize.

skillhub install @user_2cd25b29/bazicesuan-zhouyisuangua --dir <your skills directory>

In Cursor, the common path is:

~/.cursor/skills/

Other clients (subject to official installation documentation) examples:

  • Claude Code: ~/.claude/skills/
  • Codex: ~/.codex/skills/ or .agents/skills/ under the project
  • Windsurf: ~/.codeium/windsurf/skills/ or .windsurf/skills/

You can also ask the AI in conversation to install it via official prompts:

Please install @user_2cd25b29/bazicesuan-zhouyisuangua according to https://skillhub.cn/install/skillhub.md.

After installation, restart or refresh the Agent as required by your client to ensure the Skill is loaded.

Typical Usage

This Skill uses interactive collection of birth information as the entry point (specific fields and order are defined by SKILL.md, commonly including name, solar/lunar birthday, time slot, gender, birthplace, etc.). A typical conversation may start like this:

  1. User: Help me cast a Bazi chart; I want to see this year's fortune.
  2. Agent activates this Skill and asks for missing birth information item by item.
  3. For cases like the Late Zi Hour, it presents the Date-Changing / No-Date-Changing schemes and confirms the school via Three-Gate Validation.
  4. Outputs a complete report containing Bazi, Fortune Weighing, Zi Wei, and Horoscope; if the user switches to asking about hexagrams, it generates HTML and opens it in the browser.
  5. Once the profile is validated, subsequent sessions can reuse the profile in memory, reducing repeated input.

Example intent for Zhouyi side: Use Zhouyi to cast a hexagram for me regarding job changes. —— Expected to follow the divination workflow and open the HTML result page.

Use Cases & Notes

Who it is for

  • Those who need repetitive, step-by-step Bazi chart casting and fortune-related conversations within an Agent, rather than a one-off “fortune telling copy.”
  • Those who need Late Zi Hour dual schemes + historical event validation to lower the risk of chart casting school errors.
  • Those who wish to chain Western Astrology, Zi Wei, Fortune Weighing, and other comprehensive reports in the same Skill, or occasionally perform Zhouyi HTML divination.

Limitations & Notes

  • The output belongs to traditional culture and entertainment-oriented analysis and cannot replace professional decisions regarding medical, legal, or investment matters; for major life choices, consult certified professionals in the corresponding fields.
  • Metaphysical and divination results depend on the accuracy of the birth time and event descriptions provided by the user; Three-Gate Validation requires the user to recall historical nodes honestly and specifically.
  • requires_api_key=false only indicates that the Skill metadata does not require a Key; if underlying sub-capabilities (like memory skill, opening HTML in browser) depend on the environment, ensure Agent and system permissions are normal.
  • Ratings and download counts change with SkillHub updates; please refer back to the official page when citing data.

Conclusion

Bazi & Horoscope Calculation & Zhouyi Divination consolidates dual-school Bazi, Three-Gate Validation, Tianji-series comprehensive reports, Zhouyi HTML divination, and profile memory into a single Skill workflow. It is suitable for handling fixed intents like “Chart Casting, Fortune, Divination” in Agents like Cursor. Remember to use skillhub install … --dir <skills directory> during installation and point it to the actual skills path of your current client.

Official Entry: https://www.skillhub.cn/skills/user_2cd25b29/bazicesuan-zhouyisuangua

羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye