Skip to content

fix(text-embeddings): compare text_encoder_norm_type case-insensitively#504

Open
James D. Finlon (jim-finlon) wants to merge 1 commit into
Lightricks:masterfrom
jim-finlon:dna/text-encoder-norm-type-casefold-test
Open

fix(text-embeddings): compare text_encoder_norm_type case-insensitively#504
James D. Finlon (jim-finlon) wants to merge 1 commit into
Lightricks:masterfrom
jim-finlon:dna/text-encoder-norm-type-casefold-test

Conversation

@jim-finlon

Copy link
Copy Markdown

Summary

  • compare string config values case-insensitively for dual-aggregate text embedding config validation
  • keep non-string expected values strict so boolean checks do not become string-coercion checks
  • add a pytest covering both 'per_token_rms' and 'PER_TOKEN_RMS'

Context

This covers the same distilled checkpoint failure mode as #478, but includes pytest coverage and keeps non-string config validation strict.

Validation

  • python -m pytest --rootdir=/tmp/comfyui-ltxvideo-dna-pr.bRrNmp/tests /tmp/comfyui-ltxvideo-dna-pr.bRrNmp/tests/test_text_embeddings_config_validation.py -q
  • PYTHONPATH=/tmp/dna-black-24.4.2 python -m black --check text_embeddings_connectors.py tests/test_text_embeddings_config_validation.py

LTX-2.3 distilled checkpoints can serialize text_encoder_norm_type as PER_TOKEN_RMS while the expected value is per_token_rms. Compare string config values case-insensitively while keeping non-string expectations strict.

Add pytest coverage for both casings and strict non-string behavior.
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