frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Show HN: A deterministic I Ching engine, cross-validated against another impl

https://github.com/yaomancy/liuyao-engine
2•Jincheng-xie•1h ago
I built a deterministic engine for I Ching (六爻 / Liu Yao) hexagram casting and open-sourced the core (Apache-2.0). I want to be upfront that the interesting part here is not the divination — it's a testing problem, and I'd like feedback on how I handled it.

The engine takes a moment in time plus a coin toss and mechanically derives a fully annotated chart: the hexagram, its palace, the stem-branch (najia) assignments, the "six relatives," moving lines, void days, and the line-strength skeleton. It does not interpret anything — it only emits hard, mechanical facts.

The problem that made this interesting: the rules are ~3000 years old, written in classical Chinese, and different schools contradict each other. There is no official answer key, and human experts disagree and are sometimes wrong. So the tests I'd naturally write just encode the same assumptions my code does — if I misread a rule, the code and its test are wrong together and both stay green. The self-validation paradox.

My way out was differential testing against independent oracles. I diff every field of the chart against `najia` (a separate MIT implementation) and a second machine-readable rule table, over random-but-seeded samples in CI. A field is only trusted when all three agree. The calendar layer (which is zero-tolerance — a day-pillar off by one silently corrupts everything downstream) gets its own diff, sxtwl vs lunar-python, focused on the nasty boundaries: solar-term month divisions, the 23:00 day change, and cross-timezone casting.

That principle ended up driving the design: anything that can't be independently cross-validated doesn't enter the core. That's why the traditional "auspicious stars" (神煞), true-solar-time correction, and school-mixing are all deliberately excluded — not because they're "wrong," but because I have no way to prove the code computes them correctly.

I'm in UTC+8 (China) so replies from me may lag by a few hours during your daytime — but I'll be around all day when I'm awake. Happy to go deep on any of it.

Air conditioners were originally invented for printing presses

https://historyfacts.com/science-industry/fact/air-conditioners-invented-for-printing-presses/
1•thunderbong•2m ago•0 comments

Macintosh 9: Finder: View as Button (2024)

https://getbootstrap.com/docs/5.2/examples/blog/
1•haunter•4m ago•0 comments

Show HN: Create realistic group photos in real time with AI

https://pixailer.com
1•keenthinker•5m ago•1 comments

El Niño Is Wreaking Havoc on Pacific Fisheries

https://www.wired.com/story/el-nino-wreaking-havoc-on-pacific-fisheries/
1•beardyw•7m ago•0 comments

Lumvelle Drops ReviEwS (2026): We Tried It My Honest Review

https://gamma.app/embed/Lumvelle-Drops-ReviEwS-2026-We-Tried-It-My-Honest-Review-8ki1ftfh003qqdn
1•brentrq•8m ago•0 comments

Documentation is still in your Mum's filing cabinet

https://gerireid.com/blog/organising-documentation-for-humans-and-ai/
1•eigenBasis•12m ago•0 comments

Ask HN: Does your website work on Nordstjernen Web Browser?

1•roschdal•15m ago•0 comments

World Model Is the New Inflection Point

https://rajatghosh11.substack.com/p/one-model-to-rule-them-all
1•rghosh8•15m ago•0 comments

A font that humans can read but AI cannot

https://www.mixfont.com/ghost-font
2•justswim•17m ago•0 comments

Show HN: Image Generation API with QR code tracking and MCP support

https://templateson.com
1•maz225•17m ago•0 comments

Cost vs. accuracy in CursorBench 3.1: the effect of family and spend

https://www.shibaprasadb.com/2026/07/09/cursorbench-analysis.html
1•shibaprasadb•19m ago•0 comments

Show HN: A strategic word game where you make many words with 1 letter per turn

https://play.letterphile.com
1•sonOfHades•19m ago•0 comments

The Personal Safe – Zero-knowledge encrypted backup for your own S3 bucket

https://github.com/wocdamjack/thepersonalsafe
1•wocdamjack•22m ago•0 comments

Lumvelle ReviEwS (2026): We Tried It My Honest Review

https://gamma.app/embed/Lumvelle-ReviEwS-2026-We-Tried-It-My-Honest-Review-ge43hr5uq6eoxu3
1•bayszalu•24m ago•0 comments

Safari sidebar silently loads loads all your bookmarks

https://lapcatsoftware.com/articles/2026/7/1.html
2•JumpCrisscross•26m ago•0 comments

Open-source finance infrastructure in Rust

https://www.railsinfra.com
1•sibabale•35m ago•1 comments

Almost $1B Later, the US Still Can't Make a Medical Glove

https://www.bloomberg.com/news/features/2026-07-07/why-it-s-so-difficult-to-produce-100-american-...
8•helsinkiandrew•38m ago•1 comments

Consumers unsatisfied despite world-class networks

https://billbennett.co.nz/nz-telecom-customer-satisfaction-declines-comcom-report/
1•JumpCrisscross•39m ago•0 comments

New Earth Time – 360 degrees of time (2000)

https://newearthtime.net/
2•networked•39m ago•0 comments

FCC weighs changing E-Rate program, which lowers school internet bills

https://www.npr.org/2026/07/10/nx-s1-5878405/fcc-erate-schools-internet-discount
2•jonbaer•42m ago•0 comments

Microsoft latest report shows 25% emissions raised due to AI data centers

https://www.windowscentral.com/microsoft/dropping-greenwashing-credits-and-expanding-ai-datacente...
3•pjmlp•43m ago•0 comments

Ukraine's Amazon for war: Inside the marketplace built for the military

https://www.youtube.com/watch?v=BZaIh5we0bY
1•doener•44m ago•0 comments

Zeitpyramide

https://en.wikipedia.org/wiki/Zeitpyramide
3•doener•45m ago•0 comments

Kids (With Phones) Are Alright

https://heatherburns.tech/2026/07/08/the-kids-with-phones-are-alright/
1•JumpCrisscross•46m ago•0 comments

Timeline of the Far Future

https://en.wikipedia.org/wiki/Timeline_of_the_far_future
1•doener•46m ago•0 comments

Loom Document Search Engine

https://gitlab.com/swiss-armed-forces/cyber-command/cea/loom
1•ano-ther•49m ago•0 comments

In defense of not understanding your codebase

https://www.seangoedecke.com/in-defense-of-not-understanding-your-codebase/
1•suprjami•57m ago•1 comments

Show HN: ServiceBeard – Turn your support mailbox into an issue board

https://servicebeard.app/
2•hongaar•1h ago•0 comments

Adam Curtis – All Watched over by Machines of Loving Grace

https://en.wikipedia.org/wiki/All_Watched_Over_by_Machines_of_Loving_Grace_(TV_series)
4•mrauha•1h ago•1 comments

MonitorSpider. Uptime, page-change detection and login monitoring in one

https://monitorspider.com
1•hitechist•1h ago•0 comments