Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update artifact.py --- documentation edits (grammar, consistency, cla… #1159

Merged
merged 3 commits into from
Aug 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/unitxt/artifact.py
Original file line number Diff line number Diff line change
Expand Up @@ -439,10 +439,10 @@ def fetch_artifact(artifact_rep) -> Tuple[Artifact, Union[Artifactory, None]]:
"""Loads an artifict from one of possible representations.

(1) If artifact representation is already an Artifact object, return it.
(2) If artifact representation is a string location of a local file, load the Artifact from local file.
(3) If artifact representation is a string name iin the catalog, load the Artifact from the catalog.
(4) If artifact representation is a json string, create dictionary representation from the string and build an Artifact object from it.
(5) Otherwise, check the artifact representation is a dictionary and build an Artifact object from it.
(2) If artifact representation is a string location of a local file, load the Artifact from the local file.
(3) If artifact representation is a string name in the catalog, load the Artifact from the catalog.
(4) If artifact representation is a json string, create a dictionary representation from the string and build an Artifact object from it.
(5) Otherwise, check that the artifact representation is a dictionary and build an Artifact object from it.
"""
if isinstance(artifact_rep, Artifact):
return artifact_rep, None
Expand Down
Loading