+
    „WÝj!  ã                   ó’   € R t ^ RIt^ RIt^ RIHtHtHt ^ RIH	t	 ^ RI
Ht ^ RIHt R R ltR R	 ltR
 R ltR R ltRR R lltR# )zUSecret-capture prompt for the interactive CLI (``_secret_capture_callback`` backend).N)ÚcprintÚ_DIMÚ_RST)Úsave_env_value_secure)Úmasked_secret_prompt)Údisplay_hermes_homec                ó   € V ^8„  d   QhRR/# ©é   ÚreturnN© )Úformats   "ÚHC:\Users\johnn\AppData\Local\hermes\hermes-agent\hermes_cli\callbacks.pyÚ__annotate__r      s   € ÷ ñ ˜ñ ó    c                 ó¬   € \        V R 4      '       d   V P                  4        R# \        V RR4      '       d   V P                  P	                  4        R# R# )Ú
_paint_nowÚ_appN)Úhasattrr   Úgetattrr   Ú
invalidate©Úclis   &r   Ú_invalidater      s=   € Üˆs�L×!Ò!Ø�‰ÖÜ	��f˜d×	#Ò	#Ø�‰×ÑÖñ 
$r   c                ó   € V ^8„  d   QhRR/# r	   r   )r   s   "r   r   r      s   € ÷ ñ  ñ r   c                óæ   €  \        V R4      '       d   V P                  4        R# \        V RR4      '       d'   V P                  P                  P                  4        R# R#   \         d     R# i ; i)z>Drop stale draft input so Enter never stores it as the secret.Ú_clear_secret_input_bufferr   N)r   r   r   r   Úcurrent_bufferÚresetÚ	Exceptionr   s   &r   Ú_clear_secret_inputr       s]   € ðÜ�3Ð4×5Ò5Ø×*Ñ*Ö,Ü�S˜& $×'Ò'Ø�H‰H×#Ñ#×)Ñ)Ö+ñ (øäô Úðús   ‚"A! ¦7A! Á!A0Á/A0c                óH   € V ^8„  d   QhR\         R\         R\         R\        /# )r
   Úvar_nameÚreasonÚmessager   ©ÚstrÚdict)r   s   "r   r   r      s.   € ÷ Añ A”sð A¤Cð A´#ð A¼$ñ Ar   c                 ó   € R RRVRV RRRRRV/# )ÚsuccessTr#   Ú	stored_asÚ	validatedFÚskippedr$   r   )r"   r#   r$   s   &&&r   Ú_skippedr-      s(   € à�4˜ 6¨;¸Ø�U˜I t¨Y¸ðAð Ar   c                ó<   € V ^8„  d   QhR\         R\         R\        /# )r
   r"   Úvaluer   r%   )r   s   "r   r   r   $   s&   € ÷ ]ñ ]œSð ]¬ð ]´ñ ]r   c           	     ó  € V'       g'   \        R\         R\         24       \        V RR4      #  \	        W4      p\        R\         R\        4        RT  \         24       / TCR	R
RR/C#   \
         d   p\        RT 24       h Rp?ii ; i)zQStore ``value`` (or report a skip when empty) and build the callback result dict.Ú
u     â�­ Secret entry skippedÚ	cancelledzSecret setup was skipped.u   
  âœ— Nu     âœ“ Stored secret in z	/.env as r,   Fr$   zFSecret stored securely. The secret value was not exposed to the model.)r   r   r   r-   r   Ú
ValueErrorr   )r"   r/   ÚstoredÚexcs   &&  r   Ú_secret_resultr6   $   s­   € çÜ�”D�6Ð3´D°6Ð:Ô;Ü˜ +Ð/JÓKÐKðÜ& xÓ7ˆô ˆR”ˆvÐ,Ô-@Ó-BÐ,CÀ9ÈXÈJÔW[ÐV\Ð]Ô^ð]Ø
ð]à�5ØÐ[ñ]ð ]øô	 ô Ü�˜#˜ÐÔ Øûðús   °A+ Á+B
Á6BÂB
c                ó<   € V ^8„  d   QhR\         R\         R\        /# )r
   r"   Úpromptr   r%   )r   s   "r   r   r   5   s&   € ÷ /Tñ /T¤Sð /T´#ð /TÌñ /Tr   c                óº  € \        V RR4      '       gM   \        V R4      '       g   RV n        \        V R4      '       g   ^ V n         \	        V R24      p\        W4      # \        P                  ! 4       pRTRTR	T;'       g    / R
V/V n        \        P                  ! 4       ^x,           V n        \        V R4      '       d   V P                  RRV R2R7       \        V 4       \        V 4         VP                  ^R7      pRT n        ^ T n        \        T 4       \        Y4      #   \
        \        3 d    Rp Læi ; i  \        P                    d=    T P                  \        P                  ! 4       ,
          ^ 8:  d    M\        T 4        K¡  i ; iRT n        ^ T n        \        T 4       \        T 4       \#        R\$         R\&         24       \)        TRR4      # )zÙPrompt for a secret value through the TUI (e.g. API keys for skills).

Returns a dict with keys: success, stored_as, validated, skipped, message. The secret is stored
in ~/.hermes/.env and never exposed to the model.
r   NÚ_secret_stateÚ_secret_deadlinez' (hidden, ESC or empty Enter to skip): Ú r"   r8   ÚmetadataÚresponse_queueÚ
_ring_bellTzsecret needed (Ú))r8   Úcontext)Útimeoutr1   u*     â�± Timeout â€” secret capture cancelledrB   z'Secret setup timed out and was skipped.)r   r   r:   r;   r   ÚEOFErrorÚKeyboardInterruptr6   ÚqueueÚQueueÚ_timeÚ	monotonicr?   r    r   ÚgetÚEmptyr   r   r   r-   )r   r"   r8   r=   r/   r>   s   &&&&  r   Úprompt_for_secretrK   5   s½  € ô �3˜ ×%Ò%Ü�s˜O×,Ò,Ø $ˆCÔÜ�sÐ.×/Ò/Ø#$ˆCÔ ð	Ü(¨F¨8Ð3ZÐ)[Ó\ˆEô ˜hÓ.Ð.ä—[’[“]€Nà�HØ�&Ø�H—N�N Ø˜.ð	*€CÔô
 !Ÿ?š?Ó,¨sÕ2€CÔÜˆs�L×!Ò!Ø�‰˜d¨o¸h¸ZÀqÐ,IˆÔJÜ˜ÔÜ�Ôà
ð	Ø"×&Ñ&¨qÐ&Ó1ˆEð !ˆÔØ ˆÔÜ�CÔÜ˜hÓ.Ð.øô7 Ô+Ð,ô 	ØŠEð	ûô& �{‰{ô 	Ø×#Ñ#¤e§o¢oÓ&7Õ7¸1Ô<ÙÜ˜ÔÚð		úð €CÔØ€CÔÜ˜ÔÜ�ÔÜ
ˆR”ˆvÐ?Ä¸vÐFÔGÜ�H˜iÐ)RÓSÐSs+   ÁD& Ã0D? Ä&D<Ä;D<Ä?A FÆFÆF)N)Ú__doc__rE   ÚtimerG   Úhermes_cli.bannerr   r   r   Úhermes_cli.configr   Úhermes_cli.secret_promptr   Úhermes_constantsr   r   r    r-   r6   rK   r   r   r   Ú<module>rR      s?   ðÙ [ã Û ç 0Ñ 0Ý 3Ý 9Ý 0õõõAõ]÷"/Tñ /Tr   