Skip to content

Conversation

@tak-ka3
Copy link
Collaborator

@tak-ka3 tak-ka3 commented Aug 14, 2025

Description of changes・変更内容の説明

今後ドキュメントを読んだユーザーが自分で実行できるように、exampleコードを公開する。つまりリポジトリは今後公開予定。
それに必要な、チュートリアル、functionsをこのリポジトリに配置する。

本PRに含まれる具体的な実装は以下。

  • 基本チュートリアルの追加
  • functionsの追加(cross_table/join/easyocr)(apc-cliのリポジトリから取得)
  • ruff/ai-review/ressign-reviewer CIの追加

Ticket link・チケットリンク

https://www.notion.so/acompany-ac/CC-828

Testing method・実施したテスト方法 (CI/Manual)

  • 基本チュートリアルは正常に実行できたことを確認ずみ

Remarks・備考

  • APOS, MAAはapc-private-cliの実行時に標準出力される名前なので、、そちらの実装から削除後にこちらのチュートリアルにも反映させるが、このPRでは一旦無視する。
  • JupyterNotebook上ではSVGが表示されないが、Sphinx上では表示されることを確認

Review guidelines

Generic PR Review guidelines・一般的な PR レビューのガイドライン

@github-actions
Copy link

github-actions bot commented Aug 14, 2025

Ruff チェック結果

フォーマット

✅ フォーマットの問題はありませんでした。

3 files already formatted

Lint

✅ Lint の問題はありませんでした。

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed files

  • notebooks/tutorial/basic_apc_cli_tutorial.ipynb
  • functions/cross_table/function/handler.py
  • functions/cross_table/inputs/input_1/input_a.csv
  • functions/cross_table/inputs/input_2/input_b.csv
  • functions/cross_table/requirements.txt
  • functions/easyocr/README.md
  • functions/easyocr/function/handler.py
  • functions/easyocr/inputs/input_1/model/.gitkeep
  • functions/easyocr/inputs/input_2/input_b.jpg
  • functions/easyocr/requirements.txt
  • functions/join/function/handler.py
  • functions/join/inputs/input_1/input_a.csv
  • functions/join/inputs/input_2/input_b.csv
  • functions/join/requirements.txt

functions/cross_table/function/handler.py のレビュー

JP: コードは全体的に読みやすく整理されており、基本的なチュートリアルとして適切です。ただし、例外処理について改善の余地があります。特に、print_log関数内の例外を無視する部分と、run関数内でBaseExceptionをキャッチしている部分は、予期せぬエラーを隠してしまう可能性があるため、より適切な例外ハンドリングを検討してください。

EN: The code is clear and well-structured as a basic tutorial implementation. However, there are some areas in the exception handling that could be improved. In particular, suppressing exceptions in print_log and catching BaseException in run may inadvertently hide errors. Please consider refining the exception handling for better robustness.

functions/cross_table/inputs/input_1/input_a.csv のレビュー

JP: 全体的にシンプルなCSV入力ファイル追加ですが、POSIX準拠のためファイル末尾に改行を追加することをお勧めします。 EN: The CSV input file addition is straightforward; however, consider adding a newline at the end of the file to adhere to POSIX standards and improve tool compatibility.

functions/cross_table/inputs/input_2/input_b.csv のレビュー

【JP】: 全体としてCSVファイルがチュートリアル用として明確に構成されており、内容もシンプルで分かりやすいです。ただし、末尾に改行がないため、ツールとの互換性を考慮して改行を追加することをお勧めします。
【EN】: Overall, the CSV file is clearly structured for the tutorial with simple and readable content. However, please add a newline at the end for better compatibility with various tools.

functions/cross_table/requirements.txt のレビュー

JP: 追加されたrequirements.txtは必要な依存関係が明示されており、基本的な部分は良いですが、末尾の改行欠如と不要な空白があるため、それらを修正することを推奨します。 EN: The added requirements.txt clearly lists the necessary dependencies. However, it is recommended to remove trailing whitespace and add a newline at the end of the file for consistency and best practices.

functions/easyocr/README.md のレビュー

JP: ドキュメントは実行手順が明確に記載されており、全体として読みやすいです。ただし、ダウンロードするアーカイブの整合性検証や、使用する環境に関する追加の説明(例えばDCRやGraniteサーバーの詳細)を記載すると、より安全でユーザーフレンドリーになります。
EN: The documentation is clear and easy to follow. However, consider adding checksum verification instructions for the downloaded archives and more details about the environment (e.g., what DCR and Granite server entail) to enhance security and user guidance.

functions/easyocr/function/handler.py のレビュー

JP: コードの基本機能は問題ありませんが、例外のキャッチ範囲が広すぎるため、BaseExceptionではなくExceptionをキャッチするようにすることを推奨します。全体としては良好な実装ですが、将来の予期しない動作を防ぐため、例外処理を見直してください。
EN: The core functionality works well, but catching BaseException is too broad. It's recommended to catch Exception instead to avoid swallowing system-exiting exceptions. Overall, the implementation is solid, but please review your exception handling to prevent unintended behaviors.

functions/easyocr/inputs/input_1/model/.gitkeep のレビュー

JP: 基本チュートリアルと関連ファイルの追加はプロジェクトの公開準備に有益です。.gitkeepファイルはディレクトリ構造維持目的で適切に利用されています。全体的に整理され、明確な変更内容です。
EN: The addition of the basic tutorial and associated functions is beneficial for preparing the repository for public release. The .gitkeep file is appropriately used for maintaining directory structure. Overall, the changes are organized and clear.

functions/easyocr/inputs/input_2/input_b.jpg のレビュー

JP: このPRでは、基本チュートリアル用の関数群と関連の画像ファイルが追加されています。差分において、新たに追加されたバイナリファイル(JPEG画像)については、コードのロジックや可読性に関する問題は見受けられません。今後、画像の取り扱いやメタデータ管理などについて必要に応じた確認をお願いします。
EN: This PR introduces tutorial functions and related files, including a new binary JPEG image. Based on the diff, no concerns regarding logic, naming, or readability have been observed in the added binary file. Please ensure that any future handling of images, metadata, or related documentation is carefully reviewed if necessary.

functions/easyocr/requirements.txt のレビュー

JP: 新しく追加された requirements.txt は、依存関係が明確に指定されており良いと思います。ただし、extra-index-url の指定については信頼性や目的を明記すると親切です。また、torch と torchvision のバージョン整合性を確認してください。
EN: The newly added requirements.txt clearly pins dependencies which is good. However, please ensure that the use of the extra-index-url is trusted and documented for clarity, and check that the versions of torch and torchvision are compatible with each other.

functions/join/function/handler.py のレビュー

JP: 全体的に基本的な実装としては問題ありませんが、例外処理でBaseExceptionを捕捉している点やハードコードされたパスの点について改善余地があります。関数のドキュメントやログ実装についても、将来的なメンテナビリティ向上のため検討するとよいでしょう。
EN: Overall, the implementation is acceptable for a basic tutorial. However, there is room for improvement in catching BaseException rather than Exception, and in avoiding hardcoded paths. Consider adding docstrings and reviewing the logging implementation for better maintainability.

functions/join/inputs/input_1/input_a.csv のレビュー

JP: 新しいCSVファイルが追加されました。ファイル末尾に改行が存在しないため、環境による予期せぬ動作を避けるためにも、末尾に改行を追加することを検討してください。
EN: A new CSV file has been added. Consider adding a newline at the end to prevent potential issues caused by missing newline at the end of the file.

functions/join/inputs/input_2/input_b.csv のレビュー

JP: この新規追加されたCSVファイル全体は基本チュートリアルのサンプルとしては十分ですが、末尾の空白や改行が不足している点を修正するとより良くなります。 EN: The newly added CSV file works well as a tutorial sample, but please remove the trailing whitespace on the last record and add a final newline to adhere to best practices.

functions/join/requirements.txt のレビュー

JP: 新規追加された requirements.txt は、関数に必要な依存関係を明示的にピン留めしており、明確で良い実装です。依存関係のバージョンがプロジェクト全体で一貫していることを確認するとさらに安心です。
EN: The newly added requirements.txt clearly lists the required dependencies with pinned versions, which is a good and clear implementation. Ensure that these dependency versions are consistent with the rest of the project for added confidence.

notebooks/tutorial/basic_apc_cli_tutorial.ipynb のレビュー

The tutorial notebook provides detailed step-by-step instructions and is overall clear. However, to improve robustness it is recommended to include error handling in the bash cells and ensure that variable assignments are explicit. Minor improvements in the expect scripts and .env generation may help avoid potential issues during execution.

@tak-ka3 tak-ka3 requested a review from a team August 14, 2025 05:33
@come2ry
Copy link
Collaborator

come2ry commented Aug 14, 2025

@claude

@tak-ka3 tak-ka3 requested a review from a team August 15, 2025 05:36
@tak-ka3 tak-ka3 requested a review from sakamoto-souta August 21, 2025 08:49
@tak-ka3 tak-ka3 requested a review from a team August 21, 2025 12:59
@tak-ka3 tak-ka3 merged commit ec27c92 into main Aug 21, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants