Skip to content

Triage trt rtx tts - #380

Merged
tonythethompson merged 7 commits into
mainfrom
triage_trt_rtx_tts
Oct 6, 2026
Merged

tonythethompson merged 7 commits into
mainfrom
triage_trt_rtx_tts

Conversation

@tonythethompson

@tonythethompson tonythethompson commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Linked issue

  • Closes #

Scope

  • Single-responsibility change
  • No unrelated refactors included

Testing

  • dotnet build Trackdub.slnx -m:1
  • dotnet test Trackdub.slnx -m:1
  • Targeted tests only
  • Not run, with justification below

Test notes

Architecture review

  • No layer dependency violation introduced
  • No inference code added to Trackdub.App
  • No persistence added to view models
  • No pipeline truth moved into UI state
  • No state mutation added from model wrappers

License/model impact

  • No new third-party dependency
  • No new model or model asset
  • New dependency/model documented
  • Manifest/license requirements reviewed
  • Commercial-safe mode impact reviewed

Risk and rollback

  • Low-risk change
  • Rollback is straightforward
  • Follow-up work required, noted below

Milestone notes

Agent notes


Summary by cubic

Resolves the #329 triage: the reported TRT-RTX squeeze shape error originates from silero-vad, not the TTS stage, and this PR hardens the two failure paths it exposed. VAD now routes around TensorRT RTX, pooled Whisper creation gains a DirectML/CPU fallback chain, and pooled TRT sessions skip native teardown only while the runtime is poisoned.

Bug Fixes

  • Excludes TensorRT RTX for VAD in the planner; silero-vad fails the TRT engine build on every attempt. Classic TensorRT stays allowed.
  • Pooled Whisper session creation walks a TensorRT RTX → DirectML → CPU fallback chain after pre-flight, recording why each provider was abandoned.
  • Suppresses Dispose() only on TensorRT RTX sessions after a CUDA OOM poisons the runtime, so teardown no longer triggers the 0xC0000005 crash. Healthy and DirectML/CPU fallback sessions still dispose normally.
  • Sets SessionOptions.LogId from the model path so native TRT compile logs are attributable to the correct graph.
  • Updates the C13 triage audit with confirmation and mitigation evidence, including the separate Dispose-crash follow-up, and restores Trackdub.Sdk.Tests locked-mode restore (NU1004).

Written for commit 25698fa. Summary will update on new commits.

Review in cubic

@tonythethompson
tonythethompson added this pull request to stack #381 October 6, 2026 09:43
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 28 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: c5301f87-194c-4811-a433-9007be3a7c1c
📥 Commits

Reviewing files that changed from the base of the PR and between fbf42fb and 25698fa.

📒 Files selected for processing (10)
  • docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md
  • src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs
  • src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs
  • src/Trackdub.Inference.Onnx/TensorRtRtx/TensorRtRtxTeardownGuard.cs
  • src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs
  • tests/Trackdub.Inference.Tests/GenAiTensorRtExclusionTests.cs
  • tests/Trackdub.Inference.Tests/OnnxExecutionSessionFactoryTests.cs
  • tests/Trackdub.Inference.Tests/PooledWhisperTrtFallbackTests.cs
  • tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs
  • tests/Trackdub.Inference.Tests/TensorRtRtxTeardownGuardTests.cs
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@qodo-code-review

Copy link
Copy Markdown
Contributor

PR Summary by Qodo

Route VAD around TensorRT RTX and guard session teardown

🐞 Bug fix 🧪 Tests 📝 Documentation ⚙️ Configuration changes 🕐 40+ Minutes

Grey Divider

AI Description

• Identify silero-VAD, not TTS, as the source of the reported TensorRT RTX shape error.
Diagram

graph TD
  Planner["Stage planner"] --> Vad["VAD DirectML"]
  Planner --> Whisper["Whisper factory"] --> Trt{"TRT init fails?"} -->|yes| Dml["DirectML retry"] -->|fails| Cpu["CPU retry"]
  Planner --> Pool["Session pool"] --> Guard["TRT teardown guard"]
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Avoid TRT for OOM-prone Whisper graphs
  • ➕ Prevents known compilation OOM and unsafe native teardown.
  • ➕ Avoids accumulating undisposed TRT sessions.
  • ➖ Forfeits TRT acceleration for excluded graphs.
  • ➖ Requires a defensible model- or hardware-specific admission rule.
2. Fix native teardown upstream
  • ➕ Preserves TRT use and normal release of native resources.
  • ➖ Depends on the provider or ONNX Runtime maintainers.
  • ➖ Does not immediately protect affected installations.

Recommendation: Keep the VAD planner exclusion and narrowly classified fallback. Treat suppressed finalization as a temporary crash containment measure, not safe disposal: it leaves TRT native resources unreleased. Prefer avoiding known OOM-prone graphs before initialization while pursuing an upstream teardown fix.

Files changed (8) +1015 / -215

Bug fix (3) +109 / -47
OnnxExecutionSessionFactory.csRetry Whisper session creation after classified TRT failures +86/-41

Retry Whisper session creation after classified TRT failures

• Adds DirectML and CPU retries for classified TRT initialization failures in the non-pooled Whisper factory and assigns model-derived session log IDs. Its failure path suppresses finalization of already-created TRT sessions rather than disposing them.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs

InferenceSessionPool.csGuard pooled TensorRT RTX session teardown +16/-3

Guard pooled TensorRT RTX session teardown

• Stores the provider on each pool entry. Disposal of a TRT RTX entry now suppresses session finalization instead of invoking native session disposal; other providers retain normal disposal.

src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs

StageRuntimeRequirements.csExclude TensorRT families from VAD planning +7/-3

Exclude TensorRT families from VAD planning

• Routes silero-VAD away from both TensorRT providers to avoid its repeatedly failing TRT RTX engine build and misleading native stderr.

src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs

Tests (3) +105 / -58
GenAiTensorRtExclusionTests.csAssert VAD excludes both TensorRT providers +7/-5

Assert VAD excludes both TensorRT providers

• Replaces the prior TRT RTX admission assertion with checks that neither TensorRT family is allowed for VAD.

tests/Trackdub.Inference.Tests/GenAiTensorRtExclusionTests.cs

OnnxExecutionSessionFactoryTests.csCover the observed TRT error classification +80/-38

Cover the observed TRT error classification

• Adds the observed silero-VAD and Whisper error messages to classifier cases and tests single-session fallback with an injected shape-error message. Adjusts reflection-based test arguments for changed private method signatures; it does not test native teardown or Whisper's new retry loop.

tests/Trackdub.Inference.Tests/OnnxExecutionSessionFactoryTests.cs

RuntimePlannerTests.csAssert VAD plans around TensorRT +18/-15

Assert VAD plans around TensorRT

• Changes VAD planner expectations to DirectML or CUDA when TensorRT is available, and checks that TRT RTX smoke is not attempted. Updates the required-provider scenario to expect DirectML.

tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs

Documentation (1) +79 / -110
c13-trt-rtx-shape-triage-2026-10-05.mdAttribute the reported shape error to VAD +79/-110

Attribute the reported shape error to VAD

• Replaces the first-pass audit with reproduction and fallback evidence identifying silero-VAD as the source of the squeeze error. Records a separate Whisper-large-v3 OOM and access-violation finding, with issue-closure status left open.

docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md

Other (1) +722 / -0
packages.lock.jsonRecord Windows SDK test restore graph +722/-0

Record Windows SDK test restore graph

• Adds the net10.0 Windows target's resolved package and project dependency graph to the SDK test lockfile.

tests/Trackdub.Sdk.Tests/packages.lock.json

@amazon-q-developer

Copy link
Copy Markdown
Contributor

⚠️ Review Failed

I was unable to finalize my review because the pull request head or merge base was modified since I began my review. Please try again.

Request ID: 40ff7757-06cc-581a-b85b-1469c3c94548

@qodo-code-review

qodo-code-review Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (0) 🔗 Cross-repo conflicts (0) 📜 Skill insights (0)

Grey Divider


Action required

1. Failed decoder creation strands GPU memory ✓ Resolved
Description
SafeDisposeOnCreationFailure suppresses the finalizer of a previously created TensorRT-RTX encoder
without disposing that encoder. If decoder construction then throws, the retry starts another pair
of sessions while the encoder's native resources remain allocated.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R39-42]

+        if (provider is ExecutionProviderKind.TensorRTRtx)
+        {
+            GC.SuppressFinalize(session);
+        }
Relevance

●●● Strong

Native encoder resources are suppressed rather than disposed on decoder failure; cleanup precedent
strongly supports fixing this.

PR-#238
PR-#253

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Encoder construction precedes decoder construction, and both are passed to the new helper on
failure. The helper neither disposes nor permits finalization of a TensorRT-RTX encoder.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[36-47]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[594-624]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
A successfully constructed TensorRT-RTX encoder is abandoned when decoder initialization fails.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[36-47]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[594-624]
## Recommended Fix
Distinguish a healthy, fully constructed encoder from a poisoned native session and release healthy partial sessions before retry; provide a bounded strategy for sessions whose native teardown is unsafe.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


2. Desktop GPU sessions never release ✓ Resolved
Description
PoolEntry.Dispose calls GC.SuppressFinalize(Session) instead of Session.Dispose() for every
TensorRT-RTX entry, including healthy sessions, leaving native handles and VRAM allocated while the
pool counts their reservations as freed. In the gated desktop dubbing workload, budget and LRU
eviction, ephemeral release, explicit idle eviction, and shutdown all reach this path, increasing
memory pressure and the risk of out-of-memory failures across model switches and runs.
Code

src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[R281-283]

+                    // Suppress finalization to avoid calling native Session.Dispose() and keep the process alive safely.
+                    GC.SuppressFinalize(Session);
+                }
Relevance

●● Moderate

The leak is real for healthy sessions, but intentional suppression addresses an observed fatal
TensorRT teardown crash.

PR-#253

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The gated desktop sizes the shared ONNX pool for its multi-stage dubbing workload. The admission
loop disposes idle entries after crediting their reservations to make room for a new session, and
ephemeral release, explicit eviction, and pool shutdown also call PoolEntry.Dispose. Its
TensorRT-RTX branch suppresses finalization without calling Session.Dispose, even though ONNX
Runtime documents disposal as releasing the native session handle; those paths therefore stop
accounting for resources they have not released.

Trackdub -> Trackdub-gated
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[273-287]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[1588-1597]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[753-762]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[273-288]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[1384-1401]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[271-287]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[1354-1399]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[1640-1669]
External repo: trackdubllc/Trackdub-gated, src/Trackdub.App.Avalonia/Services/SessionPoolBootstrap.cs [3-36]
External repo: trackdubllc/Trackdub-gated, src/Trackdub.App.Avalonia/Program.cs [18-26]
🌐 InferenceSession holds a native session pointer; Dispose releases it, and the finalizer is its forgotten-disposal cleanup path.

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
`PoolEntry.Dispose` suppresses finalization rather than disposing every TensorRT-RTX session, including healthy sessions used by the gated desktop. Eviction and release consequently leave native resources and VRAM allocated while pool budget accounting assumes they were freed.

## Fix Focus Areas
- src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[271-288]
- src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[183-193]

## Recommended Fix
Call `Session.Dispose()` for healthy TensorRT-RTX sessions. If teardown must be avoided after an observed CUDA OOM or other native failure, explicitly mark the affected entry as poisoned and handle it separately; log any intentional leak and keep its reservation counted against the budget, or otherwise bound or isolate its resource lifetime. Verify that repeated desktop evictions release native resources.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Remediation recommended

3. Whisper fallback loses its failure reason ✓ Resolved
Description
CreateWhisperAsync saves the TensorRT-RTX exception in lastException but never incorporates it
into the successful retry's BootstrapDetail. A caller receiving a DirectML or CPU lease after
failed TensorRT-RTX initialization cannot see the failure that caused the downgrade.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R619-622]

+                if (currentProvider == ExecutionProviderKind.TensorRTRtx && LooksLikeTrtSessionInitFailure(ex))
+                {
+                    lastException = ex;
+                    continue;
Relevance

●●● Strong

Fallback precedent explicitly merges the original failure reason into successful fallback metadata.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The exception is retained only for a final throw, while metadata on success is built from the new
bootstrap and selections. The single-session fallback explicitly constructs and returns a reason for
the same transition.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[600-627]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[444-465]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
A successful Whisper retry omits the TensorRT-RTX initialization exception from returned diagnostics.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[600-622]
## Recommended Fix
Summarize the failed TensorRT-RTX attempt and merge it into the retry lease's bootstrap detail, following the single-session fallback's recorded-reason pattern.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


4. A failed fallback never reaches CPU ✓ Resolved
Description
CreateWhisperAsync retries only exceptions thrown by the TensorRT-RTX attempt; its catch rethrows
any exception from the DirectML attempt. On Windows, a recoverable DirectML session-creation failure
therefore exits before the CPU provider already present in providersToTry is attempted.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R619-624]

+                if (currentProvider == ExecutionProviderKind.TensorRTRtx && LooksLikeTrtSessionInitFailure(ex))
+                {
+                    lastException = ex;
+                    continue;
+                }
+                throw;
Relevance

●●● Strong

Existing fallback precedent continues across recoverable provider initialization failures instead of
rethrowing before CPU.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
CPU is added after DirectML in the retry list, but the catch permits continue only when the
current provider is TensorRT-RTX. The existing single-session fallback expressly handles recoverable
fallback-provider initialization failures.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[575-584]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[612-627]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[444-477]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The new Whisper fallback loop stops on a DirectML initialization failure instead of trying CPU.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[575-584]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[612-627]
## Recommended Fix
Continue to CPU for recoverable DirectML initialization failures, preserving the relevant failure details; propagate nonrecoverable failures.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


5. Fallback hides the requested provider ✓ Resolved
Description
CreateWhisperAsync fills WhisperSessionLease.RequestedProvider from the bootstrap of
currentProvider, not from the caller's original provider. After a TensorRT-RTX failure, a
successful DirectML or CPU retry reports that fallback as both the requested and selected route.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R605-610]

+                return new WhisperSessionLease(
+                    encoderSession,
+                    decoderSession,
+                    bootstrap.RequestedProviderLabel,
+                    FormatProviderLabel(metadata.SelectedProvider),
+                    metadata.BootstrapDetail);
Relevance

●●● Strong

Fallback metadata should preserve the caller’s requested provider separately from the effective
selected provider.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
Each iteration bootstraps currentProvider; the lease constructor receives that iteration's
requested label even though its requested-provider field is separate from the selected-provider
field.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[584-610]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[2347-2352]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Whisper fallback metadata labels the retry provider as the caller's requested provider.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[584-610]
## Recommended Fix
Capture the original request label before retrying and retain it in the returned lease while reporting the actual effective provider separately.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


View medium (5)
6. OOM fallback never runs in real use ✓ Resolved
Description
The new TensorRT-to-DirectML/CPU retry loop was added only to CreateWhisperAsync, which nothing in
the repository calls. Both the Whisper transcription engine and the smoke tester use
CreatePooledWhisperAsync, which was not changed, so the whisper-large-v3 out-of-memory path still
gets no fallback. The loop itself also has defects: when the decoder fails,
SafeDisposeOnCreationFailure only suppresses the finalizer of an already-built TensorRT encoder
session, leaking its VRAM before the DirectML retry. On success, the per-attempt SessionOptions
are never disposed, whereas the old code freed them with using. And the original TensorRT
exception is discarded, so the lease's labels and detail come from the fallback provider's bootstrap
with no record of why TensorRT failed.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R612-623]

+            catch (Exception ex)
+            {
+                SafeDisposeOnCreationFailure(encoderSession, currentProvider);
+                SafeDisposeOnCreationFailure(decoderSession, currentProvider);
+                selections.Encoder.Options.Dispose();
+                selections.Decoder.Options.Dispose();
+
+                if (currentProvider == ExecutionProviderKind.TensorRTRtx && LooksLikeTrtSessionInitFailure(ex))
+                {
+                    lastException = ex;
+                    continue;
+                }
Relevance

●●● Strong

Production callers use the pooled factory, so the new fallback loop does not cover the reported
Whisper path.

PR-#238
PR-#253

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
A search for CreateWhisperAsync( finds only its definition. The transcription engine and the smoke
tester both call CreatePooledWhisperAsync.

src/Trackdub.Inference.Onnx/Whisper/WhisperOnnxAudioTranscriptionEngine.cs[186-194]
src/Trackdub.Inference.Onnx/Runtime/Planning/OnnxExecutionProviderSmokeTester.cs[215-224]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[594-627]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The TensorRT fallback loop sits in `CreateWhisperAsync`, which has no callers. The production pooled path gets no fallback, and the loop leaks sessions and options and drops the TensorRT failure reason.

## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[572-628]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[901-945]

## Recommended Fix
Move the fallback logic, or reuse `CreateInferenceSessionWithTrtInitFallback`, in `CreatePooledWhisperAsync` and `AcquireDualPooledSessionsAsync`. Dispose `SessionOptions` on success. Do not leak a successfully created encoder session when the decoder fails. Pass the TensorRT exception message into the fallback reason and bootstrap detail, and keep the original requested provider label.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


7. Fallback sessions also escape cleanup ✓ Resolved
Description
new PoolEntry(session, key.Provider, ephemeral) records the pool key's provider rather than the
provider of the session returned by the factory. When TensorRT-RTX initialization falls back to
DirectML or CPU, the new teardown branch treats that fallback session as TensorRT-RTX and skips its
disposal too.
Code

src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[810]

+                var freshEntry = new PoolEntry(session, key.Provider, ephemeral);
Relevance

●●● Strong

PoolEntry records the requested key provider, which can misclassify sessions returned after provider
fallback.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The key is established before creation; the factory can replace its provider selection after a
TensorRT-RTX failure, but entry construction uses the unchanged key. The new provider-dependent
disposal branch consequently follows the wrong route.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[735-758]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[763-800]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[271-287]
src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[807-810]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
A pool entry can label a DirectML or CPU fallback session as TensorRT-RTX and apply the wrong cleanup behavior.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs[807-810]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[763-800]
## Recommended Fix
Carry the actual selected provider returned by session creation into the entry, independently of the pre-creation pool key, and test a TensorRT-RTX initialization fallback.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


8. The VAD test explains the old route ✓ Resolved
Description
PlanAsync_RequiredTensorRTRtxForVad_FallsBackToDmlSinceBlocked asserts DirectML but still says VAD
honors a required TensorRT RTX pin after smoke gating, and its warning assertion is commented out.
When VAD blocks TensorRT families, the test neither documents the fallback accurately nor checks
that the required pin is downgraded with a warning rather than silently.
Code

tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs[484]

+    public async Task PlanAsync_RequiredTensorRTRtxForVad_FallsBackToDmlSinceBlocked()
Relevance

●●● Strong

Recent precedents accept renaming/rewording tests when behavior changes and require comments to
match actual semantics.

PR-#170
PR-#354

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The renamed test and its DirectML assertion establish the current fallback behavior, while the
adjacent comment describes the former TensorRT RTX route. The commented-out warning assertion also
leaves PreferredExecutionProviderNotAllowedForEngine unchecked.

Rule 3659200: Keep XML docs and tests aligned with current behavior (rename/reword when semantics change)
tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs[484-487]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The VAD planner test expects a required TensorRT RTX request to fall back to DirectML, but its comment describes the previous route and its warning assertion is commented out.

## Fix Focus Areas
- tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs[484-514]

## Recommended Fix
Update the comment to explain that VAD excludes TensorRT families and demotes a required TensorRT RTX request to DirectML. Restore the warning check as `Assert.Contains(plan.Warnings, w => w.Code == RuntimePlanWarningCode.PreferredExecutionProviderNotAllowedForEngine);`.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


9. VAD loses classic TensorRT routing ✓ Resolved
Description
WithoutTensorRtFamilies removes both TensorRT-RTX and classic TensorRT from VAD's allowed
providers. The documented squeeze failure is specific to TensorRT-RTX, so a VAD plan that previously
selected available classic TensorRT now selects another provider even though its separate provider
implementation remains supported.
Code

src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs[63]

+                WithoutTensorRtFamilies(DefaultOnnxStageAllowedProviders),
Relevance

●●● Strong

The change excludes classic TensorRT despite evidence and intent targeting TensorRT-RTX
specifically.

PR-#253

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The applied helper removes both provider kinds; the updated planner test confirms that classic
TensorRT availability now results in CUDA selection. The audit identifies TensorRT-RTX, rather than
classic TensorRT, as the failing provider.

src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs[39-63]
tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs[160-185]
docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md[15-20]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The VAD rule disables classic TensorRT alongside the TensorRT-RTX provider implicated by the reported shape error.
## Fix Focus Areas
- src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs[39-63]
- tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs[160-185]
## Recommended Fix
Remove only TensorRT-RTX from VAD's allowed providers unless there is separate evidence for excluding classic TensorRT; keep a planner test for the classic route.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


10. Successful Whisper setup leaks options ✓ Resolved
Description
CreateWhisperAsync creates two SessionOptions objects per attempt but disposes them only in its
exception handler. Every successful return leaves both options undisposed, whereas the neighboring
dual-session factory scopes its options with using.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R605-608]

+                return new WhisperSessionLease(
+                    encoderSession,
+                    decoderSession,
+                    bootstrap.RequestedProviderLabel,
Relevance

●●● Strong

Successful dual-session returns bypass SessionOptions disposal, contrary to established factory
ownership patterns.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The newly introduced return precedes the only options disposal statements; CreateOpusAsync
demonstrates the existing scoped-ownership pattern.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[584-618]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[637-650]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Successful Whisper session creation does not dispose either set of session options.
## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[584-618]
## Recommended Fix
Give each retry attempt scoped ownership of both SessionOptions so they are disposed on success and failure after session construction.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools



Informational

11. Log label option reaches no real session 🐞 Bug ⚙ Maintainability
Description
A logId parameter was added to CreateTensorRtRtxSelection,
AppendTensorRtRtxOrFallbackProvider, BuildTensorRtRtxOptions, BuildSessionOptionsFingerprint,
CreateSessionOptionsSelection (or its equivalent) and BuildDualPooledKeysAsync, but none of them
forward or read it. The only call site that sets a value is the uncalled CreateWhisperAsync, so
production sessions still get an empty SessionOptions.LogId. Anyone reading these signatures will
assume native log labelling is wired through when it is not, and the tests had to grow an extra
null reflection argument for parameters that do nothing.
Code

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[R1514-1517]

+        bool enableCudaGraph = false, string? logId = null)
    {
        ExecutionProviderKind selectedProvider =
            AppendTensorRtRtxOrFallbackProvider(options, additionalTrtOptions, enableCudaGraph);
Relevance

●● Moderate

Production log IDs remain absent, but the parameter is partially forwarded and applied by the base
options builder.

PR-#238

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The diff shows CreateTensorRtRtxSelection calling `AppendTensorRtRtxOrFallbackProvider(options,
additionalTrtOptions, enableCudaGraph)` without passing logId, and the fingerprint and options
builders gain the parameter without using it. The only caller that supplies logIds is
CreateWhisperAsync, which has no callers.

src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[1511-1520]
src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[586-592]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The new `logId` parameters are ignored by most of the helpers that accept them, and only an uncalled method supplies a value.

## Fix Focus Areas
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[1460-1520]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[1848-1852]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[1957-1961]
- src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs[2030-2034]

## Recommended Fix
Remove `logId` from the helpers that do not use it, and revert the matching test reflection changes. Then pass logIds from the pooled and single-session creation paths that actually run, so `CreateBaseSessionOptions` sets `LogId` for real sessions.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Dismiss ↗ | View ↗


Grey Divider

Context sources
✅ Compliance rules (platform): 4 rules
✅ Web pages:
  +2 more
✅ Cross-repo context — repo relationships
  Explored: repo: trackdubllc/Trackdub-gated (branch: triage_trt_rtx_tts, sha: 8b48f2a1) — View relationship
✅ REVIEW.md
Review mode: Auto: 🧠 Deep: Dense inference changes span fallback, disposal, planning, logging, and multiple test paths.

Grey Divider

Tip of the day
💡 Did you know, you can add REVIEW.md to your repo root and Qodo follows it on every PR

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

Comment thread tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs
Comment thread src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference/Runtime/Planning/StageRuntimeRequirements.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs Outdated
@qodo-code-review

Copy link
Copy Markdown
Contributor

Qodo Fixer

🍒 Ready to be cherry-picked — ✅ Merged (0) · ☑ Fixed (2)

Grey Divider

🔗 Fix PR: #383

This fix PR was closed automatically. Its branch is preserved so you can cherry pick the changes into the original PR.

Prompt for coding agent

This is an automated fix prepared on a separate branch (#383). It is NOT applied to this PR.
To use it: review Fix PR #383 (https://github.com/trackdubllc/Trackdub/pull/383), evaluate each change critically against your local context, and cherry-pick the changes that are correct into this branch. Do not accept them blindly.
Process — 2 fixed
  • ☑ Fixed: Failed decoder creation strands GPU memory
  • ☑ Fixed: Desktop GPU sessions never release

@tonythethompson
tonythethompson requested a balanced review from Copilot October 6, 2026 09:47

@tonythethompson tonythethompson left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Review on 2b3aada. The VAD planner exclusion and the new classifier cases look right. The main concerns are in the teardown and Whisper fallback changes; details inline. Two required checks are also red on this head: Verify Code Format (whitespace in RuntimePlannerTests.cs 511-513 and OnnxExecutionSessionFactory.cs) and Verify Release Restore & Diagnostics-Free Shipping (locked-mode restore of Trackdub.Sdk.Tests fails, see the lock-file thread).

Comment thread src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs Outdated
Comment thread tests/Trackdub.Sdk.Tests/packages.lock.json Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

The production pooled Whisper path remains unchanged, while the teardown workaround can leak healthy or fallback sessions and retain GPU memory.

Review effort: Balanced
Findings: 1 High severity · 5 Medium severity

Open (6)
What changed in this PR

Hardens ONNX runtime routing and teardown after TRT-RTX failures identified in #329.

Changes:

  • Routes VAD around TensorRT providers.
  • Adds Whisper fallback and log attribution plumbing.
  • Avoids TRT-RTX pooled-session teardown and documents triage findings.
File Description
src/​Trackdub.Inference/​Runtime/​Planning/​StageRuntimeRequirements.cs Excludes TensorRT for VAD.
src/​Trackdub.Inference.Onnx/​OnnxExecutionSessionFactory.cs Adds Whisper fallback and LogIds.
src/​Trackdub.Inference.Onnx/​Pool/​InferenceSessionPool.cs Changes TRT-RTX disposal behavior.
tests/​Trackdub.Inference.Tests/​RuntimePlannerTests.cs Updates VAD routing tests.
tests/​Trackdub.Inference.Tests/​OnnxExecutionSessionFactoryTests.cs Extends TRT failure classification tests.
tests/​Trackdub.Inference.Tests/​GenAiTensorRtExclusionTests.cs Verifies VAD exclusions.
tests/​Trackdub.Sdk.Tests/​packages.lock.json Adds the Windows target lock graph.
docs/​audits/​c13-trt-rtx-shape-triage-2026-10-05.md Records updated #329 findings.

💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs Outdated

@opencode-agent opencode-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Automated review: 3 inline finding(s); the summary follows as a comment.

Comment thread src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs Outdated
@opencode-agent

opencode-agent Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Review submitted — 3 inline findings on PR #380.

Overall: the TRT-RTX triage changes are mostly sound (VAD planner exclusion, Whisper session-init fallback chain, LogId plumbing, and regression tests all look correct), but one resource-lifecycle change is too broad and worth addressing before merge.

Inline findings:

  • src/Trackdub.Inference.Onnx/Pool/InferenceSessionPool.cs:289-300 — important · TRT dispose-suppression leaks native memory for all healthy pooled sessions, not just poisoned ones.
  • src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs:605-610 — suggestion · CreateWhisperAsync reports the effective provider as requested on fallback (diverges from CreateSingleAsync).
  • tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs:511-513 — suggestion · commented-out assertion dead code; warning behavior no longer asserted.

Out of diff: none.

github run

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
Comment thread docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md Outdated
Comment thread tests/Trackdub.Inference.Tests/RuntimePlannerTests.cs
Comment thread docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md Outdated
Comment thread docs/audits/c13-trt-rtx-shape-triage-2026-10-05.md Outdated
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs
Comment thread src/Trackdub.Inference.Onnx/OnnxExecutionSessionFactory.cs Outdated
@tonythethompson
tonythethompson removed this pull request from stack #381 October 6, 2026 09:54
@tonythethompson

Copy link
Copy Markdown
Contributor Author

/oc fix

@opencode-agent

opencode-agent Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

I've completed my analysis of the delta since the previous review (head 2b3aada → cc3bc36).

Assessment

This delta is a CI-fix commit addressing two previously-red required checks: Verify Code Format (trailing whitespace) and Verify Release Restore & Diagnostics-Free Shipping (locked-mode NU1004). The three changes are:

  1. OnnxExecutionSessionFactory.cs:590 — Removed trailing whitespace on a blank line inside CreateWhisperAsync. Pure formatting fix, no behavior change.

  2. RuntimePlannerTests.cs:511-513 — Re-indented the commented-out Assert.DoesNotContain block from column 0 to 8 spaces to satisfy the format checker. The dead code and the missing PreferredExecutionProviderNotAllowedForEngine warning assertion were both already flagged by the prior review (cubic, qodo, opencode-agent, copilot). The stale comment at lines 486-487 (which contradicts the renamed test) was also already flagged and is on unchanged lines. This delta is purely cosmetic and does not introduce new issues, though the substantive feedback remains unaddressed.

  3. packages.lock.json — Removed the net10.0-windows10.0.19041 target block (722 lines) that was inadvertently added by an earlier commit. The csproj conditionally targets Windows only on Windows_NT (<TargetFrameworks Condition="'$(OS)' == 'Windows_NT'">net10.0;net10.0-windows10.0.19041.0</TargetFrameworks> vs net10.0 elsewhere), so the lock file correctly records only net10.0 for non-Windows CI. This restores the original committed baseline and fixes the Linux NU1004 failure, matching the prior review's recommendation to "drop this hunk."

No new noteworthy issues found. The changes are correct CI fixes that don't introduce regressions. The previously-posted substantive findings (VAD test dead code / missing warning assertion, stale comment, and the broader Whisper fallback/disposal concerns) remain open from the prior review.

github run

Copy link
Copy Markdown
Contributor Author

Addressed the open review threads (commits 9cf592d, 3717f71) and resolved them:

  • Teardown scope: native teardown is skipped only for TensorRT RTX sessions while the runtime is poisoned by an observed CUDA OOM (TensorRtRtxTeardownGuard). Healthy sessions and DirectML/CPU fallbacks created under a TRT pool key now dispose normally, so eviction and shutdown release VRAM. The effective provider is tracked per session, not taken from the pool key.
  • Whisper fallback: moved the TensorRT RTX → DirectML (Windows) → CPU chain into CreatePooledWhisperAsync, the path production actually calls (CreateWhisperAsync has no callers). It keeps the original requested-provider label, records why each provider was abandoned in BootstrapDetail, and continues past a failed DirectML attempt to CPU. CreateWhisperAsync is back to its using-scoped single attempt, so no SessionOptions leak. New tests cover the chain and the guard.
  • VAD: excludes only TensorRT RTX; classic TensorRT stays allowed. The planner test asserts the skip warning again and the classic-TensorRT-before-CUDA test is restored.
  • logId: removed the parameters no helper read; ExtractLogId keeps the file name so encoder and decoder differ. The pooled Whisper path now passes them; wiring the single-session path is noted as a follow-up in the audit doc.
  • CI: restored the Sdk.Tests lock file (NU1004) and fixed the whitespace format failures.
  • Audit doc: --prefer-gpu row is PARTIAL, the Dispose crash is a separate follow-up rather than a reopen of Investigate: TensorRT RTX build-time shape error on TTS under --prefer-gpu — does the EP fallback cover it? #329, local user path redacted, whisper-large-v3 row clarified.

Generated by Claude Code

@opencode-agent

opencode-agent Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

I've completed a thorough review of the delta since the previous review (head 2b3aada → 3717f71). This delta addresses all three prior inline findings:

  1. Pool teardown leakage — The broad GC.SuppressFinalize for every TRT-RTX pool entry is replaced by TensorRtRtxTeardownGuard.DisposeSafely, which only skips native teardown for tracked TRT-RTX sessions when the runtime is poisoned by a CUDA OOM. Healthy sessions and DirectML/CPU fallback sessions dispose normally. PoolEntry no longer stores Provider, eliminating the misclassification risk where a fallback session could be treated as TRT-RTX.

  2. Requested-provider misreport — The fallback chain moved from the uncalled CreateWhisperAsync to CreatePooledWhisperAsync (the production path). The lease now uses requestedProvider (the original label) as the requested field and FormatProviderLabel(pair.SelectedProvider) as the effective field, with the failure reason merged into BootstrapDetail. CreateWhisperAsync is back to a single using-scoped attempt (no SessionOptions leak).

  3. Commented-out assertion — The PreferredExecutionProviderNotAllowedForEngine warning assertion is restored as a positive Assert.Contains, the stale comment is updated, and the VAD planner now excludes only TensorRT-RTX (keeping classic TensorRT allowed).

Additional improvements verified: ExtractLogId now includes the file name so encoder/decoder LogIds differ; the logId parameters were removed from helpers that ignored them; the pooled Whisper path passes log IDs through to CreateBaseSessionOptions; the fallback catch continues past a failed DirectML attempt to CPU (via IsRecoverableTrtFallbackInitFailure); new tests cover the pooled fallback chain, the teardown guard's classification/tracking, and the VAD exclusion keeping classic TensorRT; and the packages.lock.json Windows target block was removed (NU1004 fix).

The known trade-offs (poisoned-session VRAM leak as crash containment, single-session LogId as a documented follow-up) are acknowledged in the audit and are not actionable findings for this review.

No noteworthy issues found.

github run

@tonythethompson
tonythethompson added this pull request to stack #387 October 6, 2026 14:49
@opencode-agent

opencode-agent Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

No noteworthy issues found.

I reviewed the delta since the previous review (review_base 2b3aada → head 80d51ead), which is the per-adapter GPU memory admission feature layered on top of the already-reviewed TRT-RTX triage changes. The diff spans 28 files including new per-adapter attribution in InferenceSessionPool, a WindowsProcessGpuMemoryReader LUID parser, shared-pool composition binding for both HeadlessDubbingHost and the SDK TrackdubBuilder, a GpuPeakMonitor seed-degradation fix, and supporting tests.

I focused discovery on the two highest-risk boundaries:

  • Per-adapter admission correctness — ObservedProcessGpuUsageMb's adapter-LUID branch charges only this adapter's real footprint, and AdmissionUsageMb uses Math.Max(reserved, observed + pending) (not a sum) so pooled reservations already counted in the observation aren't double-charged. The unattributed flag withholds the breakdown when any instance can't be parsed, and the OverflowException catch in QueryObservation covers the checked() LUID arithmetic edge. The BucketHasLiveEntries pending-create addition and the hadLiveEntries stall-counter reset correctly avoid both starvation and premature fail-fast.
  • Composition binding lifecycle — the adapter-map binding helper is double-nested try/catch, so it cannot throw after the reader binding succeeds (no leaked SharedPoolOptions registration). TryClear* atomicity prevents an older host from tearing down a newer one. GpuPeakMonitor's realSamples correctly distinguishes a seed-only result (returns null with reason) from a real interval sample.

Both hypotheses were falsified by the code's defensive design, and no concrete defect survived validation.

github run

Base automatically changed from benchmark-telemetry to main October 6, 2026 16:29
claude added 3 commits October 6, 2026 09:29
- dotnet format whitespace on OnnxExecutionSessionFactory.cs and RuntimePlannerTests.cs.
- Restore tests/Trackdub.Sdk.Tests/packages.lock.json to the base version; the committed copy
  lacked the net10.0-windows target and broke locked-mode restore (NU1004). No dependency change.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RHbD2BCGvKqVEiVFpTB6rn
…llback, VAD scope

- Skip native teardown only for TensorRT RTX sessions while the runtime is poisoned by an observed
  CUDA OOM (TensorRtRtxTeardownGuard); healthy and fallback sessions dispose normally, so eviction
  and shutdown release VRAM. PoolEntry tracks the effective provider through the guard, not the key.
- Move the TensorRT RTX -> DirectML -> CPU Whisper fallback into CreatePooledWhisperAsync, the path
  production uses; keep the requested provider label and record why each provider was abandoned.
  Restore CreateWhisperAsync to its using-scoped single attempt (no leaked SessionOptions).
- VAD excludes only TensorRT RTX (classic TensorRT stays allowed); restore the skip-warning assertion
  and the classic-TensorRT-before-CUDA planner test.
- Drop logId parameters that no helper reads; ExtractLogId keeps the file name so encoder and
  decoder get distinct ids.
- Tests for the guard and the pooled fallback chain.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RHbD2BCGvKqVEiVFpTB6rn
…rash follow-up

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RHbD2BCGvKqVEiVFpTB6rn
@tonythethompson
tonythethompson removed this pull request from stack #387 October 6, 2026 16:29
@opencode-agent

opencode-agent Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

No noteworthy issues found.

github run

@tonythethompson
tonythethompson merged commit 49cb422 into main Oct 6, 2026
22 checks passed
@tonythethompson
tonythethompson deleted the triage_trt_rtx_tts branch October 6, 2026 16:53
tonythethompson pushed a commit that referenced this pull request Oct 6, 2026
Main now carries #374, #380 and #382, which independently introduced the CLI
binder, the working-set monitor factory, typed evidence memory and the GPU
capture constructor this branch also built. Conflicts are resolved toward main
everywhere it is a superset (monitor factory with SamplingWarning, injected
monitorFactory, GPU capture constructor, typed StageGarbageCollection, docs).
The one exception is ControlledBenchmarkCliBinder and its tests: this branch
keeps the empty/option-looking value handling that main lacks.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RHbD2BCGvKqVEiVFpTB6rn
tonythethompson pushed a commit that referenced this pull request Oct 6, 2026
Main now carries #374, #380 and #382, which independently built the CLI binder,
monitor factory, typed evidence and sampling-warning code this branch also has.
Conflicts resolve toward main wherever it is a superset (docs, GPU capture
constructor, DefaultSamplingInterval, production-cadence test, typed memory).
This branch keeps what main lacks: the sampling ticker's LastTickTimestamp, so
dilation tests measure scripted gaps instead of wall-clock, and skipping the
capacity query when no VRAM floor is configured.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RHbD2BCGvKqVEiVFpTB6rn
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.

3 participants