2 مستودعات
User-supplied callback functions invoked for each generated token during inference, enabling custom streaming and early termination.
Distinct from Callback-Based Data Streaming: Distinct from Callback-Based Data Streaming: focuses on LLM token generation callbacks rather than general network data streaming.
Explore 2 awesome GitHub repositories matching networking & communication · Token Generation Callbacks. Refine with filters or upvote what's useful.
gemma.cpp is a C++ inference engine for Gemma, PaliGemma, and Griffin language models, designed to run directly on-device without Python dependencies. It provides a self-contained runtime that loads quantized model weights and performs text generation on CPU or GPU, along with a model checkpoint converter that transforms PyTorch or Keras checkpoints into a compact binary format for fast loading. The engine supports multiple model architectures, including the Griffin recurrent architecture with gated linear recurrent layers and sliding-window attention for efficient long-sequence handling, as
Yields each output token to a user-supplied callback, enabling custom streaming, filtering, or early termination.
ExecuTorch is a lightweight C++ runtime for deploying PyTorch models on mobile, embedded, and edge hardware. It provides an ahead-of-time compilation pipeline that exports, quantizes, and lowers model graphs into compact serialized programs, then executes them through a minimal runtime with hardware acceleration and on-device large language model inference capabilities. The project distinguishes itself through a hardware accelerator delegate system that partitions model subgraphs and offloads computation to specialized backends including NPUs, GPUs, and DSPs from Apple, Arm, Intel, MediaTek,
ExecuTorch receives each generated token via a callback function, enabling real-time output display during inference.