Skip to content

[FSTORE-1911] Improving API Docs for Transformation Functions.#748

Open
manu-sj wants to merge 7 commits into
logicalclocks:mainfrom
manu-sj:FSTORE-1911
Open

[FSTORE-1911] Improving API Docs for Transformation Functions.#748
manu-sj wants to merge 7 commits into
logicalclocks:mainfrom
manu-sj:FSTORE-1911

Conversation

@manu-sj
Copy link
Copy Markdown
Contributor

@manu-sj manu-sj commented Dec 3, 2025

This PR adds/fixes/changes...

  • please summarize your changes to the code
  • and make sure to include all changes to user-facing APIs

JIRA Issue: -

Priority for Review: -

Related PRs: -

How Has This Been Tested?

  • Unit Tests
  • Integration Tests
  • Manual Tests on VM

Checklist For The Assigned Reviewer:

- [ ] Checked if merge conflicts with master exist
- [ ] Checked if stylechecks for Java and Python pass
- [ ] Checked if all docstrings were added and/or updated appropriately
- [ ] Ran spellcheck on docstring
- [ ] Checked if guides & concepts need to be updated
- [ ] Checked if naming conventions for parameters and variables were followed
- [ ] Checked if private methods are properly declared and used
- [ ] Checked if hard-to-understand areas of code are commented
- [ ] Checked if tests are effective
- [ ] Built and deployed changes on dev VM and tested manually
- [x] (Checked if all type annotations were added and/or updated appropriately)

@manu-sj manu-sj changed the title [FSTORE-1911] Improving docs for Transformation Functions. [FSTORE-1911] Improving API Docs for Transformation Functions. Dec 3, 2025
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nope, the API reference is controlled via the @public decorator in hopsworks-api. These files should be removed. To link to the API Reference, use the import path in square brackets:

[`@udf`][hsfs.hopsworks_udf.udf]

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This file should be in the concept section (or maybe guide) in logicalclocks.github.io (or a part of a docstring).

docs folder was removed from hopsworks-api.


Transforms each value using the formula:

scaled = (value - min) / (max - min)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Better to use ```python instead of indentation-based code blocks.


where `min` and `max` are computed from the training dataset.
This transformation is useful for features that need to be bounded within a specific range,
particularly for algorithms sensitive to feature scales (e.g., neural networks, KNN).
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Sentence per line is to be used for clearer git diff and blame.

Returns:
Scaled feature values in the range [0, 1].

See Also:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

There is no such admonition. You can use:

Tip: See Also
    ...

Dictionary mapping transformed feature names to callable functions.

See Also:
- [`transform()`][hsfs.feature_view.FeatureView.transform]: Apply all transformations to a feature vector.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [`transform()`][hsfs.feature_view.FeatureView.transform]: Apply all transformations to a feature vector.
- [`FeatureView.transform`][hsfs.feature_view.FeatureView.transform]: Apply all transformations to a feature vector.


See Also:
- [`TransformationType.MODEL_DEPENDENT`][hsfs.transformation_function.TransformationType]: Transformation type description.
- [`on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: On-demand transformations from feature groups.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [`on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: On-demand transformations from feature groups.
- [`FeatureView.on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: On-demand transformations from feature groups.

List of parameter names required by on-demand transformations.

See Also:
- [`on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: The on-demand transformation functions.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [`on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: The on-demand transformation functions.
- [`FeatureView.on_demand_transformations`][hsfs.feature_view.FeatureView.on_demand_transformations]: The on-demand transformation functions.

Dictionary mapping on-demand feature names to callable functions.

See Also:
- [`compute_on_demand_features()`][hsfs.feature_view.FeatureView.compute_on_demand_features]: Compute all on-demand features.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [`compute_on_demand_features()`][hsfs.feature_view.FeatureView.compute_on_demand_features]: Compute all on-demand features.
- [`FeatureView.compute_on_demand_features`][hsfs.feature_view.FeatureView.compute_on_demand_features]: Compute all on-demand features.


See Also:
- [`compute_on_demand_features()`][hsfs.feature_view.FeatureView.compute_on_demand_features]: Compute all on-demand features.
- [`request_parameters`][hsfs.feature_view.FeatureView.request_parameters]: Parameters needed for on-demand computation.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
- [`request_parameters`][hsfs.feature_view.FeatureView.request_parameters]: Parameters needed for on-demand computation.
- [`FeatureView.request_parameters`][hsfs.feature_view.FeatureView.request_parameters]: Parameters needed for on-demand computation.

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