Skip to content

Commit

Permalink
Merge pull request #3816 from gthb/relpath_to_training_data
Browse files Browse the repository at this point in the history
fix: relative path to training data
  • Loading branch information
federicotdn committed Jun 25, 2019
2 parents 070978f + e628896 commit 7ac7caa
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ Fixed
-----
- fixed bug where facebook quick replies were not rendering
- take FB quick reply payload rather than text as input
- fixed bug where `training_data` path in `metadata.json` was an absolute path


[1.1.3] - 2019-06-14
Expand Down
3 changes: 2 additions & 1 deletion rasa/nlu/training_data/training_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import random
import warnings
from copy import deepcopy
from os.path import relpath
from typing import Any, Dict, List, Optional, Set, Text, Tuple

from rasa.nlu.training_data.message import Message
Expand Down Expand Up @@ -153,7 +154,7 @@ def persist(
"and 'md'."
)

return {"training_data": data_file}
return {"training_data": relpath(data_file, dir_name)}

def sorted_entities(self) -> List[Any]:
"""Extract all entities from examples and sorts them by entity type."""
Expand Down

0 comments on commit 7ac7caa

Please sign in to comment.