Skip to content

[ENH] class based tag system (#767)#770

Open
Abhishek9639 wants to merge 4 commits intosktime:mainfrom
Abhishek9639:Abhishek
Open

[ENH] class based tag system (#767)#770
Abhishek9639 wants to merge 4 commits intosktime:mainfrom
Abhishek9639:Abhishek

Conversation

@Abhishek9639
Copy link

Reference Issues/PRs

Fixes #767

What does this implement/fix? Explain your changes.

Replaces skpro's legacy list-of-tuples tag register with a class-based tag system, matching sktime's architecture. Each tag is now a _BaseTag subclass with docstrings. The OBJECT_TAG_REGISTER is auto-constructed via introspection at module bottom. Fully backward compatible.

Does your contribution introduce a new dependency? If yes, which one?

No

What should a reviewer concentrate their feedback on?

  • Whether the _BaseTag class structure matches sktime's pattern correctly
  • Whether all 37 tags are accurately converted from the original tuples
  • Whether the auto-construction logic at the bottom of _tags.py is clean

Did you add any tests for the change?

Yes, added two new tests:

  • test_base_tag_classes: validates all _BaseTag subclasses have required keys
  • test_tag_register_matches_classes: ensures class-to-register consistency

Any other comments?

This is a prerequisite for #768 (tag documentation). The existing test test_tag_register_type also passes unchanged, confirming backward compatibility.

PR checklist

  • The PR title starts with either [ENH], [MNT], [DOC], or [BUG]. [BUG] - bugfix, [MNT] - CI, test framework, [ENH] - adding or improving code, [DOC] - writing or improving documentation or docstrings.

@Abhishek9639
Copy link
Author

Hi @fkiraly and @felipeangelimvieira,
I have addressed the issue and pushed the latest changes.
Whenever you get time, could you please review the PR and share your feedback?
Thank you!

@fkiraly fkiraly added enhancement module:base-framework BaseObject, registry, base framework labels Feb 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement module:base-framework BaseObject, registry, base framework

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[ENH] class based tag system

2 participants