frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Ironsmith – A full grammar, parser, and compiler for Magic: The Gathering cards

https://chiplis.com/ironsmith/
1•nicolas-siplis•1h ago

Comments

nicolas-siplis•1h ago
Hey HN! I've been working on this for the past few months and I think it's at the point where I'm ready for some user feedback. It's a WASM engine attempting to accurately model all of MTG's rules and cards. AFAIK, this is the first MTG engine which tries to accomplish this by live compiling the entire card collection at runtime, instead of coding each individual card.

You can create your own unique cards to playtest against ("Compile Card" button is what you're looking for), as long as they follow the engine's supported grammar (which I'm working on so that it fully supports Magic's ~30k legally playable cards, currently at 26k partially/20k fully supported).

It also supports 4-way P2P multiplayer lobbies via PeerJS, though I haven't had enough time to test everything network related so there may be some hidden bugs there!

My dev process was heavily influenced by the recent surge in agentic coding, but I think I've settled on an architecture which successfully manages to avoid slop creeping in:

Each card from its original, normalized oracle text into a CardDefinition struct which contains every single behavior for that particular card. By the time this card definition is compiled, we no longer have access to the original oracle text.

Each effect in the card's compiled definition can be decompiled into human readable text, after which a series of normalization steps based on the AST structure of the card's compilation and a post-pass to cleanup awkward wording is applied. The resulting compiled oracle text is compared against the original card's using vector embeddings, which gives us a semantic similarity score.

The entire purpose of this development workflow is making it obvious to the AI which cards are working correctly and which ones still need better support, without having to rely on behavioral tests for every single card. It took me some time until I finally managed to get the architecture to the point where the AI doesn't cheat its way into improving the card coverage, but the whole experience has been a fantastic way of getting used to this new way of coding and I'm excited to see how the future of our profession looks like in a few years.

I'm looking for any kind of feedback, both UI/UX and engine related, so please share your thoughts!

Americans see their country's past, present and future

https://www.economist.com/graphic-detail/2026/06/29/how-americans-see-their-countrys-past-present...
1•andsoitis•20m ago•0 comments

Forestiere Underground Gardens

https://en.wikipedia.org/wiki/Forestiere_Underground_Gardens
10•onemoresoop•21m ago•1 comments

Three deleted songs from G&S's "Iolanthe" found in the British Library

https://marc154391.substack.com/p/three-deleted-songs-from-iolanthe
1•quuxplusone•22m ago•1 comments

When Impressive Performance Gains Do Not Matter

https://blog.colinbreck.com/when-impressive-performance-gains-do-not-matter/
2•birdculture•24m ago•0 comments

1975 GE Fake LED Clock [video]

https://www.youtube.com/shorts/ylfVSMsTUqY
1•thunderbong•25m ago•0 comments

Show HN: Coding agent that compiles intent into deterministic DAG before running

https://github.com/arman-jalili/rigorix-oss
1•arman-w-jalili•26m ago•0 comments

Would you use Fable 5 by Anthropic or Replit

1•NishanStepak•26m ago•0 comments

San Francisco supervisors balk at 362-page, AI-assisted city code rewrite

https://missionlocal.org/2026/06/s-f-supervisors-balk-at-362-page-city-code-rewrite/
1•tastyface•29m ago•0 comments

Show HN: Agentic OS – the operating system for AI agents

https://aos.injecting.ai/
1•nickpismenkov•35m ago•0 comments

My Mac's Wi-Fi Was Crawling at 50 Mbps with a Perfect Signal

https://bugmedaily.substack.com/p/my-macs-wi-fi-was-crawling-at-50
2•enesunal•39m ago•0 comments

An opinionated (and mainly correct) guide to naming

https://adamtornhill.substack.com/p/an-opinionated-and-mainly-correct
2•gmays•42m ago•0 comments

Serving Local AI on My Jetson Through Durable Streams

https://s2.dev/blog/local-ai
1•shikhar•44m ago•0 comments

US lifts curbs on Anthropic's Fable, Mythos AI models

https://www.reuters.com/business/us-lift-export-controls-anthropics-fable-ai-model-tuesday-source...
2•lossolo•45m ago•1 comments

Anthropic launches Claude Science: an AI workbench for scientists (2026)

https://lucasaguiar.xyz/pt/posts/claude-science-ai-workbench-cientistas-2026/
3•isfttr•46m ago•0 comments

Discretizing Reward Models

https://arxiv.org/abs/2606.21795
1•gmays•50m ago•0 comments

Exploring The Spectrum -Dr. John Ott documentary on the health effects of light [video]

https://www.youtube.com/watch?v=BOUA8UAEAdY
1•Eaglo•53m ago•0 comments

Guardians of the Agents Formal verification of AI workflows. (Dec 2025)

https://cacm.acm.org/practice/guardians-of-the-agents/
1•steilpass•55m ago•0 comments

Oʻahu Needs More Solar, Not New Power Plants

https://civilbeat.org/2026/06/oahu-needs-more-solar-not-new-power-plants/
1•toomuchtodo•57m ago•1 comments

WhiteHouse lifts export control on Anthropic that froze its most advanced models

https://www.cnn.com/2026/06/30/tech/anthropic-export-control-ban-lifted-white-house
3•dstala•58m ago•2 comments

The Future of Software Engineering Is Here but Not Evenly Distributed (Updated)

https://twitter.com/jmugan/status/2065962078322438524
1•jmugan•1h ago•0 comments

Taiwan raids Super Micro in widening China chip smuggling probe

https://www.japantimes.co.jp/business/2026/06/30/taiwan-super-micro-china-chip-smuggling/
5•billybuckwheat•1h ago•0 comments

White House picks Avi Loeb with polarizing alien theories to lead UFO council

https://www.pbs.org/newshour/politics/white-house-picks-harvard-professor-with-polarizing-alien-t...
8•ceejayoz•1h ago•2 comments

The President Made More Than $1Billon in Crypto Deals

https://www.wsj.com/politics/policy/trump-made-more-than-1-billion-on-crypto-deals-part-of-2025-w...
61•fortran77•1h ago•9 comments

A Fusion First: Realta Demos Direct Energy Conversion

https://realtafusion.com/fusion-first-realta-demos-direct-energy-conversion/
1•sien•1h ago•0 comments

Show HN: Explore Ethereum by the Shape of a Transaction

https://www.chaingenius.ai
2•spennant•1h ago•0 comments

Faster Gemma 4 on MLX with multi-token prediction

https://ollama.com/blog/faster-gemma-4-mlx-mtp
2•ilreb•1h ago•0 comments

Why Jet Engines Aren't "Made in China"

https://aakash.substack.com/p/why-jet-engines-arent-made-in-china
6•paulpauper•1h ago•0 comments

Scott Alexander as a modern-day Edmund Wilson

https://statmodeling.stat.columbia.edu/2026/06/07/scott-alexander-as-a-modern-day-edmund-wilson/
3•paulpauper•1h ago•0 comments

Frame Error

https://linch.substack.com/p/frame-error
2•paulpauper•1h ago•0 comments

Wikipedia: Deleted Articles with Freaky Titles

https://en.wikipedia.org/wiki/Wikipedia:Deleted_articles_with_freaky_titles
3•surprisetalk•1h ago•1 comments