rasa/core/training/interactive.py
def run_interactive_learning(stories: Text = None,
                             finetune: bool = False,
                             skip_visualization: bool = False,
                             server_args: Dict[Text, Any] = None,
                             additional_arguments: Dict[Text, Any] = None
                             ):
    """Start the interactive learning with the model of the agent."""

    server_args = server_args or {}

    if not skip_visualization:
        p = Process(target=start_visualization, args=("story_graph.dot",))
        p.deamon = True
        p.start()
    else:
        p = None

    app = run.configure_app(enable_api=True)
    endpoints = AvailableEndpoints.read_endpoints(server_args.get("endpoints"))

    # before_server_start handlers make sure the agent is loaded before the
    # interactive learning IO starts
    if server_args.get("core"):
        app.register_listener(
            partial(run.load_agent_on_start, server_args.get("core"),
                    endpoints, server_args.get("nlu")),
            'before_server_start')
    else:
        app.register_listener(
            partial(train_agent_on_start, server_args, endpoints,
                    additional_arguments),
            'before_server_start')

    _serve_application(app, stories, finetune, skip_visualization)

    if not skip_visualization:
        p.terminate()
        p.join()
Start the interactive learning with the model of the agent.
Start the interactive learning with the model of the agent.
Start the interactive learning with the model of the agent .
def run_interactive_learning(stories: Text = None,
                             finetune: bool = False,
                             skip_visualization: bool = False,
                             server_args: Dict[Text, Any] = None,
                             additional_arguments: Dict[Text, Any] = None
                             ):
    server_args = server_args or {}
    if not skip_visualization:
        p = Process(target=start_visualization, args=("story_graph.dot",))
        p.deamon = True
        p.start()
    else:
        p = None
    app = run.configure_app(enable_api=True)
    endpoints = AvailableEndpoints.read_endpoints(server_args.get("endpoints"))
    if server_args.get("core"):
        app.register_listener(
            partial(run.load_agent_on_start, server_args.get("core"),
                    endpoints, server_args.get("nlu")),
            'before_server_start')
    else:
        app.register_listener(
            partial(train_agent_on_start, server_args, endpoints,
                    additional_arguments),
            'before_server_start')
    _serve_application(app, stories, finetune, skip_visualization)
    if not skip_visualization:
        p.terminate()
        p.join()
def run_interactive_learning ( stories : Text = None , finetune : bool = False , skip_visualization : bool = False , server_args : Dict [ Text , Any ] = None , additional_arguments : Dict [ Text , Any ] = None ) : server_args = server_args or { } if not skip_visualization : p = Process ( target = start_visualization , args = ( "story_graph.dot" , ) ) p . deamon = True p . start ( ) else : p = None app = run . configure_app ( enable_api = True ) endpoints = AvailableEndpoints . read_endpoints ( server_args . get ( "endpoints" ) ) if server_args . get ( "core" ) : app . register_listener ( partial ( run . load_agent_on_start , server_args . get ( "core" ) , endpoints , server_args . get ( "nlu" ) ) , 'before_server_start' ) else : app . register_listener ( partial ( train_agent_on_start , server_args , endpoints , additional_arguments ) , 'before_server_start' ) _serve_application ( app , stories , finetune , skip_visualization ) if not skip_visualization : p . terminate ( ) p . join ( )
Start the interactive learning with the model of the agent.
Start the interactive learning with the model of the agent .
"""Start the interactive learning with the model of the agent.""" # before_server_start handlers make sure the agent is loaded before the # interactive learning IO starts
stories
Text
finetune
bool
skip_visualization
bool
server_args
Dict[Text, Any]
additional_arguments
Dict[Text, Any]