Open-source project
flaneur2020/pua-lang avatar
flaneur2020/pua-lang

pua-lang: A Rust Monkey Dialect That Renames Syntax to Mock Alibaba Management Speak

GitHub describes it as a dialect of The Monkey Programming Language. The repository metadata lists Rust as its primary language. The metadata lists the MIT license. This article stays within the project description and details documented in the GitHub repository README.

3,307 stars123 forksRustMIT

At a glance

What is it?
pua-lang is a Rust implementation of the Monkey interpreter language that replaces keywords like if and let with Chinese terms borrowed from Alibaba corporate jargon. It is a satirical fork of rs-monkey-lang, aimed at programmers who enjoy language design and office humor.
Who is it for?
Adopt pua-lang if you want a small, readable interpreter to study or extend, and if you appreciate satirical naming that mocks management culture. Do not use it for any production work: it lacks floats, has incomplete if-else chaining, and the WASM playground has broken I/O.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Probably not. The repository last received commits 22 months ago, on December 2, 2024.
What is it written in?
Mainly Rust, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on October 22, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • flaneur2020/pua-lang3,307 ★ · -4
Star history
Repository2026-08-132026-10-22
flaneur2020/pua-lang3.3k3.3k

-4 Stars in the last 70 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

What pua-lang actually is and who it targets

pua-lang is a fork of rs-monkey-lang, which itself is an implementation of the Monkey language from the book Writing An Interpreter In Go. The project's stated purpose is to mirror the 'inspirational babble' of Alibaba managers, using the acronym PUA to reference manipulative workplace tactics. The audience is twofold: programmers learning how interpreters work, and people who find corporate jargon funny. If you do not care about Monkey or do not appreciate the satire, this project offers little beyond a renamed syntax tree.

The keyword renaming is the entire point

The core mechanism is a lexical substitution table. Every Monkey keyword maps to a Chinese phrase: if becomes 细分, else becomes 路径, while becomes 闭环, true becomes 三七五, false becomes 三二五, let becomes 赋能, fn becomes 抓手, return becomes 反哺, and puts becomes 输出. Operators are renamed too: + is 联动, - is 差异, / is 倾斜, and = is 对齐. The README explicitly says the precise set of renames may change, and directs you to read src/lexer/mod.rs and src/evaluator/builtins.rs to understand the current mappings. This means the language is not stable; you cannot rely on a keyword staying the same across versions.

Syntax and semantics: mostly Monkey with a few twists

The grammar follows Monkey closely. You get variable bindings, integers, booleans, strings, arrays, hashes, functions, closures, and higher-order functions. The README shows a Fibonacci function written in pua-lang, which looks like a normal C-like language once you translate the keywords. One notable addition is Unicode identifiers, which follow UAX #31 (XID) plus monetary extensions like ¥, $, and an 'overly-lax' definition of emojis. This means you can name variables with emoji, as shown in the example 赋能 不变 = 抓手(工资p6) { ... } where the parameter is 工资p6 and the string includes emoji. The language does not support floating-point numbers; only integers are allowed, matching Monkey's design.

Building and running: REPL and WASM playground

The README gives two ways to run pua-lang. First, clone the repository and run make repl, which presumably builds the Rust interpreter and starts a REPL. Second, there is a WASM playground hosted at https://flaneur2020.github.io/pua-lang/. The README admits the output streams do not work properly in the playground because Rust has no I/O redirection and wasm32-unknown-unknown has no I/O by default. That is a concrete limitation: if you try the playground, do not expect stdout to appear as you might in a terminal. The REPL is the reliable path, assuming your Rust toolchain is set up.

Where pua-lang falls short: incomplete features and broken I/O

The documentation lists several gaps. The 细分 (if) construct supports a general form, and 路径 (else) exists, but the combined '细分 路径' (else if) does not exist yet. That means you cannot chain else-if conditions, which is a real restriction for writing non-trivial logic. Also, floating-point numbers cannot be handled, so any numeric code requiring decimals fails. The WASM playground's output streams are broken, which the README acknowledges. These are not hypothetical issues; they are stated limitations. If you need else-if chains or floats, pua-lang is the wrong tool.

Alternatives: rs-monkey-lang and the original Monkey

The direct alternative is rs-monkey-lang, the upstream project that pua-lang forked. It implements the same Monkey language but with standard English keywords like if, let, and fn. If you want to learn interpreter construction without the satirical renaming, rs-monkey-lang is the more predictable choice. The original Monkey language from the book Writing An Interpreter In Go is another alternative, with a reference implementation in Go. The difference is approach: pua-lang adds a lexical layer that maps Chinese phrases to tokens, while the alternatives keep the syntax as-is. If you want to study the interpreter mechanics, the upstream version is clearer because you do not have to translate keywords in your head.

Maintenance and licensing

The project is licensed under the MIT License, which permits commercial use, modification, and redistribution with attribution. The repository is not archived, and the last push date is unknown, which means you cannot assess how actively it is maintained. The README warns that the keyword set may change, so any code you write against pua-lang could break with a new commit. Since it is a fork, you also inherit the maintenance burden of tracking upstream changes in rs-monkey-lang if you want bug fixes. The documentation itself is marked with a warning that there may be mistakes, so treat the README as a guide, not a specification.

Editorial conclusion

Adopt pua-lang if you want a small, readable interpreter to study or extend, and if you appreciate satirical naming that mocks management culture. Do not use it for any production work: it lacks floats, has incomplete if-else chaining, and the WASM playground has broken I/O. Before adopting it, verify the exact keyword mappings in src/lexer/mod.rs and src/evaluator/builtins.rs, since the README warns the renames change over time. The project is a fork of rs-monkey-lang, so expect to track upstream changes if you rely on it.

Frequently asked questions

What is pua-lang?

A dialect of the Monkey programming language, written in Rust as a fork of rs-monkey-lang, with every keyword renamed into a mock management vocabulary so the interpreter teaches Monkey while reading like a slogan. Monkey itself is the language from Writing An Interpreter In Go.

Which keywords does pua-lang rename?

if becomes 细分, else 路径, while 闭环, break 破圈, true 三七五, false 三二五, let a renamed keyword about handing out responsibility, fn the word for a handle, return 反哺, puts 输出 and quit 淘汰, with assignment as 对齐, addition 联动, subtraction 差异 and division 倾斜.

How do I run the pua-lang REPL?

Clone the repository and run make repl, which starts the interpreter with its binaries feature. A wasm playground is published as well, though the file warns that its output streams do not work because Rust has no I/O redirection and wasm32-unknown-unknown has no I/O by default.

What identifiers does pua-lang accept?

Unicode identifiers following the XID recommendation, plus monetary extensions and what the file describes as an overly lax definition of emoji, with Rust-compatible double-quoted strings.

Does pua-lang support floating point numbers?

No. Floating point numbers cannot be handled, and the documented integer literal format is an optional sign followed by a non-zero leading digit and any number of further digits.

How many built-in functions does pua-lang have?

The documentation covers one, named 输出, which writes its arguments to stdout or to the console in the playground. The rename table also maps quit to 淘汰 and atoi to 量化, which that section does not cover.

Official sources

  1. Official README
  2. Project repository
  3. README
  4. Releases
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/flaneur2020-pua-lang.svg)](https://hysenlabs.com/projects/flaneur2020-pua-lang)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/flaneur2020-pua-lang.svg)](https://hysenlabs.com/projects/flaneur2020-pua-lang)