📚 docs(granite-speech): add comprehensive usage examples
Author: gorkachea
Pull request: yes

# docs(granite-speech): add comprehensive usage examples

Resolves the TODO (@alex-jw-brooks) by adding complete usage documentation for Granite Speech model now that it's released and compatible with transformers.

Added examples for:
- Basic speech transcription
- Speech-to-text with additional context
- Batch processing multiple audio files
- Tips for best results (audio format, LoRA adapter, memory optimization)

This helps users get started with the Granite Speech multimodal model by providing practical, copy-paste-ready code examples for common use cases.

Replaces TODO comment on line 44 with ~100 lines of comprehensive documentation following the patterns used in other multimodal model docs.

## What does this PR do?

This PR resolves an existing TODO in the Granite Speech documentation by adding comprehensive usage examples now that the model is released and compatible with transformers.

**Problem**: The documentation contained a placeholder TODO comment asking for usage examples once the model was released. Since `ibm-granite/granite-3.2-8b-speech` is now available, users need practical examples to get started.

**Solution**: Added a complete "Usage example" section with three practical code examples:
1. Basic speech transcription - simple audio-to-text
2. Speech-to-text with additional context - using text prompts with audio
3. Batch processing - efficient handling of multiple audio files
4. Tips section - audio format, LoRA adapter info, optimization guidance

**Impact**: Users can now quickly get started with Granite Speech without searching external resources. The examples follow the same structure as other multimodal models (SAM2, SmolVLM, LLaVA) for consistency.

## Before submitting

- [x] This PR fixes a typo or improves the docs - **Yes, this is documentation enhancement**
- [x] Did you read the contributor guideline, Pull Request section? **Yes**
- [ ] Was this discussed/approved via a Github issue or the forum? **No - this directly resolves an existing TODO comment left by @alex-jw-brooks in the documentation**
- [x] Did you make sure to update the documentation with your changes? **Yes - this PR is entirely documentation**
- [ ] Did you write any new necessary tests? **N/A - documentation only change, no code changes**

## Who can review?

@alex-jw-brooks (original TODO author)
@stevhliu (documentation)
@zucchini-nlp (multimodal models)

---

**Additional Context:**

This PR adds ~105 lines of documentation to replace a single TODO comment. All code examples:
- Follow transformers conventions
- Are syntactically correct
- Match patterns used in other multimodal model docs
- Cover the most common use cases for this model

The Granite Speech model is a multimodal speech-to-text model from IBM that's now fully integrated into transformers, so users need these examples to get started effectively.


Comments:
Thanks for the review @zucchini-nlp! I've addressed both points:

1. ✅ **Chat template**: Updated the second example to properly use `apply_chat_template()` for formatting the prompt with audio
2. ✅ **Generic tips**: Removed general LLM advice (temperature, batch size, memory) and moved Granite Speech-specific tips (audio format, LoRA adapter) to the "Usage tips" section at the top

The documentation now focuses on model-specific features. Let me know if you'd like any other adjustments!

cc @eustlb as requested

The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/transformers/pr_42125). All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.