+
    Q(i                         R t ^ RIHt ^ RIHt ^ RIHt ^ RIHtH	t	H
t
 ^ RIHt ^ RIHt ^ RIHt ^ RIHt R	 t]! ]R
7      t]P*                  ! ]! RR7      R7      RRRRRR^/R R lll4       tR# )z1Generate documentation for Cyclopts applications.)Path)	Annotated)app)FORMAT_ALIASES	DocFormatnormalize_format)Group)load_app_from_script)	Parameter)UNSETc                     V P                  R 4      pV P                  R4      pVP                  \        J EdB   VP                  \        J d   \        R4      hVP                  '       d   \	        VP                  R4      '       g   \        R4      hVP                  P
                  P                  4       pV'       g   \        R4      hVP                  R4      pV'       g   \        R4      h\        P                   ! V4      pVfm   \        P                  ! 4        Uu. uF  p\        V4      ^8:  g   K  RV 2NK  	  pp\        R	V R
RP                  \        \        V4      4      4       R24      hWQn        R# R# u upi )z--formatz--outputz>"--format" must be specified when output path is not provided.suffixzB"--output" must be a valid file path when format is not specified.zOutput file must have an extension to infer format (e.g., .md, .html, .rst). Please specify "--format" explicitly or add an extension to the output file..zwInvalid file extension. Output file must have a valid extension after the period. Please specify "--format" explicitly.Nz+Cannot infer format from output extension "z". Supported extensions: z, z'. Please specify "--format" explicitly.)getvaluer   
ValueErrorhasattrr   lowerlstripr   keyslenjoinsortedset)argument_collection
format_arg
output_argr   
suffix_keyinferred_formatextsupported_extensionss   &       W/Users/agent/.openclaw/workspace/venv/lib/python3.14/site-packages/cyclopts/cli/docs.py_format_group_validatorr"      sk   $((4J$((4J5 u$]^^wz/?/?'J'Jabb!!((..0_  ]]3'
8 
 ),,Z8"9G9L9L9N#`9N#RUVYRZ^_R_IauI9N #`=fX F))-6#>R:S3T)U(V W89  +E !6 $as   E;3	E;)	validator )negative)default_parameterNformatinclude_hiddenFheading_levelc                    V ^8  d   QhR\         R\        \        R,          \        R\        R7      3,          R\        \
        R,          \        R\        R7      3,          R\        R	\        /# )
   scriptoutputNz-o)aliasgroupr'   z-fr(   r)   )strr   r   r
   format_groupr   boolint)r'   s   "r!   __annotate__r4   ?   sk     * **dTk94|#LLM* DL1	3	* * *    c                   Vf   \        R4      h\        V4      p\        V 4      w  rVVP                  VVVR7      pV'       d   VP	                  V4       R# \        V4       R# )ad  Generate documentation for a Cyclopts application.

Parameters
----------
script : str
    Python script path, optionally with ``':app_object'`` notation to specify
    the App object. If not specified, will search for App objects in the
    script's global namespace.
output : Optional[Path]
    Output file path. If not specified, prints to stdout.
format : Optional[DocFormat]
    Output format for documentation. If not specified, inferred from output
    file extension.
include_hidden : bool
    Include hidden commands in documentation.
heading_level : int
    Starting heading level for markdown format.
NzMust specify format.)output_formatr(   r)   )r   r   r	   generate_docs
write_textprint)r,   r-   r'   r(   r)   app_obj_docs_contents   &&$$$   r!   r8   r8   >   sd    < ~/00f%F%f-JG((%# ) L ,'lr5   )N)__doc__pathlibr   typingr   cyclopts.clir   cyclopts.docs.typesr   r   r   cyclopts.groupr   cyclopts.loaderr	   cyclopts.parameterr
   cyclopts.utilsr   r"   r1   commandr8    r5   r!   <module>rI      s|    7    
 ! 0 (  &+R 67 y"56* 	* !* * 7*r5   