OpenFate Bazi MCP
Lets your AI agent calculate Bazi (Four Pillars) charts, True Solar Time and branch interactions with a deterministic engine.
162 stars on GitHubby OpenFateLicense MITUpdated 2 months ago
How to install
This MCP is local: it runs on your computer.
It works in apps installed on your PC (Claude Desktop, Claude Code, Cursor, VS Codeβ¦). Choose your app:
Paste in the terminal:
claude mcp add bazi -- npx -y @openfate/bazi-mcp
Ready! Now test it
Restart the app and paste one of these requests in the chat:
Calculate the Bazi chart for a man born on 1990-05-12 at 14:30 in Taipei.
What is the True Solar Time for this birth time and longitude?
What it is
This server gives your AI agent a reliable engine for Bazi, the Chinese Four Pillars system. The agent passes birth data and gets a computed chart as JSON, so it does not guess calendar math. It handles solar terms, longitude, time zones, daylight saving and the Zi-hour day boundary. Calculations run locally.
What it can do
calculate_bazi_chart: compute a Bazi chart with Da Yun timingdetect_bazi_interactions: find clashes, combinations, punishments and harms between branchescalculate_true_solar_time: True Solar Time from time and longitudereverse_bazi_to_solar_times: find candidate dates for a four-pillar stringget_openfate_bazi_policy: the calculation rules usedget_openfate_bazi_resources: links to OpenFate pages
When to use
- βΊWhen you want a Bazi chart that is calculated, not guessed by the model
- βΊWhen you need to explain why an hour pillar differs from a clock-time tool
- βΊWhen you want candidate birth times for a known set of four pillars
What you need
Skills that pair well
MCP or skill?
The MCP gives the agent the hands. The skill teaches the right way to use them. Together, the result is better and uses fewer tokens.
eol-resistor-calculatorHelps your agent calculate resistors for alarm systems. Helps ensure security circuits function correctly.hps-true-blueprintHelps your agent explain the architecture of a design system. It details components and their interactions. Useful for engineering and product management teams.healthcare-cdss-patternsDevelops clinical decision support systems (CDSS) for healthcare. It helps check drug interactions, validate doses, and calculate clinical scores.Frequently asked questions
Is it free?
Yes. It is MIT licensed.
Does it send data out?
The readme says it does not phone home. Calculations run locally.
Why use it instead of the model?
The model should not do calendar math. The engine gives stable JSON, and the model explains it.
Is reverse lookup exact?
No. The readme treats it as a candidate search to recheck with exact longitude, time zone and True Solar Time.
Which clients work?
Claude Desktop, Cursor, Cline and Continue.
Is there a skill too?
Yes. The repository includes an Agent Skill to teach tools how to use it.
If it does not work
- βΊOn macOS, if Claude Desktop cannot find npx, use its absolute path such as /opt/homebrew/bin/npx.
- βΊCheck that Node.js is installed.
- βΊPass the exact birth time plus timezone, and longitude for True Solar Time, to get a calculated Da Yun result.
5 new skills a week. 1 minute to read.