Skip to content

InputStream

autogen.io.InputStream #

Bases: Protocol

input #

input(prompt='', *, password=False)

Read a line from the input stream.

PARAMETER DESCRIPTION
prompt

The prompt to display. Defaults to "".

TYPE: str DEFAULT: ''

password

Whether to read a password. Defaults to False.

TYPE: bool DEFAULT: False

RETURNS DESCRIPTION
str

The line read from the input stream.

TYPE: str

Source code in autogen/io/base.py
def input(self, prompt: str = "", *, password: bool = False) -> str:
    """Read a line from the input stream.

    Args:
        prompt (str, optional): The prompt to display. Defaults to "".
        password (bool, optional): Whether to read a password. Defaults to False.

    Returns:
        str: The line read from the input stream.

    """
    ...  # pragma: no cover