gerrit_comment: Add "autogenerated" tag to comment

Add an "autogenerated" tag to the Gerrit comment posted by this module.
This will make it easier to filter out these comments in other tooling.

Bug: b/339023785
Change-Id: Ic686f7a3caf07d3d26a04cb0227157eb248b2660
Reviewed-on: https://pigweed-review.googlesource.com/c/infra/recipes/+/208227
Reviewed-by: Ted Pudlik <tpudlik@google.com>
Commit-Queue: Auto-Submit <auto-submit@pigweed-service-accounts.iam.gserviceaccount.com>
Pigweed-Auto-Submit: Rob Mohr <mohrr@google.com>
Lint: Lint 🤖 <android-build-ayeaye@system.gserviceaccount.com>
Presubmit-Verified: CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com>
diff --git a/recipe_modules/gerrit_comment/api.py b/recipe_modules/gerrit_comment/api.py
index 5dc3d60..f1e4c5a 100644
--- a/recipe_modules/gerrit_comment/api.py
+++ b/recipe_modules/gerrit_comment/api.py
@@ -86,4 +86,5 @@
                     self.m.buildbucket.build.id,
                 ),
                 notify="OWNER",
+                tag="autogenerated:pigweed:gerrit_comment",
             )
diff --git a/recipe_modules/gerrit_comment/tests/full.expected/try-build.json b/recipe_modules/gerrit_comment/tests/full.expected/try-build.json
index dd3e482..f311767 100644
--- a/recipe_modules/gerrit_comment/tests/full.expected/try-build.json
+++ b/recipe_modules/gerrit_comment/tests/full.expected/try-build.json
@@ -144,7 +144,7 @@
       "-host",
       "https://pigweed-review.googlesource.com",
       "-input",
-      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\"}, \"revision_id\": \"current\"}",
+      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\", \"tag\": \"autogenerated:pigweed:gerrit_comment\"}, \"revision_id\": \"current\"}",
       "-output",
       "/path/to/tmp/json"
     ],
@@ -172,7 +172,8 @@
       "@@@STEP_LOG_LINE@json.input@  \"change_id\": \"123456\",@@@",
       "@@@STEP_LOG_LINE@json.input@  \"input\": {@@@",
       "@@@STEP_LOG_LINE@json.input@    \"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\",@@@",
-      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\"@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\",@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"tag\": \"autogenerated:pigweed:gerrit_comment\"@@@",
       "@@@STEP_LOG_LINE@json.input@  },@@@",
       "@@@STEP_LOG_LINE@json.input@  \"revision_id\": \"current\"@@@",
       "@@@STEP_LOG_LINE@json.input@}@@@",
@@ -194,7 +195,7 @@
       "-host",
       "https://pigweed-review.googlesource.com",
       "-input",
-      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status Bad stuff: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\"}, \"revision_id\": \"current\"}",
+      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status Bad stuff: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\", \"tag\": \"autogenerated:pigweed:gerrit_comment\"}, \"revision_id\": \"current\"}",
       "-output",
       "/path/to/tmp/json"
     ],
@@ -222,7 +223,8 @@
       "@@@STEP_LOG_LINE@json.input@  \"change_id\": \"123456\",@@@",
       "@@@STEP_LOG_LINE@json.input@  \"input\": {@@@",
       "@@@STEP_LOG_LINE@json.input@    \"message\": \"builder completed with status Bad stuff: http://go/bbid/8945511751514863184\",@@@",
-      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\"@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\",@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"tag\": \"autogenerated:pigweed:gerrit_comment\"@@@",
       "@@@STEP_LOG_LINE@json.input@  },@@@",
       "@@@STEP_LOG_LINE@json.input@  \"revision_id\": \"current\"@@@",
       "@@@STEP_LOG_LINE@json.input@}@@@",
diff --git a/recipe_modules/pw_presubmit/tests/full.expected/comment-always.json b/recipe_modules/pw_presubmit/tests/full.expected/comment-always.json
index f37ce35..6a14d3d 100644
--- a/recipe_modules/pw_presubmit/tests/full.expected/comment-always.json
+++ b/recipe_modules/pw_presubmit/tests/full.expected/comment-always.json
@@ -1882,7 +1882,7 @@
       "-host",
       "https://pigweed-review.googlesource.com",
       "-input",
-      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\"}, \"revision_id\": \"current\"}",
+      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\", \"tag\": \"autogenerated:pigweed:gerrit_comment\"}, \"revision_id\": \"current\"}",
       "-output",
       "/path/to/tmp/json"
     ],
@@ -1910,7 +1910,8 @@
       "@@@STEP_LOG_LINE@json.input@  \"change_id\": \"123456\",@@@",
       "@@@STEP_LOG_LINE@json.input@  \"input\": {@@@",
       "@@@STEP_LOG_LINE@json.input@    \"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\",@@@",
-      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\"@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\",@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"tag\": \"autogenerated:pigweed:gerrit_comment\"@@@",
       "@@@STEP_LOG_LINE@json.input@  },@@@",
       "@@@STEP_LOG_LINE@json.input@  \"revision_id\": \"current\"@@@",
       "@@@STEP_LOG_LINE@json.input@}@@@",
@@ -3363,7 +3364,7 @@
       "-host",
       "https://pigweed-review.googlesource.com",
       "-input",
-      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\"}, \"revision_id\": \"current\"}",
+      "{\"change_id\": \"123456\", \"input\": {\"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\", \"notify\": \"OWNER\", \"tag\": \"autogenerated:pigweed:gerrit_comment\"}, \"revision_id\": \"current\"}",
       "-output",
       "/path/to/tmp/json"
     ],
@@ -3391,7 +3392,8 @@
       "@@@STEP_LOG_LINE@json.input@  \"change_id\": \"123456\",@@@",
       "@@@STEP_LOG_LINE@json.input@  \"input\": {@@@",
       "@@@STEP_LOG_LINE@json.input@    \"message\": \"builder completed with status OK: http://go/bbid/8945511751514863184\",@@@",
-      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\"@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"notify\": \"OWNER\",@@@",
+      "@@@STEP_LOG_LINE@json.input@    \"tag\": \"autogenerated:pigweed:gerrit_comment\"@@@",
       "@@@STEP_LOG_LINE@json.input@  },@@@",
       "@@@STEP_LOG_LINE@json.input@  \"revision_id\": \"current\"@@@",
       "@@@STEP_LOG_LINE@json.input@}@@@",