Skip to content

Comments

Fix BatchPostProcess losing init arg types#991

Merged
nkaenzig merged 4 commits intomainfrom
990-batchpostprocess-instantiation-logic-loses-init-arg-types
Feb 13, 2026
Merged

Fix BatchPostProcess losing init arg types#991
nkaenzig merged 4 commits intomainfrom
990-batchpostprocess-instantiation-logic-loses-init-arg-types

Conversation

@nkaenzig
Copy link
Collaborator

@nkaenzig nkaenzig commented Feb 11, 2026

Closes #990

Summary

  • Remove dict-based transform initialization from BatchPostProcess to fix type coercion bug where non-string args (e.g., booleans) were passed as strings
  • Add dim and keepdim parameters to AsDiscrete transform
  • Update ExtractAnswer and ExtractDiscreteAnswer factories to use __init__ + __call__ pattern for proper jsonargparse validation

@nkaenzig nkaenzig linked an issue Feb 11, 2026 that may be closed by this pull request
@nkaenzig nkaenzig added the bug Something isn't working label Feb 12, 2026
@nkaenzig nkaenzig self-assigned this Feb 12, 2026
@nkaenzig nkaenzig requested a review from MaxFeucht February 12, 2026 09:46
Copy link
Collaborator

@MaxFeucht MaxFeucht left a comment

Choose a reason for hiding this comment

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

LGTM with one comment

@nkaenzig nkaenzig enabled auto-merge (squash) February 13, 2026 12:02
@nkaenzig nkaenzig merged commit b6a1b38 into main Feb 13, 2026
8 checks passed
@nkaenzig nkaenzig deleted the 990-batchpostprocess-instantiation-logic-loses-init-arg-types branch February 13, 2026 12:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

BatchPostProcess instantiation logic loses init arg types

2 participants