Hands-on Tech Lead building the AI Companion for an online mahjong game: a decision-making model (RL, imitation learning, or MCTS) with an LLM reasoning/explanation layer on top, hitting a 2-second move budget. A 3-month, 0.5 FTE engagement owning architecture, the training/evaluation pipeline, and leading a small delivery pod for a web3 gaming client.
Hands-on Tech Lead for an AI Companion in an online mahjong game. The client is a social gaming company (web3 element) that scales its product and team. We deliver the AI side of their game as their embedded AI partner.
The AI Companion plays mahjong at a strong level and explains its moves. The core of the role is to build the mahjong-playing algorithm: a dedicated decision-making model (RL, imitation learning, or search-based — trained on the client's hand-history data) with an LLM reasoning layer on top. Key design constraints: a valid-action contract with the game engine (the bridge supplies legal moves), win detection, and a 2-second response budget per move. Explanations run async. Support for more than one rule set (riichi and regional variants) is on the roadmap.
Duration: 3 months, 0.5 FTE.
What you'll actually do (example tasks)
Design and build the mahjong-playing algorithm: choose and defend the approach (imitation learning on hand histories, RL / self-play, search with MCTS, or a hybrid), then train, evaluate, and ship it.
Own the technical architecture end to end: game model + LLM reasoning layer, valid-action mask, win detection, and the API contract with the client's game bridge.
Hit the 2-second response budget: design and measure the inference path, batching, and caching; keep a latency buffer for the client-facing number.
Define what data and event names we need from the client (hand histories, event streams); build the training and calibration pipeline on that data.
Build and run the evaluation harness: measure play strength against the client's reference points, and validate explanation quality.
Stand up LLM observability with Langfuse (async logging, N+1 batch) as an early sprint quick win.
Take over context from Vlad Borysenko (0.15–0.2 FTE supervision during ramp-up) and lead the sprint work with the AI Engineer; work with the client's Product Owner in a scrum process.
Front the client's CTO and engineers on technical decisions; explain trade-offs in plain language and in depth when asked.
Watch the risks the account team flagged: licensing on new training data, engine-bridge capabilities, and multi-rule-set scope.
Skills (hands-on first)
Game AI / sequential decision-making: hands-on RL, imitation learning, or search-based agents (MCTS, self-play) — ideally for imperfect-information games (mahjong, poker, card games)
Expert Python for ML systems; strong software engineering (APIs, testing, CI)
Model training on gameplay data end to end: data → training → evaluation → serving
6+ years hands-on ML/AI engineering, with real game AI or sequential decision-making work (RL / MCTS / self-play — not only LLM apps)
Trained models on user or gameplay data end-to-end (data → training → evaluation → serving)
Led small delivery teams while still coding personally
Comfortable owning an architecture in front of a technical client CTO
Questions for Applicants
Imperfect information: mahjong hides most tiles from each player. How does hidden information change your algorithm choice compared to a perfect-information game like chess?
Latency budget: tell us about a system you shipped with a hard response-time limit. How did you design, measure, and defend the budget?
LLM + model hybrid: how would you combine a trained game model with an LLM explanation layer so the explanation never contradicts the move?
Hands-on + lead: how do you balance personally coding the hard parts with leading an engineer and fronting the client?