Skip to content

AIP-90: HITLOperator within standard provider #52053

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 48 commits into
base: main
Choose a base branch
from

Conversation

Lee-W
Copy link
Member

@Lee-W Lee-W commented Jun 23, 2025

Why

AIP-90

What

  • db change (model, manager, migration)
    1. HITLInputRequestModel: Store the information of body, options, etc.
    2. HITLResponseModel: Human response to an input request
  • public API endpoint
    1. GET /hitl/{task_instance_id}/input-requests: get an input request created by the TI (should we change it to something like /hitl/task-instance/{task_instance_id}/input-requests)
    2. POST /hitl/{task_instance_id}/response: write a response to the input request created by the TI
    3. GET /hitl/input-requests: get all input requests
  • execution API endpoint
    1. POST /hitl/{task_instance_id}/input-requests: HITLOperator create a HITLInputRequestModel before deferring
    2. GET /hitl/{task_instance_id}/response: after deferring, HITLTrigger keeps checking whether the response is ready
  • operators
    1. HITLOperator
    2. ApprovalOperator
    3. HITLTerminationOperator defer to follow up PRs
    4. HITLBranchOperator defer to follow up PRs
    5. HITLEntryOperator (not implemented) defer to follow up PRs
  • trigger
    1. HITLTrigger -> query whether there's a HITLResponse for a certain HITLInputRequest in database

TODO

  • use plugin to load api endpoints
  • fix existing tests
  • add tests

^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@Lee-W Lee-W changed the title AIP-90: InteractiveOperator within standard provider AIP-90: HITLOperator within standard provider Jun 23, 2025
@Lee-W Lee-W moved this to In progress in AIP-90 - Human in the loop Jun 23, 2025
@Lee-W Lee-W force-pushed the aip-90-within-standard-provider branch 11 times, most recently from 39043d9 to 3b35e89 Compare June 25, 2025 15:52
@Lee-W Lee-W force-pushed the aip-90-within-standard-provider branch 8 times, most recently from e30a6ac to c513ced Compare June 26, 2025 12:16
@Lee-W Lee-W force-pushed the aip-90-within-standard-provider branch from c513ced to 43506bf Compare June 27, 2025 08:16
@Lee-W Lee-W force-pushed the aip-90-within-standard-provider branch from cd338eb to 4563a53 Compare July 1, 2025 01:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In progress
Development

Successfully merging this pull request may close these issues.

2 participants