Instructions to use KrorngAI/TrorYongASR-tiny with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use KrorngAI/TrorYongASR-tiny with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("automatic-speech-recognition", model="KrorngAI/TrorYongASR-tiny", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("KrorngAI/TrorYongASR-tiny", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
| # Author: KrorngAI org. | |
| # Date: March 2026 | |
| from transformers import PreTrainedConfig | |
| class TrorYongASRConfig(PreTrainedConfig): | |
| model_type = "troryongasr" | |
| def __init__( | |
| self, | |
| vocab_size: int = 48005, # use the tokenizer's vocab size | |
| n_mels: int = 80, | |
| n_audio_ctx: int = 1500, | |
| n_text_ctx: int = 1024, | |
| n_embed: int = 384, | |
| n_head: int = 6, | |
| n_layer: int = 4, | |
| dropout: float= 0.0, | |
| bias: bool = True, | |
| pad_id: int = 0, | |
| eot_id: int = 2, | |
| tie_word_embeddings: bool = True, | |
| **kwargs, | |
| ): | |
| self.vocab_size = vocab_size | |
| self.n_mels = n_mels | |
| self.n_audio_ctx = n_audio_ctx | |
| self.n_text_ctx = n_text_ctx | |
| self.n_embed = n_embed | |
| self.n_head = n_head | |
| self.n_layer = n_layer | |
| self.dropout = dropout | |
| self.bias = bias | |
| self.pad_id = pad_id | |
| self.eot_id = eot_id | |
| self.tie_word_embeddings = tie_word_embeddings | |
| super().__init__(**kwargs) | |