Skip to content

[OpenVINO][Models] CohereASR conversion fix - #1910

Draft
PiotrKrzem wants to merge 6 commits into
huggingface:mainfrom
PiotrKrzem:feature/cohere_asr_fix
Draft

[OpenVINO][Models] CohereASR conversion fix#1910
PiotrKrzem wants to merge 6 commits into
huggingface:mainfrom
PiotrKrzem:feature/cohere_asr_fix

Conversation

@PiotrKrzem

@PiotrKrzem PiotrKrzem commented Aug 3, 2026

Copy link
Copy Markdown

What does this PR do?

  • Fixes conversion of CohereASR for optimum-intel, adds missing layers and configs to the program

Fixes issue:

  • 191527

@PiotrKrzem PiotrKrzem changed the title [ [OpenVINO][Models] CohereASR conversion fix Aug 3, 2026
Comment on lines +1115 to +1118
if task.startswith(("text2text-generation", "automatic-speech-recognition")) and (
not task.endswith("with-past") or model.decoder.stateful
):
expected_int8.pop("decoder_with_past", None)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it makes sense to execute only for cohereasr only to avoid impact on other ASR models

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use existing test suite in test_asr. No need to implement new test.

Comment thread tests/openvino/utils_tests.py Outdated
Comment on lines +147 to +159
def _get_cohere_asr_test_model():
# Falls back to a checkout local to the repository so the fixture can be regenerated offline
model_id_override = os.getenv("OPTIMUM_INTEL_COHERE_ASR_TEST_MODEL")
if model_id_override:
return model_id_override

local_fixture_path = Path(__file__).resolve().parents[3] / "tiny-random-cohere-asr"
if local_fixture_path.exists():
return str(local_fixture_path)

return "optimum-intel-internal-testing/tiny-random-cohere-asr"


Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not needed, let us use tiny-model model from HF

@rkazants rkazants left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please provide proper PR description. Check other PRs already merged, for ASR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants