QUALIA IT Personal Assistant
Artificial Intelligence and Reactive Event-based python systems join together.
Version 4.5.0 contains several changes, including:
- Centralized process oriented ZeroMQ, including common shared Threadpool, Logging and ZeroMQ Socket Context
- New action and reaction engine, including action configuration in the frontend
Main features
- Image Classification
- Object Detection
- Face Recognition
- Natural Language Sentiment Analysis
- Chatbot
- Every day utilities: notes, weather
- Action reaction qualias mechanism
Engine Main Features
- Asynchronous calls are the main approach, used as much as possible
- Event-based programming paradigm through pure Publisher/Subscriber architecture
- Publisher/Subscriber ZeroMQ with topic filtering
- Possibility to Balance and scale nodes with multiple Publishers and Subscribers
- Messagepack json compression
- Python Dataclasses standard object representation
- Websockets
- Document driven database MongoDB
- Json Type Serializer used at Typescript level
- Dockerizable with docker-compose
Frontend main functionalities
- Microphone speech detection
- Microphone sound recording
- Speaker text-to-speech
- Webcamera image processing
- Geolocation
- Responsive mobile-first bootstrap based
- Angular 9.x
- Multilanguage support (en,it)
Integrations with external systems:
- Netatmo
- Openweather
- Wikipedia
- JiraServer Rest api
How to use it
Requirements
Main requirements are a machine with:
- Docker installed (docker mode)
- Python >= 3.7.x installed (dev mode)
- Web Browser (Chrome, Safari, Firefox supported)
- OpenSSL installed for generating the certificates (initial setup)
- NodeJS installed (dev mode)
Running the full system in dev mode with the compact run
- Generating the ZeroMQ Certificates is done by:
common/setup.sh
- Run the MongoDB:
docker-compose up mongo or have your local mongo running and available on loopback 127.0.0.1
- Run the all the system with ZeroMQ Inproc:
./start.sh
Running separate services in dev mode
- Generating the ZeroMQ Certificates is done by:
common/setup.sh
- Run the MongoDB:
docker-compose up mongo or have your local mongo running and available on loopback 127.0.0.1
- Run the chainer service:
chainer/start.sh
- Run the mouth service:
mouth/start.sh
- Run the hear service:
hear/start.sh
- Run the system service:
system/start.sh
- Run the sight service:
sse/start.sh
- Run the plugins service:
plugins/start.sh
- Run the sse service:
sse/start.sh
- Finally run the frontend:
sse/start.sh
- Go to
http://127.0.0.1:4200 with your favourite browser
Running the full system in production ready mode
The system is governed by a full Docker system through docker compose.
Before starting the application, you should generate the certificates.
- Generating the ZeroMQ Certificates is done by:
- Go to common folder and:
common/setup.sh
- Go to services/nginx folder
services/nginx/setup.sh
- Build the frontend
web/build.sh
Execute docker-compose up and go to your local browser at https://127.0.0.1, the docker compose will launch
-
Sight docker image (image parsing and classification, face and object recognition)
-
Mouth docker image (output message and voice)
-
Hear docker image (hear sense, text parsing and sentiment analysis)
-
System docker image (main data storage handler and authentication)
-
Plugins docker image (plugin handlers)
-
SSE docker image (websocket forwarder)
-
Chainer docker image (qualias action reaction engine)
-
Mongodb docker image (data persistence service)
-
NGINX docker image (web reverse proxy handler)
-
Portainer docker image (docker services handler)
-
Socat docker image (docker services handler helper)
-
Maxtext docker image (sentiment analysis for text)
Technical standards
- Semantic versioning for git and npm:
[major].[minor].[patch]-[build/beta/rc]
- Angular 9.x with Ivy AOT Compiler
- Standard Python logging formatting with rotation
Local installation of OpenSSL on MACOSX1
In order to generate the certificates, it is required to have the openssl installed in your system
- Install homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
- Install openssl with brew:
brew install openssl
- Install tesseract with brew:
brew install tesseract this is required for OCR Pytesseract to work
- Install the sound file encoder:
brew install libsndfile
Local installation of Kubernetes on MacOSX
- Install homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
- Install minikube
brew install minikube
- Install kompose
- Download the binary
curl -L https://github.com/kubernetes/kompose/releases/download/v1.21.0/kompose-darwin-amd64 -o kompose
- Make it executable
chmod +x kompose
- Move it to the bin folder to be available on the system
sudo mv ./kompose /usr/local/bin/kompose
- Start minikube
minikube start
- Start the docker on minikube
kompose --file docker-compose.yml up
Optional steps are:
- Enable metrics-server
minikube addons enable metrics-server
- See metrics
kubectl get apiservices
Next steps
- Evaluating the possibility to use a generic json schema based generator, with proper serializers and deserializers, marshallers and unmarshallers