スキル一覧に戻る
marcoloco23

code-review

by marcoloco23

Unit-aware tensors for physics and scientific machine learning

2🍴 0📅 2026年1月13日
GitHubで見るManusで実行

SKILL.md


name: code-review description: Review dimtensor code for correctness, dimensional safety, and adherence to patterns. Use when reviewing new code or during consolidation phases. allowed-tools: Read, Grep, Glob

Code Review Skill

Review checklist for dimtensor code.

Review Checklist

Dimensional Correctness (CRITICAL)

  • Addition/subtraction requires same dimension
  • Multiplication/division correctly combines dimensions
  • Power operations handle dimension exponents correctly
  • Transcendental functions (sin, exp, log) require dimensionless input
  • sqrt halves dimension exponents

Edge Cases

  • Empty arrays handled
  • Scalar values handled
  • Zero values (division by zero)
  • None/null inputs
  • inf/nan values
  • Very large/small scale factors

Error Handling

  • Raises DimensionError for incompatible operations
  • Raises UnitConversionError for impossible conversions
  • Error messages are helpful (show dimensions involved)

Code Patterns

  • Uses DimArray._from_data_and_unit(data, unit) internally
  • Operations return new instances (immutable)
  • Follows patterns from core/dimarray.py
  • Type hints on public functions
  • Docstrings on public functions

Scale Factors

  • Uses authoritative values (CODATA, IAU, IUPAC)
  • Scientific notation for large/small values
  • Source documented in comments

Test Coverage

  • Happy path tests exist
  • Edge case tests exist
  • Error case tests exist
  • Conversion accuracy tests with tolerances

Review Output Format

### File: `path/to/file.py`
**Reviewed by**: agent
**Status**: APPROVED / ISSUES FOUND / NEEDS CHANGES

**Issues Found**:
1. [CRITICAL] Description...
2. [IMPORTANT] Description...
3. [MINOR] Description...

**Recommendations**:
- Suggestion 1
- Suggestion 2

After Review

Update CONTINUITY.md:

  • Add review findings to CODE REVIEW FINDINGS section
  • Mark review task as DONE in TASK QUEUE
  • Add session log entry

スコア

総合スコア

65/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

+10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

1ヶ月以内に更新

+10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

+5

レビュー

💬

レビュー機能は近日公開予定です