Skip to content

refactor(libsy): move escalation router into its own module - #507

Draft
afourniernv wants to merge 1 commit into
NVIDIA-NeMo:mainfrom
afourniernv:codex/switch-1276-escalation-module
Draft

refactor(libsy): move escalation router into its own module#507
afourniernv wants to merge 1 commit into
NVIDIA-NeMo:mainfrom
afourniernv:codex/switch-1276-escalation-module

Conversation

@afourniernv

Copy link
Copy Markdown
Contributor

What

Moves the escalation classifier implementation and its focused tests from llm_class.rs into algorithms/escalation.rs.

LlmTaskClassifier continues to own the shared route shell and delegates escalation-specific classifier construction to the new private module.

Why

The escalation router was embedded in the much larger LLM classifier module, making the implementation and its tests harder to find. Giving it a dedicated algorithm file makes the routing implementations visible from crates/libsy/src/algorithms and narrows the responsibility of llm_class.rs.

Linear: SWITCH-1276

How tested

  • cargo fmt --all --check
  • cargo test -p switchyard-libsy — 259 passed
  • cargo clippy -p switchyard-libsy --all-targets -- -D warnings
  • RUSTDOCFLAGS='-D warnings' cargo doc -p switchyard-libsy --no-deps

Checklist

  • Escalation unit tests moved with the implementation.
  • No new public symbols or exports.
  • No customer-facing configuration or documentation changes.
  • Commit signed off for DCO.

Notes for reviewers

This is intended to be a structural-only change. LlmClassifierConfig::Escalation, LlmTaskClassifier, crate-root exports, target ordering, classifier behavior, and the TOML interface remain unchanged. The new module is private; llm_class.rs delegates construction through a crate-internal helper.

Signed-off-by: Alex Fournier <afournier@nvidia.com>
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.

1 participant