repowiserepowise
Sign in
shinkuan/akagi
OverviewDocsArchitectureKnowledge GraphFilesCode HealthSecurityRefactoring

People & History

CommitsContributorsDecisions
Chat
Stats
repowiserepowise
ExplorePricingDocs
Sign in
repowiseshinkuan/akagi
AK
AK

shinkuan / akagi

rusttypescriptv397478d076.2K linessynced 1mo ago

Code health

5.9out of 10Fair

This codebase scores 5.9 out of 10 for code health, which we rate fair. It also scores maintainability 7.7 and static performance 9.7 out of 10. The three are scored separately and never blended into one number. Risk is concentrated, as it usually is: 47 of 352 files are git hotspots, and they average 3.7 — which is where the fixes pay off most.

Full health report →
Documentation507pages0 with model-written prose, 507 built from the indexScore validation20/203.0× baselineTop-ranked files that did go on to need a bug fixDead code35exportsUnused exports that nothing in the graph reaches

Do next

4 things worth doing this quarter.

Worth planning

  • Break up load_config (CCN 13, 60 lines)

    src/config/mod.rs:167

    load_config nests its control flow deeply; 36 files import it, changed 11 times in 90 days.

    gain
    up to +2.2 health on this file(inferred)
    finding
    Nested complexity
    size
    CCN 13, 60 lines, nests 8 deep
    severity
    critical
    Medium effort, worth a check
  • Flatten the nesting in plan

    src/autoplay/majsoul/mod.rs:48

    plan nests its control flow deeply, and part of it is duplicated, so splitting it also removes a copy; 7 files import it, changed 20 times in 90 days.

    gain
    up to +1.1 health on this file(inferred)
    finding
    Nested complexity
    size
    CCN 27, 129 lines, nests 5 deep
    severity
    high
    Medium effort, worth a check
  • Delete 35 unused symbols and files (705 lines)

    Nothing in the graph reaches them, across 18 files; every reader and agent pays to skip them.

    symbols
    35
    lines
    705
    safe to delete
    Yes(inferred)
    Medium effort
  • Break up aggregate (CCN 50, 264 lines)

    src/history/aggregator.rs:102

    aggregate nests its control flow deeply; 5 files import it, changed 4 times in 90 days.

    gain
    up to +1.5 health on this file(inferred)
    finding
    Nested complexity
    size
    CCN 50, 264 lines, nests 6 deep
    severity
    high
    Medium effort, worth a check

Improve what Repowise can see

  • Add a test coverage report

    Without one, Repowise cannot tell tested code from untested code, so every test-related action says “unknown”.

    line coverage
    Unknown, no report
    Small effort
Lines of code
76.2K
Files
352
Symbols
4,996
Modules
8
Languages
6

Recent activity

All commits →

Commits

  • 588c0dfcstyle: apply rustfmt to #257 changes1mo ago
  • 77cd181drefactor(autoplay): remove dead synthetic-reach Path B; decline tile-less reach1mo ago
  • 13af54fffix(bot): resolve plain-mjai riichi discard via autoplay reach follow-up1mo ago
  • 535a4dbadocs: chankan window, discard guard, and blind-riichi refusal1mo ago
  • 4a3afc5ffix(capture): subscribe the pause listener before arming the interceptor1mo ago
  • ca67bca3fix(tenhou): resolve the thrown tile before acting, and to the exact copy1mo ago

Decisions

  • fix(capture): unmute CDP Chromium by defaultproposed · 1mo ago
  • fix(tenhou): use 4-cycle seat math for sanma gamesproposed · 1mo ago
  • Read active bot from live config at each game startproposed · 1mo ago
  • Track autoplay CDP page handle by browser tab, not WebSocketproposed · 1mo ago
  • Emit start_kyoku.scores in absolute-seat order for Tenhouproposed · 1mo ago
  • Answer forced moves locally to avoid unnecessary API callsproposed · 1mo ago
▸

Everything we found

1,447 open

Every detector's open count by area, each with its worst example. An inventory, not a to-do list: the actions above are the part worth doing.

  • worst item is critical severity. Code health924Untested hotspot · src/lib.rs12 findings · 9.6 deducted→
  • worst item is medium severity. Refactoring130main+1.5 health, S effort · native_bot/src/bin/extract.rs→
  • worst item is medium severity. Decisions67src/autoplay/majsoul/mod.rs20 awaiting review · 47 hotspots ungoverned→
  • worst item is medium severity. Ownership291frontend/src/types.ts100% single-owner concentration, 22 commits in 90d→
  • worst item is low severity. Dead code35CardFooterUnreachable function (11 lines)→

Composition

Open the graph →
rust 53%typescript 43%
luau 2%python 1%shell 1%Other 0%

Explore this codebase

  • Docs507 pages across 8 modules→
  • ChatAsk this codebase a question and get an answer with its sources.→
  • Files352 files with per-file docs, health and history→
  • ArchitectureDependency graph, layers, and 7 entry points→
  • Code healthPer-file scores, 1,017 open findings, coverage and refactoring targets→
  • Knowledge graphEntities, communities, and the paths between them→
  • Change couplingFiles that keep changing together, mined from commit history→
  • CommitsChange-risk ranked history with agent provenance→
  • ContributorsBus factor, per-file maintainers, and the human/agent split→
  • StatsSize class, origin, lifetime churn, rhythm and records→
  • CostsWhat indexing this snapshot cost, by model and by run.→