
    Ij              	      p   U d Z ddlmZ ddlZddlZddlmZmZ ddlmZ ddl	m
Z
mZmZ ddlmZmZmZ ddlmZmZmZ dd	lmZmZmZmZmZmZmZ dd
lmZ ddl m!Z!m"Z" ddl#m$Z$ dZ%de&d<   dZ'de&d<   dZ(de&d<   dZ)de&d<   dZ*de&d<   dZ+de&d<   d.dZ,d/dZ-d0dZ.d1dZ/	 	 	 	 	 	 d2dZ0d3d Z1d4d!Z2ddddddd"d#d$	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 d5d%Z3	 	 	 	 d6d&Z4dd#d"ddd'	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 d7d(Z5ddd)	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 	 d8d*Z6d"dd+	 	 	 	 	 	 	 	 	 d9d,Z7g d-Z8y):u  anu_v3.goal_activation_controller — GOAL_DRIVEN_ACTIVATION_CONTROLLER_V0 (task-2553+7).

회장 §명시 핵심 불변식 (verbatim 박제):
  chair 가 goal_execution_contract 만 제공 → controller 가 deriver→gate→activation
  루프를 자동 구성 + 기계 결정. 회장 1~13 단계 수동 절차 불필요.

``--activate`` 는 더 이상 인간 첨부 옵션이 아님. 내부적으로 6 조건 전부 충족 시에만
activate=True 로 run_activation 호출:
  1. goal_contract.allowed_actions 에 ``clean_replacement_pr_open`` 포함
  2. pre_authorized_action_gate 가 DECISION_ALLOW 반환 (dry-run 결과 기준)
  3. goal_boundary_validator PASS (planned actions ⊆ allowed; forbidden 충돌 0;
     effective_diff ⊆ 6 파일; forbidden_write_target 미포함)
  4. binding preflight == DRY_RUN_PLAN_ONLY (provenance stamp 유효 + sha256 재해시
     일치 + decision machine 4-field ok)
  5. hold_conditions 트리거 수 == 0 (dry-run 결과로 평가)
  6. callback collector 준비 완료 (normal + fallback contract 존재,
     collector-only 권한)

6 조건 전부 PASS → run_activation(activate=True). 그 외 → activate=False (dry-run)
또는 HOLD_FOR_CHAIR packet.

방어 심층 (9-R.1): run_activation 이 자체 gate ALLOW + binding + 4 조건을 재검증.
controller 의 activate=True 통과는 필요조건이지 충분조건 아님.

9-R.4 정적 부재 (controller):
  merge / PR-merge / auto-merge / PR#102-mutation / same_branch_push /
  source_branch_push — 이 파일에 없음.
    )annotationsN)datetimetimezone)Path)AnyFinalMapping)parse_hold_conditionsparse_success_conditionvalidate_boundary)GOAL_RESULT_SCHEMAGoalContractErrorparse_goal_contract)STATUS_ACTIVATED_PR_OPENSTATUS_DRY_RUN_VERIFIEDSTATUS_HOLDadjudication_hookcollector_handoffrun_activationwrite_hold_for_chair_packet)DECISION_ALLOW)TASK_2553P1_EFFECTIVE_DIFF_6#TASK_2553P6_FORBIDDEN_WRITE_TARGETS)STATUS_DRY_RUN_PLANz!anu_v3.goal_activation_controllerz
Final[str]CONTROLLER_MODULEz1.0.0CONTROLLER_VERSION7memory/events/task-2553+7.goal-activation-decision.json_DEFAULT_DECISION_PATH%memory/events/task-2553+7.result.json_DEFAULT_RESULT_PATHclean_replacement_pr_open_GOAL_ACTION_ACTIVATE)
clean_replacement_branch_createcommitpushr!   result_marker_writereport_writenormal_callback_registerfallback_callback_registercodex_post_result_auditanu_codex_adjudicationzFinal[tuple[str, ...]]_PLANNED_ACTIONSc                 f    t        j                  t        j                        j	                  d      S )Nz%Y-%m-%dT%H:%M:%SZ)r   nowr   utcstrftime     8/home/jay/workspace/anu_v3/goal_activation_controller.py_now_utcr4   ]   s!    <<%../CDDr2   c                    t        |       j                  j                  dd       t        |       j                  t	        j
                  |dd      dz   d       y )	NT)parentsexist_ok   F)indentensure_ascii
zutf-8)encoding)r   parentmkdir
write_textjsondumps)pathobjs     r3   _write_jsonrD   a   sN    JD48J

3qu5<  r2   c                h    t        |       }|j                  }||v ryd|vryt        d| d| d      )u>  Finding 4: output 파일명에 포함된 task id 가 controller_task_id 와 일치하는지 검증.

    불일치 시 ValueError 를 발생시켜 controller 를 중단 (stale/mis-routed output 방지).
    파일명에 task id 가 없거나 경로가 메모리/이벤트 경로가 아닌 경우는 검사 스킵.
    Nztask-z-output path task id mismatch: filename stem 'z'' does not contain controller_task_id='uF   '. Stale/mis-routed output detected — aborting to prevent overwrite.)r   stem
ValueError)rB   controller_task_idprF   s       r3   _validate_output_path_task_idrJ   i   sW     	T
A66DT!d

7v >12 3N	N r2   c                \    t        |       }|j                         r|j                          yy)uR   Finding 4: non-HOLD 결과 시 stale hold.json 삭제 (delete-on-non-HOLD 정책).N)r   existsunlink)	hold_pathrI   s     r3   _delete_stale_holdrO      s"    YAxxz	
 r2   c                n  	
 g }t        |       }j                  dd      }j                  dd      
j                  di       	j                  dd      j                  dg       }d	
fd}|D ]  } ||      s|j                  |        |t        k(  r|r|j	                  |d	d
        |S )u   goal_contract.hold_conditions 중 dry-run result 에서 트리거된 항목 반환.

    빈 list = 0개 트리거 = Condition 5 PASS.
    status gate_decisionfour_conditionsall_four_conditions_metFhold_reasonsc                   | j                         }d|v r	t        k7  S d|v sd|v r	t        k7  S d|v sd|v r%j                  di       }|j                  dd       S d	|v r S d
|v r S d|v sd|v r S d|v sd|v ryd|v sd|v r S d|v sd|v r S d|v sd|v sd|v sd|v r S d|v sd|v ryd|v sd|v sd|v ryd|v rj                  dd      }| S y)Nz
critical 7zgate decision holdzgate decisionzexpected_files mismatchexpected_filesrT   .provenance_and_sha_and_decision_machine_4fieldTzforbidden targetzsource pr mutationzsame branch pushzsame-branch pushzmerge requiredmergeFf2ztoken transportphase3mqe
credentialapi
real_writez
real writezcodex unresolvedcodexz	anu-codexu   anu–codexdisagreement
provenance)lowerr   get)condclprovprov_okall_fourdry_run_resultfourrS   s       r3   _checkz)_evaluate_hold_conditions.<locals>._check   s`   ZZ\2 N222%B)> N22$*.>".D!%%&7<Dxx PRVWWW#<2%<#'9R'?<r!W]2:*b0<r>Ub[<2"0BlVXFX<#w"}" 3~7K2hh@%G ;r2   N   )rf   strreturnbool)r
   re   appendRUNNER_STATUS_HOLDextend)goal_contractrk   	triggered
hold_condsresult_statusrV   rm   rf   rj   rl   rS   s    `      @@@r3   _evaluate_hold_conditionsry      s     I&}5J"&&x4M"&&;M/4D!!";UCH!%%nb9L! !F  #$<T"#
 **\"1-.r2   c                 0    dt               dddddddddddS )u   normal + fallback callback 주입 contract (collector-only 권한).

    실제 cron 등록 0. contract 객체만 생성. 9-R.5 강제.
    z anu_v3.goal_callback_contract.v1Tcollector_onlyz;dry-run contract injection (no cron registration performed)ui   callback collector = 결과 회수 전용. write/재가동/dispatch/closeout/merge 권한 없음 (9-R.5).)schemats_utcnormalfallback	authorityno_writeno_dev_reactivationno_dispatchno_closeoutno_mergeinjection_modenote)r4   r1   r2   r3   _build_callback_contractr      s6     5*%#W4 r2   c                h   g }| j                  d      dur|j                  d       | j                  d      dur|j                  d       | j                  d      dk7  r#|j                  d| j                  d             d	D ]+  }| j                  |      dus|j                  d
| d       - |S )u@   callback contract 유효성 확인. 빈 list = Condition 6 PASS.r~   Tzcallback.normal != truer   zcallback.fallback != truer   r{   z(callback.authority != 'collector_only': )r   r   r   r   z	callback.z != true)re   rr   )cbissueskeys      r3   _validate_callback_contractr      s    F	vvht#/0	vvj%12	vvk..6rvvk7J6MN	
 Q 566#;d"MMIcU(345 Mr2   ztask-2553+7F)evidence_bundlecodex_auditdecision_out_pathresult_out_pathhold_out_pathregression_resultrH   _force_dry_runc        
           t               }
t        t        j                               }t	        |      }|xs	 |t
        z  }|xs	 |t        z  }|xs	 |d| dz  }t        ||       t        ||       t        ||       	 t        t        |             }|j!                  d
d      }t"        |j!                  dg       v }|rg n
dt"         dg}t%        ||d      }|j!                  d      }|t&        k(  }|rg nd|dg}|j!                  d      xs i }t)        |t              rt+        |j!                  d      xs g       ng }t-        |t+        t.              |t+        t0                    }t3        |      dk(  }|s|ng }|j!                  d      }|t4        k(  } | rg nd|dg}!t7        ||      }"t3        |"      dk(  }#|#rg ndt3        |"       d|"dd  g}$t9               }%t;        |%      }&t3        |&      dk(  }'|'rg nd|& g}(||z   |z   |!z   |$z   |(z   })|xr |xr |xr
 | xr |#xr |'}*|*xr |	 }+|||| |#|'d},|	rB|*r?t=        |      }-t?        ||      }.t9               }%|-j!                  d      r|-j!                  d d!      d"g}/t        ||/|d#|-d$d%&      }0t        |d|/|,t        |
d|||'
      }1t        ||1       t        |      }2t@        |2d(<   tC        |
||||||1|2|%|.|-|0d||)      }3t        ||3       |3S t        |d$g |,t        |
d$|||'
      }1d$|1d*<   d$|1d+<   d,|1d-<   t        ||1       t        |      }4tD        |4d(<   tC        |
||||||1|4|%|.|-dd||)      }3d|3d.<   d$|3d/<   t        ||3       tG        |       |3S |+s|)xs d0g}/|j!                  d(      t@        k(  r|/|j!                  d1g       dd z  }/t        ||/|d2|,|	d3&      }0t=        |      }-|-j!                  d      r|/|-j!                  d d4      gz  }/t?        ||      }.t        |d|/|,t        |
d|||'
      }1t        ||1       tC        |
||||||1||%|.|-|0d||)      }3t        ||3       |3S t%        ||d$      }5t=        |      }-|-j!                  d      rR|5j!                  d(      t@        k7  r:t        ||-j!                  d d!      g|d5      }0t        |5      }5t@        |5d(<   d$|5d6<   nd}0tG        |       t?        |5|      }.|5j!                  d(      tD        tH        fv xr |-j!                  d       }6t        ||+g |,t        |
|6|||'
      }1t        ||1       tC        |
||||||1|5|%|.|-|0d||)      }3t        ||3       |3S # t        $ ro}t        |d| g|d      }t        |t        ddt        |      gt        |
||             t        |t        |
|||	             t        |
|||	      cY d}~S d}~ww xY w)7u  goal_execution_contract 만으로 deriver→gate→activation 루프 자동 구성 + 기계 결정.

    Parameters
    ----------
    goal_contract:
        chair 제공 goal_execution_contract (schema: anu_v3.goal_execution_contract.v1).
    repo_path:
        workspace root 경로.
    evidence_bundle:
        None 이면 run_activation 내부 builder 가 자동 구성.
    codex_audit:
        선택적 Codex post-result audit mapping. HIGH/CRITICAL → HOLD 강제.
    decision_out_path:
        activation decision JSON 저장 경로 (None 이면 기본값).
    result_out_path:
        final goal result JSON 저장 경로 (None 이면 기본값).
    hold_out_path:
        HOLD packet 저장 경로 (None 이면 기본값).
    regression_result:
        pytest 결과 dict {"passed": N, "failed": M, "total": T, "ts_utc": ..., "command": ...}.
        제공 시 field 11 = 실 결과. 없으면 {"status": "NOT_PROVIDED"}.
    controller_task_id:
        이 controller 실행의 task ID (e.g. "task-2553+7"). 출력 파일명과 일치해야 함.
    _force_dry_run:
        True = 6 조건 전부 충족해도 activate=False 강제 (CLI --dry-run 안전 오버라이드).

    Returns
    -------
    dict — 16-field final goal result packet.
    zmemory/events/z
.hold.jsonu   goal contract parse 실패: goal_contract_parse)out_pathstageNF)gcall_passreasonscontroller_versiontsrH   run_idr   holdrH   r   target_task_idztask-2553+1allowed_actionszCondition 1 FAIL: 'z&' not in goal_contract.allowed_actions)	repo_pathr   activaterS   z"Condition 2 FAIL: gate_decision = z != DECISION_ALLOWderived_contracteffective_diff_files)planned_effective_actionsr   forbidden_write_targetsr   binding_preflight_statusz-Condition 4 FAIL: binding_preflight_status = z != DRY_RUN_PLAN_ONLYzCondition 5 FAIL: z hold condition(s) triggered: rn   zCondition 6 FAIL: )0cond1_allowed_actions_contains_clean_replacementcond2_gate_decision_allowcond3_boundary_validator_pass$cond4_binding_preflight_dry_run_plancond5_hold_conditions_zerocond6_callback_collector_ready
force_holdreasonzCodex unresolved HIGH/CRITICALz5force_hold=True overrides --dry-run all-six-pass pathcodex_audit_force_hold_dry_runT)codex_resultforce_dry_run)r   r   detail)
r   r   r   six_conditionsr   r   auto_continuerH   r   r   rQ   )r   rH   r   r   r   rS   activation_decisionactivation_resultcb_contractadjr   hold_pktmerge_performedr   r   activation_permittedforce_dry_run_overrideu   DRY_RUN_VERIFIED — 6 조건 전부 통과. --dry-run 안전 오버라이드로 activate=False 강제 (실 write 0). 회장 gated real activation 별도 실행 가능.r   hold_for_chairr   z6 conditions not all passedrV   six_conditions_check)r   r   zCodex HIGH/CRITICALcodex_post_auditcodex_forced_hold)%r4   ro   uuiduuid4r   r   r    rJ   r   dictr   r   rD   _activation_decisionr   _empty_result_packetre   r"   r   r   
isinstancelistr   r,   r   lenr   ry   r   r   _handle_codex_auditr   rs   _build_final_packetr   rO   r   )7ru   r   r   r   r   r   r   r   rH   r   r   r   repodec_pathres_pathrN   r   er   r   
cond1_passcond1_reasonsrk   gate_dec
cond2_passcond2_reasonsr   	eff_filesboundary_violations
cond3_passcond3_reasons	bp_status
cond4_passcond4_reasonstriggered_holds
cond5_passcond5_reasonsr   	cb_issues
cond6_passcond6_reasonsall_six_reasonsall_six_passr   r   r   r   rV   r   decision_jsonhold_resultfinal_packetdry_run_verifiedr   r   s7                                                          r3   run_goal_activationr      sM   V 
BF	?D CT,B%BH?4*>#>H  23:>>  "(,>?!(,>?!)-?@
 m!454 VV,m<N '"&&1BB*GGJ  	 ""7!8 93 3
  $'N !!/2H^+J  	28,>PQR  &))*<=C &- 	!!"89?R@ 
 ,
"&'7"8& $%H I	 ()Q.J:D2"M ""#=>I11J  	 <I= I# $
  0NCO_%*J  	 !_!5 6 7)"1-.0
  +,K+K8IY1$J!3I;?@  	
	
	 	 		
 	  	 			 	 		
   (>,> =G%/)30:&0*4N , +;7<.0L)   +KLGL 3""6(4tLH 1$-#5##5-M -0~.K$6K!.#5-!1&$1"-')! %"3L" ,/ -)11)
 15,-26./f 	f 	Hm,/%<"*1)-" -.#%!/
$ */%&(,_%Hl+9%  &I+H*Ih'+==N..~rB2AFFL.("0!/	
 +;7L)\--h8MNOOL  < - )11)
 	Hm,*1)-" -,#%!/
" 	Hl+ '' '{3L%*;*?*?+	+ /h(HIJ$	
 !!23&8(#15-.9% -{
;C &))(3 8  - |,
, 
 )%%-#-%M -( '-%))+!+L" ,']  
*+A3/0'	
 	H2ec!fX1b1	
 	 	H21
 	
 $1
 	
%
s   ?U, ,	W$5A$WW$W$c           	        | ddddS t        | j                  dd            j                         }| j                  dg       }|xs g D cg c]0  }t        |j                  dd            j                         dv s/|2 }}t        | j                  d	d
      xs d
      }|dv rdd|d|ddS |rdd|t	        |      dt	        |       ddS |d
kD  rdd||d| ddS dd|dS c c}w )u  Codex post-result audit 처리.

    force_hold=True 조건 (any of):
      1. verdict ∈ {NEEDS_REFINEMENT, FAIL, HIGH, CRITICAL}
      2. unresolved_findings[*].severity ∈ {HIGH, CRITICAL}
      3. scalar unresolved_high_or_critical > 0

    Only verdict ∈ {PASS, PASS_WITH_RECOMMENDATIONS} AND
    unresolved_high_or_critical == 0 AND no HIGH/CRITICAL findings
    → force_hold=False (auto-continue allowed).
    FNO_AUDIT_PROVIDED)attachedr   verdictr   rR   unresolved_findingsseverity)HIGHCRITICALunresolved_high_or_criticalr   )NEEDS_REFINEMENTFAILr   r   TzCodex verdict=z$ is not a pass (force_hold required))r   r   r   r   zCodex z$ unresolved HIGH/CRITICAL finding(s))r   r   r   unresolved_high_critical_countr   z"Codex unresolved_high_or_critical=z6 > 0 (scalar field indicates unresolved HIGH/CRITICAL))r   r   r   r   r   )ro   re   upperintr   )r   r   
unresolvedf	high_critscalar_high_crits         r3   r   r     sZ    *
 	

 +//)R01779G!6;J$"QUU:r-B)C)I)I)KOc)cI  ;??+H!LQPQR BB&wk1UV	
 	
 .1)ns9~..RS
 	
 !+;45E4F GD D	
 		
  Ks   0C(=C()r   r   rH   r   r   c        
            | t        |       ni }
|xs | r| j                  d      nd }i dddt        d|d|d|	d|d|d	| r| j                  d	      nd d
|d|xs i d|d|ddddd|
d|rdS dS )Nr   r|   z"anu_v3.goal_activation_decision.v1controller_moduler   r}   r   rH   goal_idr   r   rV   r   merge_not_permittedTmerge_not_performedsuccess_condition_parsedr   u   activation_permitted=True 이면 controller 가 run_activation(activate=True) 호출. runner 의 fail-closed gate 가 최종 barrier.u;   activation_permitted=False — HOLD_FOR_CHAIR. 실 write 0.)r   re   r   )r   r   r   r   r   r   r   rH   r   r   success_cond_parsed_tids               r3   r   r     s$    :<1"5RG"bff%56$D6. 	0 	"	
 	& 	0 	$ 	266)$ 	 	..B 	 	 	t 	t  	#$7!" 	 F% * O+ r2   )r   r   c                   |j                  d      }|j                  d      }t        |t              rt        |j                  d      xs g       ng }t	        t
              }|r t        t	        |            t        |      k(  nd}|t        |      }ndddd	d
}i dt        dt        dt        d| d|d|d|d|d|xs t        dg dd|d|d|d|d|d|ddddt        |t              xr7 t        |j                  d      t              xr |d   j                  d       d!u d"d#d$dd%d&ddd'd(||
|	|t        |      d!d!d!d!d!d!d)d|d*d+|t        k(  xs |du||j                  d,d      |j                  d-d      d.S )/u   회장 §명시 16-field final packet 생성.

    NOTE: activation_permitted removed — it was passed but never used inside this
    function (LOW unused-param cleanup). Callers updated accordingly.
    rQ   	pr_numberr   FN=tests/regression/test_goal_activation_controller_2553plus7.py   NOT_PROVIDEDuR   pytest 결과 미제공 (--regression-result 없이 실행). 별도 실행 필요.)
test_suiterequired_testsrQ   r   r|   r   r   r}   r   rH   r   task_idimplementation_files)z!anu_v3/goal_execution_contract.pyz!anu_v3/goal_boundary_validator.pyz$anu_v3/goal_activation_controller.pyzanu_v3/goal_result_planner.pyz)scripts/run_goal_activation_controller.pyz+schemas/goal_execution_contract.schema.jsonz)schemas/goal_execution_result.schema.jsonz5memory/fixtures/task-2553+1.f1solo.goal-contract.jsonr  r   r   zmemory/reports/task-2553+7.mdru   r   rS   r   clean_replacement_pr_numbereffective_diff_6_file_matchpr_102_preservation_evidencef   ztask/task-2553-dev5(bd5ad74f5d443b354319fc8b3cb006816b8a9025	source_pr	preservedTuG   PR #102 원본 변경 0. clean replacement PR 은 별도 신규 branch.)source_pr_numbersource_branchrecorded_head_shar  r   ztoken_transport / owner_triggeruf   controller 는 F2 관련 파일 변경 0. effective diff = 6 파일만 (TASK_2553P1_EFFECTIVE_DIFF_6).)f2_scopecontroller_changed_f2r   u*   controller 는 phase3/mqe 파일 변경 0.)phase3_tests_changedmerge_queue_executor_changedr   )contracthandoffr{   r   r   r   r   r   u   merge NOT permitted / NOT performed. controller 설계상 merge 경로 부재 (9-R.4 정적 증명). activation = clean replacement PR open 만.)merge_permittedr   r   real_write_performedgithub_mutation_performed)f2_byte_identical_evidencephase3_mqe_unchanged_evidencer   r*   r+   callback_collector_resultmerge_possibility_judgmentr   hold_packetr  r   )re   r   r   r   setr   sortedr   r   r   rs   r   )r   rH   r   r   r   rS   r   r   r   r   r   r   r   r   r   
act_statusr  r   expected_6_seteffective_6_match_regression_fields                        r3   r   r   !  s   . #&&x0J!%%k2I &- 	!!"89?R@ 
 56NLUs9~.&2HH[` $ !23 Z $h	
d$d 	.d 	0	d
 	"d 	&d 	0d 	.d 	%d 	*2 2d 	 !
d: 	;d> 	,?dB 	CdF 	2GdJ 	&yKdN 	&'8OdR 	' #2!K+T2 K/33K@$GK$[155kBdJ]
)
Sdl :%*2	'
 %*,1@*
 /#/"% $():;"#'	&
  %.U	'
 %(::Rhd>R 1 5 56Le T%6%:%:'&
Cd dr2   )rH   r   c                    i dt         dt        dt        d| d|d|ddd	|d
t        dddddddddddddddidddiddid
didddi i dddd|ddg dS )u&   parse 실패 시 최소 결과 패킷.r|   r   r   r}   r   rH   r   Nr  rQ   ru   r   rS   r   r  r  Fr  r  r!  r  r  NOT_RUN)r   r   )r  r   T)r"  r   r*   r+   r#  r$  r   r%  r  r   r  )r   r   r   rs   r   s       r3   r   r     s#   $. 	0 	"	
 	& 	0 	$ 	% 	$ 	 	D 	 	t 	&t 	&u  	'e(<!" 	%'>&F#$ +A%)H&	205U#K"$%':?TY&Z %%* "9 r2   )r   r   r   )rp   ro   )rB   
str | PathrC   dict[str, Any]rp   None)rB   r.  rH   ro   rp   r0  )rN   r.  rp   r0  )ru   Mapping[str, Any]rk   r1  rp   	list[str])rp   r/  )r   r1  rp   r2  )ru   r1  r   r.  r   Mapping[str, Any] | Noner   r3  r   str | Path | Noner   r4  r   r4  r   r3  rH   ro   r   rq   rp   r/  )r   r3  rp   r/  )r   dict[str, Any] | Noner   rq   r   r2  r   zdict[str, bool] | Noner   ro   r   ro   r   rq   rH   ro   r   
str | Noner   r6  rp   r/  ) r   ro   rH   ro   r   ro   r   r/  r   r5  rS   r6  r   r/  r   r/  r   r/  r   r/  r   r/  r   r5  r   rq   r   r3  r   r6  rp   r/  )
r   ro   r   r/  rH   ro   r   r6  rp   r/  )9__doc__
__future__r   r@   r   r   r   pathlibr   typingr   r   r	   anu_v3.goal_boundary_validatorr
   r   r   anu_v3.goal_execution_contractr   r   r   'anu_v3.pre_authorized_activation_runnerr   r   r   rs   r   r   r   r   !anu_v3.pre_authorized_action_gater   -anu_v3.pre_authorized_evidence_bundle_builderr   r   &anu_v3.pre_authorized_executor_bindingr   r   __annotations__r   r   r    r"   r,   r4   rD   rJ   rO   ry   r   r   r   r   r   r   r   __all__r1   r2   r3   <module>rC     s  : #   '  & & 
 
   G C : C!( J ( > 
  $K j J %@ z ?, ( E,>$>%> >H00 15,0+/)-'+26+ p$p p .	p
 *p )p 'p %p 0p p p pl?)??T .2  +!%'' ' 	'
 +' ' 	' ' ' ' ' 'x 37!QQ Q 	Q
 	Q ,Q Q (Q &Q  Q 
Q !Q $Q Q 0Q  !Q" #Qp ,%% % 	%
 % %Pr2   