Skip to content

refactor auto_round api, using local symbol table to pass all args#1358

Merged
n1ck-guo merged 1 commit intomainfrom
hengguo/refactor_ar_api
Jan 29, 2026
Merged

refactor auto_round api, using local symbol table to pass all args#1358
n1ck-guo merged 1 commit intomainfrom
hengguo/refactor_ar_api

Conversation

@n1ck-guo
Copy link
Copy Markdown
Contributor

@n1ck-guo n1ck-guo commented Jan 28, 2026

Description

refactor auto_round api, using local symbol table to pass all args

Type of Change

  • Bug fix
  • New feature
  • Documentation update
  • Performance improvement
  • Code refactoring
  • Other (please specify):

Related Issues

Fixes or relates to #

Checklist Before Submitting

  • My code has been tested locally.
  • Documentation has been updated as needed.
  • New or updated tests are included where applicable.

Copilot AI review requested due to automatic review settings January 28, 2026 06:05
Signed-off-by: n1ck-guo <heng.guo@intel.com>
Copy link
Copy Markdown
Contributor

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 refactors the AutoRound API by replacing explicit parameter passing with a local symbol table approach. The change simplifies method signatures by capturing local variables with locals() and unpacking them using **local_args, eliminating the need to explicitly list all parameters when calling parent class constructors.

Changes:

  • Introduced SKIP_ARGS constant to exclude internal variables from local argument collection
  • Replaced explicit parameter passing in __new__ and multiple __init__ methods with **local_args unpacking
  • Fixed a spelling error in documentation ("s" suffix removed)

Copy link
Copy Markdown
Contributor

@yiliu30 yiliu30 left a comment

Choose a reason for hiding this comment

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

Overall LGTM

@n1ck-guo n1ck-guo merged commit 528c9c8 into main Jan 29, 2026
29 checks passed
@n1ck-guo n1ck-guo deleted the hengguo/refactor_ar_api branch January 29, 2026 02:40
lvliang-intel pushed a commit that referenced this pull request Jan 29, 2026
lvliang-intel pushed a commit that referenced this pull request Feb 2, 2026
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