From 9aee4296574eed55583bb4a593b1571967a9d528 Mon Sep 17 00:00:00 2001 From: Paul Gauthier Date: Fri, 24 May 2024 10:28:30 -0700 Subject: [PATCH] copy --- _posts/2024-05-24-self-assembly.md | 78 +++++++++++++++--------------- scripts/blame.py | 4 +- 2 files changed, 40 insertions(+), 42 deletions(-) diff --git a/_posts/2024-05-24-self-assembly.md b/_posts/2024-05-24-self-assembly.md index 213585148..1c9ca4aad 100644 --- a/_posts/2024-05-24-self-assembly.md +++ b/_posts/2024-05-24-self-assembly.md @@ -24,45 +24,43 @@ according to `git blame`. | File | Lines | Percent | |---|---:|---:| -|aider/args.py| 6 of 449 | 1.34% | -|aider/coders/base_coder.py| 37 of 1354 | 2.73% | -|aider/coders/editblock_coder.py| 10 of 507 | 1.97% | -|aider/coders/editblock_func_coder.py| 8 of 141 | 5.67% | -|aider/coders/udiff_coder.py| 2 of 421 | 0.48% | -|aider/coders/wholefile_coder.py| 5 of 146 | 3.42% | -|aider/coders/wholefile_func_coder.py| 11 of 134 | 8.21% | -|aider/commands.py| 68 of 703 | 9.67% | -|aider/diffs.py| 15 of 129 | 11.63% | -|aider/gui.py| 2 of 533 | 0.38% | -|aider/history.py| 18 of 124 | 14.52% | -|aider/io.py| 45 of 368 | 12.23% | -|aider/linter.py| 29 of 240 | 12.08% | -|aider/main.py| 26 of 466 | 5.58% | -|aider/mdstream.py| 2 of 122 | 1.64% | -|aider/models.py| 18 of 549 | 3.28% | -|aider/repo.py| 20 of 266 | 7.52% | -|aider/repomap.py| 17 of 518 | 3.28% | -|aider/scrape.py| 11 of 199 | 5.53% | -|aider/versioncheck.py| 10 of 37 | 27.03% | -|aider/voice.py| 8 of 104 | 7.69% | -|benchmark/benchmark.py| 32 of 730 | 4.38% | -|benchmark/over_time.py| 32 of 60 | 53.33% | -|benchmark/swe_bench_lite.py| 39 of 71 | 54.93% | -|scripts/blame.py| 65 of 214 | 30.37% | -|scripts/versionbump.py| 92 of 123 | 74.80% | -|setup.py| 11 of 47 | 23.40% | -|tests/test_coder.py| 40 of 612 | 6.54% | -|tests/test_commands.py| 138 of 588 | 23.47% | -|tests/test_editblock.py| 23 of 403 | 5.71% | -|tests/test_io.py| 30 of 65 | 46.15% | -|tests/test_main.py| 25 of 239 | 10.46% | -|tests/test_models.py| 6 of 28 | 21.43% | -|tests/test_repo.py| 2 of 296 | 0.68% | -|tests/test_repomap.py| 70 of 217 | 32.26% | -|tests/test_udiff.py| 7 of 119 | 5.88% | -|tests/test_wholefile.py| 23 of 321 | 7.17% | -|**TOTAL**| **1003 of 14221** | **7.05%** | - - +|aider/args.py| 6 of 449 | 1.3% | +|aider/coders/base_coder.py| 37 of 1354 | 2.7% | +|aider/coders/editblock_coder.py| 14 of 507 | 2.8% | +|aider/coders/editblock_func_coder.py| 6 of 141 | 4.3% | +|aider/coders/udiff_coder.py| 2 of 421 | 0.5% | +|aider/coders/wholefile_coder.py| 5 of 146 | 3.4% | +|aider/coders/wholefile_func_coder.py| 4 of 134 | 3.0% | +|aider/commands.py| 67 of 703 | 9.5% | +|aider/diffs.py| 15 of 129 | 11.6% | +|aider/gui.py| 2 of 533 | 0.4% | +|aider/history.py| 19 of 124 | 15.3% | +|aider/io.py| 55 of 368 | 14.9% | +|aider/linter.py| 30 of 240 | 12.5% | +|aider/main.py| 30 of 466 | 6.4% | +|aider/mdstream.py| 3 of 122 | 2.5% | +|aider/models.py| 22 of 549 | 4.0% | +|aider/repo.py| 19 of 266 | 7.1% | +|aider/repomap.py| 17 of 518 | 3.3% | +|aider/scrape.py| 12 of 199 | 6.0% | +|aider/versioncheck.py| 10 of 37 | 27.0% | +|aider/voice.py| 9 of 104 | 8.7% | +|benchmark/benchmark.py| 33 of 730 | 4.5% | +|benchmark/over_time.py| 32 of 60 | 53.3% | +|benchmark/swe_bench_lite.py| 40 of 71 | 56.3% | +|scripts/blame.py| 55 of 212 | 25.9% | +|scripts/versionbump.py| 96 of 123 | 78.0% | +|setup.py| 11 of 47 | 23.4% | +|tests/test_coder.py| 48 of 612 | 7.8% | +|tests/test_commands.py| 135 of 588 | 23.0% | +|tests/test_editblock.py| 23 of 403 | 5.7% | +|tests/test_io.py| 30 of 65 | 46.2% | +|tests/test_main.py| 13 of 239 | 5.4% | +|tests/test_models.py| 6 of 28 | 21.4% | +|tests/test_repo.py| 2 of 296 | 0.7% | +|tests/test_repomap.py| 70 of 217 | 32.3% | +|tests/test_udiff.py| 7 of 119 | 5.9% | +|tests/test_wholefile.py| 37 of 321 | 11.5% | +| **Total** | **1022 of 14219** | 7.2% | diff --git a/scripts/blame.py b/scripts/blame.py index 4f83c63e4..c49cfced4 100755 --- a/scripts/blame.py +++ b/scripts/blame.py @@ -119,11 +119,11 @@ def process_fnames(fnames, git_dname): percent_modified = (num_aider_lines / num_lines) * 100 if num_lines > 0 else 0 if not num_aider_lines: continue - print(f"|{fname}| {num_aider_lines} of {num_lines} | {percent_modified:.2f}% |") + print(f"|{fname}| {num_aider_lines} of {num_lines} | {percent_modified:.1f}% |") total_percent_modified = (total_aider_lines / total_lines) * 100 if total_lines > 0 else 0 print( - f"Total: {total_aider_lines}/{total_lines} lines by aider ({total_percent_modified:.2f}%)" + f"| **Total** | **{total_aider_lines} of {total_lines}** | {total_percent_modified:.1f}% |" ) return total_aider_lines, total_lines, total_percent_modified