Skip to content
3 changes: 2 additions & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,6 @@
* text=auto
*.png binary
*.jpg binary
*.drawio binary
*.py text eol=lf
*.sh text eol=lf
*.sh text eol=lf
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ build/
docs/source/apiref
docs/source/release_notes.rst
docs/source/tutorials
docs/source/_static/drawio
docs/source/diagrams/*/export
*__pycache__*
*.idea/*
.idea/*
Expand Down
5 changes: 5 additions & 0 deletions dff/pipeline/pipeline/actor.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@

Overall, the actor acts as a bridge between the user's input and the dialog graph,
making sure that the conversation follows the expected flow and providing a personalized experience to the user.

Below you can see a diagram of user request processing with Actor.
Both `request` and `response` are saved to :py:class:`.Context`.

.. figure:: /_static/drawio/dfe/user_actor.png
"""
import logging
from typing import Union, Callable, Optional, Dict, List, Any, ForwardRef
Expand Down
1 change: 1 addition & 0 deletions docs/source/diagrams/dfe/user_actor.drawio
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<mxfile scale="20" border="0"><diagram id="JaFah7PjJ86j10p3dxxR" name="Page-1">zVhNk6IwEP01XrZqtwhf4nUcZ/ayJw87c4zQAjWRuCEo7q/fIB0BwRFX0blQ6Zfv1/26U4ys6Sp/FXQd/eIBsJFpBPnIeh6ZpuNa6lsAuxIgrmOXSCjiALEKmMd/AUED0SwOIG0MlJwzGa+boM+TBHzZwKgQfNsctuSsueuahtAC5j5lbfR3HMioRG1iVfhPiMMId3Y87FhRPRYvkkY04NsaZM1G1lRwLsvWKp8CK7jTtJTzXk70Hs4lIJF9JozxGHKnrwaBuimaXMiIhzyhbFahT5FcMdVJVBPyWL6ptvHDQeu9sLD9nNeNnTYSKXZvdeO9WqEwq2l7S89LP0D6EW7sZ2IDARrLmLEpZ1zsb2AtPR98v5ghBf+AWs/Cc2ynWKtNEzKX8kz4yISJgUVFCNqRJVRwVJuG1L4CX4E6sRoggFEZb5rRQjHowsO4yjGqgb7p9hOeZUNZhouOTJepUz0tVCMsGlkKQoNquQPe9jBjSieFJ7dRLGG+pvsbb5VUm96l6boUzzLOC7KPiQ4oeMtOol3fg8Xy2GknWd+AkJB/yij2TsaoJMwc310blbStdEgIZpOopsEDeI0bJv8hl0aoNvg4KyTST0jkMiEdeRFI4MC4y4sTd2xRt69cdPKr68V9lF60s7+GpwZivINw7YT7M26dz1ALVdWKevRSbOVLfu905YAX2F20e+bCct0B0hUxbeeR+cobWgWkpoFKEb1UcKsy7XSogDxKBc55FQj4k0Eqe8W+4FkSHJxxJv4v5/fm4U4soxnu43FHuBtGO9z1g/iqpG+0CLx10r8g3Kt3blWRD6Xi/uXZbcvEfJRK3D4qSdc8UWl/aJn04Hd4mdhdVWEwmZhf6W10SibGZTK5VTXRpaOuk4e9qfRhPhPKN58nKu4GqCcNL9+Q7oueT+ZRPSEdQjE7hGLfQig93rQPYf+amnAN+44xHPvKrH577ftq/w6t2T8=</diagram></mxfile>
22 changes: 21 additions & 1 deletion makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.ONESHELL:

SHELL = /bin/bash

PYTHON = python3
Expand All @@ -8,6 +10,7 @@ TEST_COVERAGE_THRESHOLD=95
TEST_ALLOW_SKIP=all # for more info, see tests/conftest.py

PATH := $(VENV_PATH)/bin:$(PATH)
PWD := $(shell pwd)

help:
@echo "Thanks for your interest in Dialog Flow Framework!"
Expand Down Expand Up @@ -62,7 +65,22 @@ test: venv
test_all: venv wait_db test lint
.PHONY: test_all

doc: venv clean_docs
build_drawio:
docker run --rm --name="drawio-convert" -v $(PWD)/docs/source/diagrams:/data rlespinasse/drawio-export -f png --on-changes --remove-page-suffix
docker run --rm --name="drawio-chown" -v $(PWD)/docs/source/diagrams:/data --entrypoint chown rlespinasse/drawio-export -R "$(shell id -u):$(shell id -g)" /data
for folder in docs/source/diagrams/*; do
foldername=`basename $${folder}`
for file in $${folder}/*; do
filename=`basename $${file}`
if [[ -d $${file} && $${filename} == "export" ]]; then
mkdir -p docs/source/_static/drawio/$${foldername}
cp -r $${file}/* docs/source/_static/drawio/$${foldername}
fi
done
done
.PHONY: build_drawio

doc: venv clean_docs build_drawio
python3 docs/source/utils/patching.py
sphinx-apidoc -e -E -f -o docs/source/apiref dff
sphinx-build -M clean docs/source docs/build
Expand Down Expand Up @@ -91,6 +109,8 @@ clean_docs:
rm -rf docs/tutorials
rm -rf docs/source/apiref
rm -rf docs/source/tutorials
rm -rf docs/source/_static/drawio
rm -rf docs/source/diagrams/**/export
.PHONY: clean_docs

clean: clean_docs
Expand Down