Skip to content

Add PatchTST-FM support for levels#331

Open
spolisar wants to merge 21 commits intomainfrom
feat/patchtst-levels
Open

Add PatchTST-FM support for levels#331
spolisar wants to merge 21 commits intomainfrom
feat/patchtst-levels

Conversation

@spolisar
Copy link
Copy Markdown
Contributor

@spolisar spolisar commented Mar 26, 2026

Adds support for levels when using PatchTST-FM.

The quantile fix for #328 resolved the main issue that occurred when adding level support for PatchTST-FM, all that was left is removing a couple lines.

This should close #316.

TODO:

@spolisar spolisar linked an issue Mar 26, 2026 that may be closed by this pull request
@spolisar spolisar requested a review from AzulGarza March 27, 2026 16:58
@AzulGarza AzulGarza marked this pull request as ready for review April 20, 2026 21:42
Copilot AI review requested due to automatic review settings April 20, 2026 21:42
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 enables level-based prediction intervals for the PatchTST-FM foundation model by removing the explicit guard that previously rejected level, and updates the model-level tests accordingly.

Changes:

  • Remove ValueError that blocked level in PatchTST-FM’s forecast().
  • Update test_using_level so PatchTST-FM is no longer treated as a “levels unsupported” model.
  • Modify pyproject.toml optional dependency declarations (currently introduces a duplication issue).

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

File Description
timecopilot/models/foundation/patchtst_fm.py Removes the hard-coded rejection of level to allow interval outputs via QuantileConverter.
tests/models/test_models.py Updates the “levels unsupported” model list to include PatchTST-FM in the positive path.
pyproject.toml Adds a duplicated [project.optional-dependencies] table (needs correction).

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

Comment thread pyproject.toml Outdated
Copy link
Copy Markdown
Member

@AzulGarza AzulGarza left a comment

Choose a reason for hiding this comment

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

thanks, lgtm!

@AzulGarza AzulGarza self-requested a review April 20, 2026 21:45
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.

Support levels for PatchTST-FM

3 participants