chore: remove dead code, debug logging, and fix typos#17
Open
lakshith-403 wants to merge 1 commit into
Open
Conversation
Mechanical, no-behavior-change cleanup surfaced by a code-quality review. Python (python/inspectus/__init__.py): - Remove unused compress_series() (never called, not in __all__) - Remove unused loop counter `i` in distribution() - Simplify histogram build to dist.tolist(), dropping the shadowed comprehension variable and the magic count 9 - Fix distribution() docstring: alpha default is 0.5, not 0.6 TypeScript (ui/src): - Remove dead chartsEmbedTest() scaffolding (charts.ts) - Remove unused `attentions` field and now-unused createMatrix import (attention_matrix_view.ts) - Remove leftover console.log in LineCellView click handler (line_grid.ts) - Fix typo selectHanlder -> selectHandler (line_grid.ts) - Rename doubled-word method calcGridAttentionAttention -> calcGridAttention (controller.ts) - Remove large commented-out `menu` dead-code block (token_loss.ts) No functional changes. Python compiles; changed TS files parse cleanly. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mechanical, no-behavior-change cleanup surfaced by a code-quality review of the repository. Pure dead-code removal, a stray debug log, and typo/naming fixes — no functional logic touched.
Python —
python/inspectus/__init__.pycompress_series()(never called anywhere, not in__all__)iindistribution()histogram = [dist[i] for i in range(0, 9)]→dist.tolist(), dropping the shadowed comprehension variable and the hard-coded count9distribution()docstring:alphadefault is0.5, not0.6(matches the signature)TypeScript —
ui/src/chartsEmbedTest()scaffolding (unreferenced, hard-coded empty sample)attentionsfield and the now-unusedcreateMatriximportconsole.log('click', ...)in the click handler; fix typoselectHanlder→selectHandlercalcGridAttentionAttention→calcGridAttention(all 3 call sites)menudead-code block referencing a removed fieldVerification
python -m py_compilepasses on the changed modules.tsfiles parse cleanly via esbuildgrepconfirms no residual references to any removed/renamed symbolDiff: 6 files, +8 / −76.
🤖 Generated with Claude Code