ipython_gpt package#
Submodules#
ipython_gpt.api_client module#
- exception ipython_gpt.api_client.APIResponseException(method, path, response_status, response_body)[source]#
Bases:
APIClientException
- exception ipython_gpt.api_client.UnauthorizedAPIException(method, path, response_status, response_body)[source]#
Bases:
APIResponseException
ipython_gpt.displays module#
- ipython_gpt.displays.DEFAULT_DISPLAY#
alias of
ShellDisplay
- class ipython_gpt.displays.NotebookDisplay[source]#
Bases:
BaseDisplay
- TEMPLATE = "<div style='width:60%;margin-left:5%;overflow: scroll;max-height:500px'>\n\n{}\n\n</div>"#
- class ipython_gpt.displays.ShellDisplay[source]#
Bases:
BaseDisplay
ipython_gpt.subcommands module#
- class ipython_gpt.subcommands.ChatCommand(context)[source]#
Bases:
BaseIPythonGPTCommand
- COMMAND_NAME = 'chat'#
- class ipython_gpt.subcommands.ChatModelsBrowserCommand(context)[source]#
Bases:
BaseIPythonGPTCommand
- class ipython_gpt.subcommands.ConfigCommand(context)[source]#
Bases:
BaseIPythonGPTCommand
Module contents#
- class ipython_gpt.IPythonGPT(**kwargs)[source]#
Bases:
Magics
Create a configurable given a config config.
- Parameters:
config (Config) – If this is empty, default values are used. If config is a
Config
instance, it will be used to configure the instance.parent (Configurable instance, optional) – The parent Configurable instance of this object.
Notes
Subclasses of Configurable must call the
__init__()
method ofConfigurable
before doing anything else and usingsuper()
:class MyConfigurable(Configurable): def __init__(self, config=None): super(MyConfigurable, self).__init__(config=config) # Then any other code you need to finish initialization.
This ensures that instances will be configured properly.
- magics = {'cell': {'chat': 'chat'}, 'line': {'chat_config': 'chat_config', 'chat_models': 'chat_models'}}#
- registered = True#