137 lines
6.5 KiB
Plaintext
137 lines
6.5 KiB
Plaintext
{
|
|
"cells": [
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {
|
|
"collapsed": false
|
|
},
|
|
"source": [
|
|
"![Logo 1](https://git.wmi.amu.edu.pl/AITech/Szablon/raw/branch/master/Logotyp_AITech1.jpg)\n",
|
|
"<div class=\"alert alert-block alert-info\">\n",
|
|
"<h1> Systemy Dialogowe </h1>\n",
|
|
"<h2> 1. <i>Rodzaje system\u00f3w dialogowych</i> [laboratoria]</h2> \n",
|
|
"<h3> Marek Kubis (2021)</h3>\n",
|
|
"</div>\n",
|
|
"\n",
|
|
"![Logo 2](https://git.wmi.amu.edu.pl/AITech/Szablon/raw/branch/master/Logotyp_AITech2.jpg)"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"Rodzaje system\u00f3w dialogowych\n",
|
|
"============================\n",
|
|
"\n",
|
|
"Wprowadzenie\n",
|
|
"------------\n",
|
|
"\n",
|
|
"Systemy dialogowe mo\u017cna zgrubnie podzieli\u0107 na dwie kategorie <cite>(Jurafsky and Martin, 2020)</cite>:\n",
|
|
"\n",
|
|
" 1. chatboty,\n",
|
|
"\n",
|
|
" 2. systemy ukierunkowane na wykonywanie zada\u0144 (ang. task-oriented dialogue agents).\n",
|
|
"\n",
|
|
"### Chatboty\n",
|
|
"Przeznaczeniem chatbota\n",
|
|
"jest prowadzenie swobodnej dyskusji z u\u017cytkownikiem na dowolny (nienarzucony z g\u00f3ry) temat.\n",
|
|
"Konwersacja z chatbotem nie s\u0142u\u017cy wype\u0142nieniu \u017cadnego z g\u00f3ry okre\u015blonego zadania.\n",
|
|
"\n",
|
|
"Klasycznym przyk\u0142adem chatbota jest [ELIZA](https://en.wikipedia.org/wiki/ELIZA) <cite>(Weizenbaum, 1966)</cite>.\n",
|
|
"Program ten,\n",
|
|
"udaj\u0105c psychoanalityka, mia\u0142 zademonstrowa\u0107 potencja\u0142 tkwi\u0105cy w komunikacji cz\u0142owieka z komputerem w\n",
|
|
"j\u0119zyku naturalnym. Jego pythonow\u0105 implementacj\u0119 znajdziemy w pakiecie [nltk](www.nltk.org)."
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"from nltk.chat import eliza\n",
|
|
"eliza.demo()"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"ELIZA sk\u0142ada si\u0119 ze zbioru wzorc\u00f3w, kt\u00f3re s\u0105 dopasowywane do wypowiedzi u\u017cytkownika.\n",
|
|
"Z ka\u017cdym wzorcem jest powi\u0105zany zestaw szablon\u00f3w, kt\u00f3re s\u0105 wykorzystywane do przygotowania\n",
|
|
"odpowiedzi dla u\u017cytkownika."
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "code",
|
|
"execution_count": null,
|
|
"metadata": {},
|
|
"outputs": [],
|
|
"source": [
|
|
"eliza.pairs[:3]"
|
|
]
|
|
},
|
|
{
|
|
"cell_type": "markdown",
|
|
"metadata": {},
|
|
"source": [
|
|
"### Systemy dialogowe ukierunkowane na wykonywanie zada\u0144\n",
|
|
"Systemy ukierunkowane na wykonywanie zada\u0144 b\u0119d\u0105 stanowi\u0107 g\u0142\u00f3wny temat tego przedmiotu.\n",
|
|
"Dla uproszenia b\u0119dziemy je nazywa\u0107 *agentami dialogowymi*.\n",
|
|
"\n",
|
|
"Pierwotnie agenty dialogowe by\u0142y ukierunkowywane na jedno, \u015bci\u015ble okre\u015blone zadanie.\n",
|
|
"Systemem tego typu by\u0142 GUS <cite>(Bobrow, 1977)</cite> umo\u017cliwiaj\u0105cy planowanie podr\u00f3\u017cy.\n",
|
|
"\n",
|
|
"Obecnie zar\u00f3wno w praktyce badawczej jak i w zastosowaniach przemys\u0142owych rozwijane s\u0105 systemy\n",
|
|
"ukierunkowane na wykonywanie wielu zada\u0144 r\u00f3wnocze\u015bnie.\n",
|
|
"*Inteligentne asystenty osobiste* (ang. *IPA*, *Intelligent Personal Assistant*) takie, jak:\n",
|
|
"\n",
|
|
" - [Alexa](https://developer.amazon.com/en-US/alexa),\n",
|
|
" - [Bixby](http://bixby.samsung.com/),\n",
|
|
" - [Google Assistant](https://assistant.google.com/),\n",
|
|
" - [Siri](https://www.apple.com/siri/)\n",
|
|
"\n",
|
|
"realizuj\u0105 wiele cel\u00f3w u\u017cytkownika, do kt\u00f3rych nale\u017c\u0105 m.in.:\n",
|
|
"\n",
|
|
" - wyszukiwanie kontakt\u00f3w w ksi\u0105\u017cce adresowej,\n",
|
|
" - zarz\u0105dzanie kalendarzem,\n",
|
|
" - zmiana ustawie\u0144 telefonu.\n",
|
|
"\n",
|
|
"Zadanie\n",
|
|
"-------\n",
|
|
"Zaimplementowa\u0107 program typu ELIZA prowadz\u0105cy konwersacj\u0119 w j\u0119zyku polskim.\n",
|
|
"Kod \u017ar\u00f3d\u0142owy umie\u015bci\u0107 w ga\u0142\u0119zi `chatbot` repozytorium projektowego.\n",
|
|
"\n",
|
|
"Literatura\n",
|
|
"----------\n",
|
|
" 1. Dan Jurafsky and James H. Martin, *Speech and Language Processing*, 3rd ed. draft,\n",
|
|
"\tch. 24, Chatbots and Dialogue Systems,\n",
|
|
" https://web.stanford.edu/~jurafsky/slp3/24.pdf\n",
|
|
" data dost\u0119pu: 14 marca 2021.\n",
|
|
"\n",
|
|
" 2. J. Weizenbaum, ELIZA - A Computer Program For the Study of Natural Language Communication\n",
|
|
" Between Man And Machine Communications of the ACM, Vol 9, No 1, January 1966,\n",
|
|
" https://cse.buffalo.edu/~rapaport/572/S02/weizenbaum.eliza.1966.pdf\n",
|
|
" data dost\u0119pu: 14 marca 2021.\n",
|
|
"\n",
|
|
" 3. Bobrow, D. G., Kaplan, R. M., Kay, M., Norman, D. A., Thompson, H., and Winograd, T. (1977).\n",
|
|
" GUS, A frame driven dialog system. Artificial Intelligence 8, 155\u2013173."
|
|
]
|
|
}
|
|
],
|
|
"metadata": {
|
|
"jupytext": {
|
|
"cell_metadata_filter": "-all",
|
|
"main_language": "python",
|
|
"notebook_metadata_filter": "-all"
|
|
},
|
|
"author": "Marek Kubis",
|
|
"email": "mkubis@amu.edu.pl",
|
|
"lang": "pl",
|
|
"subtitle": "1.Rodzaje system\u00f3w dialogowych[laboratoria]",
|
|
"title": "Systemy Dialogowe",
|
|
"year": "2021"
|
|
},
|
|
"nbformat": 4,
|
|
"nbformat_minor": 4
|
|
} |