Skip to content

Conversation

@dfalbel
Copy link
Member

@dfalbel dfalbel commented Oct 29, 2025

No description provided.

@dfalbel dfalbel requested a review from Copilot October 29, 2025 20:26
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds support for passing additional arguments to custom predict methods in fitted luz modules. Previously, the ... parameter was documented as unused but is now utilized to forward arguments to custom predict functions.

Key changes:

  • Modified predict.luz_module_fitted to extract and forward additional arguments (excluding stack) to the predict function
  • Added a new test to verify that additional arguments are correctly passed to custom predict methods

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
R/module.R Updated predict logic to extract the stack parameter separately and forward remaining arguments via do.call
tests/testthat/test-module.R Added test case verifying custom predict methods can receive additional arguments like scale
Comments suppressed due to low confidence (1)

R/module.R:377

  • The documentation states that ... is 'Currently unused', but the implementation now uses these parameters to pass additional arguments to custom predict methods. Update the documentation to describe that additional parameters can be passed to custom predict methods.
#' @param ... Currently unused.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@dfalbel dfalbel merged commit b563e70 into main Oct 29, 2025
12 of 14 checks passed
@dfalbel dfalbel deleted the pass-predict-args branch October 29, 2025 21:08
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.

2 participants