MCPcopy Create free account
hub / github.com/PAIR-code/lit / description

Method description

lit_nlp/api/dataset.py:120–130  ·  view source on GitHub ↗

Return a human-readable description of this component. Defaults to class docstring, but subclass may override this (or simply set self._description) to be instance-dependent - for example, including the path from which the data was loaded. Returns: (string) A human-readable d

(self)

Source from the content-addressed store, hash-verified

118 self._description = description or self._description
119
120 def description(self) -> str:
121 """Return a human-readable description of this component.
122
123 Defaults to class docstring, but subclass may override this (or simply set
124 self._description) to be instance-dependent - for example, including the
125 path from which the data was loaded.
126
127 Returns:
128 (string) A human-readable description for display in the UI.
129 """
130 return self._description or inspect.getdoc(self) or '' # pytype: disable=bad-return-type
131
132 @classmethod
133 def init_spec(cls) -> Optional[lit_types.Spec]:

Callers 2

__init__Method · 0.45
loadMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected