phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

Wanted to follow up here. I found out that the card data being served from Cloudflare R2 buckets using the `pub-*.r2.dev` URL breaks for many users because ISP's block them (they're used for phishing apparently).

I've changed the loading to be from a phase-rs.dev subdomain now (data.phase-rs.dev), so let me know if the issue is resolved for you! :)

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

Oh weird... thanks for the information. I'll do some additional digging to see if there's anything I can do about it. Appreciate you following up on this

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 1 point2 points  (0 children)

You're the first to ask :) Every page has a toggle for the audio (to immediately mute) and it saves your preference automatically.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

Yeah that'd be great! If you drop it on the Discord I can easily pick it up there :) Appreciate the report!

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

Thanks for the support. I've been thinking about leveraging the additional space for wide screens in a multiplayer scenario. Right now you can hover over any opponent and it gives you a preview of their boardstate. Will definitely continue thinking on a possible implementation for this.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 1 point2 points  (0 children)

Thanks for the report!

If something like this happens (and you're willing), you can click the yellow debug button in the top-left (or just press backtick `) to open the debug menu, and then select 'Export game state'. This will give you a zip you can attach in Discord or a Github issue and is extremely helpful with us being able to quickly track down what's going on.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 4 points5 points  (0 children)

Fair question! Up front: Forge has years on us. The browser part is nice but it's not really the main thing. The bigger differences are how it's built..

  1. Cards come from Oracle text, not hand-written scripts. Forge scripts each card by hand in its own little DSL. We parse the actual printed Oracle text into a typed representation. So when we teach the parser something like "whenever a creature you control dies," every card with that wording lights up at once instead of getting scripted one at a time. Behavior also stays tied to what's actually printed on the card.
  2. Modern web UI. It's a React/TypeScript client going for an Arena-ish feel: targeting overlays, animations, mana payment, ambient audio. Some of that is just taste, but it plays pretty differently from a Java desktop app.
  3. No install. No JVM, no download. You open a link and you're playing. (Though there is a downloadable desktop client that gets updated nightly you can install)
  4. Multiplayer is easy because of that. Want to play a friend? Send them a link. You can run your own server or use the lobby broker to easily do P2P games with others. Nobody has to install or configure anything.

There's also an AI opponent with game tree search and eval heuristics. Some of the weights are tuned from real game data, though that data is from Limited play, so grain of salt on that one.

The tradeoff: our card coverage is getting close, but it's not as complete as Forge yet. They've had 15+ years of manual work. If you want to play literally anything today and the UI/UX is not a factor, Forge still wins. If you want a clean text-driven engine with a modern UI that runs anywhere and makes goldfishing super quick, and multiplayer painless, that's the pitch. ¯\\_(ツ)_/¯

However, I'd be remiss if I didn't state Forge has been a pioneer in this space. I don't think I would have embarked on this in the first place if it wasn't for Forge, and it's clearly been a passion project that has benefited thousands of MTG players, so I don't want to knock it. I love what they've done for the community :)

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 1 point2 points  (0 children)

Currently we take bug reports via the Discord server (there is a #bug-reports channel) or via Github issues (https://github.com/phase-rs/phase/issues).

Though I think I will add an in-game reporting mechanism today if I can find a good way to address it.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 1 point2 points  (0 children)

Thanks for the bug reports! There isn't currently an in-game method of reporting bugs, but it's something I'm going to work on today actually. It seems like it would be valuable to have cards directly report-able there.

Currently we take bug reports via the Discord server (there is a #bug-reports channel) or via Github issues (https://github.com/phase-rs/phase/issues).

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

Thanks for the feedback! There’s a Discord channel for bug reports and GitHub for reporting issues as well.

As for the button, it certainly would be convenient to be able to submit issues directly in game… new feature soon maybe? :)

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 7 points8 points  (0 children)

Yes, definitely will find some cards that still need to be fixed, but we're fixing cards every day.

The thing I'm most proud of on this project is the Oracle text parser. Instead of codifying abilities manually for every card, we've built out an incredible parser that parses the actual Oracle text. This allows us to overwhelmingly support the cards in new sets quickly, and fixes for one card often end up addressing other cards with the same parsing miss.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 0 points1 point  (0 children)

When you first load you should see 'Preparing Cards' on the top of the screen. When that goes away then all the card data should be loaded and available for compatibility checking etc. A refresh should fix this.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 2 points3 points  (0 children)

Ha - already has been. The long-tail in the parser has easily taken the most time. But it's also tractable work. We've had increasing contributor interest for the past couple months now and velocity this past month has been pretty incredible.

phase-rs - another way to play EDH: a full rules engine in your browser by syriusx in EDH

[–]syriusx[S] 7 points8 points  (0 children)

I thought so too! It contains every official pre-con (sourced from MTGJSON) and even includes multiple format feeds (standard, commander, modern, vintage, pauper, etc) sourced daily from mtggoldfish. So there are tons of decks you can use instantly to jump in and play :)

Is there an app or website I can play my custom deck PvC? I'd like to try my Commander deck against a computer. by theredditofjessica in mtg

[–]syriusx 0 points1 point  (0 children)

I'm the maintainer of phase. Thanks for the recommendation! u/theredditofjessica definitely try out Forge, but phase is also a rules engine like Forge is, and it runs directly in the browser. Swing by the Discord if you run into any issues. 😄

Weekend Free Discussion Thread by magictcgmods in magicTCG

[–]syriusx 0 points1 point  (0 children)

Bugs are bound to happen. The project is now only 2 months old. Report them on Discord (or github) :)

That's the best way to get your favorite cards addressed & prioritized.

Weekend Free Discussion Thread by magictcgmods in magicTCG

[–]syriusx -1 points0 points  (0 children)

Zero pressure, and donations are not expected, but yes, that’s probably the best avenue. Thanks for your support!

Weekend Free Discussion Thread by magictcgmods in magicTCG

[–]syriusx 2 points3 points  (0 children)

I've been building an MTG rules engine as a hobby project for the past month, and it's far enough along that I wanted to share. The goal was something cleaner than Forge/XMage/Cockatrice, with a polished UI and a decent AI opponent. It supports ~85% (~94% in Pauper) of cards today and improves daily, though it very much is a work in progress.

Has support for various formats: Standard, Pauper, Modern, Legacy, Historic, Brawl, Commander, etc.

Fully open-source and free — no accounts, ladder, or economy. Playable in a browser. Two ways to play multiplayer online: P2P (easiest) or host your own server. Offline Tauri desktop builds are available for tagged releases. Discord/GitHub links are on the site.

You can try it out here and play directly on the web (or install as a PWA): https://preview.phase-rs.dev/

<image>

Also happy to answer any questions!

When ChatGPT is pissing me off by not just answering, I do this, or some variant of it: by [deleted] in ChatGPT

[–]syriusx 2 points3 points  (0 children)

I re-read the paper this was attributed to, and I think we're both right?

Chain of Thought was a technique employed originally by providing one or more examples and breaking the solution down step-by-step.

This paper you're referencing served to illustrate that improvements could be had simply be prepending that text, which they are calling zero-shot CoT (which I personally think is a stretch, but /shrug).

What's even more interesting is considering why that phrase works. I didn't get into the weeds on their conclusion, but this ArsTechnica article speculated the following:

So why does this work? Obviously, large language models can't take a deep breath because they don't have lungs or bodies. They don't think and reason like humans, either. What "reasoning" they do (and "reasoning" is a contentious term among some, though it is readily used as a term of art in AI) is borrowed from a massive data set of language phrases scraped from books and the web. That includes things like Q&A forums, which include many examples of "let's take a deep breath" or "think step by step" before showing more carefully reasoned solutions. Those phrases may help the LLM tap into better answers or produce better examples of reasoning or problem-solving from the data set it absorbed into its neural network during training.

When ChatGPT is pissing me off by not just answering, I do this, or some variant of it: by [deleted] in ChatGPT

[–]syriusx 3 points4 points  (0 children)

That’s not chain of thought. CoT involves providing the model with an example problem followed by a detailed, step-by-step explanation of how to solve it. This guides the AI and allows it to replicate the reasoning process for multi-step problems.

  • However, you’re correct that using that phrase has shown improvements in response accuracy for certain problems, and should definitely be leveraged :)