{ "cells": [ { "cell_type": "markdown", "id": "8ec2fef2", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "# Prototyping a Basic Chatbot UI\n", "* **Created by:** Eric Martinez\n", "* **For:** Software Engineering 2\n", "* **At:** University of Texas Rio-Grande Valley" ] }, { "cell_type": "markdown", "id": "e989bbe3", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "## Tools and Concepts" ] }, { "cell_type": "markdown", "id": "368cda1a", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "#### Gradio\n", "\n", "Gradio is an open-source Python library that allows developers to create and prototype user interfaces (UIs) and APIs for machine learning applications and LLMs quickly and easily. Three reasons it is a great tool are:\n", "\n", "* Simple and intuitive: Gradio makes it easy to create UIs with minimal code, allowing developers to focus on their models.\n", "* Versatile: Gradio supports a wide range of input and output types, making it suitable for various machine learning tasks.\n", "* Shareable: Gradio interfaces can be shared with others, enabling collaboration and easy access to your models." ] }, { "cell_type": "markdown", "id": "e2888a24", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "#### Chatbots\n", "\n", "Chatbots are AI-powered conversational agents designed to interact with users through natural language. LLMs have the potential to revolutionize chatbots by providing more human-like, accurate, and context-aware responses, leading to more engaging and useful interactions." ] }, { "cell_type": "markdown", "id": "6f24bac1", "metadata": { "slideshow": { "slide_type": "slide" } }, "source": [ "#### Example: Gradio Interface\n" ] }, { "cell_type": "code", "execution_count": null, "id": "4ecdb50a", "metadata": { "slideshow": { "slide_type": "fragment" } }, "outputs": [], "source": [ "!pip -q install --upgrade gradio" ] }, { "cell_type": "code", "execution_count": 3, "id": "0b28a4e7", "metadata": { "slideshow": { "slide_type": "fragment" } }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Running on local URL: http://127.0.0.1:7882\n", "Running on public URL: https://d807b00726b10425a4.gradio.live\n", "\n", "This share link expires in 72 hours. For free permanent hosting and GPU upgrades (NEW!), check out Spaces: https://huggingface.co/spaces\n" ] }, { "data": { "text/html": [ "
" ], "text/plain": [ "