zhu·qihao
Researcher · DeepSeek · Beijing

Qihao Zhu

朱琪豪

I teach machines to write, repair and reason, by treating programs, patches and reasoning traces as trees grown under constraints a machine can check.

1DeepSeek-AI: code LLMs, reasoning and RL from verifiable feedback
2Ph.D. in Computer Science, Peking University; advised by Prof. Yingfei Xiong

Fig. 1 drag to rotate ↻
depth ↓ · grammar rules applied: 0
Figure 1. One tree, three forces. (a) Grammar decides how the tree grows: a program is generated one rule at a time, as in TreeGen and GrammarT5. (b) Types and tests decide how it is edited: a buggy AST is rewritten under type constraints, as in Recoder and Tare. (c) Reward decides which branches survive: on a verifiable coding task, chains of thought are sampled, scored by unit tests, and reinforced with GRPO as in DeepSeek-R1. Over three updates the tree grows deeper and greener. Branches here picture sampled rollouts, not a tree search.
§1

Abstract

Who I am and what I work on.

I study how machines can write, repair and reason about programs. In my Ph.D. at Peking University, advised by Prof. Yingfei Xiong, I treated code as structured objects rather than flat text. I built grammar-guided decoders (TreeGen, GrammarT5, Grape) that generate programs rule by rule, and syntax- and type-aware repair models (Recoder, Tare) that edit the abstract syntax tree directly.

At DeepSeek I apply the same view to large language models. I help train code models (DeepSeek-Coder, DeepSeek-Coder-V2) and math and formal-reasoning models (DeepSeekMath, DeepSeek-Prover), and I contribute to the general reasoning models DeepSeek-R1, V3 and V4.

What connects this work is a simple claim: a program, a patch and a proof are all trees. They are best grown under constraints a machine can check, such as a grammar, a type system, a test suite or a proof assistant. Those same checks then become the reward signal that teaches models to reason.

Keywords: code generation · automated program repair · code LLMs · reinforcement learning with verifiable rewards · formal theorem proving · program synthesis

Qihao Zhu in Peking University graduation gown
Fig. 2. The author, with co-author (teddy bear), at Ph.D. graduation, Peking University.
Listing 1 · research.lean (informal)-- still compiling
theorem research_agenda :
  ∀ intent : NaturalLanguage,
    ∃ p : Program, WellTyped p ∧ Satisfies p intent := by
  grow_by_grammar          -- TreeGen · GrammarT5 · Grape          (2018–2024)
  repair_until_typed       -- Recoder · Tare                       (2021–2023)
  scale_and_pretrain       -- DeepSeek-Coder · DeepSeek-Coder-V2  (2024)
  reinforce_with_checker   -- DeepSeekMath (GRPO) · Prover · R1   (2024–)
  sorry                    -- work in progress
§2

News

A changelog, newest first.

  • releaseDeepSeek-V4: towards highly efficient million-token context intelligence. Tech report on arXiv.
  • acceptedDSCodeBench, a realistic benchmark for data-science code generation, at AAAI 2026.
  • preprintLearning to guarantee type correctness in code generation through type-guided program synthesis (arXiv).
  • publishedDeepSeek-R1 appears in Nature 645: “DeepSeek-R1 incentivizes reasoning in LLMs through reinforcement learning” (paper).
  • publishedDirectional diffusion-style code-editing pre-training in IEEE TSE; LEAM++ in ACM TOSEM.
  • releaseDeepSeek-Prover-V2: formal reasoning through RL for subgoal decomposition (arXiv).
  • acceptedDeepSeek-Prover-V1.5 (proof-assistant feedback + RL + MCTS) at ICLR 2025.
  • releaseDeepSeek-Coder-V2: an open model that breaks the barrier of closed-source models in code intelligence.
  • publishedGrammarT5, a grammar-integrated pre-trained model for code, at ICSE 2024.
  • releaseDeepSeekMath, which introduced GRPO, later the RL algorithm behind DeepSeek-R1.
  • releaseDeepSeek-Coder: when the large language model meets programming.
§3

Research trajectory

Written as a derivation: each stage rewrites the one before it.

𝒢 2018 – 2021

Structure

text ⇒ AST

Generate code as a sequence of grammar rules instead of tokens, so the output is always syntactically valid.

  • Grammar-CNN
  • TreeGen
  • OCoR
  • Lyra
Δ 2021 – 2023

Repair

AST ⇒ AST′ ⊨ tests

Edit trees, not strings. Syntax-guided edits and type-aware decoding lead to patches that compile.

  • Recoder
  • Tare
  • Grace
  • FIRA
∑ 2022 – 2024

Scale

grammar ⇒ pre-training

Build structure into pre-training, then scale open code models to the frontier.

  • Grape
  • GrammarT5
  • DeepSeek-Coder
  • Coder-V2
⊢ 2024 – now

Reason

checker ⇒ reward

Use compilers, tests and proof assistants as verifiers, and their verdicts as the reward signal for reinforcement learning.

  • DeepSeekMath
  • Prover V1–V2
  • R1
  • V3 · V4
§4

Publications

See Google Scholar for the complete, up-to-date list.

★ selected  ·  Qihao Zhu underlined  ·  venue colour: LLMs & reasoning / code & SE / ML & AI / wireless sensing

§6

Positions, honors & service

// positions

  • Researcher, DeepSeek-AI
    Code LLMs, reasoning, RL
  • Ph.D. in Computer Science, Peking University
    Advisor: Prof. Yingfei Xiong · Program generation & repair

// service

  • Reviewer
    AAAI · ICSE · FSE · IJCAI · ASE
  • Teaching assistant
    Program Analysis (2022) · Software Engineering (2021)
  • Mentoring
    Undergraduate and graduate research projects

// honors

  • Peking University President Scholarship
  • Outstanding Student Award, Peking University
  • May 4th Scholarship, Peking University
  • Guanghua Scholarship, Peking University
§7

Contact

I'm happy to talk about code LLMs, program repair, formal reasoning or collaborations. The fastest way to reach me is email:
zhuqh@pku.edu.cn
Also on GitHub and Google Scholar.