For the tokenizer they had three more obvious options:
1. Use a JavaScript lib and call it via FFI. Tokenization isn't a hard task.
2. Compile tiktoken to WASM and call it directly.
3. Stick with their Python server.
Writing a custom regex automaton in OCaml and then running it in the browser is surely the worst option. How does this make sense, outside of just arbitrarily writing more OCaml for the sake of it? The justification for not using their previous scheme is only that it's "grungy", without further explanation.
Every other project also seems to be like this. The justification for it boils down to nobody else using OCaml, so they need an intern army to reinvent all the wheels they're missing.
I mean, I'm sure the interns had fun and were paid well. But there's a post below by someone with a massive inferiority complex, stating that everyone is "objectively inferior" to the people at Jane Street. This post doesn't make me feel inferior, it makes me feel a sense of awe and wonder that Jane Street's traders are so profitable they can subsidise this kind of objectively excessive IT bloat. Even the author seems to recognize this, it says the post is by the guy who has "the dubious honor of having convinced the firm to start using OCaml".