AI Engineer World's Fair 2026

From Tokenmaxxing to Trusted Throughput — Mingsheng Hong, Ironclad

Read the talk

From Tokenmaxxing to Trusted Throughput

Mingsheng Hong explains how Ironclad connects AI coding costs to software that survives automated checks, human judgment, and customer use—and why faster generation moves the real bottleneck into review and CI.

From a talk by Mingsheng Hong

At a glance

Ideas worth remembering

  • Use token dashboards to investigate adoption gaps and unusual bursts, with comparisons grounded in each team’s work. Do not reward consumption.

  • Measure delivered value alongside cost. Ironclad’s complexity-weighted merged PRs are an evolving proxy, not a complete measure of customer value.

  • Trusted throughput combines objective checks, human engineering judgment, and evidence from customer use. A merge is only an intermediate delivery measure.

  • Expect abundant generation to move constraints into review and CI. Measure readiness-to-submission time and retries, remove flaky tests, and resist giant batched PRs.

  • Bound agent retry loops, arrange prompts for cacheable prefixes, prune growing context, and turn recurring lessons into shared practices.

  • Buy common infrastructure and build company-specific working knowledge, while evaluating ambiguous agent investments in light of their downstream review and CI costs.

Token usage is a smoke detector, not a leaderboard

Mingsheng Hong, VP of engineering focused on AI at Ironclad, opens with a management failure hiding inside an ordinary dashboard. In a reported story from Amazon, an employee created a voluntary view of AI token usage. Some engineers then competed to reach the top. Hong is explicit that he does not know whether leadership encouraged the competition; the consequential point is that publishing a number can create an incentive even without attaching a formal reward to it.

Core contrast: usage dashboards should function as smoke detectors rather than leaderboards.
Core contrast: usage dashboards should function as smoke detectors rather than leaderboards.

Ironclad also tracks token usage and cost by team and individual, but treats the dashboard as a “smoke detector.” Surprisingly low usage can expose a pocket where access, training, or confidence is missing. A sudden burst can justify investigating what changed. Neither observation establishes employee performance, and rewarding the largest number would turn consumption—the input cost—into the goal.

0:120:45
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

0:12 · section reference included

Cost controls come after the adoption hump

This advice has a boundary: it primarily applies after a team has made AI tools readily available and established real usage. A company still provisioning access or persuading engineers to experiment may undermine adoption by introducing aggressive cost controls too early. Ironclad had only crossed that threshold over the preceding couple of quarters, and roughly half the audience identified with the next phase: adoption exists, so spending has become a serious concern.

Explains that cost controls are appropriate only after teams cross the initial AI-adoption hump.
Explains that cost controls are appropriate only after teams cross the initial AI-adoption hump.

Adoption itself cannot be solved entirely by executive instruction. Some engineers told Hong that the pride of handcrafting code had been replaced by reviewing “AI slop code.” That objection describes a real change in the work, not mere resistance to a tool. Leaders need to sit with affected teams, understand where the friction comes from, and preserve demanding technical work through which engineers can continue developing judgment and skill.

2:182:49
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

2:18 · section reference included

Trust grows by testing familiar ground first

Ironclad builds AI products for legal contracting, where lawyers, procurement teams, and other business users need to move contracts faster without losing control of risk. A lawyer may first run conversational search over contracts they already know. Familiar material provides a reference point: if the answers match expectations, the lawyer can cautiously expand to unfamiliar contracts or higher-stakes workflows such as redlining and anomaly detection.

Introduces trust as the primary product constraint for Ironclad’s legal-contracting AI.
Introduces trust as the primary product constraint for Ironclad’s legal-contracting AI.

AI-assisted engineering follows the same progression. Generated work has to earn confidence from engineers and leadership before it reaches customers, then survive contact with actual customer use. Hong calls the result trusted throughput: code reviewed and validated internally, then ultimately validated in customer deployments. The objective is therefore better return on token spending, not austerity for its own sake.

4:284:58
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

4:28 · section reference included

Measure value before trying to minimize cost

Cost measurement starts with the available usage data. A team centered on one coding tool may get enough detail from its vendor dashboard. Ironclad uses several tools, so it built extraction pipelines and dashboards that combine vendor data, then aggregate and break down spending by team and individual. This makes cross-tool usage visible instead of leaving each vendor’s portion isolated.

Uses lines of code as the analogy for a metric worth observing but dangerous to optimize directly.
Uses lines of code as the analogy for a metric worth observing but dangerous to optimize directly.

Moving directly from that dashboard to cost cutting evaluates only one side of the return. Ironclad pairs cost with a proxy for delivered value, then looks for whatever prevents generated work from becoming shipped work. As code generation becomes abundant, those constraints increasingly appear downstream in code review, continuous integration, and merging.

Dashboard comparisons also require local context. A platform infrastructure team may use AI differently from a UI team and derive value through different work. Regular review should answer two practical questions. Adoption gaps: Where is usage unexpectedly low, and does that reveal a problem worth helping with? Anomalies: Where did spending suddenly jump, and was the burst legitimate? The resulting lessons can update shared practices without stack-ranking employees.

Lines of code provide the useful analogy. LOC can describe activity, but maximizing it would punish an engineer who deletes unnecessary code and leaves the system simpler. Token usage has the same shape: worth observing, terrible as a direct performance target.

6:507:20
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

6:50 · section reference included

From generated volume to complexity-weighted merges

Hong uses lines of code as an analogy for a metric that counts output without saying whether it forms a useful change. He then describes Ironclad’s measurement evolution from open to merged pull requests. Open pull requests grouped work into proposals and showed a pronounced increase, but proposals can remain experimental or never ship. Merged pull requests moved the metric closer to delivery because the code had at least passed through the path to the codebase.

Presents the internal evidence behind trusted throughput: objective checks complemented by human judgment.
Presents the internal evidence behind trusted throughput: objective checks complemented by human judgment.

The next failure appears in a concrete comparison. A 10-line change might represent a concurrency bug that took substantial investigation to find and fix. A thousand-line change might be boilerplate that was easy to generate but expensive to review. Counting each as one merge treats visibly different work as equivalent; counting lines makes the boilerplate look more valuable. Ironclad therefore asks one or two LLMs, using a crafted prompt, to assign each merged PR a T-shirt-sized complexity score and uses that score as a weight.

This is an evolving proxy, not a settled definition of value. The talk supplies neither a reproducible scoring rubric nor numerical weights, and complexity does not necessarily equal customer value. The complexity weighting is intended to distinguish a concurrency fix from boilerplate; the talk does not report evaluated discrimination results, but the remaining gap is why trusted throughput needs qualitative evidence beyond the score.

What evidence makes throughput trusted? The comparison below separates three forms of validation that catch different failures. Automated checks test predefined properties, people judge qualities that resist simple rules, and customer experience reveals whether internally acceptable work holds up in production.

Compare the ideasThe three forms of evidence behind trusted throughput

Test coverage, predefined security checks, and canary rollout practices test known requirements.

Objective checks and human judgment validate work internally. Production and customer signals provide the external test. These are evidence categories, not a claim that every check runs in one strict sequence.

10:2210:53
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

10:22 · section reference included

Abundant generation moves the bottleneck into review and CI

Once AI makes PR creation easier, review and merging become the scarce stages. A tempting workaround is to stop splitting changes. If the regression suite takes an hour, an engineer may reason that 10 small PRs imply 10 hours of waiting and submit one large PR instead. The apparent CI saving creates a review problem: larger diffs demand more human attention, spread that attention thin, and make careful review less likely.

Highlights the operational metric of wall-clock waiting from a ready PR to submission, including flaky-test delays.
Highlights the operational metric of wall-clock waiting from a ready PR to submission, including flaky-test delays.

Ironclad uses AI as the first review pass rather than the final authority. Automated review can flag simpler issues such as style problems or missing test coverage before a human sees the change. Human reviewers can then spend their limited attention on code quality, architectural fit, and security design. The engineering team keeps final accountability.

CI creates a second queue. More numerous, smaller PRs increase test demand, while flaky tests force engineers to babysit runs and press retry. Assigning an agent to babysit merely exchanges human waiting for token spending. Both are workarounds around the same unstable pipeline, and the repetitive delay also damages morale.

The useful measurement is end-to-end waiting, not just the nominal duration of one CI run. Ironclad tracks wall-clock time from a PR being ready to submit until it is submitted, plus the number of retries required to pass. If one CI run normally takes an hour but a typical PR takes two or three hours to get through, the unexplained gap is the red flag. That observation directs platform and developer-experience investment toward flaky-test removal and CI capacity.

Where does the extra AI-generated work accumulate? The flow below shows review and CI as parallel downstream constraints rather than a universal ordering. Increasing generation loads both systems; slow CI can then encourage batching, which sends larger, harder diffs back into review.

How it fits togetherThe bottleneck moves downstream

Engineers can create and split changes into more pull requests.

Increasing generation without expanding review and CI capacity produces queues rather than trusted throughput. The exact ordering of review and CI varies by workflow; both must clear before delivery.

13:5214:21
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

13:52 · section reference included

Bound waste, improve the loop, and build only local advantage

The operating framework combines three mechanisms. Guardrails set budgets and quotas, track usage, and define anomalies that trigger attention. Working practices improve how engineers use AI. Learning loops bring leaders and engineers together to review patterns, refine limits, and feed useful discoveries into institutional knowledge. Automated alerts identify known conditions; human review still catches patterns the predefined rules miss.

Summarizes the build-versus-buy rule: purchase commodity infrastructure and build company-specific working knowledge.
Summarizes the build-versus-buy rule: purchase commodity infrastructure and build company-specific working knowledge.

A test-and-repair agent loop makes the need for guardrails concrete. The agent generates a PR, runs tests, modifies the code or tests after a failure, and retries. A hard limit on loop steps makes the process finite. Hong does not prescribe a universal retry count; the design requirement is to stop a broken workflow from consuming tokens indefinitely.

Two prompt and context practices reduce repeated work. Stable prefixes: when a vendor supports prompt caching, fixed material should come first and varying material afterward—for example, a stable system prompt above the changing user prompt. Context pruning: as a session grows, engineers should summarize or compact accumulated history rather than repeatedly carrying everything forward. Coding tools may automate compaction. Hong presents these practices as improving token efficiency and output quality, without quantifying either effect.

The build-versus-buy rule is deliberately plain: buy common, non-differentiating infrastructure such as IDE and CI capabilities; build the knowledge specific to how the company works. Ironclad’s example is an internal playbook of carefully written prompts for distinct tasks such as small bug fixes, new UI features, and refactoring. Sharing those prompts lets teams reuse and improve their working methods.

The boundary remains ambiguous for systems that mix commodity infrastructure with local workflow. Ironclad was exploring a cloud-based “builder agent” wrapping coding tools while also considering external vendors. Hong leaves that decision unresolved rather than claiming every company should build its own agent.

The closing lesson is to plan for second-order effects. More code generation changes review load, CI demand, pull-request shape, and developer experience. Teams should make build-versus-buy decisions early, invest in downstream capacity before queues force bad workarounds, and keep instrumenting the path from ready PR to customer outcome. Maximizing token ROI means expanding the organization’s ability to validate and deliver software alongside its ability to generate it.

17:5818:28
Suggest correction

This note stays in this page until you copy or download it. Nothing is submitted; reloading clears the draft.

17:58 · section reference included

Resources

From the talk

Read the complete timestamped transcript
  1. 0:01

    [music]

  2. 0:12

    All right, let's get started. Apologies

  3. 0:15

    for the delay, but I'm really excited to

  4. 0:17

    be here. I'm Mingshan, VP of engineering

  5. 0:20

    focused on AI at Ironclad. And today

  6. 0:24

    I'll be telling you about something

  7. 0:25

    that's probably on top of many of your

  8. 0:28

    mind. uh how to control and optimize for

  9. 0:32

    your AI token spend. Can I get a get a

  10. 0:35

    quick show of hands that this is a

  11. 0:37

    relevant topic?

  12. 0:40

    Okay, awesome. I appreciate that.

  13. 0:45

    So, we have all heard a few sensational

  14. 0:48

    stories from the media. There's an

  15. 0:51

    interesting Amazon story where an

  16. 0:53

    employee just created kind of a

  17. 0:55

    voluntary dashboard and everyone start

  18. 0:58

    tracking their own AI token usage. I'm

  19. 1:01

    not sure there's explicit encouragement

  20. 1:03

    from the leadership, but the effect is

  21. 1:05

    you know engineers some of the engineers

  22. 1:07

    started competing with each other in

  23. 1:09

    maximizing their token usage and get to

  24. 1:12

    the top of the so-called leaderboard.

  25. 1:14

    There's a similar story from Meta and

  26. 1:17

    then another even more sensational story

  27. 1:19

    about some companies spending $500

  28. 1:21

    million on cloud oops within a month. So

  29. 1:26

    while these may not be happening in your

  30. 1:28

    companies today, the threats, the risks

  31. 1:31

    are real. How do we think about the

  32. 1:34

    policies? How do we measure the cost?

  33. 1:36

    And how do we control and optimize for

  34. 1:38

    it?

  35. 1:40

    So one initial learning I want to share

  36. 1:42

    is it is really important to have

  37. 1:45

    dashboard that track every team every

  38. 1:48

    individual's token usage and cost but

  39. 1:51

    that should not be positioned as a

  40. 1:53

    leaderboard. We think of the the usage

  41. 1:57

    dashboard more as a smoke detector. If

  42. 2:00

    there are local pockets of teams or

  43. 2:02

    individuals that don't use much AI token

  44. 2:05

    that might be a signal worth

  45. 2:06

    investigating. But beyond that certainly

  46. 2:09

    we don't want to create even indirect

  47. 2:12

    incentive to maximize the token usage

  48. 2:15

    itself.

  49. 2:18

    So how do we think about it then? First

  50. 2:21

    I want to make sure that we position

  51. 2:23

    this talk for those of you whose teams

  52. 2:26

    have already gone through the hump of

  53. 2:29

    getting AI adopted. If you're still in

  54. 2:32

    the initial process of provisioning easy

  55. 2:36

    access to your engineers or encouraging

  56. 2:39

    the teams and individuals to adopt, then

  57. 2:42

    you may not be ready to implement some

  58. 2:45

    of the ideas for controlling and

  59. 2:47

    optimizing for cost. But that's okay.

  60. 2:50

    This could still be a good discussion.

  61. 2:51

    And frankly, we just got over that hump

  62. 2:54

    over the last couple quarters. So this

  63. 2:56

    is a very topical subject that every

  64. 2:59

    engineering leader I believe is

  65. 3:01

    navigating. So I would love to start

  66. 3:02

    that dialogue with you all today to

  67. 3:04

    explore the best practices. Can I get a

  68. 3:07

    quick show of hand for those of you

  69. 3:09

    whose teams have gone over the initial

  70. 3:11

    adoption phase now you are starting to

  71. 3:14

    seriously worry about the cost. Okay, I

  72. 3:17

    see roughly half of the hands raised.

  73. 3:18

    Thank you. So let's talk about then how

  74. 3:22

    we can control and how we can optimize

  75. 3:25

    what we call the trusted throughput as a

  76. 3:27

    kind of a proxy metric as a way to

  77. 3:30

    measure your ROI. But before that, just

  78. 3:33

    for those of you who are in the process

  79. 3:35

    of still increasing adoption, one lesson

  80. 3:38

    we learned is to after the kind of the

  81. 3:41

    top down leadership push is to sit down

  82. 3:43

    with the individual teams and uh the

  83. 3:47

    individuals who may be resistant or

  84. 3:49

    struggling with adoption, understand

  85. 3:51

    where they came from. For example, there

  86. 3:53

    are some legitimate concerns that I

  87. 3:55

    heard, you know, people say, "Hey, I

  88. 3:57

    used to really take pride and joy in

  89. 3:59

    handcrafting the code and now a lot of

  90. 4:01

    the joy and the pride got taken away and

  91. 4:05

    replaced with me reviewing AI slop code,

  92. 4:08

    right? So that doesn't sound like a very

  93. 4:10

    satisfying professional activity and

  94. 4:12

    that's where we need to kind of dig down

  95. 4:14

    and understand what are still the kind

  96. 4:16

    of the high impact and uh engineering

  97. 4:19

    tasks technical work that we can help

  98. 4:21

    our engineers continue to grow

  99. 4:23

    themselves in the era of the AI.

  100. 4:28

    So I wanted to share with you a bit more

  101. 4:31

    about what we at ironclad does and

  102. 4:33

    there's an interesting connection

  103. 4:35

    actually within how we think about

  104. 4:36

    optimizing for engineering AI token

  105. 4:39

    usage. So, ironclad is a legal

  106. 4:42

    contracting AI companies AI company. We

  107. 4:45

    build AI features and native AI products

  108. 4:49

    to help lawyers, procurement and other

  109. 4:52

    business users move forward new

  110. 4:54

    contracts, move them forward faster with

  111. 4:57

    controlled risk. What that means is

  112. 5:00

    building trust is the number one

  113. 5:02

    priority with our AI product features

  114. 5:05

    and products. And for the prior speak uh

  115. 5:07

    speaker speaker, she did a wonderful job

  116. 5:09

    telling you about the importance of

  117. 5:11

    trust and how to build it in their

  118. 5:13

    domain. In our ironclad product domain,

  119. 5:16

    it often means lawyers especially, but

  120. 5:19

    other persona as well taking the time to

  121. 5:21

    kind of test the water and see if they

  122. 5:23

    can trust the AI output. For example,

  123. 5:26

    they may feed our conversational search

  124. 5:28

    a set of contracts they are firmly

  125. 5:30

    familiar with and they run a search and

  126. 5:33

    see if the output is towards the

  127. 5:35

    expectation. If so, they may expand on

  128. 5:38

    searching for things they don't know

  129. 5:39

    about or apply other workflows using AI

  130. 5:42

    to solve other things like redlinining

  131. 5:44

    the contract um and you know finding

  132. 5:47

    anomalies and so on. And so similarly

  133. 5:51

    using AI and making sure AI is

  134. 5:54

    delivering high engineering value also

  135. 5:56

    involves a you know a sequence of steps

  136. 5:59

    in gaining trust from the internal

  137. 6:01

    engineers the leadership as well with as

  138. 6:04

    uh with our customers. So this is the

  139. 6:06

    focus of our talk today

  140. 6:11

    and this probably will not come as a

  141. 6:13

    surprise here. The goal is not to

  142. 6:17

    minimizing or not even necessarily to

  143. 6:19

    reduce token spend. So here we kind of

  144. 6:22

    use the word it's not about austerity.

  145. 6:24

    It's about further improving the ROI of

  146. 6:26

    the token spend.

  147. 6:29

    So how do we do that? Here we propose um

  148. 6:32

    a concept we call trusted throughput. So

  149. 6:36

    the trusted throughput comes from having

  150. 6:39

    the code reviewed and validated

  151. 6:42

    internally and ultimately validated in

  152. 6:45

    customer uh in customer deployments.

  153. 6:50

    So how do we go and how do we think

  154. 6:54

    about controlling the cost and uh

  155. 6:57

    measuring and in turn optimizing the

  156. 7:00

    ROI? The first step is I'm pretty

  157. 7:03

    confident that all of you your teams who

  158. 7:05

    have been adopting AI have been

  159. 7:06

    measuring the cost. If you're using a

  160. 7:09

    single tool like claw code or codeex

  161. 7:12

    then you tend to get very rich analytics

  162. 7:14

    from the vendor's dashboard already. If

  163. 7:16

    you're like us who use a combination of

  164. 7:18

    these different coding tools then we

  165. 7:21

    basically use AI to build simple

  166. 7:23

    dashboards and pipelines to extract such

  167. 7:26

    vendor data. So we can kind of

  168. 7:28

    crossorrelate them. Then we can break it

  169. 7:30

    down, aggregate and then break down by

  170. 7:32

    per team, per individual, what is their

  171. 7:35

    cost usage across all of these uh tools.

  172. 7:39

    So that's the first step for measuring

  173. 7:40

    cost. Now one pitfall I have seen and we

  174. 7:44

    wanted to caution everybody is to then

  175. 7:47

    jump from measuring cost to start

  176. 7:50

    reducing or minimizing the cost, right?

  177. 7:52

    Cutting cost. We think that is

  178. 7:54

    premature. Instead, the other important

  179. 7:56

    side of the equation for ROI is to

  180. 7:58

    measure value. How much value are we

  181. 8:01

    getting from burning the tokens? Once we

  182. 8:04

    can measure the cost and value side, we

  183. 8:06

    understand ROI and then to improve ROI,

  184. 8:09

    we want to find and then fix the

  185. 8:11

    bottlenecks. In the next couple slides,

  186. 8:14

    I'm going to introduce two new

  187. 8:15

    bottlenecks we identify in this whole

  188. 8:17

    new software development life cycle

  189. 8:19

    where code generation now becomes

  190. 8:21

    abundant thanks to AI. But the pressure

  191. 8:24

    is now getting pushed down to code

  192. 8:26

    review and continuous integration CICD

  193. 8:29

    the merging the code. So we'll talk

  194. 8:31

    about that and finally we'll put

  195. 8:33

    together these ideas into a pra

  196. 8:35

    pragmatic framework of how we think

  197. 8:37

    about optimizing the ROI and thus the

  198. 8:39

    leverage in using AI.

  199. 8:45

    Okay. So this is kind of just a slide in

  200. 8:48

    building or using the vendor dashboard

  201. 8:50

    to measure the cost. And again we want

  202. 8:52

    to caution that here the main goal for

  203. 8:55

    regularly reviewing the dashboard is to

  204. 8:58

    see a if there's still adoption gap

  205. 9:00

    within individual pockets of teams or

  206. 9:02

    the individual engineers and b if there

  207. 9:05

    are any sudden surprises in kind of the

  208. 9:08

    usage burst and if so understand what's

  209. 9:10

    been happening if they're legitimate and

  210. 9:12

    then also compare teams

  211. 9:15

    contextually. So this is important. We

  212. 9:17

    don't control just the AI usage per se

  213. 9:20

    because for example a platform

  214. 9:21

    infrastructure team the way they use AI

  215. 9:24

    and the way they get value may be

  216. 9:25

    different from the UI team. So we need

  217. 9:27

    to take the context into consideration.

  218. 9:30

    All of such review analysis is to help

  219. 9:32

    us extract learnings. So there's a

  220. 9:34

    self-learning loop that we can then feed

  221. 9:36

    back into institutional best practices.

  222. 9:39

    What we don't want to use the dashboards

  223. 9:42

    are to kind of stack rank people, right?

  224. 9:44

    making it a a leaderboard and somehow

  225. 9:47

    reward maximization.

  226. 9:49

    There's an interesting analogy I want to

  227. 9:50

    draw with uh a traditional edge

  228. 9:53

    productivity metric called lines of

  229. 9:55

    code. So I believe all of you will be

  230. 9:58

    tracking that metric but it wouldn't be

  231. 10:00

    wise to use that metric as the key goal

  232. 10:02

    to measure engine velocity because if we

  233. 10:05

    want productive and high quality engine

  234. 10:08

    work one can argue that removing code is

  235. 10:11

    even better. So, LOC line of code is an

  236. 10:14

    important metric but not something we

  237. 10:16

    want to directly optimize for. Same

  238. 10:18

    thing for the token usage and spend.

  239. 10:22

    So, that that gets us to the notion of

  240. 10:25

    trusted throughput. How do we think

  241. 10:27

    about that? How do we define that?

  242. 10:29

    First, I want to kind of share the

  243. 10:31

    quantified uh side of the things. What

  244. 10:33

    are the metrics that kind of we have

  245. 10:34

    been involving in defining and tracking.

  246. 10:37

    So we talked about line of code is

  247. 10:39

    clearly not a good way to measure if AI

  248. 10:42

    is you know generating a lot of value.

  249. 10:44

    So the next evolution can be let's count

  250. 10:47

    the number of open PRs pull requests.

  251. 10:50

    The intuition being engineers are using

  252. 10:53

    AI to generate a lot more code. So let's

  253. 10:55

    measure the open PR. So clearly we see a

  254. 10:59

    big kind of inflection in the open PR

  255. 11:02

    count. But eventually as we as I assume

  256. 11:05

    everyone would agree over the time even

  257. 11:07

    though people may do oneoff you know R&D

  258. 11:10

    work to try out things without lending

  259. 11:12

    them but eventually we're all measured

  260. 11:14

    by the code we ship. So therefore we

  261. 11:17

    evolved from tracking the open PR count

  262. 11:20

    to tracking the merge PR count. So

  263. 11:22

    that's an improvement.

  264. 11:25

    But the next question is not every

  265. 11:27

    merged PR is equal. There can be a PO

  266. 11:30

    with only 10 lines of code that takes

  267. 11:32

    forever that finds and fix a concurrency

  268. 11:34

    bug or there can be a thousand line kind

  269. 11:37

    of boilerplate code that just takes a

  270. 11:39

    lot of time to then kind of generate and

  271. 11:41

    review but otherwise it's not necessary

  272. 11:43

    adding as much business value.

  273. 11:46

    So as such we then started kind of

  274. 11:48

    tagging each merged PR with some sort of

  275. 11:51

    complexity score. There's no traditional

  276. 11:54

    definition of what that means. We looked

  277. 11:56

    at the literature a bit. So we just took

  278. 11:58

    a pragmatic approach of giving AI a

  279. 12:00

    well-crafted prompt and then we feed the

  280. 12:03

    PR into basically one or two M and say

  281. 12:06

    score the complexity based on t-shirt

  282. 12:08

    size. So I the idea being if you use AI

  283. 12:11

    to generate a more complex PR we

  284. 12:13

    consider that as being more valuable

  285. 12:15

    basically that's how we kind of add a

  286. 12:17

    weightage to each merged PR but that's

  287. 12:20

    not the end of the journey that's still

  288. 12:21

    something we're going to evolve keep

  289. 12:23

    evolving and I would love to discuss

  290. 12:25

    with everyone on kind of how we end up

  291. 12:27

    creating defining a set of metrics that

  292. 12:30

    kind of approximate the value AI is

  293. 12:32

    generating.

  294. 12:34

    Now let's look at the qualitative view.

  295. 12:36

    What we think about the way we would

  296. 12:38

    define trusted throughput is a high

  297. 12:41

    quality output that's interested by both

  298. 12:43

    internal engineering and leadership and

  299. 12:46

    external customers. We think they come

  300. 12:48

    from three buckets.

  301. 12:50

    The first bucket is all of the objective

  302. 12:53

    metrics that we run with checking the

  303. 12:55

    test coverage whether uh all of the

  304. 12:58

    predefined security checks are passing.

  305. 13:00

    Do we go through the regular canarying

  306. 13:03

    practice as we roll out features safely

  307. 13:04

    and so on. In addition, we complement

  308. 13:08

    the subjective objective metrics with

  309. 13:11

    our subjective human judgment. So that's

  310. 13:13

    where the code review, the design review

  311. 13:16

    come in to look at the code quality,

  312. 13:18

    clarity, maintenance, architecture fit

  313. 13:20

    and so on. And then finally we want to

  314. 13:23

    make sure through all of these internal

  315. 13:25

    objective and subjective check when the

  316. 13:27

    rubber meets the road how customer

  317. 13:30

    perceive the changes are there

  318. 13:32

    production fire that lead to ro

  319. 13:34

    rollbacks do customers complain have

  320. 13:37

    tickets that talk about usability uh

  321. 13:39

    friction uh bugs and so on. So these are

  322. 13:42

    the three buckets that together form

  323. 13:44

    what we think is trusted throughput from

  324. 13:46

    engineering.

  325. 13:52

    Okay. So now let's talk about from a

  326. 13:54

    software deploy deployment life cycle

  327. 13:56

    perspective where we observe the new

  328. 13:59

    bottlenecks are as I mentioned earlier

  329. 14:02

    AI code generation is making PR creation

  330. 14:06

    abundant. So now the the bottleneck from

  331. 14:10

    kind of the whole life cycle perspective

  332. 14:12

    gets shifted onto re review and they're

  333. 14:15

    subsequently merging the PR. Does that

  334. 14:17

    resonate?

  335. 14:20

    I see some heads nodding. So this is

  336. 14:23

    where we spend time on figuring out how

  337. 14:25

    we can further improve the review

  338. 14:27

    process as well as the continuous

  339. 14:29

    integration the CI process. So we will

  340. 14:32

    dive into these two topics in the next

  341. 14:34

    couple slides here. I just want to say a

  342. 14:37

    potential anti-attern anti-solution is

  343. 14:40

    that hey if the CI infrastructure gets

  344. 14:43

    overloaded then a workar around by

  345. 14:45

    engineers to stop splitting PR just

  346. 14:48

    start submitting large PR for review and

  347. 14:50

    submission because if it takes an hour

  348. 14:53

    to run all of your regression test and

  349. 14:55

    submit it I don't want to break my PR

  350. 14:57

    into 10 right which might take 10 hours

  351. 14:59

    however this in our view can be pretty

  352. 15:02

    risky because it makes the human review

  353. 15:06

    overhead higher it also reduce the

  354. 15:09

    quality of the review because the human

  355. 15:10

    attention can be spread thin so that is

  356. 15:12

    an anti-attern I wanted to caution

  357. 15:17

    so for code review the key principle we

  358. 15:21

    use is to make sure we onboard AI

  359. 15:23

    tooling as the first level of defense

  360. 15:26

    they don't replace human reviewers but

  361. 15:28

    we want to offload human reviewers as

  362. 15:30

    much as possible let the AI review take

  363. 15:32

    care of simpler things like coding style

  364. 15:35

    issues or if there's a missing test

  365. 15:38

    coverage. So, make sure the author gets

  366. 15:41

    through all of them before then the

  367. 15:43

    review gets routed to a human reviewer.

  368. 15:46

    And this way our human engineers can

  369. 15:48

    focus on applying their deep judgment on

  370. 15:51

    aspects that are somewhat subjective

  371. 15:53

    like if the code is good, if the

  372. 15:55

    architecture is sound, if the code uh uh

  373. 15:59

    passes kind of the security uh the

  374. 16:02

    security design and so on. so that in

  375. 16:04

    the end our engineering team can take

  376. 16:07

    the final accountability.

  377. 16:11

    Now let's look at CI. So I assume all of

  378. 16:14

    you deploy some form of CI uh CI/CD and

  379. 16:18

    what we're seeing is thanks to AI now

  380. 16:21

    making it much easier to generate code

  381. 16:24

    as splitting code into smaller but more

  382. 16:27

    PRs it puts a lot more pressure on the

  383. 16:30

    CI and this is something that uh if we

  384. 16:33

    don't address uh at a company level

  385. 16:36

    individual engineers can be struggling

  386. 16:38

    because that means they have to waste

  387. 16:39

    their human time babysitting the PR to

  388. 16:42

    get merged. If they run into flaky test

  389. 16:45

    then they have to manually they hit

  390. 16:47

    rerun it's very frustrating or they can

  391. 16:49

    recruit an AI agent to babysit and kind

  392. 16:52

    of do a loop but that in turn waste AI

  393. 16:54

    token as well. So these are not these

  394. 16:56

    are just workarounds not perfect

  395. 16:58

    solution and also tend to make engineers

  396. 17:01

    feel a little bit lower morale a little

  397. 17:03

    bit more frustrated. So what we what we

  398. 17:06

    are doing is kind of we put more uh

  399. 17:09

    developer experience uh platform kind of

  400. 17:12

    engineering to invest into reducing

  401. 17:15

    removing the flaky test improving the CI

  402. 17:18

    infrastructure and the key thing here is

  403. 17:21

    to also define and measure the right

  404. 17:24

    metrics for example uh the work clock

  405. 17:27

    time between when a peer is ready to

  406. 17:29

    submit till when it's submitted right if

  407. 17:32

    a typical CR uh run takes an hour. Does

  408. 17:36

    the typical PR submission take two or

  409. 17:37

    three hours? In which case, that's a red

  410. 17:39

    flag and also the number of times a PR

  411. 17:42

    needs to get retrieded for passing

  412. 17:44

    through the test. So, these are the key

  413. 17:46

    metrics that we are using to measure our

  414. 17:48

    developer experiences and the relevant

  415. 17:50

    team who is focused on improving uh

  416. 17:53

    these uh the developer experience.

  417. 17:58

    So with all of the analysis and ideas

  418. 18:00

    here we uh want to share kind of the a

  419. 18:04

    pragmatic framework of how we can then

  420. 18:07

    measure and optimize token usage. It has

  421. 18:10

    three aspects. The first one is set the

  422. 18:13

    right set of guards across setting the

  423. 18:15

    budget and quota tracking usage defining

  424. 18:19

    anomalies so that no users uh leaders

  425. 18:22

    can get notified if something feels

  426. 18:24

    wrong. This is complementaryary to still

  427. 18:27

    regular human review which can catch

  428. 18:29

    other interesting patterns or learnings

  429. 18:31

    and feedback into the institutional

  430. 18:33

    knowledge base.

  431. 18:35

    Let me just couple that with the third

  432. 18:37

    item here which is the learning loop we

  433. 18:40

    talk about as our leadership work with

  434. 18:43

    individuals to define these guard rails

  435. 18:45

    review the metrics and then refine

  436. 18:47

    that's how we kind of close the learning

  437. 18:49

    loop. In addition to that, we want to

  438. 18:52

    work with our teams, individual

  439. 18:54

    engineers to continue to search for and

  440. 18:56

    if needed innovate on the best practices

  441. 18:59

    of how to use AI, how to use AI to build

  442. 19:02

    products and also use it internally. For

  443. 19:05

    example,

  444. 19:07

    some engineers may be writing an agentic

  445. 19:09

    loop as part of the harness when they

  446. 19:11

    use cloud code. after they generated

  447. 19:14

    initial PR they go and loop around and

  448. 19:16

    say try and pass the set of tests and

  449. 19:19

    then if some tests don't pass just auto

  450. 19:22

    fix the test or the code and retry. One

  451. 19:25

    thing to watch out for is to put a limit

  452. 19:27

    on the number of loop steps to make sure

  453. 19:30

    if things go out of control we don't

  454. 19:32

    waste too many tokens on that. Another

  455. 19:35

    example is prompt caching. This is

  456. 19:38

    becoming increasingly more prevalent by

  457. 19:39

    the commercial uh model vendors where

  458. 19:44

    what they advise is if you send a prompt

  459. 19:48

    with the same prefix they could optimize

  460. 19:51

    how they process the prefix of the

  461. 19:53

    prompt. What that means then as a user

  462. 19:56

    to those is that we want to encourage

  463. 19:58

    our users to structure their prompt that

  464. 20:01

    way. For example, if your prompt

  465. 20:03

    consists of a system prompt followed by

  466. 20:05

    a user prompt, you want to put the

  467. 20:06

    system prompt that's fixed at the top

  468. 20:09

    and the varying content at the bottom.

  469. 20:12

    Context pruning is also important. We

  470. 20:14

    want to kind of drill it into each

  471. 20:15

    individual users kind of new kind of

  472. 20:18

    muscle memory. So they are aware that as

  473. 20:20

    they build out the context through a

  474. 20:22

    longer chat session, they would be

  475. 20:24

    mindful of summarizing the context and

  476. 20:26

    make sure that the token usage is

  477. 20:28

    efficient that way. There are

  478. 20:29

    increasingly more tools like claw code

  479. 20:31

    that will automatically manage and

  480. 20:33

    compact the context for you. And so this

  481. 20:35

    increases the token usage efficiency but

  482. 20:38

    also increase the quality of AI output.

  483. 20:40

    There are other ideas we're exploring as

  484. 20:42

    well.

  485. 20:48

    So I know we're at time so this is

  486. 20:50

    towards the end of the talk. There is

  487. 20:52

    sometimes we also face build versus by

  488. 20:54

    decision. The principle is simple for

  489. 20:57

    things that are non- differentiating

  490. 20:59

    like IDE CI infrastructure we want to

  491. 21:02

    buy. But then for things that are

  492. 21:04

    specific to our context like how we

  493. 21:06

    would generate high quality PR for small

  494. 21:09

    bug fixes versus building a new UI

  495. 21:11

    feature for refactoring and so on. We

  496. 21:13

    have our internal playbook which is a

  497. 21:15

    set of well-crafted AI prompts. So we

  498. 21:18

    save that and share across our team. So

  499. 21:21

    that gets reused and enhanced. So that's

  500. 21:23

    something we must build internally. When

  501. 21:25

    it comes to case to case though,

  502. 21:27

    sometimes it's still a bit ambiguous

  503. 21:28

    like we're trying to build what we call

  504. 21:30

    builder agent. That's like a cloud-based

  505. 21:32

    code generation that wrap the cloud

  506. 21:34

    codec and so on. While we know there are

  507. 21:37

    also other vendors out there that we're

  508. 21:39

    still exploring. So we love to exchange

  509. 21:40

    thoughts on that.

  510. 21:43

    So then to summarize here are a couple

  511. 21:45

    key lessons as we went through the last

  512. 21:47

    couple quarters of journey. I wanted to

  513. 21:49

    share so that hopefully you could kind

  514. 21:50

    of accelerate your process there. If I

  515. 21:53

    were to summarize these three things I

  516. 21:54

    would it's about learning planning ahead

  517. 21:57

    and learn from other people's stories

  518. 21:59

    mistakes. So what that means is think

  519. 22:01

    about build respences by early on as you

  520. 22:05

    are encouraging more code gen think

  521. 22:07

    about how that impact your code review

  522. 22:09

    and CI and how you can address these new

  523. 22:12

    bottlenecks. And finally, continue to

  524. 22:14

    define and instrument your system to get

  525. 22:16

    the right metrics to measure the health

  526. 22:18

    of your CI system and the whole

  527. 22:21

    developer experience in general.

  528. 22:24

    So that's it for the talk. We believe

  529. 22:26

    that this is the golden era of AI where

  530. 22:29

    maximizing token ROI is the key for

  531. 22:32

    every team success. And with that, I

  532. 22:34

    just want to end with saying we are

  533. 22:36

    hiring. I know this is engineering

  534. 22:38

    leadership crowd but if you know of

  535. 22:39

    someone who is interested in building

  536. 22:41

    cutting edge legal contracting AI we

  537. 22:43

    would love to talk. Thank you.