HomeAboutProjectsSkillsContactLab

Benchmarks

Six small coding prompts, one response per task per variant. Useful for spotting mistakes, far too small for conclusions about quality.

Four kinds of evidence

How to read the results
KindWhat it isCoverage
Automated checkCase-insensitive search for required and forbidden strings anywhere in the answerRounds 1 and 2, recorded
Manual evaluationHuman-review notes as written in the recordsDetailed for v2 in round 1; one brief remark for v3
Execution spot checkRun or type-check the first code block; added during blog preparation4 of 6 tasks
Correctness scoreA validated measure of whether answers are rightNone exists

Methodology

Round 1 commands
ollama pull qwen3:1.7b-q4_K_M
ollama create qwen3-coder-assistant-v2 -f Modelfile-v2
python3 run_benchmark.py

Both scripts hard-code /workspace/qwen3-lora-lab as their root folder. Edit that path before running them from a fresh clone.

Test examples

Concurrent async saves js-async-01 · javascript

Write an async function saveAll(items, save) that runs all saves concurrently, returns their results in input order, and rejects if any save rejects. Include a short usage example.

Required strings: async function, Promise.all, items.map
Forbidden strings: items.map(async item => save(item)).then

Parse a positive integer py-parse-01 · python

Write parse_positive_int(value): accept a string containing only decimal digits, return its integer value if greater than zero, otherwise raise ValueError. Include tests for '42', '0', '-2', '3.5', and 'abc'.

Required strings: def parse_positive_int, ValueError, 3.5, -2

Nullable user name ts-null-01 · typescript

Given async function getUser(): Promise<User | null>, write a function that safely returns the user's name or the string 'Guest'. Do not use any or non-null assertions.

Required strings: User | null, ??, Guest
Forbidden strings: as any, !

Parameterised SQL sql-sec-01 · sql

Show a safe parameterized SQL query to find a user by email. Explain briefly why string concatenation is unsafe. Use a generic placeholder parameter, not string interpolation.

Required strings: SELECT, WHERE, parameter
Forbidden strings: + email<ß}úo+^²‰¢¶ם3/3 keywords✓ passed3/3 keywords✓ passed2/3 keywords✕ failedParse a positive integerpy-parse-014/4 keywords✓ passed4/4 keywords✕ failed4/4 keywords✓ passedNullable user namets-null-011/3 keywords · flagged✓ passed2/3 keywords✓ passed1/3 keywords✕ failedParameterised SQLsql-sec-013/3 keywords– not run3/3 keywords– not run3/3 keywords– not runAverage of an empty listdebug-py-012/3 keywords✓ passed2/3 keywords✓ passed2/3 keywords✓ passedBranch and commitgit-012/3 keywords– not run2/3 keywords– not run2/3 keywords– not run

What each spot check tests
  • js-async-01: Node: input order kept, rejection propagates (usage example excluded).
  • py-parse-01: Python: a plain call handles the five prompt inputs.
  • ts-null-01: tsc --strict with a declared User type; compiling does not mean every constraint was met.
  • debug-py-01: Python: [] does not raise, [1,2,3] gives 2.0.

SQL and Git answers were not executed. A pass is not a correctness score.

Response time and length

Seconds per responseBasev2v3
Concurrent async saves
Base8.75
v26.1
v34.88
Parse a positive integer
Base7.22
v29.97
v35.06
Nullable user name
Base6.59
v24.56
v32.54
Parameterised SQL
Base5.47
v26.74
v31.81
Average of an empty list
Base4.63
v23.94
v33.4
Branch and commit
Base3.44
v25.49
v32.31

Wall-clock time from one request each on a shared small machine. Longer answers take longer; model loading may be included. Not a speed benchmark.

Generated tokens per responseBasev2v3
Concurrent async saves
Base378
v2269
v3151
Parse a positive integer
Base290
v2400
v3218
Nullable user name
Base290
v2189
v398
Parameterised SQL
Base252
v2279
v368
Average of an empty list
Base211
v2174
v3135
Branch and commit
Base156
v2218
v385

Output length, capped at 400. Shorter is not better or worse by itself. v2's Python parser answer reached the cap.

Time and token data
TaskBase (s / tokens)v2 (s / tokens)v3 (s / tokens)
Concurrent async saves8.75 / 3786.1 / 2694.88 / 151
Parse a positive integer7.22 / 2909.97 / 4005.06 / 218
Nullable user name6.59 / 2904.56 / 1892.54 / 98
Parameterised SQL5.47 / 2526.74 / 2791.81 / 68
Average of an empty list4.63 / 2113.94 / 1743.4 / 135
Branch and commit3.44 / 1565.49 / 2182.31 / 85

Manual review: round 1, v2

  • The v2 response for the JavaScript task used a faulty mock save function that returned a function instead of a promise, so the example is not correct as written.
  • The v2 Python parser was unnecessarily declared async and accepted 0, although the requirement said positive integer only.
  • The v2 TypeScript example omitted the declared User | null type and did not use the requested nullish-coalescing operator.
  • The v2 Python average explanation incorrectly claimed sum([]) raises TypeError; in Python it returns 0, so division by zero is the actual issue.
  • The v2 Git commands use git checkout -b, which works, but do not match the requested git switch -c form.
  • Conclusion: this small run does not demonstrate a reliable overall improvement from the prompt configuration. More importantly, generated code needs executable unit tests.

These are the recorded notes. On the parser, awaiting the coroutine does reject '0'; a plain call does not. See case 1.

For v3, the changelog records only that manual inspection remains necessary and that some required details were still missing.

Limitations and observations

  • One run per prompt: no measure of variation.
  • Rounds 1 and 2 differ in prompt suffix and temperature, so v3 is not a controlled comparison.
  • Configuration 1 has no saved responses.
  • A keyword can match in prose while the code is wrong, and the ! check can flag ordinary punctuation.
  • Ollama version and model digest were not recorded.
  • coding-eval.md lists a separate five-prompt set; no results for it are recorded.

Read all 18 recorded responses