mudler / mudler/parakeet.cpp

Support for AI4Bharat IndicConformer Models

Open
#47 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
786
Forks
93
PR merge metrics
No merged PRs in 30d

Description

Feature Description

Please add support for AI4Bharat IndicConformer models.

Currently loading the GGUF model crashes during the feature downsampling/subsampling block.

Error

GGML_ASSERT(a->ne[2] == 1) failed

Stack:
ggml_conv_2d_dw_direct()
Subsampling::build_graph()

Root Cause

The current implementation assumes FastConformer subsampling:

conv.2 depthwise
conv.3 pointwise
conv.5 depthwise
conv.6 pointwise

However AI4Bharat IndicConformer uses:

conv.0 Conv2d
ReLU
conv.2 Conv2d
ReLU

ONNX inspection:

conv.0.weight
[512,1,3,3]
group=1

conv.2.weight
[512,512,3,3]
group=1

GGUF:

encoder.pre_encode.conv.2.weight
[3,3,512,512]

This is a different computation graph, not only a tensor layout issue.

Proposed implementation
  1. Detect subsampling architecture during loading.

  2. Preserve existing FastConformer depthwise path.

  3. Add IndicConformer path:

Conv2d(conv.0)
→ ReLU
→ Conv2d(conv.2)
→ ReLU

using ggml_conv_2d().

  1. Reuse existing encoder blocks after subsampling.
Additional observation

The GGUF file itself is valid:

  • parakeet-cli info works correctly.
  • parakeet-cli quantize works correctly.

The failure only occurs during parakeet-cli transcribe, when the inference graph is constructed and the subsampling layer is executed.

Use Case

Standalone C++ Speech-to-Text inference for Indian languages.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at Subsampling::build_graph() and inspect the existing FastConformer depthwise path, then compare it with the ggml_conv_2d() operations needed by the IndicConformer graph. Use parakeet-cli transcribe with an AI4Bharat GGUF model to verify that loading and inference complete while existing FastConformer behavior remains unchanged.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
machine-learning
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.