guan404ming commented on code in PR #70651:
URL: https://github.com/apache/airflow/pull/70651#discussion_r3708945481


##########
providers/common/ai/src/airflow/providers/common/ai/operators/llm_branch.py:
##########
@@ -95,4 +108,54 @@ def execute(self, context: Context) -> str | Iterable[str] 
| None:
         else:
             branches = str(output)
 
+        if self.require_approval:
+            choices = sorted(self.downstream_task_ids)
+            chosen = branches if isinstance(branches, str) else 
json.dumps(branches)
+            body = (
+                f"```\nPrompt: {self.prompt}\n\nChosen branch(es): 
{chosen}\n```\n\n"
+                f"Valid branches: {', '.join(f'`{c}`' for c in choices)}"

Review Comment:
   Make sense to me, just moved the list above the fence.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to