Skip to main content
QUICK REVIEW

[論文レビュー] Empirical Characterization of Logging Smells in Machine Learning Code

Patrick Loic Foalem, Léuson Da Silva|arXiv (Cornell University)|Mar 24, 2026
Scientific Computing and Data Management被引用数 0
ひとこと要約

この論文は、444のオープンソースMLリポジトリから12のML特有のロギングの悪臭を実証的に特定し、実務家調査で検証し、2,448の悪臭事例のラベル付きデータセットを公開しています。

ABSTRACT

Logging plays a central role in ensuring reproducibility, observability, and reliability in machine learning (ML) systems. While logging is generally considered a good engineering practice, poorly designed logging can negatively affect experiment tracking, security, debugging, and system performance. In this paper, we present an empirical study of logging smells in ML projects and propose a taxonomy of ML-specific logging smell types. We conducted a large-scale analysis of 444 ML repositories and manually labeled 2,448 instances of logging smells. Based on this analysis, we identified 12 categories of logging smells spanning security, metric management, configuration, verbosity, and context-related issues. Our results show that logging smells are widespread in ML systems and vary in frequency and manifestation across projects. To assess practical relevance, we conducted a survey with 27 ML practitioners. Most respondents agreed with the identified smells and reported that several types, including Logging Sensitive Data, Metric Overwrite, Missing Hyperparameter Logging, and Log Without Context, have a strong impact on reproducibility, maintainability, and trustworthiness. Other smells, such as Heavy Data Logging and Print-based Logging, were perceived as more context-dependent. We publicly release our labeled dataset to support future research. Our findings highlight logging quality as a critical and underexplored aspect of ML system engineering and open opportunities for automated detection and repair of logging issues.

研究の動機と目的

  • 研究を動機づけるために、ML観測性にとってロギングが重要である一方、MLコードベースではしばしば設計が不十分であることを示す。
  • 大規模なラベリングを通じてML特有のロギングの悪臭のデータ駆動型分類を構築する。
  • 分類をML実務家で検証し、関連性と重大度を評価する。
  • 将来の研究を支援するラベル付きデータセットを含む再現パッケージを提供する。

提案手法

  • Foalem ら(2024)のMLロギング実践の既存データセットを用いて、444のアクティブなMLリポジトリにわたるPythonファイルのロギング文を特定する。
  • 純粋な設定文を除外するために、ロギング関連コードをクラスタリングおよびフィルタリングし、4,528個の関数にわたる15,911のロギング文を得る。
  • 人間-in-the-loopの反復的分類構築を、LLM支援のコーディング(GPT-5-mini)と手動検証で行い、12の悪臭を導出する。
  • 2,448の関数レベルのサンプルを種生成、反復的改良、飽和、信頼性評価(κ = 0.817)を経て分割する。
  • 使用状況の文脈、スニペット、メタデータを文書化した構造化JSONデータセットを作成し、再現のために公開する。

実験結果

リサーチクエスチョン

  • RQ1RQ1: オープンソースのMLベースシステムにはどのようなロギングの悪臭が存在するか?
  • RQ2RQ2: ML実務家は実務でこれらのロギングの悪臭をどう認識し、経験しているか?

主な発見

  • 12のML特有のロギングの悪臭が特定され、セキュリティ、指標管理、設定、冗長性、文脈関連の問題を横断している。
  • 悪臭は広く分布しており、プロジェクトごとに頻度と現れ方が異なる。
  • 実務家の回答は分類に強く同意し、セキュリティ、再現性、実験の正確さに影響を与える悪臭の関連性と重大度をより高く認識している。
  • いくつかの悪臭(例:Heavy Data Logging、Print-based Logging)は文脈依存で、パフォーマンスと観測性のトレードオフを反映している。
  • 2,448のロギング悪臭事例の公開データセットは自動検出とAI支援修復研究を支援する。

より良い研究を、今すぐ始めましょう

論文の読解から最終レビューまで、研究時間を劇的に削減しましょう。

クレジットカード登録不要

このレビューはAIが作成し、人間の編集者が確認しました。