1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

【UiPath】ヒーリングエージェント(自己修復機能)のログの見方

Last updated at Posted at 2025-03-24

はじめに

  • 本記事は、ヒーリングエージェント(自己修復機能)のログの見方を扱います。
  • 記事の内容は、個人の見解または確認結果であり、UiPath の公式見解ではありません。
  • 製品仕様や参考画像は 25.0.161 バージョンのもので構成しています。

2025年3月17日時点の公開情報

■UiPathフォーラムの記事

■Automation Cloud の Orchestrator のリリースノート

■Healing Agent の公式ガイド

機能概要(Google翻訳)

このたび、ヒーリングエージェントのパブリックプレビューを発表できることを嬉しく思います。この機能には、UiPath Robots、Orchestrator、Studio全体でAIを活用した一連のエクスペリエンスが含まれており、自動化のダウンタイムを削減し、効率を向上させます。これにより、次のものが提供されます。

  • UIベースの自動化のためのインテリジェントな自己修復: アプリケーションインターフェースに変更があったり、UIの干渉によって自動化が妨げられたりするたびに、Healing Agentは問題を修復して、自動化を中断することなく続行できるようにします
  • 実用的な推奨事項: Healing Agent(以降、HAと略す) は、アプリケーション インターフェイスをインテリジェントに分析し、トラブルシューティングやデバッグに費やす時間を最小限に抑えるための的を絞った提案を提供します。これにより、問題の迅速な解決が可能になり、自動化をできるだけ早く本番環境に戻すことができます。

要は

  1. UI変更やUI干渉(たまに出るポップアップなど)について、よしなに回避しますよ
  2. 回避したUI変更やUI干渉への処方箋を出しますよ
    といった機能みたいです。

何故ログの見方を書くのか?

筆者はプレビュー版が出て間もない頃に動作確認した際、次の前提条件でヒーリングエージェントの処理は発火しました。
発火した際は処理実行後にジョブの詳細で「Healing Agent(プレビュー)」タブを確認できます。

ポップアップ回避成功1.JPG

ところが、今月に入って久しぶりに動作確認した際に一度も発火せず、ログから原因を追う必要があったためです。

2025年1月の実行結果から、次の条件でもHealing Agentの処理が起動することはわかっています。

  • UIAパッケージ:25.2.0 preview
  • ST/RT:24.10 以上

3月17日 時点最新は以下

  • UIAパッケージ:25.2.1 preview
  • ST:25.0.157
  • RT:24.10 以上

HA発火条件.JPG

細かいことを書くと、サポートOS(ランタイムプロジェクト)が「Windows」「クロスプラットフォーム」に限られる、また一部動作確認のため「実行を検証」機能を有効化する必要がある等ありますが、Healing Agent(以降、HAと略す)の処理発火条件は、上述のパッケージとST/RT要件を除けばOCと接続があり、ジョブの実行時にHAおよび自己修復の有効化のチェックをONにしていれば満たします!

HA有効化.JPG

ログの見方

HAの処理発火の見分け方

まず、Execution.log にジョブ開始後に次の様なレコードが出現しますが、この行の有無ではHAの処理発火は判断できない点にご注意ください。

{"message":"Healing agent configuration.","level":"Information","logType":"Default","timeStamp":~

自己修復を試みた際は次の成功 or 失敗、修復動作のログが残ります。

■修復失敗
{"message":"Healing agent could not recover the activity.","level":"Information","logType":"Default","timeStamp":~
■修復成功
{"message":"Healing agent successfully recovered the activity.","level":"Information","logType":"Default","timeStamp":~

■修復中のログの例
{"message":"Healing Agent: 回復分析を開始しています。","level":"Information","logType":"Default","timeStamp":~

💡自己修復対象のうむを判断するためのHAの前処理が起動したかどうかはExecution.logではわかりません。

HAの処理結果の詳細を確認するためには UIAutomation.log を確認するのが有効です。
なお、HAの処理はログレベル:Debugで出力されるので、次の環境変数を登録し一度PCを再起動する必要があります。

環境変数UIAログ.JPG

変数名:UIPATH_LOG_LEVEL_UIA
値:Verbose

処理が正常に発火した際は、次の様なリクエスト結果を確認できます。

[2025-03-17T11:30:52.694][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/start

失敗した際の例

[2025-03-11T15:49:23.470][Error] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[BadRequest] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/start

紛らわしいですが、成功・失敗問わず出現するリクエスト結果のログが以下

[2025-03-17T11:31:54.661][Error] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[NotFound] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/configuration/HealingAgentConfig

HAの処理結果を確認できなかった私の環境では、
status=[NotFound] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/configuration/HealingAgentConfig
の直後に
[Tag=Image.GetScreenshot]
が続き、その後に
status=[BadRequest] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/start
が出力されて終わっていました。

サポートからの一次回答は「あなたのアカウントに付与されているHAライセンスに問題があり、修正対応中」でした。

回復処理のログ(予期しないポップアップの例)

分析処理の開始時には次のリクエストが飛んでいます。

[2025-03-17T11:30:53.616][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/check

回復戦略を探しているところ↓↓(セマンティック検索をしています)

[2025-03-17T11:32:38.744][Debug] - [Tag=TextMatchingService] Matching using Semantic
[2025-03-17T11:32:38.744][Debug] - [Tag=SemanticService] QueryQaDOM ::: Prepare payload for Decline
[2025-03-17T11:32:38.744][Verbose] - [Tag=SemanticService] Semantic Payload: '{"dom_xml":"<body><ul><button id=\"0\">OK</button></ul></body>","human_description":"Decline","add_label_matching_examples":true}'
[2025-03-17T11:32:38.744][Debug] - [Tag=SemanticService] GetMatchingLabelAsync ::: send request
[2025-03-17T11:32:38.744][Debug] - [Tag=HttpClientWrapper] SendAsync ::: START request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:39.820][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:39.821][Error] - [Tag=SemanticService] GetMatchingLabelAsync ::: QA DOM service returned an unmapped index=-1. Candidate keys=System.Collections.Generic.Dictionary`2+KeyCollection[System.Int32,System.String]
[2025-03-17T11:32:39.822][Debug] - [Tag=TextMatchingService] No match.
[2025-03-17T11:32:39.822][Verbose] - [Tag=TextMatchingService] 
		Match type: Semantic
		Haystack: 'OK'
		Needle: 'No'
[2025-03-17T11:32:39.822][Debug] - [Tag=TextMatchingService] Matching using Semantic
[2025-03-17T11:32:39.822][Debug] - [Tag=SemanticService] QueryQaDOM ::: Prepare payload for No
[2025-03-17T11:32:39.822][Verbose] - [Tag=SemanticService] Semantic Payload: '{"dom_xml":"<body><ul><button id=\"0\">OK</button></ul></body>","human_description":"No","add_label_matching_examples":true}'
[2025-03-17T11:32:39.822][Debug] - [Tag=SemanticService] GetMatchingLabelAsync ::: send request
[2025-03-17T11:32:39.823][Debug] - [Tag=HttpClientWrapper] SendAsync ::: START request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:41.131][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:41.131][Error] - [Tag=SemanticService] GetMatchingLabelAsync ::: QA DOM service returned an unmapped index=-1. Candidate keys=System.Collections.Generic.Dictionary`2+KeyCollection[System.Int32,System.String]
[2025-03-17T11:32:41.131][Debug] - [Tag=TextMatchingService] No match.
[2025-03-17T11:32:41.131][Verbose] - [Tag=TextMatchingService] 
		Match type: Semantic
		Haystack: 'OK'
		Needle: 'Yes'

分析が完了し、回復戦略を詰めてるところ↓↓

[2025-03-17T11:32:41.131][Debug] - [Tag=TextMatchingService] Matching using Semantic
[2025-03-17T11:32:41.132][Debug] - [Tag=SemanticService] QueryQaDOM ::: Prepare payload for Yes
[2025-03-17T11:32:41.132][Verbose] - [Tag=SemanticService] Semantic Payload: '{"dom_xml":"<body><ul><button id=\"0\">OK</button></ul></body>","human_description":"Yes","add_label_matching_examples":true}'
[2025-03-17T11:32:41.132][Debug] - [Tag=SemanticService] GetMatchingLabelAsync ::: send request
[2025-03-17T11:32:41.132][Debug] - [Tag=HttpClientWrapper] SendAsync ::: START request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:42.605][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/autopilot/qa-dom
[2025-03-17T11:32:42.614][Debug] - [Tag=TextMatchingService] Matched
[2025-03-17T11:32:42.617][Debug] - [Tag=RuntimePopupHandlerService] Strategy Semantic result for needle 'Yes': score 1, text 'OK'
[2025-03-17T11:32:42.662][Debug] - [Tag=DriverApplicationService] FindApplicationAsync ::: start with Selector=<wnd app='chrome.exe' cls='Chrome_WidgetWin_1' title='タイムアウト・ポップアップエラー再現 - Google Chrome' />, IsBrowser=False, Url=, VariantTypes=ExactSelector
[2025-03-17T11:32:42.662][Debug] - [Tag=DriverApplicationService] FindApplicationAsync ::: try find by selector=<wnd app='chrome.exe' cls='Chrome_WidgetWin_1' title='タイムアウト・ポップアップエラー再現 - Google Chrome' />
[2025-03-17T11:32:42.695][Debug] - [Tag=DriverApplicationService] FindApplicationAsync ::: OK successfully attached

回復処理が完了すると、HAライセンス?を消費しにいくリクエストを確認できます。
(Execution.log の「Healing Agent: アクティビティが正常に回復されました。」の直前ら辺)

[2025-03-17T11:32:47.528][Debug] - [Tag=HttpClientWrapper] SendAsync ::: semantic server url = https://cloud.uipath.com:443/***/semanticproxy_/api/
[2025-03-17T11:32:47.528][Debug] - [Tag=HttpClientWrapper] SendAsync ::: START request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/consume
[2025-03-17T11:32:48.195][Debug] - [Tag=HttpClientWrapper] SendAsync ::: END with status=[OK] for request uri = https://cloud.uipath.com/***/semanticproxy_/api/operation/consume

回復に失敗したジョブでは上記の「/semanticproxy_/api/operation/consume」は呼ばれていないので、回復処理が成功した際のみHAライセンスを消費する見込みです。※HAライセンスの消費に関する公開情報がまだ出ていないため、あくまで推測です。

回復処理完了後は、スクリーンショット(画像(.png))や回復処理のサマリー(.json)などをクラウドOCのストレージにアップロードする様です。

さいごに

いかがでしたでしょうか。
HAおよび自己修復を有効化したが、一向に処理が発火せず困った経験から書かせていただきました。
新しい機能なので、同様に?がついた方は是非ご一読ください。
最後までお読みいただきありがとうございます(・ω・)ノ

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?