The parsing & matching core of Semgrep is implemented in OCaml, which is why it can scan 10,000+ lines/sec. But the semgrep CLI tool is written in Python to make it easy to contribute to it!
semgrep