text stringlengths 38 361k | type stringclasses 1
value | start int64 156 155k | end int64 451 418k | depth int64 0 0 | filepath stringlengths 87 141 | parent_class null | class_index int64 0 305 |
|---|---|---|---|---|---|---|---|
class EvalResult:
"""
Flattened representation of individual evaluation results found in model-index of Model Cards.
For more information on the model-index spec, see https://github.com/huggingface/hub-docs/blob/main/modelcard.md?plain=1.
Args:
task_type (`str`):
The task identifie... | class_definition | 248 | 7,185 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/repocard_data.py | null | 0 |
class CardData:
"""Structure containing metadata from a RepoCard.
[`CardData`] is the parent class of [`ModelCardData`] and [`DatasetCardData`].
Metadata can be exported as a dictionary or YAML. Export can be customized to alter the representation of the data
(example: flatten evaluation results). `Ca... | class_definition | 7,199 | 10,080 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/repocard_data.py | null | 1 |
class ModelCardData(CardData):
"""Model Card Metadata that is used by Hugging Face Hub when included at the top of your README.md
Args:
base_model (`str` or `List[str]`, *optional*):
The identifier of the base model from which the model derives. This is applicable for example if your model ... | class_definition | 10,083 | 16,711 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/repocard_data.py | null | 2 |
class DatasetCardData(CardData):
"""Dataset Card Metadata that is used by Hugging Face Hub when included at the top of your README.md
Args:
language (`List[str]`, *optional*):
Language of dataset's data or metadata. It must be an ISO 639-1, 639-2 or
639-3 code (two/three letters... | class_definition | 16,714 | 20,971 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/repocard_data.py | null | 3 |
class SpaceCardData(CardData):
"""Space Card Metadata that is used by Hugging Face Hub when included at the top of your README.md
To get an exhaustive reference of Spaces configuration, please visit https://huggingface.co/docs/hub/spaces-config-reference#spaces-configuration-reference.
Args:
title... | class_definition | 20,974 | 24,542 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/repocard_data.py | null | 4 |
class BaseModel: # type: ignore [no-redef]
def __init__(self, *args, **kwargs) -> None:
raise ImportError(
"You must have `pydantic` installed to use `WebhookPayload`. This is an optional dependency that"
" should be installed separately. Please run `pip install --up... | class_definition | 986 | 1,347 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 5 |
class ObjectId(BaseModel):
id: str | class_definition | 1,991 | 2,029 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 6 |
class WebhookPayloadUrl(BaseModel):
web: str
api: Optional[str] = None | class_definition | 2,032 | 2,110 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 7 |
class WebhookPayloadMovedTo(BaseModel):
name: str
owner: ObjectId | class_definition | 2,113 | 2,186 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 8 |
class WebhookPayloadWebhook(ObjectId):
version: SupportedWebhookVersion | class_definition | 2,189 | 2,264 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 9 |
class WebhookPayloadEvent(BaseModel):
action: WebhookEvent_T
scope: str | class_definition | 2,267 | 2,346 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 10 |
class WebhookPayloadDiscussionChanges(BaseModel):
base: str
mergeCommitId: Optional[str] = None | class_definition | 2,349 | 2,452 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 11 |
class WebhookPayloadComment(ObjectId):
author: ObjectId
hidden: bool
content: Optional[str] = None
url: WebhookPayloadUrl | class_definition | 2,455 | 2,592 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 12 |
class WebhookPayloadDiscussion(ObjectId):
num: int
author: ObjectId
url: WebhookPayloadUrl
title: str
isPullRequest: bool
status: DiscussionStatus_T
changes: Optional[WebhookPayloadDiscussionChanges] = None
pinned: Optional[bool] = None | class_definition | 2,595 | 2,863 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 13 |
class WebhookPayloadRepo(ObjectId):
owner: ObjectId
head_sha: Optional[str] = None
name: str
private: bool
subdomain: Optional[str] = None
tags: Optional[List[str]] = None
type: Literal["dataset", "model", "space"]
url: WebhookPayloadUrl | class_definition | 2,866 | 3,135 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 14 |
class WebhookPayloadUpdatedRef(BaseModel):
ref: str
oldSha: Optional[str] = None
newSha: Optional[str] = None | class_definition | 3,138 | 3,259 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 15 |
class WebhookPayload(BaseModel):
event: WebhookPayloadEvent
repo: WebhookPayloadRepo
discussion: Optional[WebhookPayloadDiscussion] = None
comment: Optional[WebhookPayloadComment] = None
webhook: WebhookPayloadWebhook
movedTo: Optional[WebhookPayloadMovedTo] = None
updatedRefs: Optional[List... | class_definition | 3,262 | 3,616 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_payload.py | null | 16 |
class MixinInfo:
model_card_template: str
model_card_data: ModelCardData
repo_url: Optional[str] = None
docs_url: Optional[str] = None | class_definition | 1,902 | 2,052 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hub_mixin.py | null | 17 |
class ModelHubMixin:
"""
A generic mixin to integrate ANY machine learning framework with the Hub.
To integrate your framework, your model class must inherit from this class. Custom logic for saving/loading models
have to be overwritten in [`_from_pretrained`] and [`_save_pretrained`]. [`PyTorchModelH... | class_definition | 2,055 | 31,281 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hub_mixin.py | null | 18 |
class PyTorchModelHubMixin(ModelHubMixin):
"""
Implementation of [`ModelHubMixin`] to provide model Hub upload/download capabilities to PyTorch models. The model
is set in evaluation mode by default using `model.eval()` (dropout modules are deactivated). To train the model,
you should first set it back ... | class_definition | 31,284 | 36,922 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hub_mixin.py | null | 19 |
class WebhooksServer:
"""
The [`WebhooksServer`] class lets you create an instance of a Gradio app that can receive Huggingface webhooks.
These webhooks can be registered using the [`~WebhooksServer.add_webhook`] decorator. Webhook endpoints are added to
the app as a POST endpoint to the FastAPI router.... | class_definition | 1,356 | 9,272 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_webhooks_server.py | null | 20 |
class SpaceStage(str, Enum):
"""
Enumeration of possible stage of a Space on the Hub.
Value can be compared to a string:
```py
assert SpaceStage.BUILDING == "BUILDING"
```
Taken from https://github.com/huggingface/moon-landing/blob/main/server/repo_types/SpaceInfo.ts#L61 (private url).
... | class_definition | 786 | 1,492 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_space_api.py | null | 21 |
class SpaceHardware(str, Enum):
"""
Enumeration of hardwares available to run your Space on the Hub.
Value can be compared to a string:
```py
assert SpaceHardware.CPU_BASIC == "cpu-basic"
```
Taken from https://github.com/huggingface/moon-landing/blob/main/server/repo_types/SpaceInfo.ts#L7... | class_definition | 1,495 | 2,248 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_space_api.py | null | 22 |
class SpaceStorage(str, Enum):
"""
Enumeration of persistent storage available for your Space on the Hub.
Value can be compared to a string:
```py
assert SpaceStorage.SMALL == "small"
```
Taken from https://github.com/huggingface/moon-landing/blob/main/server/repo_types/SpaceHardwareFlavor... | class_definition | 2,251 | 2,664 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_space_api.py | null | 23 |
class SpaceRuntime:
"""
Contains information about the current runtime of a Space.
Args:
stage (`str`):
Current stage of the space. Example: RUNNING.
hardware (`str` or `None`):
Current hardware of the space. Example: "cpu-basic". Can be `None` if Space
i... | class_definition | 2,678 | 4,403 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_space_api.py | null | 24 |
class SpaceVariable:
"""
Contains information about the current variables of a Space.
Args:
key (`str`):
Variable key. Example: `"MODEL_REPO_ID"`
value (`str`):
Variable value. Example: `"the_model_repo_id"`.
description (`str` or None):
Descripti... | class_definition | 4,417 | 5,362 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_space_api.py | null | 25 |
class KerasModelHubMixin(ModelHubMixin):
"""
Implementation of [`ModelHubMixin`] to provide model Hub upload/download
capabilities to Keras models.
```python
>>> import tensorflow as tf
>>> from huggingface_hub import KerasModelHubMixin
>>> class MyModel(tf.keras.Model, KerasModelHubMixi... | class_definition | 16,893 | 19,573 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/keras_mixin.py | null | 26 |
class _FileToUpload:
"""Temporary dataclass to store info about files to upload. Not meant to be used directly."""
local_path: Path
path_in_repo: str
size_limit: int
last_modified: float | class_definition | 461 | 668 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_commit_scheduler.py | null | 27 |
class CommitScheduler:
"""
Scheduler to upload a local folder to the Hub at regular intervals (e.g. push to hub every 5 minutes).
The recommended way to use the scheduler is to use it as a context manager. This ensures that the scheduler is
properly stopped and the last commit is triggered when the scr... | class_definition | 671 | 11,802 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_commit_scheduler.py | null | 28 |
class PartialFileIO(BytesIO):
"""A file-like object that reads only the first part of a file.
Useful to upload a file to the Hub when the user might still be appending data to it. Only the first part of the
file is uploaded (i.e. the part that was available when the filesystem was first scanned).
In p... | class_definition | 11,805 | 14,678 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_commit_scheduler.py | null | 29 |
class LocalDownloadFilePaths:
"""
Paths to the files related to a download process in a local dir.
Returned by [`get_local_download_paths`].
Attributes:
file_path (`Path`):
Path where the file will be saved.
lock_path (`Path`):
Path to the lock file used to ensu... | class_definition | 1,891 | 2,627 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_local_folder.py | null | 30 |
class LocalUploadFilePaths:
"""
Paths to the files related to an upload process in a local dir.
Returned by [`get_local_upload_paths`].
Attributes:
path_in_repo (`str`):
Path of the file in the repo.
file_path (`Path`):
Path where the file will be saved.
... | class_definition | 2,654 | 3,250 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_local_folder.py | null | 31 |
class LocalDownloadFileMetadata:
"""
Metadata about a file in the local directory related to a download process.
Attributes:
filename (`str`):
Path of the file in the repo.
commit_hash (`str`):
Commit hash of the file in the repo.
etag (`str`):
ET... | class_definition | 3,264 | 3,965 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_local_folder.py | null | 32 |
class LocalUploadFileMetadata:
"""
Metadata about a file in the local directory related to an upload process.
"""
size: int
# Default values correspond to "we don't know yet"
timestamp: Optional[float] = None
should_ignore: Optional[bool] = None
sha256: Optional[str] = None
upload_... | class_definition | 3,979 | 5,308 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_local_folder.py | null | 33 |
class UploadInfo:
"""
Dataclass holding required information to determine whether a blob
should be uploaded to the hub using the LFS protocol or the regular protocol
Args:
sha256 (`bytes`):
SHA256 hash of the blob
size (`int`):
Size in bytes of the blob
s... | class_definition | 1,632 | 2,779 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/lfs.py | null | 34 |
class PayloadPartT(TypedDict):
partNumber: int
etag: str | class_definition | 5,640 | 5,704 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/lfs.py | null | 35 |
class CompletionPayloadT(TypedDict):
"""Payload that will be sent to the Hub when uploading multi-part."""
oid: str
parts: List[PayloadPartT] | class_definition | 5,707 | 5,861 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/lfs.py | null | 36 |
class HfFileMetadata:
"""Data structure containing information about a file versioned on the Hub.
Returned by [`get_hf_file_metadata`] based on a URL.
Args:
commit_hash (`str`, *optional*):
The commit_hash related to the file.
etag (`str`, *optional*):
Etag of the f... | class_definition | 5,777 | 6,475 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/file_download.py | null | 37 |
class Discussion:
"""
A Discussion or Pull Request on the Hub.
This dataclass is not intended to be instantiated directly.
Attributes:
title (`str`):
The title of the Discussion / Pull Request
status (`str`):
The status of the Discussion / Pull Request.
... | class_definition | 530 | 2,958 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 38 |
class DiscussionWithDetails(Discussion):
"""
Subclass of [`Discussion`].
Attributes:
title (`str`):
The title of the Discussion / Pull Request
status (`str`):
The status of the Discussion / Pull Request.
It can be one of:
* `"open"`
... | class_definition | 2,972 | 5,564 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 39 |
class DiscussionEvent:
"""
An event in a Discussion or Pull Request.
Use concrete classes:
* [`DiscussionComment`]
* [`DiscussionStatusChange`]
* [`DiscussionCommit`]
* [`DiscussionTitleChange`]
Attributes:
id (`str`):
The ID of the event. An hexadec... | class_definition | 5,578 | 6,507 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 40 |
class DiscussionComment(DiscussionEvent):
"""A comment in a Discussion / Pull Request.
Subclass of [`DiscussionEvent`].
Attributes:
id (`str`):
The ID of the event. An hexadecimal string.
type (`str`):
The type of the event.
created_at (`datetime`):
... | class_definition | 6,521 | 8,292 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 41 |
class DiscussionStatusChange(DiscussionEvent):
"""A change of status in a Discussion / Pull Request.
Subclass of [`DiscussionEvent`].
Attributes:
id (`str`):
The ID of the event. An hexadecimal string.
type (`str`):
The type of the event.
created_at (`dateti... | class_definition | 8,306 | 9,238 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 42 |
class DiscussionCommit(DiscussionEvent):
"""A commit in a Pull Request.
Subclass of [`DiscussionEvent`].
Attributes:
id (`str`):
The ID of the event. An hexadecimal string.
type (`str`):
The type of the event.
created_at (`datetime`):
A [`datetim... | class_definition | 9,252 | 10,073 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 43 |
class DiscussionTitleChange(DiscussionEvent):
"""A rename event in a Discussion / Pull Request.
Subclass of [`DiscussionEvent`].
Attributes:
id (`str`):
The ID of the event. An hexadecimal string.
type (`str`):
The type of the event.
created_at (`datetime`):... | class_definition | 10,087 | 10,936 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/community.py | null | 44 |
class InferenceApi:
"""Client to configure requests and make calls to the HuggingFace Inference API.
Example:
```python
>>> from huggingface_hub.inference_api import InferenceApi
>>> # Mask-fill example
>>> inference = InferenceApi("bert-base-uncased")
>>> inference(inputs="The goal of li... | class_definition | 1,026 | 8,322 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/inference_api.py | null | 45 |
class InferenceEndpointStatus(str, Enum):
PENDING = "pending"
INITIALIZING = "initializing"
UPDATING = "updating"
UPDATE_FAILED = "updateFailed"
RUNNING = "running"
PAUSED = "paused"
FAILED = "failed"
SCALED_TO_ZERO = "scaledToZero" | class_definition | 516 | 780 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_inference_endpoints.py | null | 46 |
class InferenceEndpointType(str, Enum):
PUBlIC = "public"
PROTECTED = "protected"
PRIVATE = "private" | class_definition | 783 | 896 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_inference_endpoints.py | null | 47 |
class InferenceEndpoint:
"""
Contains information about a deployed Inference Endpoint.
Args:
name (`str`):
The unique name of the Inference Endpoint.
namespace (`str`):
The namespace where the Inference Endpoint is located.
repository (`str`):
The... | class_definition | 910 | 16,749 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/_inference_endpoints.py | null | 48 |
class LastCommitInfo(dict):
oid: str
title: str
date: datetime
def __post_init__(self): # hack to make LastCommitInfo backward compatible
self.update(asdict(self)) | class_definition | 9,657 | 9,846 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 49 |
class BlobLfsInfo(dict):
size: int
sha256: str
pointer_size: int
def __post_init__(self): # hack to make BlobLfsInfo backward compatible
self.update(asdict(self)) | class_definition | 9,860 | 10,048 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 50 |
class BlobSecurityInfo(dict):
safe: bool # duplicate information with "status" field, keeping it for backward compatibility
status: str
av_scan: Optional[Dict]
pickle_import_scan: Optional[Dict]
def __post_init__(self): # hack to make BlogSecurityInfo backward compatible
self.update(asdic... | class_definition | 10,062 | 10,390 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 51 |
class TransformersInfo(dict):
auto_model: str
custom_class: Optional[str] = None
# possible `pipeline_tag` values: https://github.com/huggingface/huggingface.js/blob/3ee32554b8620644a6287e786b2a83bf5caf559c/packages/tasks/src/pipelines.ts#L72
pipeline_tag: Optional[str] = None
processor: Optional[st... | class_definition | 10,404 | 10,850 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 52 |
class SafeTensorsInfo(dict):
parameters: Dict[str, int]
total: int
def __post_init__(self): # hack to make SafeTensorsInfo backward compatible
self.update(asdict(self)) | class_definition | 10,864 | 11,054 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 53 |
class CommitInfo(str):
"""Data structure containing information about a newly created commit.
Returned by any method that creates a commit on the Hub: [`create_commit`], [`upload_file`], [`upload_folder`],
[`delete_file`], [`delete_folder`]. It inherits from `str` for backward compatibility but using metho... | class_definition | 11,068 | 14,227 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 54 |
class AccessRequest:
"""Data structure containing information about a user access request.
Attributes:
username (`str`):
Username of the user who requested access.
fullname (`str`):
Fullname of the user who requested access.
email (`Optional[str]`):
E... | class_definition | 14,241 | 15,282 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 55 |
class WebhookWatchedItem:
"""Data structure containing information about the items watched by a webhook.
Attributes:
type (`Literal["dataset", "model", "org", "space", "user"]`):
Type of the item to be watched. Can be one of `["dataset", "model", "org", "space", "user"]`.
name (`str... | class_definition | 15,296 | 15,828 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 56 |
class WebhookInfo:
"""Data structure containing information about a webhook.
Attributes:
id (`str`):
ID of the webhook.
url (`str`):
URL of the webhook.
watched (`List[WebhookWatchedItem]`):
List of items watched by the webhook, see [`WebhookWatchedIt... | class_definition | 15,842 | 16,618 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 57 |
class RepoUrl(str):
"""Subclass of `str` describing a repo URL on the Hub.
`RepoUrl` is returned by `HfApi.create_repo`. It inherits from `str` for backward
compatibility. At initialization, the URL is parsed to populate properties:
- endpoint (`str`)
- namespace (`Optional[str]`)
- repo_name (... | class_definition | 16,621 | 19,267 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 58 |
class RepoSibling:
"""
Contains basic information about a repo file inside a repo on the Hub.
<Tip>
All attributes of this class are optional except `rfilename`. This is because only the file names are returned when
listing repositories on the Hub (with [`list_models`], [`list_datasets`] or [`list... | class_definition | 19,281 | 20,751 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 59 |
class RepoFile:
"""
Contains information about a file on the Hub.
Attributes:
path (str):
file path relative to the repo root.
size (`int`):
The file's size, in bytes.
blob_id (`str`):
The file's git OID.
lfs (`BlobLfsInfo`):
T... | class_definition | 20,765 | 22,883 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 60 |
class RepoFolder:
"""
Contains information about a folder on the Hub.
Attributes:
path (str):
folder path relative to the repo root.
tree_id (`str`):
The folder's git OID.
last_commit (`LastCommitInfo`, *optional*):
The folder's last commit metada... | class_definition | 22,897 | 23,852 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 61 |
class ModelInfo:
"""
Contains information about a model on the Hub.
<Tip>
Most attributes of this class are optional. This is because the data returned by the Hub depends on the query made.
In general, the more specific the query, the more information is returned. On the contrary, when listing mod... | class_definition | 23,866 | 31,439 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 62 |
class DatasetInfo:
"""
Contains information about a dataset on the Hub.
<Tip>
Most attributes of this class are optional. This is because the data returned by the Hub depends on the query made.
In general, the more specific the query, the more information is returned. On the contrary, when listing... | class_definition | 31,453 | 36,212 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 63 |
class SpaceInfo:
"""
Contains information about a Space on the Hub.
<Tip>
Most attributes of this class are optional. This is because the data returned by the Hub depends on the query made.
In general, the more specific the query, the more information is returned. On the contrary, when listing spa... | class_definition | 36,226 | 41,445 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 64 |
class CollectionItem:
"""
Contains information about an item of a Collection (model, dataset, Space or paper).
Attributes:
item_object_id (`str`):
Unique ID of the item in the collection.
item_id (`str`):
ID of the underlying object on the Hub. Can be either a repo_i... | class_definition | 41,459 | 42,738 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 65 |
class Collection:
"""
Contains information about a Collection on the Hub.
Attributes:
slug (`str`):
Slug of the collection. E.g. `"TheBloke/recent-models-64f9a55bb3115b4f513ec026"`.
title (`str`):
Title of the collection. E.g. `"Recent models"`.
owner (`str`)... | class_definition | 42,752 | 44,887 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 66 |
class GitRefInfo:
"""
Contains information about a git reference for a repo on the Hub.
Attributes:
name (`str`):
Name of the reference (e.g. tag name or branch name).
ref (`str`):
Full git ref on the Hub (e.g. `"refs/heads/main"` or `"refs/tags/v1.0"`).
targ... | class_definition | 44,901 | 45,399 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 67 |
class GitRefs:
"""
Contains information about all git references for a repo on the Hub.
Object is returned by [`list_repo_refs`].
Attributes:
branches (`List[GitRefInfo]`):
A list of [`GitRefInfo`] containing information about branches on the repo.
converts (`List[GitRefInf... | class_definition | 45,413 | 46,399 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 68 |
class GitCommitInfo:
"""
Contains information about a git commit for a repo on the Hub. Check out [`list_repo_commits`] for more details.
Attributes:
commit_id (`str`):
OID of the commit (e.g. `"e7da7f221d5bf496a48136c0cd264e630fe9fcc8"`)
authors (`List[str]`):
List ... | class_definition | 46,413 | 47,503 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 69 |
class UserLikes:
"""
Contains information about a user likes on the Hub.
Attributes:
user (`str`):
Name of the user for which we fetched the likes.
total (`int`):
Total number of likes.
datasets (`List[str]`):
List of datasets liked by the user (a... | class_definition | 47,517 | 48,168 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 70 |
class Organization:
"""
Contains information about an organization on the Hub.
Attributes:
avatar_url (`str`):
URL of the organization's avatar.
name (`str`):
Name of the organization on the Hub (unique).
fullname (`str`):
Organization's full name... | class_definition | 48,182 | 48,827 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 71 |
class User:
"""
Contains information about a user on the Hub.
Attributes:
username (`str`):
Name of the user on the Hub (unique).
fullname (`str`):
User's full name.
avatar_url (`str`):
URL of the user's avatar.
details (`str`, *optional*)... | class_definition | 48,841 | 51,985 | 0 | /Users/nielsrogge/Documents/python_projecten/huggingface_hub/src/huggingface_hub/hf_api.py | null | 72 |
End of preview. Expand in Data Studio
README.md exists but content is empty.
- Downloads last month
- 15