Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

INTRODUCTION:

Makes chatbot menu options configurable so it can easy to maintain without a dev engineer. So we can add/edit existing menu options.

Status

Status
titleNot started

Owner

Jagadish Pujari

Contributors

Vinu Kumar

Approved

Status
colourYellow
titlein review

Decision

Status
colourBlue
titlePENDING


As a solution owner, I would want to deploy menu options faster without having to depend on a release on both portal and WhatsApp with the following details -

  1. Able to change the text

  2. Able to change the menu options (Add/edit/remove)

  3. Able to create new flows/structure such as introducing new menu options which are not there

  4. Able to change answers to queries

  5. Able to add/edit/remove hyperlinks

  6. Able to analyze the data after changes


It takes place for any owner can change the menu-driven flow for the chatbot and its full flex change any time without doing code change in a git repository.


  • It will help with a faster deployment process.

  • Quick change based on the requirement and easy to deploy.

  • Any time/ anyone / any flow/menu text can change quickly.

  • Add/Edit change the text for Menu options.

Solution 1

Solution 2

Overview

Using AWS container

Enable load and execute config from was container for chatbot.

  • Make literals and chartflow configurable.

  • Keep files in blob storage public accessible.

  • While doing build for chatbot/router run below commands in dockerFile

    Code Block
    FROM node:10.19.0 as builder
    WORKDIR /app
    COPY . /app
    
    ADD http://source.file/config/literals  /config/literals.js 
    ADD http://source.file/config/chatflow  /config/chatflow.js
    RUN npm install
    
    FROM node:10.19-slim
    COPY --from=builder /app .
    EXPOSE 4000 8443
    CMD [ "node", "appRest.js" ]
  • For every build it will download it from blob and add it /router/config/* files.

  • So now we can change the only those required files and do build and deploy

Using API (DB)

Store config in Database to fetch and update config. It all using API’s to create and update config using JSON object as request body.

Code Block
Create
{{host}}/chatbot/config/create
Update
{{host}}/chatbot/config/update

This will take place in jenkins job,

Any owner can update config

Link

https://project-sunbird.atlassian.net/browse/SB-21295

Benefits and risks

(plus) Easy to maintain, add and modify any time Menu options and query answers.

(plus) Now its configurable from outside chatbot so its more easier to deploy.

(plus) Below requirements will satisfy.

  1. Able to change the text

  2. Able to change the menu options (Add/edit/remove)

  3. Able to create new flows/structure such as introducing new menu options which are not there

  4. Able to change answers to queries

  5. Able to add/edit/remove hyper links

  6. Able to analyse the data after changes

(minus) TBA

(plus) We can keep/maintaing all versions of files

(plus) It will help to revert back the old version of files if something went wrong with new version of files.

(minus) Only tech guys can do upload an

(plus) Easy to create and update using API’s

(plus) Jenkins job to read and update config using API’s.

(plus) non tech guys can easy update using API

(minus) Can't revert back to old version config.

(minus) Difficult to maintain versionsing of files.

Criteria

Keep track of the discussion with the following status and steps.

Decision

Status

Next steps

https://project-sunbird.atlassian.net/browse/SB-21488

Status
colourYellow
titlein review

  •  POC
  •  Discussion with DC
  •  Implementation
  •  Verify