+
    jHàj@  ã                  óê  € R t ^ RIHt ^ RIt^ RIt^ RIt^ RIHtHt ^ RI	H
t
 ]P                  ! ]4      tRt]P                  ! R4      t]P                  ! R4      t]P                  ! R4      t]P                  ! R	4      tR
]! R04      R]! R04      /t]! 4       P,                  ! ]P/                  4       !  tR.tR R lt/ ^ R/b^R0b^R1b^R2b^R3b^R4b^R5b^	R6b^
R7b^R8b^R9b^R:b^R;b^R<b^R=b^R>b^R?b/ ^R@b^R1b^R8b^RAb^RBb^RCb^R0b^R/b^RDb^RDb^REb^R0b^'RFb^(RGb^)RHb^*RIbCt^^	utt^ R^R^R^R^R^R^R^R^
R^R^R/tRRRRRRRRR R!R"R#R$R%/t] ! R& R'4      4       t R( R) lt!R* R+ lt"R, R- lt#R# )Jz¾GGUF metadata + tensor-table reader (stdlib only).

Reads the header only (metadata + tensor infos); never touches tensor data, so it is fast enough to
run at picker time on multi-GB files.
)ÚannotationsN)Ú	dataclassÚfield)ÚPaths   GGUFz-(\d{5})-of-(\d{5})\.gguf$z-\d{5}-of-\d{5}$zblk\.(\d+)\.ffn_.*\.weightzblk\.(\d+)\.ssm_conv1d\.weightÚqwen4expzper_layer_token_embd.weightÚgemma4c               ó    € V ^8„  d   QhRRRR/# )é   ÚstemÚstrÚreturn© )Úformats   "ÚB/home/ubuntu/.hermes/hermes-agent/hermes_cli/local_runtime/gguf.pyÚ__annotate__r   '   s   € ÷ )ñ )˜Sð ) Sñ )ó    c                ó.   € \         P                  RV 4      # )z<Model id from a GGUF file stem (split-part suffix stripped).Ú )Ú_PART_SUFFIX_REÚsub)r
   s   &r   Úmodel_id_from_stemr   '   s   € ä×Ñ˜r 4Ó(Ð(r   z<Bz<bz<Hz<hú<Iz<iz<fz<?ú<Qz<qz<dÚtempÚtemperatureÚtop_pztop-pÚtop_kztop-kÚmin_pzmin-pÚrepeat_penaltyzrepeat-penaltyÚpresence_penaltyzpresence-penaltyc                  óN  € ] tR t^Jt$ R]R&   R]R&   ]! ]R7      tR]R&   ^ tR]R&   ^ t	R]R	&   ^ t
R]R
&   ]! ]R7      tR]R&   ]! ]R7      tR]R&   ]! 4       tR]R&   ]R R l4       t]R R l4       tR R lt]R R l4       tR8R R llt]! R4      t]! R4      t]! R4      t]! R4      t]! R4      t]! R R!4      t]! R"R#4      t]! R$R%4      tA]R& R' l4       t]R( R) l4       t]R* R+ l4       t]R, R- l4       t ]R. R/ l4       t!R0 R1 lt"]R2 R3 l4       t#]R4 R5 l4       t$R6t%R7# )9Ú
GGUFHeaderr   ÚpathÚintÚversion)Údefault_factoryÚdictÚmetadataÚ	n_tensorsÚtensor_bytesÚembd_table_byteszdict[int, int]Úffn_block_byteszdict[str, int]Úlazy_candidate_byteszfrozenset[int]Úrecurrent_blocksc               ó   € V ^8„  d   QhRR/# ©r	   r   r   r   )r   s   "r   r   ÚGGUFHeader.__annotate___   s   € ÷ Bñ B˜cñ Br   c                	óL   € \        V P                  P                  R R4      4      # )zgeneral.architecturer   )r   r'   Úget)Úselfs   &r   ÚarchitectureÚGGUFHeader.architecture^   s   € ä�4—=‘=×$Ñ$Ð%;¸RÓ@ÓAÐAr   c               ó   € V ^8„  d   QhRR/# ©r	   r   r#   r   )r   s   "r   r   r0   c   s   € ÷ Hñ H˜Cñ Hr   c                ó®   a€ \         P                  V P                  \        4       4      o\	        V3R lV P
                  P                  4        4       4      # )zQBytes of weights llama.cpp keeps on disk and reads row by row instead of loading.c              3  óX   <"  € T F  w  rVS9   g   K  V\         8”  g   K  Vx € K!  	  R # 5i©N)Ú_LAZY_READ_MIN_BYTES)Ú.0ÚnameÚnbytesÚmarkeds   &  €r   Ú	<genexpr>Ú(GGUFHeader.lazy_bytes.<locals>.<genexpr>f   s2   øé € ð HÑ.O™l˜dØ˜f‘nô Ø)/Ô2FÑ)F÷ ’6Ó.Oùs   ƒ*“* 
*)Ú_LAZY_READ_TENSORSr2   r4   Ú	frozensetÚsumr,   Úitems)r3   r?   s   &@r   Ú
lazy_bytesÚGGUFHeader.lazy_bytesb   sK   ø€ ô $×'Ñ'¨×(9Ñ(9¼9»;ÓGˆÜô H¨d×.GÑ.G×.MÑ.MÔ.Oó Hó Hð 	Hr   c               ó   € V ^8„  d   QhRR/# )r	   Úsuffixr   r   )r   s   "r   r   r0   i   s   € ÷ Bñ B ñ Br   c                	óV   € V P                   P                  V P                   R V 24      # )Ú.)r'   r2   r4   ©r3   rI   s   &&r   Ú	_arch_keyÚGGUFHeader._arch_keyi   s)   € Ø�}‰}× Ñ  D×$5Ñ$5Ð#6°a¸°xÐ!@ÓAÐAr   c               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   m   s   € ÷ 6ñ 6 sñ 6r   c                óV  a € R V 3R llpV! R4      V! R4      r2S P                   '       d   V'       d	   V'       g   ^ # V^V! R4      ,          V,          ,           p^W#,          \        ^ V! R4      ^,
          4      V,          ,           ,          p\        S P                   4      V,          # )z×One copy of one sequence's recurrent state: an f32 conv window plus the SSM state, per
block that keeps state. llama.cpp holds one copy per slot per speculative draft position.
0 when the file declares no SSM shape.c               ó    € V ^8„  d   QhRRRR/# )r	   Úkeyr   r   r#   r   )r   s   "r   r   Ú6GGUFHeader.recurrent_state_bytes.<locals>.__annotate__q   s   € ÷ 	:ñ 	:�Sð 	:˜Sñ 	:r   c                óR   <€ \        SP                  R V  24      ;'       g    ^ 4      # )zssm.©r#   rM   )rR   r3   s   &€r   ÚssmÚ-GGUFHeader.recurrent_state_bytes.<locals>.ssmq   s%   ø€ Ü�t—~‘~¨¨S¨E lÓ3×8Ð8°qÓ9Ð9r   Ú
inner_sizeÚ
state_sizeÚgroup_countÚconv_kernel)r-   ÚmaxÚlen)r3   rV   ÚinnerÚstateÚconv_dimÚ	per_blocks   f     r   Úrecurrent_state_bytesÚ GGUFHeader.recurrent_state_bytesl   s‰   ø€ ÷
	:ð 	:ñ ˜<Ó(©#¨lÓ*;ˆuØ×%×%Ð%¯%·EÙØ˜1™s =Ó1Õ1°EÕ9Õ9ˆØ˜�¬¨Q±°MÓ0BÀQÕ0FÓ)GÈ(Õ)RÕRÕSˆ	Ü�4×(Ñ(Ó)¨IÕ5Ð5r   c               ó    € V ^8„  d   QhRRRR/# )r	   rI   r   Údocr   )r   s   "r   r   r0   {   s   € ÷ Pñ P˜#ð P Cñ Pr   c                	ó&   a € \        V 3R  lVR7      # )c                óL   <€ \        V P                  S4      ;'       g    ^ 4      # )é    rU   rL   s   &€r   Ú<lambda>Ú&GGUFHeader._arch_int.<locals>.<lambda>|   s   ø€ ¤S¨¯©¸Ó)?×)DÐ)DÀ1Ô%Er   )re   )Úproperty)rI   re   s   f&r   Ú	_arch_intÚGGUFHeader._arch_int{   s   ø€ ÜÔEÈ3ÔOÐOr   Úblock_countÚcontext_lengthÚembedding_lengthzattention.sliding_windowÚexpert_countÚfull_attention_intervalz|GDN-hybrid discriminator (qwen35 family): every Nth layer is full attention, the rest are linear/recurrent. 0 = not present.zattention.key_length_swazˆPer-token key size for sliding-window layers when it differs from the global attention.key_length (e.g. gemma3/gemma4). 0 = not present.zattention.value_length_swazwPer-token value size for sliding-window layers when it differs from the global attention.value_length. 0 = not present.c               ó   € V ^8„  d   QhRR/# )r	   r   zlist[int] | Noner   )r   s   "r   r   r0   ’   s   € ÷ Dñ DÐ(8ñ Dr   c                ó”   € V P                  R4      p\        V\        4      '       d   V Uu. uF  p\        V4      NK  	  up# R# u upi )uF  Per-layer SWA pattern declared by the file itself: a truthy entry marks a
sliding-window layer, falsy marks global. None when the file doesn't declare the per-layer
array form (older GGUFs, architectures without per-layer SWA metadata, or files that use
the scalar period form instead â€” see `sliding_window_pattern_period`).ú attention.sliding_window_patternN)rM   Ú
isinstanceÚlistr#   )r3   ÚvÚxs   &  r   Úsliding_window_patternÚ!GGUFHeader.sliding_window_pattern‘   s@   € ð �N‰NÐ=Ó>ˆÜ&0°´D×&9Ò&9¡Ó"¡˜1”�A–¡Ñ"ÐC¸tÐCùÒ"s   ¬Ac               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   ›   s   € ÷ Oñ O¨sñ Or   c                ó–   € V P                  R4      p\        V\        4      '       d"   \        V\        4      '       g   \        V4      # ^ # )uB  Scalar SWA period declared by the file: llama.cpp also permits
`attention.sliding_window_pattern` as a single integer N (every Nth layer is full
attention, e.g. Gemma-family writers) rather than a per-layer array. 0 when absent or when
the file uses the array form instead â€” callers should fall back to a coarser signal.ru   )rM   rv   r#   Úbool©r3   rx   s   & r   Úsliding_window_pattern_periodÚ(GGUFHeader.sliding_window_pattern_periodš   s:   € ð �N‰NÐ=Ó>ˆÜ# A¤s×+Ò+´J¸qÄ$×4GÒ4GŒs�1‹vÐNÈQÐNr   c               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   ¤   s   € ÷ :ñ :˜ñ :r   c                óÆ   € V P                  R4      pV'       d   \        V4      # V P                  P                  R4      p\	        V\
        4      '       d   \        V4      # ^ # )zrVocabulary size (prices the GPU logits buffers): vocab_size metadata when present, else
the tokenizer list length.Ú
vocab_sizeztokenizer.ggml.tokens)rM   r#   r'   r2   rv   rw   r]   )r3   rx   Útokss   &  r   Ún_vocabÚGGUFHeader.n_vocab£   sN   € ð �N‰N˜<Ó(ˆßÜ�q“6ˆMØ�}‰}× Ñ Ð!8Ó9ˆÜ& t¬T×2Ò2Œs�4‹yÐ9¸Ð9r   c               ó   € V ^8„  d   QhRR/# )r	   r   r&   r   )r   s   "r   r   r0   ®   s   € ÷ ñ  4ñ r   c                ó®  € / pV P                   P                  4        F´  w  r#VP                  R4      '       g   K  \        P	                  VP                  R^4      R,          4      pVf   KP  \        V\        \        34      '       g   Kn  \        \        V4      ^4      pV\        V4      8X  d   \        \        V4      4      M
\        V4      W&   K¶  	  V# )uE  Upstream's recommended sampling as preset INI keys, when the file carries it.

Publishers bake ``general.sampling.*`` keys into the GGUF (llama-server reads them as that
model's defaults), so the file is the source of truth â€” it ships with the download and
updates with every re-upload, no catalog needed. Empty if absent.
zgeneral.sampling.rK   éÿÿÿÿ)r'   rE   Ú
startswithÚ_SAMPLING_INI_KEYr2   Úrsplitrv   r#   ÚfloatÚroundr   )r3   ÚoutrR   Úvaluer=   Únums   &     r   Úsampling_defaultsÚGGUFHeader.sampling_defaults­   s¡   € ð ˆØŸ-™-×-Ñ-Ö/‰JˆCØ—>‘>Ð"5×6Ò6ÙÜ$×(Ñ(¨¯©°C¸Ó);¸BÕ)?Ó@ˆDØÔ¤J¨u´s¼E°l×$CÔ$CÜœE %›L¨!Ó,�Ø-0´C¸³H¬_œC¤ C£œMÄ#ÀcÃ(�“	ñ 0ð ˆ
r   c               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   À   s   € ÷ ñ ˜ñ r   c                	ó¢   € V P                  R 4      p\        V\        4      '       d   \        \	        V4      4      # \        T;'       g    ^ 4      # )zattention.head_count)rM   rv   rw   r#   r\   r   s   & r   Ún_headÚGGUFHeader.n_head¿   s<   € à�N‰NÐ1Ó2ˆÜ�aœ×ÒÜ”s˜1“v“;ÐÜ�1—6�6˜‹{Ðr   c               ó   € V ^8„  d   QhRR/# )r	   r   z	list[int]r   )r   s   "r   r   r0   Æ   s   € ÷ 'ñ ' 	ñ 'r   c                óŠ  € V P                  R4      p\        V\        4      '       d   V Uu. uF  p\        V4      NK  	  up# \        T;'       g    ^ 4      pV P                  pV^8”  d=   \        V P                  4       Uu. uF  pV^,           V,          ^ 8X  d   TM^ NK  	  up# V.V P                  ,          # u upi u upi )uq  Per-layer KV head counts; 0 marks a recurrent/linear layer (n_head_kv == 0).

Three GGUF shapes: a per-layer array (nemotron_h_moe) is used as-is; a scalar plus
``full_attention_interval`` (qwen35) applies to every N-th layer (1-indexed) and is zero
elsewhere â€” pricing all layers as attention was a 4x overestimate; a plain scalar (dense)
broadcasts to every layer.
zattention.head_count_kv)rM   rv   rw   r#   rr   ÚrangeÚn_layer)r3   rx   ry   ÚscalarÚintervalÚis   &     r   Úhead_counts_kvÚGGUFHeader.head_counts_kvÆ   s³   € ð �N‰NÐ4Ó5ˆÜ�aœ×ÒÙ$%Ó&¡A˜q”C˜–F¡AÑ&Ð&Ü�Q—V�V˜!“ˆØ×/Ñ/ˆØ�aŒ<ä" 4§<¡<Ô0ó2Ù0˜ð  ! 1�u¨Õ0°AÔ5‘F¸1Ò<Ù0ñ2ð 2àˆx˜$Ÿ,™,Õ&Ð&ùò 'ùò2s   ¬B;Â"C c               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   Ù   s   € ÷ @ñ @˜Cñ @r   c                	ó¬   € V P                  R 4      pV'       d   \        V4      # V P                  '       d   V P                  V P                  ,          # ^ # )zattention.key_length)rM   r#   r—   Ún_embdr   s   & r   Ú
head_dim_kÚGGUFHeader.head_dim_kØ   s=   € à�N‰NÐ1Ó2ˆßÜ�q“6ˆMØ-1¯[¯[¨[ˆt�{‰{˜dŸk™kÕ)Ð?¸aÐ?r   c               ó   € V ^8„  d   QhRR/# r7   r   )r   s   "r   r   r0   à   s   € ÷ ñ ˜Cñ r   c                	ób   € V P                  R 4      pV'       d   \        V4      # V P                  # )zattention.value_length)rM   r#   r¥   r   s   & r   Ú
head_dim_vÚGGUFHeader.head_dim_vß   s'   € à�N‰NÐ3Ó4ˆßÜ�q“6ˆMØ�‰Ðr   r   N)r   )&Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__annotations__r   r&   r'   r(   r)   r*   r+   r,   rC   r-   rk   r4   rF   rM   rb   rl   rœ   Ún_ctx_trainr¤   Úsliding_windowrq   rr   Úkey_length_swaÚvalue_length_swarz   r€   r†   r“   r—   r    r¥   r©   Ú__static_attributes__r   r   r   r!   r!   J   sÇ  ‡ à
ƒIØƒLÙ¨4Ô0€HˆdÓ0Ø€IˆsÓØ€L�#ÓØÐ�cÓñ ',¸DÔ&A€O�^ÓAñ ,1ÀÔ+FÐ˜.ÓFñ (1£{Ð�nÓ2ð ôBó ðBð ôHó ðHõBð ô6ó ð6÷Pñ ˜Ó&€GÙÐ,Ó-€KÙÐ)Ó*€FÙÐ9Ó:€NÙ˜^Ó,€LÙ'Ø!ð	1ó2Ðñ Ø"ð	FóG€Nñ !Ø$ð	3ó4Ðð 	àôDó ðDð ôOó ðOð ô:ó ð:ð ôó ðð" ôó ðõ'ð$ ô@ó ð@ð ôó ôr   r!   c               ó    € V ^8„  d   QhRRRR/# )r	   r"   r   r   zlist[Path] | Noner   )r   s   "r   r   r   ç   s   € ÷ -ñ -�dð -Ð0ñ -r   c                ó€  a aa€ \         P                  S P                  4      pVf   R# S P                  RVP                  4        \	        VP                  ^4      4      uooV VV3R l\        ^S^,           4       4        Uu. uF  pVP                  4       '       g   K  VNK  	  pp\        V4      ^8”  d   V# R# u upi )a˜  Every on-disk part of the split ``path`` belongs to, first part first; None when ``path`` is
not a split member or no other part is present.

A split is priced as the set, never as one file: publishers lay shards out so the first part
can hold little more than metadata while the bulk sits in the later ones, so reading one part
prices the model at whatever fraction of its weights that part happens to hold.Nc           	   3  ó\   <"  € T F!  pSP                  S R VR RSR R24      x € K#  	  R# 5i)Ú-Ú05dz-of-z.ggufN)Ú	with_name)r<   rŸ   r"   r
   Útotals   & €€€r   r@   Úsplit_parts.<locals>.<genexpr>ò   s;   øé € ð 7Ù"5˜Qð Ÿ™¨4¨&°°!°C°¸¸UÀ3¸KÀuÐ(M×NÐNÛ"5ùs   ƒ),)	ÚSPLIT_PART_REÚsearchr=   Ústartr#   Úgroupr›   Úis_filer]   )r"   ÚmÚpÚpartsr
   r»   s   f   @@r   Úsplit_partsrÅ   ç   s§   ú€ ô 	×Ñ˜TŸY™YÓ'€AØ‚yÙØ—)‘)˜K˜aŸg™g›iÐ(¬#¨a¯g©g°a«j«/€K€Dˆ%ö7Ü"'¨¨5°1­9Ô"5ô7ó Gñ 7�1Ø:;¿)¹)¿+÷ ˆQñ 7€Eð Gä˜“J ”Nˆ5Ð,¨Ð,ùòGs   ÂB;ÂB;c               ó    € V ^8„  d   QhRRRR/# )r	   r"   r   r   r!   r   )r   s   "r   r   r   ÷   s"   € ÷ DDñ DD�Tð DD˜jñ DDr   c                ó¬  a aaa€ R V 3R lloR V3R lloR VVV3R llo\        S R4      ;_uu_ 4       pVP                  ^4      \        8w  d   \        RS  24      hS! VR	4      w  r#p/ p\	        V4       F   pS! V4      pS! VR
4      w  pS! W4      WW&   K"  	  ^ p	^ p
/ p/ p\        4       p\	        V4       EFW  pS! V4      pS! VR
4      w  pS! VRV R24      pS! VR
4      w  pVP                  ^4       \        P                  V4      pVf   \        RV RS  24      hVw  pp^pV F  pVV,          pK  	  VV,          V,          pV	V,          p	VR8X  d   Tp
K§  \        P                  V4      ;p'       d9   \        VP                  ^4      4      pVP                  V^ 4      V,           VV&   Kü  V\        9   d   VWÎ&   EK  \        P                  V4      ;p'       g   EK.  VP                  \        VP                  ^4      4      4       EKZ  	  RRR4       \        \!        S 4      XXXX	X
XX\#        X4      R7	      #   + '       g   i     L6; i)z=One file's own header: metadata and that file's tensor table.c               ó   € V ^8„  d   QhRR/# )r	   Úfmtr   r   )r   s   "r   r   Ú _read_part.<locals>.__annotate__ù   s   € ÷ (ñ (�Sñ (r   c                óº   <€ \         P                  ! V4      pV P                  V4      p\        V4      V8w  d   \	        R S 24      h\         P
                  ! W4      # )ztruncated GGUF header: )ÚstructÚcalcsizeÚreadr]   Ú
ValueErrorÚunpack)ÚfrÉ   ÚsizeÚdatar"   s   &&  €r   rÎ   Ú_read_part.<locals>.readù   sN   ø€ ô �Š˜sÓ#ˆØ�v‰v�d‹|ˆÜˆt‹9˜ÔÜÐ6°t°fÐ=Ó>Ð>Ü�}Š}˜SÓ'Ð'r   c               ó   € V ^8„  d   QhRR/# r/   r   )r   s   "r   r   rÊ     s   € ÷ ;ñ ;�sñ ;r   c                ó^   <€ S! V R 4      w  pV P                  V4      P                  RRR7      # )r   zutf-8Úreplace)Úerrors)rÎ   Údecode)rÑ   ÚnrÎ   s   & €r   Úread_strÚ_read_part.<locals>.read_str  s.   ø€ Ù�A�t‹}‰ˆØ�v‰v�a‹y×Ñ °	ÐÓ:Ð:r   c               ó   € V ^8„  d   QhRR/# )r	   Úvtyper#   r   )r   s   "r   r   rÊ     s   € ÷ .ñ .˜Sñ .r   c                óØ   <€ V\         8X  d	   S! V 4      # V\        8X  d-   S! V R 4      w  r#\        V4       Uu. uF  pS! W4      NK  	  up# S! V \        V,          4      ^ ,          # u upi )z<IQ)Ú	_V_STRINGÚ_V_ARRAYr›   Ú_SCALAR_FMT)rÑ   rÞ   ÚetyperÚ   Ú_rÎ   rÛ   Ú
read_values   &&   €€€r   rå   Ú_read_part.<locals>.read_value  sd   ø€ Ø”IÔÙ˜A“;ÐØ”HÔÙ˜A˜u“~‰HˆEÜ27¸´(Ó;±(¨Q‘J˜qÖ(±(Ñ;Ð;Ù�A”{ 5Õ)Ó*¨1Õ-Ð-ùò <s   ¸A'Úrbznot a GGUF file: z<IQQr   Ú<ÚQNzunknown ggml tensor type z in ztoken_embd.weight©	r"   r$   r'   r(   r)   r*   r+   r,   r-   )ÚopenrÎ   Ú_GGUF_MAGICrÏ   r›   ÚsetÚ_GGML_TYPE_SIZESr2   Ú_FFN_WEIGHTÚmatchr#   rÀ   Ú_LAZY_READ_CANDIDATESÚ	_SSM_CONVÚaddr!   r   rC   )r"   rÑ   r$   r(   Ún_kvr'   rä   rR   rÞ   r)   Ú
embd_bytesr+   r,   r-   r=   Ún_dimsÚdimsÚttyperÒ   Úblock_bytesÚblock_elemsÚelemsÚdr>   rÂ   ÚblockrÎ   rÛ   rå   s   f                         @@@r   Ú
_read_partrþ   ÷   sH  û€ ÷(ð (÷;ð ;÷.ò .ô 
ˆd�D×	Ô	˜QØ�6‰6�!‹9œÔ#ÜÐ0°°Ð7Ó8Ð8Ù#'¨¨6£?Ñ ˆ˜DàˆÜ�t–ˆAÙ˜1“+ˆCÙ˜A˜t“}‰HˆUÙ& qÓ0ˆH‹Mñ ð
 ˆØˆ
Ø*,ˆØ/1ÐÜ%(£UÐÜ�y×!ˆAÙ˜A“;ˆDÙ˜Q ›‰IˆVÙ˜˜Q˜v˜h a˜=Ó)ˆDÙ˜A˜t“}‰HˆUØ�F‰F�1ŒIÜ#×'Ñ'¨Ó.ˆDØŠ|Ü Ð#<¸U¸GÀ4ÈÀvÐ!NÓOÐOØ'+Ñ$ˆK˜ØˆEÛ�Ø˜•
’ñ à˜{Õ*¨kÕ9ˆFØ˜FÕ"ˆLØÐ*Ô*Ø#’
Ü!×'Ñ'¨Ó-Ð-�Ö-Ü˜AŸG™G A›J›�Ø)8×)<Ñ)<¸UÀAÓ)FÈÕ)O� Ó&ØÔ.Ô.Ø-3Ð$Ô*Ü—o‘o dÓ+Ð+�×+Ñ+Ø ×$Ñ$¤S¨¯©°«£_×5ñ/ "÷! 
ôR œ3˜t›9¨gÀØ )¸Ø'1À?Ø+?Ü'0Ð1AÓ'Bô	Dð D÷S 
×	ús   ¶EIÅ=A$IÇ'.IÉI	c               ó    € V ^8„  d   QhRRRR/# )r	   r"   z
str | Pathr   r!   r   )r   s   "r   r   r   >  s   € ÷ +Uñ +U˜:ð +U¨*ñ +Ur   c                ó|  € \        V 4      p \        V 4      pVf   \        V 4      # \        V^ ,          4      pV.pVR,           F  p VP                  \        V4      4       K   	  \        V4      ^8X  d   V# / pV FA  pVP                  P                  4        F   w  r‰VP                  V^ 4      V	,           Wh&   K"  	  KC  	  \        \        V 4      VP                  VP                   \#        R V 4       4      \#        R V 4       4      \#        R V 4       4      TV U
UU	u/ uF(  p
V
P$                  P                  4        F  w  r¹W¹bK	  	  K*  	  up	pp
\'        4       P(                  ! R V 4       !  R7	      #   \        \
        3 d.   p\        P                  RTP                  T4        Rp?EKk  Rp?ii ; iu up	pp
i )	u¸  Header for a MODEL, not for a file: a split GGUF is priced as the sum of its parts.

Weights, the host-side embedding-table duplicate and the per-block FFN map are all summed
across the shards on disk, because a split is a layout choice, not a smaller model â€” pricing
part 1 alone underprices every model whose first shard is a metadata stub (the Hugging Face
layout), which then makes the physics check and the residency cap admit giants the card cannot
hold. Architecture metadata (block count, train context, the per-layer SWA pattern, vocab) is
taken from the first part: gguf-split writes the model's metadata there only, and every later
part carries just its ``split.*`` keys.

A part that has gone missing or become unreadable is skipped rather than fatal: a half-arrived
split prices at what is actually on disk. Refusing it is ``staged_in(require_complete=True)``'s
job â€” an incomplete split is never servable, it is only underpriced here.N:é   NNzsplit part unreadable %s: %sc              3  ó8   "  € T F  qP                   x € K  	  R # 5ir:   )r(   ©r<   Úhs   & r   r@   Ú#read_gguf_header.<locals>.<genexpr>c  s   é € Ð4©8 a—k–k«8ùó   ‚c              3  ó8   "  € T F  qP                   x € K  	  R # 5ir:   )r)   r  s   & r   r@   r  d  s   é € Ð:±¨AŸž³ùr  c              3  ó8   "  € T F  qP                   x € K  	  R # 5ir:   )r*   r  s   & r   r@   r  e  s   é € ÐB¹°A×/Ö/»ùr  c              3  ó8   "  € T F  qP                   x € K  	  R # 5ir:   )r-   r  s   & r   r@   r  i  s   é € Ð,RÉÀA×-?Ö-?Ëùr  rê   )r   rÅ   rþ   ÚappendrÏ   ÚOSErrorÚloggerÚdebugr=   r]   r+   rE   r2   r!   r   r$   r'   rD   r,   rC   Úunion)r"   rÄ   ÚfirstÚreadableÚpartÚexcr+   Úheaderrý   r>   r  r=   s   &           r   Úread_gguf_headerr  >  s”  € ô �‹:€DÜ˜Ó€EØ‚}Ü˜$ÓÐä�u˜Q•xÓ €EØˆw€HØ�b—	�	ˆð	IØ�O‰OœJ tÓ,Ö-ñ ô
 ˆ8ƒ}˜ÔØˆà&(€OÛˆØ#×3Ñ3×9Ñ9Ö;‰MˆEØ%4×%8Ñ%8¸ÀÓ%BÀVÕ%KˆOÓ"ó <ñ ô ô �‹Y §¡¸¿¹ÜÑ4©8Ó4Ó4ÜÑ:±Ó:Ó:ÜÑB¹ÓBÓBØ'Ù4<õ R±H¨qØ23×2HÑ2H×2NÑ2NÖ2P¡, $ð #šlÙ2Pñ #±Hó Rä"›×*Ò*Ñ,RÉÓ,RÑSô
Uð 
Uøô œGÐ$ô 	IÜ�L‰LÐ7¸¿¹ÀC×HÓHûð	Iüô"Rs   ÁE6Ä .F7Å6F4Æ!F/Æ/F4l        )é   r  )r	   r  )é   é    )é   r  )é   r  )é   r  )é"   r  )é$   r  )éT   é   )én   r  )é�   r  )é°   r  )éÒ   r  )i$  r  )éB   r  )éJ   r  )éb   r  )é2   r  )éR   r  )éˆ   r  )r  r  )é   r  )é8   r  )é   r  )r  é@   )r  é€   )r  r,  )$Ú__doc__Ú
__future__r   ÚloggingÚrerÌ   Údataclassesr   r   Úpathlibr   Ú	getLoggerr«   r  rì   Úcompiler½   r   rï   rò   rC   rB   r  Úvaluesrñ   r;   r   rî   rà   rá   râ   rŒ   r!   rÅ   rþ   r  r   r   r   Ú<module>r7     sá  ðñõ #ã Û 	Û ß (Ý à	×	Ò	˜8Ó	$€à€ð —
’
Ð8Ó9€Ø—*’*Ð0Ó1€à�jŠjÐ6Ó7€à�JŠJÐ8Ó9€	ð ‘	Ð8Ð9Ó:Ø‰iÐ6Ð7Ó8ðÐ ñ "›×)Ò)Ð+=×+DÑ+DÓ+FÑGÐ ØÐ õ)ðØ€vðØ�&ðØ˜XðØ'(¨(ðØ45°xðØABÀHðà€xðà�Hðà  )ðà-/°ðà=?Àðð ˆ
ðð ˜
ðð %'¨
ðð 57¸	ðð ˆ	ð	ð �yñ	ð #% ið	ð 24°Xð	ð
 ˆ
ðð
 ˜	ðð
 $& zðð
 46°vðð
 @BÀ6ðð ˆðð �Fðð  ðð )+¨Iðð 8:¸6ðð ˆðð ˆðð ˆ	ðð ˆñÐ ð ˜Ð €	ˆ8à€tˆQ��a˜˜q $Ø€tˆQ��a˜˜q $Øˆˆb�$˜˜Dð€ð ˜V ]°F¸GÀWØ˜g w°Ø%Ð'7Ø'Ð);ð=Ð ð ÷Yð Yó ðYõx-õ DD÷N+Ur   