|
| 1 | +# Changelog |
| 2 | + |
| 3 | +All notable changes to this project will be documented in this file. |
| 4 | + |
| 5 | +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), |
| 6 | +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). |
| 7 | + |
| 8 | +## [1.2.0] - 2024-03-15 |
| 9 | + |
| 10 | +### Added |
| 11 | +- `pyproject.toml` as the canonical build configuration (replaces `setup.py` as the primary build definition) |
| 12 | +- `py.typed` marker file for PEP 561 compliance — fully typed package |
| 13 | +- `Makefile` with `install`, `test`, `lint`, `lint-fix`, `format`, `format-check`, `typecheck`, `check`, and `dev` targets |
| 14 | +- GitHub Actions CI workflow (`ci.yml`) running lint, type checking, and tests across Python 3.10–3.13 |
| 15 | +- `ruff` for linting and formatting (replaces `black`) |
| 16 | +- `mypy` for static type checking |
| 17 | +- Full type annotations on all public APIs in `helpers.py`, `converters.py`, `webvtt.py`, and `srt.py` |
| 18 | +- Comprehensive docstrings for all public classes and functions |
| 19 | +- `SECURITY.md` with responsible disclosure policy |
| 20 | +- `CHANGELOG.md` (this file) |
| 21 | + |
| 22 | +### Changed |
| 23 | +- `DeepgramConverter`, `AssemblyAIConverter`, and `WhisperTimestampedConverter` now carry full type hints |
| 24 | +- `webvtt()` and `srt()` functions are now fully typed with `Any` converter protocol |
| 25 | +- `EmptyTranscriptException` and `ConverterException` are now exported from the top-level `deepgram_captions` package |
| 26 | +- Updated classifiers to reflect Production/Stable status and Python 3.10–3.13 support |
| 27 | +- Release workflow updated to use `actions/checkout@v4` and `actions/setup-python@v4` |
| 28 | +- Release workflow version bumping now targets `pyproject.toml` instead of `_version.py` only |
| 29 | + |
| 30 | +### Fixed |
| 31 | +- `chunk_array` simplified to a single list comprehension (functionally identical, more idiomatic) |
| 32 | + |
| 33 | +## [1.1.0] - 2023-11-08 |
| 34 | + |
| 35 | +### Added |
| 36 | +- `AssemblyAIConverter` — support for AssemblyAI speech-to-text API responses |
| 37 | +- `WhisperTimestampedConverter` — support for [Whisper Timestamped](https://github.com/linto-ai/whisper-timestamped) responses (word-level timestamps required) |
| 38 | +- `replace_text_with_word()` helper to normalise `"text"` key to `"word"` for Whisper Timestamped compatibility |
| 39 | +- Documentation note clarifying that OpenAI Whisper (without word timestamps) is not supported directly; users should use Deepgram's hosted Whisper Cloud (`model=whisper`) with `DeepgramConverter` |
| 40 | + |
| 41 | +### Changed |
| 42 | +- `get_lines()` on `AssemblyAIConverter` now respects `utterances` array when present, falling back to flat `words` array |
| 43 | +- `WhisperTimestampedConverter.get_lines()` processes `segments` array and applies `replace_text_with_word` normalisation |
| 44 | + |
| 45 | +## [1.0.0] - 2023-10-15 |
| 46 | + |
| 47 | +### Added |
| 48 | +- Speaker diarisation support in `DeepgramConverter.get_lines()`: when word objects include a `"speaker"` field, caption lines break on speaker changes in addition to `line_length` limits |
| 49 | +- Speaker labels in WebVTT output using voice tags: `<v Speaker 0>text</v>` |
| 50 | +- Speaker labels in SRT output as `[speaker N]` prefix lines, emitted once per speaker change |
| 51 | +- `use_exception` parameter on `DeepgramConverter.__init__()` — set to `False` to suppress `ConverterException` when no valid transcript is found |
| 52 | +- `EmptyTranscriptException` raised by `webvtt()` and `srt()` when the converter returns an empty first line |
| 53 | +- `line_length` parameter on `webvtt()` and `srt()` — controls the maximum number of words per caption cue (default: 8) |
| 54 | +- `get_headers()` on `DeepgramConverter` returns a `NOTE` block for WebVTT output containing request ID, creation time, duration, and channel count from the Deepgram response metadata |
| 55 | + |
| 56 | +### Changed |
| 57 | +- `DeepgramConverter` now prefers the `utterances` array over `channels[0].alternatives[0].words` when both are present, producing more natural sentence-level caption breaks |
| 58 | +- `webvtt()` checks for `get_headers()` capability via `hasattr`/`callable` — custom converters do not need to implement it |
| 59 | + |
| 60 | +### Fixed |
| 61 | +- Microsecond precision in `seconds_to_timestamp()` correctly truncated to milliseconds for both WebVTT (`.`) and SRT (`,`) formats |
| 62 | + |
| 63 | +## [0.1.0] - 2023-09-20 |
| 64 | + |
| 65 | +### Added |
| 66 | +- `DeepgramConverter` class wrapping Deepgram pre-recorded and streaming API responses |
| 67 | +- `webvtt()` function generating valid WebVTT documents from any converter |
| 68 | +- `srt()` function generating valid SRT documents from any converter |
| 69 | +- `seconds_to_timestamp()` utility converting float seconds to `HH:MM:SS.mmm` or `HH:MM:SS,mmm` |
| 70 | +- `chunk_array()` utility splitting word lists into fixed-length groups |
| 71 | +- `EmptyTranscriptException` for empty transcript detection |
| 72 | +- Support for Deepgram SDK response objects via `.to_json()` method detection |
| 73 | +- Initial test suite covering Deepgram pre-recorded responses |
| 74 | + |
| 75 | +## [0.0.1] - 2023-08-01 |
| 76 | + |
| 77 | +### Added |
| 78 | +- Initial project scaffold |
| 79 | +- Package structure: `deepgram_captions/` with `__init__.py`, `helpers.py`, `converters.py`, `webvtt.py`, `srt.py` |
| 80 | +- `setup.py` with basic package metadata |
| 81 | +- MIT License |
| 82 | +- Initial README |
| 83 | + |
| 84 | +[1.2.0]: https://github.com/deepgram/deepgram-python-captions/compare/v1.1.0...v1.2.0 |
| 85 | +[1.1.0]: https://github.com/deepgram/deepgram-python-captions/compare/v1.0.0...v1.1.0 |
| 86 | +[1.0.0]: https://github.com/deepgram/deepgram-python-captions/compare/v0.1.0...v1.0.0 |
| 87 | +[0.1.0]: https://github.com/deepgram/deepgram-python-captions/compare/v0.0.1...v0.1.0 |
| 88 | +[0.0.1]: https://github.com/deepgram/deepgram-python-captions/releases/tag/v0.0.1 |
0 commit comments