Skip to content

Conversation

@Omswastik-11
Copy link

@Omswastik-11Omswastik-11 commented Dec 24, 2025

initially

importsklearnimportopenmlclf=KNeighborsClassifier(n_neighbors=3) clf.fit(X_train, y_train) # Verbose manual flow construction requiredknn_flow=openml.flows.OpenMLFlow( model=clf, name="CustomKNeighborsClassifier", description="A custom KNeighborsClassifier flow for OpenML.", external_version=f"{sklearn.__version__}", language="English", tags=["openml_tutorial_knn"], dependencies=f"{sklearn.__version__}", parameters={k: str(v) fork, vinknn_parameters.items()}, parameters_meta_info={"n_neighbors":{"description": "number of neighbors to use", "data_type": "int"} }, components={}, ) knn_flow.publish()

API

fromsklearn.neighborsimportKNeighborsClassifierimportopenml_sklearn# Register the extensionimportopenmlclf=KNeighborsClassifier(n_neighbors=3) openml.publish(clf)

@Omswastik-11Omswastik-11 changed the title [ENH] improve publish api for users[ENH] Simplified Publish API with Automatic Type RecognitionDec 24, 2025
Copy link
Collaborator

@fkiralyfkiraly left a comment

Choose a reason for hiding this comment

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

I get this is a draft still, some early comments.

  • works for flows only, I would recommend to try for at least two different object types to see the dispatching challenge there.
  • do the extension checking inside publish and not in the usage example

@Omswastik-11
Copy link
Author

Omswastik-11 commented Dec 25, 2025

Thanks @fkiraly !!
I checked on flow , datset , task . it is working correctly but in run it is getting some server side issues.

Task 1 failed: https://test.openml.org/api/v1/xml/data/features/1 returned code 274: No features found. Additionally, dataset processed with error - None 

Sign up for freeto 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

@Omswastik-11@fkiraly