منصوبے کے بارے میں
ferrite ایک high-performance inference engine ہے جو Rust میں لکھا گیا ہے، خاص طور پر GLM-5.3-Flash ماڈل کے لیے ڈیزائن کیا گیا ہے۔ یہ engine ایک hybrid architecture کا استعمال کرتا ہے جو GatedDeltaNet linear attention، DSA sparse attention، اور dense/MoE FFN layers کو جوڑتا ہے۔ اس کا بنیادی ڈیزائن مقصد روایتی serving frameworks سے وابستہ runtime overhead کو دور کرنا ہے، جس کے لیے compile-time model specialization اور static layer planning کا استعمال کیا جاتا ہے۔
اہم architectural features میں شامل ہیں:
1. **PDAF Disaggregation**: Prefill، Decode، Attention، اور FFN phases کو first-class citizens کے طور پر سمجھا جاتا ہے، جن کے لیے ایک dedicated router اور static operation graph موجود ہے، جس سے runtime dispatch overhead ختم ہو جاتی ہے۔
2. **Composable Parallelism**: engine Tensor Parallelism (TP)، Context Parallelism (CP)، اور Data-Parallel Context Parallelism (DCP) کو ایک unified axis algebra system کے ذریعے سپورٹ کرتا ہے۔ یہ flexible 3D mesh configurations (Q، Kv، اور Head axes) کی اجازت دیتا ہے، جنہیں throughput اور latency کو بہتر بنانے کے لیے جوڑا جا سکتا ہے۔
3. **Exact MHC اور GatedDeltaNet**: یہ exact Multi-Head Connection (MHC) residuals اور ایک WYF-parallel chunkwise GatedDeltaNet recurrence کو نافذ کرتا ہے، جو CPU golden standards کے خلاف verify کیا گیا ہے۔
4. **CUDA Optimization**: engine میں sm_100a/sm_103a architectures کے لیے custom CUDA kernels شامل ہیں، جن میں CUDA graph capture اور verification کی سپورٹ ہے تاکہ decoding کے دوران operation sequence stability کو یقینی بنایا جا سکے۔
پروجیکٹ numerical correctness پر زور دیتا ہے، CPU backend کو golden standard کے طور پر استعمال کرتے ہوئے باقی تمام backends کی validation کرتا ہے۔ یہ فی الحال continuous batching، speculative decoding (MTP) کو سپورٹ کرتا ہے، اور B300 GPUs پر significant performance improvements حاصل کر چکا ہے، speculative execution کے ساتھ decode mode میں 64.8 tok/s تک پہنچ رہا ہے۔ codebase modular ہے، جس میں types، model configuration، kernel backends، KV management، batching، scheduling، اور execution کے لیے separate crates موجود ہیں۔
Comments
0 Rating appears after 10 ratings
Sign in to join the discussion.