Skip to content

Commit

Permalink
fix indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
ricwo committed Sep 11, 2018
1 parent 54f210a commit bea36ee
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions docs/migrations.rst
Expand Up @@ -13,49 +13,49 @@ how you can migrate from one version to another.
``endpoints.yml`` needs to contain the ``model`` key
with a ``url`` and an optional ``token``. Here's an example:

.. code-block:: yaml
.. code-block:: yaml
model:
url: http://my_model_server.com/models/default/nlu/tags/latest
token: my_model_server_token
model:
url: http://my_model_server.com/models/default/nlu/tags/latest
token: my_model_server_token
.. note::
.. note::

If you configure ``rasa_nlu.server`` to pull models from a remote server,
the default project name will be used. It is defined
``RasaNLUModelConfig.DEFAULT_PROJECT_NAME``.
If you configure ``rasa_nlu.server`` to pull models from a remote server,
the default project name will be used. It is defined
``RasaNLUModelConfig.DEFAULT_PROJECT_NAME``.


- ``rasa_nlu.train`` can also be run with the ``--endpoints`` argument
if you want to pull training data from a URL. Alternatively, the
current ``--url`` syntax is still supported.

.. code-block:: yaml
.. code-block:: yaml
data:
url: http://my_data_server.com/projects/default/data
token: my_data_server_token
data:
url: http://my_data_server.com/projects/default/data
token: my_data_server_token
.. note::
.. note::

Your endpoint file may contain entries for both ``model`` and ``data``.
``rasa_nlu.server`` and ``rasa_nlu.train`` will pick the relevant entry.
Your endpoint file may contain entries for both ``model`` and ``data``.
``rasa_nlu.server`` and ``rasa_nlu.train`` will pick the relevant entry.

- If you directly access the ``DataRouter`` class or ``rasa_nlu.train``'s
``do_train()`` method, you can directly create instances of
``EndpointConfig`` without creating a ``yml`` file. Example:

.. code-block:: python
.. code-block:: python
from rasa_nlu.utils import EndpointConfig
from rasa_nlu.data_router import DataRouter
from rasa_nlu.utils import EndpointConfig
from rasa_nlu.data_router import DataRouter
model_endpoint = EndpointConfig(
url="http://my_model_server.com/models/default/nlu/tags/latest",
token="my_model_server_token"
)
model_endpoint = EndpointConfig(
url="http://my_model_server.com/models/default/nlu/tags/latest",
token="my_model_server_token"
)
interpreter = DataRouter("projects", model_server=model_endpoint)
interpreter = DataRouter("projects", model_server=model_endpoint)
0.12.x to 0.13.0
Expand Down

0 comments on commit bea36ee

Please sign in to comment.