Quick Start Guide
Get started with HyperDex in just a few minutes! This guide shows you how to run your first large language model inference on HyperAccel's LPU.
Prerequisites
Before you begin, make sure you have:
- ✅ Xilinx Runtime (XRT) installed on your system
- ✅ HyperDex-Toolchain Python package installed
- 📝 If you haven't completed the installation, follow our Installation Guide
Your First LLM Inference
Step 1: Import HyperDex Libraries
HyperDex provides a familiar API similar to HuggingFace Transformers, making it easy to get started.
Step 2: Load Model and Tokenizer
Device Mapping
The device_map={"lpu": 1} parameter tells HyperDex to load the model onto the LPU hardware.
Step 3: Generate Text
Complete Example
Here's the complete working example:
Key Design Principles
- Familiar APIs: HyperDex mirrors HuggingFace Transformers APIs, so you can leverage your existing knowledge
- Hardware Abstraction: LPU optimization schemes are handled automatically behind the scenes
- Zero Learning Curve: If you know HuggingFace, you already know HyperDex
Next Steps
🎯 Ready to explore more? Check out these resources:
- Advanced Examples: vLLM API for LPU
- API Documentation: Detailed API reference
Additional Resources
📖 Quick Reference Guide: If you have a server with HyperDex already installed, you can also refer to our PDF user guide for a quick overview.