SYMBOL INDEX (156 symbols across 21 files) FILE: sgpt/app.py function main (line 27) | def main( function entry_point (line 271) | def entry_point() -> None: FILE: sgpt/cache.py class Cache (line 7) | class Cache: method __init__ (line 12) | def __init__(self, length: int, cache_path: Path) -> None: method __call__ (line 22) | def __call__(self, func: Callable[..., Any]) -> Callable[..., Any]: method _delete_oldest_files (line 47) | def _delete_oldest_files(self, max_files: int) -> None: FILE: sgpt/config.py class Config (line 44) | class Config(dict): # type: ignore method __init__ (line 45) | def __init__(self, config_path: Path, **defaults: Any): method _exists (line 67) | def _exists(self) -> bool: method _write (line 70) | def _write(self) -> None: method _read (line 77) | def _read(self) -> None: method get (line 84) | def get(self, key: str) -> str: # type: ignore FILE: sgpt/function.py class Function (line 11) | class Function: method __init__ (line 12) | def __init__(self, path: str): method name (line 19) | def name(self) -> str: method openai_schema (line 23) | def openai_schema(self) -> dict[str, Any]: method execute (line 27) | def execute(self) -> Callable[..., str]: method _read (line 31) | def _read(cls, path: str) -> Any: function get_function (line 59) | def get_function(name: str) -> Callable[..., Any]: function get_openai_schemas (line 66) | def get_openai_schemas() -> List[Dict[str, Any]]: FILE: sgpt/handlers/chat_handler.py class ChatSession (line 19) | class ChatSession: method __init__ (line 27) | def __init__(self, length: int, storage_path: Path): method __call__ (line 37) | def __call__(self, func: Callable[..., Any]) -> Callable[..., Any]: method _read (line 65) | def _read(self, chat_id: str) -> List[Dict[str, str]]: method _write (line 72) | def _write(self, messages: List[Dict[str, str]], chat_id: str) -> None: method invalidate (line 80) | def invalidate(self, chat_id: str) -> None: method get_messages (line 84) | def get_messages(self, chat_id: str) -> List[str]: method exists (line 88) | def exists(self, chat_id: Optional[str]) -> bool: method list (line 91) | def list(self) -> List[Path]: class ChatHandler (line 98) | class ChatHandler(Handler): method __init__ (line 101) | def __init__(self, chat_id: str, role: SystemRole, markdown: bool) -> ... method initiated (line 113) | def initiated(self) -> bool: method is_same_role (line 117) | def is_same_role(self) -> bool: method initial_message (line 122) | def initial_message(cls, chat_id: str) -> str: method list_ids (line 128) | def list_ids(cls, value: str) -> None: method show_messages (line 134) | def show_messages(cls, chat_id: str, markdown: bool) -> None: method validate (line 150) | def validate(self) -> None: method make_messages (line 165) | def make_messages(self, prompt: str) -> List[Dict[str, str]]: method get_completion (line 173) | def get_completion(self, **kwargs: Any) -> Generator[str, None, None]: method handle (line 176) | def handle(self, **kwargs: Any) -> str: # type: ignore[override] FILE: sgpt/handlers/default_handler.py class DefaultHandler (line 12) | class DefaultHandler(Handler): method __init__ (line 13) | def __init__(self, role: SystemRole, markdown: bool) -> None: method make_messages (line 17) | def make_messages(self, prompt: str) -> List[Dict[str, str]]: FILE: sgpt/handlers/handler.py class Handler (line 35) | class Handler: method __init__ (line 38) | def __init__(self, role: SystemRole, markdown: bool) -> None: method printer (line 49) | def printer(self) -> Printer: method make_messages (line 56) | def make_messages(self, prompt: str) -> List[Dict[str, str]]: method handle_function_call (line 59) | def handle_function_call( method get_completion (line 98) | def get_completion( method handle (line 168) | def handle( FILE: sgpt/handlers/repl_handler.py class ReplHandler (line 13) | class ReplHandler(ChatHandler): method __init__ (line 14) | def __init__(self, chat_id: str, role: SystemRole, markdown: bool) -> ... method _get_multiline_input (line 18) | def _get_multiline_input(cls) -> str: method handle (line 24) | def handle(self, init_prompt: str, **kwargs: Any) -> None: # type: ig... FILE: sgpt/llm_functions/common/execute_shell.py class Function (line 7) | class Function(BaseModel): method execute (line 19) | def execute(cls, shell_command: str) -> str: method openai_schema (line 28) | def openai_schema(cls) -> Dict[str, Any]: FILE: sgpt/llm_functions/init_functions.py function install_functions (line 14) | def install_functions(*_args: Any) -> None: FILE: sgpt/llm_functions/mac/apple_script.py class Function (line 7) | class Function(BaseModel): method execute (line 20) | def execute(cls, apple_script): method openai_schema (line 33) | def openai_schema(cls) -> Dict[str, Any]: FILE: sgpt/printer.py class Printer (line 10) | class Printer(ABC): method live_print (line 14) | def live_print(self, chunks: Generator[str, None, None]) -> str: method static_print (line 18) | def static_print(self, text: str) -> str: method __call__ (line 21) | def __call__(self, chunks: Generator[str, None, None], live: bool = Tr... class MarkdownPrinter (line 30) | class MarkdownPrinter(Printer): method __init__ (line 31) | def __init__(self, theme: str) -> None: method live_print (line 35) | def live_print(self, chunks: Generator[str, None, None]) -> str: method static_print (line 44) | def static_print(self, text: str) -> str: class TextPrinter (line 50) | class TextPrinter(Printer): method __init__ (line 51) | def __init__(self, color: str) -> None: method live_print (line 54) | def live_print(self, chunks: Generator[str, None, None]) -> str: method static_print (line 63) | def static_print(self, text: str) -> str: FILE: sgpt/role.py class SystemRole (line 47) | class SystemRole: method __init__ (line 50) | def __init__( method create_defaults (line 63) | def create_defaults(cls) -> None: method get (line 76) | def get(cls, name: str) -> "SystemRole": method create (line 84) | def create(cls, name: str) -> None: method list (line 91) | def list(cls, _value: str) -> None: method show (line 102) | def show(cls, name: str) -> None: method get_role_name (line 106) | def get_role_name(cls, initial_message: str) -> Optional[str]: method _os_name (line 115) | def _os_name(cls) -> str: method _shell_name (line 128) | def _shell_name(cls) -> str: method _exists (line 138) | def _exists(self) -> bool: method _file_path (line 142) | def _file_path(self) -> Path: method _save (line 145) | def _save(self) -> None: method delete (line 155) | def delete(self) -> None: method same_role (line 163) | def same_role(self, initial_message: str) -> bool: class DefaultRoles (line 169) | class DefaultRoles(Enum): method check_get (line 176) | def check_get(cls, shell: bool, describe_shell: bool, code: bool) -> S... method get_role (line 185) | def get_role(self) -> SystemRole: FILE: sgpt/utils.py function get_edited_prompt (line 14) | def get_edited_prompt() -> str: function run_command (line 36) | def run_command(command: str) -> None: function option_callback (line 56) | def option_callback(func: Callable) -> Callable: # type: ignore function install_shell_integration (line 67) | def install_shell_integration(*_args: Any) -> None: function get_sgpt_version (line 91) | def get_sgpt_version(*_args: Any) -> None: FILE: tests/_integration.py class TestShellGpt (line 32) | class TestShellGpt(TestCase): method setUpClass (line 34) | def setUpClass(cls): method get_arguments (line 43) | def get_arguments(prompt, **kwargs): method test_default (line 53) | def test_default(self): method test_shell (line 61) | def test_shell(self): method test_describe_shell (line 70) | def test_describe_shell(self): method test_code (line 79) | def test_code(self): method test_chat_default (line 116) | def test_chat_default(self): method test_chat_shell (line 136) | def test_chat_shell(self): method test_chat_describe_shell (line 161) | def test_chat_describe_shell(self): method test_chat_code (line 176) | def test_chat_code(self): method test_list_chat (line 197) | def test_list_chat(self): method test_show_chat (line 202) | def test_show_chat(self): method test_validation_code_shell (line 217) | def test_validation_code_shell(self): method test_repl_default (line 227) | def test_repl_default( method test_repl_multiline (line 247) | def test_repl_multiline( method test_repl_shell (line 272) | def test_repl_shell(self): method test_repl_describe_command (line 304) | def test_repl_describe_command(self): method test_repl_code (line 326) | def test_repl_code(self): method test_zsh_command (line 362) | def test_zsh_command(self): method test_model_option (line 384) | def test_model_option(self, mocked_get_completion): method test_color_output (line 400) | def test_color_output(self): method test_simple_stdin (line 409) | def test_simple_stdin(self): method test_shell_stdin_with_prompt (line 413) | def test_shell_stdin_with_prompt(self): method test_role (line 423) | def test_role(self): method test_shell_command_run_description (line 479) | def test_shell_command_run_description(self): method test_version (line 490) | def test_version(self): FILE: tests/conftest.py function mock_os_name (line 7) | def mock_os_name(monkeypatch): FILE: tests/test_code.py function test_code_generation (line 13) | def test_code_generation(completion): function test_code_generation_no_markdown (line 27) | def test_code_generation_no_markdown(completion, markdown_printer, text_... function test_code_generation_stdin (line 40) | def test_code_generation_stdin(completion): function test_code_chat (line 55) | def test_code_chat(completion): function test_code_repl (line 96) | def test_code_repl(completion): function test_code_and_shell (line 128) | def test_code_and_shell(completion): function test_code_and_describe_shell (line 138) | def test_code_and_describe_shell(completion): FILE: tests/test_default.py function test_default (line 18) | def test_default(completion): function test_default_stdin (line 30) | def test_default_stdin(completion): function test_show_chat_use_markdown (line 43) | def test_show_chat_use_markdown(completion, console_print): function test_show_chat_no_use_markdown (line 61) | def test_show_chat_no_use_markdown(completion, console_print): function test_default_chat (line 79) | def test_default_chat(completion): function test_default_repl (line 131) | def test_default_repl(completion): function test_default_repl_stdin (line 160) | def test_default_repl_stdin(completion): function test_llm_options (line 194) | def test_llm_options(completion): function test_version (line 219) | def test_version(completion): function test_markdown (line 230) | def test_markdown(completion, markdown_printer, text_printer): function test_no_markdown (line 243) | def test_no_markdown(completion, markdown_printer, text_printer): FILE: tests/test_roles.py function test_role (line 12) | def test_role(completion): FILE: tests/test_shell.py function test_shell (line 12) | def test_shell(completion): function test_shell_no_markdown (line 27) | def test_shell_no_markdown(completion, markdown_printer, text_printer): function test_shell_stdin (line 39) | def test_shell_stdin(completion): function test_describe_shell (line 54) | def test_describe_shell(completion): function test_describe_shell_stdin (line 67) | def test_describe_shell_stdin(completion): function test_shell_run_description (line 83) | def test_shell_run_description(completion, system): function test_shell_chat (line 96) | def test_shell_chat(completion): function test_shell_repl (line 133) | def test_shell_repl(completion, mock_system): function test_shell_and_describe_shell (line 165) | def test_shell_and_describe_shell(completion): function test_shell_no_interaction (line 175) | def test_shell_no_interaction(completion): FILE: tests/utils.py function mock_comp (line 17) | def mock_comp(tokens_string): function cmd_args (line 36) | def cmd_args(prompt="", **kwargs): function comp_args (line 48) | def comp_args(role, prompt, **kwargs):