|
|
|
@ -62,7 +62,7 @@ logger = logging.getLogger(__name__)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Runtime(BaseModel):
|
|
|
|
|
"""This class represents a Runtime.
|
|
|
|
|
"""Pebblo Runtime.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
|
type (Optional[str]): Runtime type. Defaults to ""
|
|
|
|
@ -90,7 +90,7 @@ class Runtime(BaseModel):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Framework(BaseModel):
|
|
|
|
|
"""This class represents a Framework instance.
|
|
|
|
|
"""Pebblo Framework instance.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
|
name (str): Name of the Framework.
|
|
|
|
@ -102,7 +102,7 @@ class Framework(BaseModel):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class App(BaseModel):
|
|
|
|
|
"""This class represents an AI application.
|
|
|
|
|
"""Pebblo AI application.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
|
name (str): Name of the app.
|
|
|
|
@ -124,7 +124,7 @@ class App(BaseModel):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class Doc(BaseModel):
|
|
|
|
|
"""This class represents a pebblo document.
|
|
|
|
|
"""Pebblo document.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
|
name (str): Name of app originating this document.
|
|
|
|
@ -148,8 +148,8 @@ class Doc(BaseModel):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def get_full_path(path: str) -> str:
|
|
|
|
|
"""Return absolute local path for a local file/directory,
|
|
|
|
|
for network related path, return as is.
|
|
|
|
|
"""Return an absolute local path for a local file/directory,
|
|
|
|
|
for a network related path, return as is.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
|
path (str): Relative path to be resolved.
|
|
|
|
@ -184,7 +184,7 @@ def get_loader_type(loader: str) -> str:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def get_loader_full_path(loader: BaseLoader) -> str:
|
|
|
|
|
"""Return absolute source path of source of loader based on the
|
|
|
|
|
"""Return an absolute source path of source of loader based on the
|
|
|
|
|
keys present in Document object from loader.
|
|
|
|
|
|
|
|
|
|
Args:
|
|
|
|
@ -266,7 +266,7 @@ def get_runtime() -> Tuple[Framework, Runtime]:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
def get_ip() -> str:
|
|
|
|
|
"""Fetch local runtime ip address
|
|
|
|
|
"""Fetch local runtime ip address.
|
|
|
|
|
|
|
|
|
|
Returns:
|
|
|
|
|
str: IP address
|
|
|
|
|