feat: return waveform peaks as a typed list instead of a JSON string - #4
Merged
Conversation
ProbeResult.WaveformResult was a string holding a JSON-serialized List<double> -- a leftover of the old JSON-blob-everything design that Result (removed earlier this cycle) also used. Return the data itself: ProbeResult.Waveform is now IReadOnlyList<double>?, populated directly from WaveformCalculator.GetNormalizedWindows() with no serialize step in between. Docs (llms.txt, llms-full.txt, API-Reference.html, Advanced-Features.html, Getting-Started.html) updated to match. BREAKING CHANGE: ProbeResult.WaveformResult (string?) no longer exists; use ProbeResult.Waveform (IReadOnlyList<double>?) instead.
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ProbeResult.WaveformResultwas astring?holding a JSON-serializedList<double>-- a leftover of the old JSON-blob-everything design thatResult(removed earlier in this same API-cleanup cycle) also used. Return the actual typed data instead of a string to parse:ProbeResult.Waveformis nowIReadOnlyList<double>?, assigned directly fromWaveformCalculator.GetNormalizedWindows()-- noJsonSerializer.Serialize/Deserializeround trip in between.NativeEncoder.Probe*methods, the unit tests (AssertNonEmptyWaveformnow takes the list directly), and the docs that documented the old shape (llms.txt, llms-full.txt, API-Reference.html, Advanced-Features.html, Getting-Started.html, CLAUDE.md).Breaking change
ProbeResult.WaveformResult(string?) no longer exists -- useProbeResult.Waveform(IReadOnlyList<double>?) instead.Test plan
dotnet build --configuration Release(net8.0/net9.0/net10.0)dotnet test --configuration Releasepasses on all three target frameworks (109 passed, 1 pre-existing skip)🤖 Generated with Claude Code