Giter VIP home page Giter VIP logo

digiteinfotech / kairon Goto Github PK

View Code? Open in Web Editor NEW
246.0 20.0 76.0 156.77 MB

Conversational AI Platform to build effective Proactive Digital Assistants using Visual LLM Chaining

Home Page: https://kairon.nimblework.com/bots

License: Apache License 2.0

Python 97.44% Batchfile 0.01% Shell 0.01% HTML 2.52% Dockerfile 0.03%
nlp machine-learning machine-learning-library bot bots bot-framework botkit rasa rasa-nlu nlu

kairon's Introduction

Python application Codacy Badge Coverage Status

Kairon : You can directly converse with Kairon on Whatsapp and stay informed of our latest releases !

qrcode

Kairon is now envisioned as a conversational digital transformation platform that helps build LLM based digital assistants at scale. It is designed to make the lives of those who work with ai-assistants easy, by giving them a no-coding web interface to adapt , train , test and maintain such assistants . We are now enhancing the backbone of Kairon with a full fledged context management system to build proactive digital assistants .

What is Kairon?

Kairon is currently a set of tools built on the RASA framework with a helpful UI interface . While RASA focuses on technology of chatbots itself. Kairon on the other hand focuses on technology that deal with pre-processing of data that are needed by this framework. These include question augmentation and generation of knowledge graphs that can be used to automatically generate intents, questions and responses. It also deals with the post processing and maintenance of these bots such metrics / follow-up messages etc.

What can it do?

Kairon is open-source. It is a Conversational digital transformation platform: Kairon is a platform that allows companies to create and deploy digital assistants to interact with customers in a conversational manner.

End-to-end lifecycle management: Kairon takes care of the entire digital assistant lifecycle, from creation to deployment and monitoring, freeing up company resources to focus on other tasks. Tethered digital assistants: Kairon’s digital assistants are tethered to the platform, which allows for real-time monitoring of their performance and easy maintenance and updates as needed.

Low-code/no-code interface: Kairon’s interface is designed to be easy for functional users, such as marketing teams or product management, to define how the digital assistant responds to user queries without needing extensive coding skills. Secure script injection: Kairon’s digital assistants can be easily deployed on websites and SAAS products through secure script injection, enabling organizations to offer better customer service and support.

Kairon Telemetry: Kairon’s telemetry feature monitors how users are interacting with the website/product where Kairon was injected and proactively intervenes if they are facing problems, improving the overall user experience. Chat client designer: Kairon’s chat client designer feature allows organizations to create customized chat clients for their digital assistants, which can enhance the user experience and help build brand loyalty.

Analytics module: Kairon’s analytics module provides insights into how users are interacting with the digital assistant, enabling organizations to optimize their performance and provide better service to customers. Robust integration suite: Kairon’s integration suite allows digital assistants to be served in an omni-channel, multi-lingual manner, improving accessibility and expanding the reach of the digital assistant.

Realtime struggle analytics: Kairon’s digital assistants use real-time struggle analytics to proactively intervene when users are facing friction on the product/website where Kairon has been injected, improving user satisfaction and reducing churn. This website can be found at Kairon and is hosted by NimbleWork Inc.

Who uses it ?

Kairon is built for two personas Teams and Individuals who want an easy no-coding interface to create, train, test and deploy digital assistants . One can directly access these features from our hosted website. Teams who want to host the chatbot trainer in-house. They can build it using docker compose. Our teams current focus within NLP is Knowledge Graphs – Do let us know if you are interested.

At this juncture it layers on top of Rasa Open Source

Deployment

Kairon only requires a recent version of Docker and Docker Compose.

Please do the below changes in docker/docker-compose.yml

  1. set env variable server to public IP of the machine where trainer api docker container is running for example: http://localhost:81

  2. Optional, if you want to have google analytics enabled then uncomment trackingid and set google analytics tracking id

  3. set env variable SECRET_KEY to some random key.

    use below command for generating random secret key

    openssl rand -hex 32
  4. run the command.

    cd kairon/docker
    docker-compose up -d
  5. Open http://localhost/ in browser.

  6. To Test use username: [email protected] and password: Changeit@123 to try with demo user

Development

Installation

  1. Kairon requires python 3.10 and mongo 4.0+

  2. Then clone this repo

    git clone https://github.com/digiteinfotech/kairon.git
    cd kairon/
  3. For creating Virtual environment, please follow the link

  4. For installing dependencies

    Windows

    setup.bat   
    

    No Matching distribution found tensorflow-text - remove the dependency from requirements.txt file, as window version is not available #44

    Linux

    chmod 777 ./setup.sh
    sh ./setup.sh
    
  5. For starting augmentation services run

    python -m uvicorn augmentation.paraphrase.server:app --host 0.0.0.0
    
  6. For starting trainer-api services run

    python -m uvicorn kairon.api.app.main:app --host 0.0.0.0 --port 8080
    

System Configuration

Email verification setup

The email.yaml file can be used to configure the process for account confirmation through a verification link sent to the user's mail id. It consists of the following parameters:

  • enable -

    set value to True for enabling email verification, and False to disable.

    You can also use the environment variable EMAIL_ENABLE to change the values.

  • url -

    this url, along with a unique token is sent to the user's mail id for account verification as well as for password reset tasks.

    You can also use the environment variable APP_URL to change the values.

  • email -

    the mail id of the account which sends the confirmation mail.

    You can also use the environment variable EMAIL_SENDER_EMAIL to change the values.

  • password -

    the password of the account which sends the confirmation mail.

    You can also use the environment variable EMAIL_SENDER_PASSWORD to change the values.

  • port -

    the port that is used to send the mail [For ex. "587"].

    You can also use the environment variable EMAIL_SENDER_PORT to change the values.

  • service -

    the mail service that is used to send the confirmation mail [For ex. "gmail"].

    You can also use the environment variable EMAIL_SENDER_SERVICE to change the values.

  • tls -

    set value to True for enabling transport layer security, and False to disable.

    You can also use the environment variable EMAIL_SENDER_TLS to change the values.

  • userid -

    the user ID for the mail service if you're using a custom service for sending mails.

    You can also use the environment variable EMAIL_SENDER_USERID to change the values.

  • confirmation_subject -

    the subject of the mail to be sent for confirmation.

    You can also use the environment variable EMAIL_TEMPLATES_CONFIRMATION_SUBJECT to change the subject.

  • confirmation_body -

    the body of the mail to be sent for confirmation.

    You can also use the environment variable EMAIL_TEMPLATES_CONFIRMATION_BODY to change the body of the mail.

  • confirmed_subject -

    the subject of the mail to be sent after confirmation.

    You can also use the environment variable EMAIL_TEMPLATES_CONFIRMED_SUBJECT to change the subject.

  • confirmed_body -

    the body of the mail to be sent after confirmation.

    You can also use the environment variable EMAIL_TEMPLATES_CONFIRMED_BODY to change the body of the mail.

  • password_reset_subject -

    the subject of the mail to be sent for password reset.

    You can also use the environment variable EMAIL_TEMPLATES_PASSWORD_RESET_SUBJECT to change the subject.

  • password_reset_body -

    the body of the mail to be sent for password reset.

    You can also use the environment variable EMAIL_TEMPLATES_PASSWORD_RESET_BODY to change the body of the mail.

  • password_changed_subject -

    the subject of the mail to be sent after changing the password.

    You can also use the environment variable EMAIL_TEMPLATES_PASSWORD_CHANGED_SUBJECT to change the subject.

  • password_changed_body -

    the body of the mail to be sent after changing the password.

    You can also use the environment variable EMAIL_TEMPLATES_PASSWORD_CHANGED_BODY to change the body of the mail.

Documentation

Documentation for all APIs for Kairon are still being fleshed out. A intermediary version of the documentation is available here. Documentation

Contribute

We ❤️ contributions of all size and sorts. If you find a typo, if you want to improve a section of the documentation or if you want to help with a bug or a feature, here are the steps:

  1. Fork the repo and create a new branch, say rasa-dx-issue1

  2. Fix/improve the codebase

  3. write test cases and documentation for code'

  4. run test cases.

python -m pytest
  1. reformat code using black
python -m black bot_trainer
  1. Commit the changes, with proper comments about the fix.

  2. Make a pull request. It can simply be one of your commit messages.

  3. Submit your pull request and wait for all checks passed.

  4. Request reviews from one of the developers from our core team.

  5. Get a 👍 and PR gets merged.

Built With

Authors

The repository is being maintained and supported by NimbleWork Inc.

See also the list of contributors who participated in this project.

License

Licensed under the Apache License, Version 2.0. Copy of the license

A list of the Licenses of the dependencies of the project can be found at the Link

kairon's People

Contributors

anitej avatar apurupkumar avatar ash-pramila avatar chrisbward avatar deenaik avatar dependabot-preview[bot] avatar digiteinc avatar divkothuru avatar gmayank0310 avatar hasinaxp avatar hghuge avatar himanshugt16 avatar hiteshghuge avatar leothorn avatar maheshsattala avatar monisha98reddy avatar nupur-khare avatar pmestry25 avatar rit1200 avatar sfahad1414 avatar shashank411 avatar siddbane10 avatar snyk-bot avatar sushantpatade avatar udit-pandey avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kairon's Issues

CI/CD pipeline

Create basic CI/CD Pipeline for Repo

  • Create Docker Image with build number in versioning.
  • Push it to Docker hub
  • Find out a way to update documentation of Docker Hub as a CI/CD pipeline.

Knowledge Graphs

  • Sentence Extraction for document
    • Triplet Extraction
    • Graph Formation
    • Graph Traversal Logic
    • Domain Augmentation

Response empty with only Q&A

Hi Guys, i hope you can help me with a situation that is occurring when I call the /chat end-point. When i call the end-point, the response is always empty and I really don't know why.

Response:
{ "success": true, "message": null, "data": { "nlu": { "text": "Hi", "intent": { "id": -5668266704242435470, "name": "greet", "confidence": 0.9999999403953552 }, "entities": [], "intent_ranking": [ { "id": -5668266704242435470, "name": "greet", "confidence": 0.9999999403953552 }, { "id": -1894405930850988402, "name": "new", "confidence": 6.276561492768451e-08 }, { "id": -6269350766581444242, "name": "bye", "confidence": 2.6635090577542542e-08 } ], "response_selector": { "all_retrieval_intents": [], "default": { "response": { "id": null, "responses": null, "response_templates": null, "confidence": 0.0, "intent_response_key": null, "utter_action": "utter_None", "template_name": "utter_None" }, "ranking": [] } } }, "action": [ { "action_name": "utter_greet", "max_confidence": 0.9937130212783813, "policy_name": "policy_1_TEDPolicy" }, { "action_name": "action_listen", "max_confidence": 0.9982038140296936, "policy_name": "policy_1_TEDPolicy" } ], "response": [], "slots": [ "doc_url: None", "document: None", "video: None", "audio: None", "image: None", "order: None", "kairon_action_response: None", "bot: 65985df50ac8038d3104f6ae", "session_started_metadata: {'tabname': 'default', 'is_integration_user': False, 'bot': '65985df50ac8038d3104f6ae', 'account': 2, 'channel_type': 'chat_client'}" ], "events": null, "tabname": "default", "agent_handoff": { "initiate": false, "type": null, "additional_properties": null } }, "error_code": 0 }

image
image
image

Could you help-me with this issue?

Thank you very much.

ReadMe Questions and Concerns that need research

Questions Regarding Our Project that need researching for better information and access

  • Can we use RASA in our project Name ? Research RASA community guidelines

  • Naming Candidates for Project - RASA Rishi , RASA Sensei , RASA DX - need ideas here

  • Which License should we choose ?

docker compose

Hi Team getting the following error
[+] Running 13/13
✘ kairon-worker Error context canceled 1.0s
✘ kairon-history-server Error context canceled 1.0s
✘ kairon-chat Error context canceled 1.0s
✘ duckling Error context canceled 1.0s
✘ kairon-script-executor Error context canceled 1.0s
✘ kairon-action-server Error context canceled 1.0s
✘ kairon-paraphrase Error context canceled 1.0s
✘ kairon-event-server Error context canceled 1.0s
✘ kairon-live-agent Error Head "https://730423251530.dkr... 1.0s
✘ kairon-api Error context canceled 1.0s
✘ kairon-question-generation Error context canceled 1.0s
✘ kairon-ui Error context canceled 1.0s
✘ mongo Error context canceled 1.0s
Error response from daemon: Head "https://730423251530.dkr.ecr.us-east-1.amazonaws.com/v2/kairon-live-agent/manifests/152905": no basic auth credentials

Cannot docker compose

Operating System: Windows

Running command: docker-compose up -d

Result:

Pulling kairon-question-generation (digite/kairon-question-generation:latest)...
ERROR: The image for the service you're trying to recreate has been removed. If you continue, volume data could be lost. Consider backing up your data before continuing.

Continue with the new image? [yN]y
Pulling kairon-question-generation (digite/kairon-question-generation:latest)...
ERROR: pull access denied for digite/kairon-question-generation, repository does not exist or may require 'docker login': denied: requested access to the resource is denied

Video Demo

Could you put a video demo or images so we know what the system looks like before we go through the process of deploying it.

GPU support on event worker

Hi,

As discussed with Fahad on discord - the kairon worker is using CPU and not GPU inside the docker container.

I ran some tests to make sure it wasn't a problem on my side;

version: "3"
services:
  test:
    image: tensorflow/tensorflow:latest-gpu
    command: python -c "import tensorflow as tf;tf.test.gpu_device_name()"
    deploy:
      resources:
        reservations:
          devices:
            - capabilities: [gpu]

and

services:
  test:
    image: nvidia/cuda:10.2-base
    command: nvidia-smi
    deploy:
      resources:
        reservations:
          devices:
            - driver: nvidia
              count: 1
              capabilities: [gpu]

Both worked fine and detected my GPU

I added the same config to kairon-worker;

    deploy:
      resources:
        reservations:
          devices:
            - capabilities: [gpu]

but this did not seem to make a difference.

I inquired to check the Dockerfile for the worker, and noticed that there are no packages installed or drivers for the image.

Found some steps here for someone to implement;
https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/efa-start-nccl-base.html

Api action

Hello all
how can I create an API action? I don't see any doc or any example for it

I get this error :

The fields "{'headers'}" do not exist on the document "HttpActionConfig"

I have this simple get request https://61e13d1463f8fc0017618ac5.mockapi.io/test/akbar
and the response will be :

{
"key_test": "value_test"
}

I have one Rule which I want to use this api action. So which fields Should I fill.
in api action there are : Action name | request_type | Headers | Body | Response
How should I fill these parts

GET http://kairon-chat:5000/api/bot/6526d1e07776256c76530d47/conversation net::ERR_NAME_NOT_RESOLVED

"I have deployed Kairon on a Windows operating system, but when I try to run a chat in the chat box, I encounter the following errors:

GET http://kairon-chat:5000/api/bot/6526d1e07776256c76530d47/conversation net::ERR_NAME_NOT_RESOLVED
POST http://localhost:8000/api/bot/6526d1e07776256c76530d47/metric/user/logs/user_metrics net::ERR_CONNECTION_REFUSED
Can anyone help me understand and resolve these [issues?"[]
20dedde159ac8ef2d7bd

RTL support for texts

Hi
On the kairon website When I want to label my entities ( when highlighting the specific word ) it will not work properly. for example, look at this example. The text loses its word order. this is because the textarea tag in your webpage does not support RTL texts.

1
it should be :

محل کارم [مرکز تهران] (tehran_district) شده. اونجاها کجا میشه قهوه [عربیکا] (coffee_type) خوب خرید

github textarea support RTL . :)

will you support this feature soon?

Docker Images does not exist - kairon-history-server and kairon-chat

Operating System: Linux Ubuntu 21.04
Running command: docker-compose up -d

Result:

Pulling kairon-question-generation (digite/kairon-question-generation:latest)...
ERROR: The image for the service you're trying to recreate has been removed. If you continue, volume data could be lost. Consider backing up your data before continuing.

Continue with the new image? [yN]y
Pulling kairon-question-generation (digite/kairon-question-generation:latest)...
ERROR: pull access denied for digite/kairon-question-generation, repository does not exist or may require 'docker login': denied: requested access to the resource is denied

Email notifications?

When a conversation begins. When someone submits something (assuming forms can be filled using the bot). Based on certain keywords the visitor types in.

Strict Bot Training

if the particular bot is getting trained then no other user must be able to trigger training, till the previous training session is completed

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.