Skip to content
This repository has been archived by the owner on Aug 29, 2022. It is now read-only.

Commit

Permalink
Merge pull request #223 from navigateconsulting/release_candidate
Browse files Browse the repository at this point in the history
Release candidate
  • Loading branch information
saikiran2603 authored Sep 3, 2020
2 parents a0cdc6b + 28bcfcf commit d22730c
Show file tree
Hide file tree
Showing 37 changed files with 264 additions and 93 deletions.
13 changes: 11 additions & 2 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,22 @@ Bug fixes

## Major Features and Improvements

* [223](https://github.com/navigateconsulting/eva/pull/223) Added authentication for mongo, and redis containers<br/>
Lazy loading for conversations API and UI<br/>
Changes In Routes (Separate for each component eg: Actions, Conversations, Projects, etc.)<br/>
CSS Tweaks in Conversations Chat Components
Added Entity Display feature respective to the intent selected in the chat

## Bug Fixes and Other Changes

* [213](https://github.com/navigateconsulting/eva/pull/213) Updated documentation
* [214](https://github.com/navigateconsulting/eva/pull/214) Spinner was continously spinning in loop even after the training had completed and getting the completed status in the front end.
* [215](https://github.com/navigateconsulting/eva/pull/215) npm dependancy in package.json file upgraded from 6.13.4 to 6.14.6
* [216](https://github.com/navigateconsulting/eva/pull/216) loadash dependancy in package.json file upgraded from 4.17.15 to 4.17.19
* [216](https://github.com/navigateconsulting/eva/pull/216) and [217](https://github.com/navigateconsulting/eva/pull/217) loadash dependancy in package.json file upgraded from 4.17.15 to 4.17.19
* [218](https://github.com/navigateconsulting/eva/pull/218) and [219](https://github.com/navigateconsulting/eva/pull/219) changes in populating default actions for projects
* [220](https://github.com/navigateconsulting/eva/pull/220) elliptic dependancy in package-lock.json upgraded from 6.5.2 to 6.5.3.
* [221](https://github.com/navigateconsulting/eva/pull/221) removed Credentials yml file from rasa container, presence of this caused rasa to assume channels are used.
* [222](https://github.com/navigateconsulting/eva/pull/222) Sorted Conversations in descending order with respect to timestamp of comversation date and added Full Date on the right side panel in try now page

# Release 2.0.3

Expand All @@ -49,4 +58,4 @@ Bug fixes

* [207](https://github.com/navigateconsulting/eva/pull/207) changes to UI
* [210](https://github.com/navigateconsulting/eva/pull/210) Spinner issue on Manage Project Page has now been resolved, earlier there was a delay in showing the spinner. Conversations Chat was not displaying the slot values earlier, now the issue is fixed.
* [211](https://github.com/navigateconsulting/eva/pull/211) Displaying Conversations In Descending Order so that the latest conversation would be displayed first in the list.
* [211](https://github.com/navigateconsulting/eva/pull/211) Displaying Conversations In Descending Order so that the latest conversation would be displayed first in the list.
2 changes: 1 addition & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ A snippet of how this application works !

We used below projects as chat bot framework.

* [Rasa Open Source](https://github.com/RasaHQ/rasa) Version 1.10.3
* [Rasa Open Source](https://github.com/RasaHQ/rasa) Version 1.10.11

The Application stack is built with Python as backend and Angular as front end.

Expand Down
14 changes: 9 additions & 5 deletions docker-compose.build_from_source.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@ services:
- THREADS=50
- REDIS_URL=redis
- REDIS_PORT=6379
- REDIS_PASS=Y7T6r5re3t8j9yr
- MONGODB_HOST=mongodb
- MONGODB_PORT=27017
- MONGODB_USERNAME=eva
- MONGODB_PASS=evapass
- RASA_SERVER=http://va_custom_rasa:5005/model
ports:
- "3000:3000"
Expand All @@ -21,12 +24,15 @@ services:
- redis

redis:
image: 'redis:4-alpine'
image: redis:latest
command: redis-server --requirepass Y7T6r5re3t8j9yr
ports:
- '6379:6379'

va_trainer_worker:
build: './trainer_worker'
environment:
- REDIS_PASS=Y7T6r5re3t8j9yr
volumes:
- rasa_projects:/rasa_projects
depends_on:
Expand All @@ -39,8 +45,8 @@ services:
environment:
- MONGO_DATA_DIR=/data/db
- MONGO_LOG_DIR=/dev/null
- MONGODB_USER="eva"
- MONGODB_PASS="evapass"
- MONGO_INITDB_ROOT_USERNAME=eva
- MONGO_INITDB_ROOT_PASSWORD=evapass
volumes:
- mongodb:/data/db
ports:
Expand Down Expand Up @@ -70,8 +76,6 @@ services:
- run
- --endpoints
- config/endpoints.yml
- --credentials
- config/credentials.yml
- --debug
- --enable-api
- --cors
Expand Down
14 changes: 9 additions & 5 deletions docker-compose.ngrok_example.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ services:
- THREADS=50
- REDIS_URL=redis
- REDIS_PORT=6379
- REDIS_PASS=Y7T6r5re3t8j9yr
- MONGODB_HOST=mongodb
- MONGODB_PORT=27017
- MONGODB_USERNAME=eva
- MONGODB_PASS=evapass
- RASA_SERVER=http://va_custom_rasa:5005/model
ports:
- "3000:3000"
Expand All @@ -23,14 +26,17 @@ services:
- redis

redis:
image: 'redis:4-alpine'
image: redis:latest
command: redis-server --requirepass Y7T6r5re3t8j9yr
ports:
- '6379:6379'

va_trainer_worker:
build: './trainer_worker'
volumes:
- rasa_projects:/rasa_projects
environment:
- REDIS_PASS=Y7T6r5re3t8j9yr
depends_on:
- redis
- va_api_gateway
Expand All @@ -41,8 +47,8 @@ services:
environment:
- MONGO_DATA_DIR=/data/db
- MONGO_LOG_DIR=/dev/null
- MONGODB_USER="eva"
- MONGODB_PASS="evapass"
- MONGO_INITDB_ROOT_USERNAME=eva
- MONGO_INITDB_ROOT_PASSWORD=evapass
volumes:
- mongodb:/data/db
ports:
Expand Down Expand Up @@ -72,8 +78,6 @@ services:
- run
- --endpoints
- config/endpoints.yml
- --credentials
- config/credentials.yml
- --debug
- --enable-api
- --cors
Expand Down
14 changes: 9 additions & 5 deletions docker-compose.test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,11 @@ services:
- THREADS=50
- REDIS_URL=redis
- REDIS_PORT=6379
- REDIS_PASS=Y7T6r5re3t8j9yr
- MONGODB_HOST=mongodb
- MONGODB_PORT=27017
- MONGODB_USERNAME=eva
- MONGODB_PASS=evapass
- RASA_SERVER=http://custom_rasa:5005/model
ports:
- "3000:3000"
Expand All @@ -31,12 +34,15 @@ services:
- redis

redis:
image: 'redis:4-alpine'
image: redis:latest
command: redis-server --requirepass Y7T6r5re3t8j9yr
ports:
- '6379:6379'

trainer_worker:
build: './trainer_worker'
environment:
- REDIS_PASS=Y7T6r5re3t8j9yr
volumes:
- rasa_projects:/rasa_projects
depends_on:
Expand All @@ -49,8 +55,8 @@ services:
environment:
- MONGO_DATA_DIR=/data/db
- MONGO_LOG_DIR=/dev/null
- MONGODB_USER="eva"
- MONGODB_PASS="evapass"
- MONGO_INITDB_ROOT_USERNAME=eva
- MONGO_INITDB_ROOT_PASSWORD=evapass
volumes:
- mongodb:/data/db
ports:
Expand Down Expand Up @@ -82,8 +88,6 @@ services:
- run
- --endpoints
- config/endpoints.yml
- --credentials
- config/credentials.yml
- --debug
- --enable-api
- --cors
Expand Down
14 changes: 9 additions & 5 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,11 @@ services:
- THREADS=50
- REDIS_URL=redis
- REDIS_PORT=6379
- REDIS_PASS=Y7T6r5re3t8j9yr
- MONGODB_HOST=mongodb
- MONGODB_PORT=27017
- MONGODB_USERNAME=eva
- MONGODB_PASS=evapass
- RASA_SERVER=http://va_custom_rasa:5005/model
ports:
- "3000:3000"
Expand All @@ -22,13 +25,16 @@ services:
- redis

redis:
image: 'redis:4-alpine'
image: redis:latest
command: redis-server --requirepass Y7T6r5re3t8j9yr
ports:
- '6379:6379'

va_trainer_worker:
#image: docker.pkg.github.com/navigateconsulting/virtual-assistant/trainer_worker:latest
image: navigateconsulting/va_trainer_worker
environment:
- REDIS_PASS=Y7T6r5re3t8j9yr
volumes:
- rasa_projects:/rasa_projects
depends_on:
Expand All @@ -41,8 +47,8 @@ services:
environment:
- MONGO_DATA_DIR=/data/db
- MONGO_LOG_DIR=/dev/null
- MONGODB_USER="eva"
- MONGODB_PASS="evapass"
- MONGO_INITDB_ROOT_USERNAME=eva
- MONGO_INITDB_ROOT_PASSWORD=evapass
volumes:
- mongodb:/data/db
ports:
Expand Down Expand Up @@ -75,8 +81,6 @@ services:
- run
- --endpoints
- config/endpoints.yml
- --credentials
- config/credentials.yml
- --debug
- --enable-api
- --cors
Expand Down
2 changes: 1 addition & 1 deletion rasa_custom/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Extend the official Rasa SDK image
FROM rasa/rasa:1.10.3-full
FROM rasa/rasa:1.10.11-full

# Use subdirectory as working directory
#WORKDIR /app/config
Expand Down
2 changes: 2 additions & 0 deletions rasa_custom/endpoints.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,7 @@ tracker_store:
store_type: mongod
url: mongodb://mongodb:27017
db: eva_platform
username: eva
password: evapass
auth_source: admin
collection: conversations
2 changes: 1 addition & 1 deletion trainer_worker/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
celery[redis]
rasa[convert]==1.10.3
rasa[convert]==1.10.11
4 changes: 3 additions & 1 deletion trainer_worker/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@

logger = get_task_logger(__name__)

app = Celery('tasks', broker='redis://redis:6379/0', backend='redis://redis:6379/0')
redis_url = 'redis://:' + os.environ['REDIS_PASS'] + '@redis:6379/0'

app = Celery('tasks', broker=redis_url, backend=redis_url)


@app.task()
Expand Down
6 changes: 3 additions & 3 deletions ui-trainer/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion ui-trainer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
"minimist": ">=0.2.1",
"node-sass": "^4.12.0",
"protractor": "~5.4.0",
"serialize-javascript": ">=2.1.1",
"serialize-javascript": ">=3.1.0",
"ts-node": "~7.0.0",
"tslint": "~5.11.0",
"typescript": "~3.1.6"
Expand Down
1 change: 0 additions & 1 deletion ui-trainer/src/app/app-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import { ApplicationsComponent } from '../app/applications/applications.componen
import { AuthGuard } from './auth.guard';

const routes: Routes = [
// { path: ':atoken', component: AppComponent },
// { path: '', redirectTo: 'home/trainer', pathMatch: 'full' },
{ path: 'applications', component: ApplicationsComponent, canActivate: [AuthGuard] },
{ path: 'home', component: HomeComponent, canActivate: [AuthGuard], children: [
Expand Down
22 changes: 17 additions & 5 deletions ui-trainer/src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { DomSanitizer } from '@angular/platform-browser';
import { Router } from '@angular/router';
import { AuthService } from './common/services/auth.service';
import { environment } from '../environments/environment';
import { ActivatedRoute } from '@angular/router';

@Component({
selector: 'app-root',
Expand All @@ -16,8 +17,9 @@ export class AppComponent {
loggedIn = false;

constructor(private matIconRegistry: MatIconRegistry,
private domSanitizer: DomSanitizer,
private router: Router, public authService: AuthService) {
private domSanitizer: DomSanitizer,
private route: ActivatedRoute,
private router: Router, public authService: AuthService) {
this.matIconRegistry.addSvgIcon(
'project',
this.domSanitizer.bypassSecurityTrustResourceUrl('../assets/images/project.svg')
Expand Down Expand Up @@ -117,15 +119,25 @@ export class AppComponent {
checkTokenValidity() {
if (!this.authService.isTokenExpired()) {
this.loggedIn = true;
this.router.navigate(['/home/trainer'])
if (localStorage.getItem('jwt_token') === 'no_token' && window.location.href.split('/').pop() !== 'applications' && window.location.href.split('/').pop() !== 'home' && window.location.href.split('/').pop() !== '') {
if (window.location.href.split('/').slice(-2)[0] !== 'home' && window.location.href.split('/').slice(-2)[0] !== 'conversations' && window.location.href.split('/').slice(-2)[0] !== 'trainer') {
sessionStorage.setItem('appParamExists', 'Y');
this.router.navigate(['applications', { app: window.location.href.split('/').pop() }]);
} else {
sessionStorage.setItem('appParamExists', 'N');
}
} else {
sessionStorage.setItem('appParamExists', 'N');
this.router.navigate(['applications']);
}
} else {
this.callParentApp();
}
}

callParentApp () {
callParentApp() {
localStorage.clear();
let url = environment.PARENT_APP_URL;
let url = environment.PARENT_APP_URL;
window.open(url, '_self');
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

.main-app-div {
box-sizing: border-box;
height: 740px;
height: 100vh;
}

/* Create two equal columns that floats next to each other */
Expand Down
9 changes: 9 additions & 0 deletions ui-trainer/src/app/applications/applications.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ import { NotificationsService } from '../common/services/notifications.service';
import { MatDialog } from '@angular/material/dialog';
import { ConfirmRefreshComponent } from '../common/modals/confirm-refresh/confirm-refresh.component';
import { ApiService } from '../common/services/apis.service';
import { ActivatedRoute } from '@angular/router';
import { Router } from '@angular/router';

@Component({
selector: 'app-applications',
Expand All @@ -13,9 +15,16 @@ export class ApplicationsComponent implements OnInit {

constructor(public dialog: MatDialog,
public apiService: ApiService,
private route: ActivatedRoute,
private router: Router,
private notificationsService: NotificationsService) { }

ngOnInit() {
if (this.route.snapshot.paramMap.get('app') !== null && this.route.snapshot.paramMap.get('app') !== 'refresh') {
this.router.navigate(['home/' + this.route.snapshot.paramMap.get('app')]);
} else if (this.route.snapshot.paramMap.get('app') === 'refresh') {
this.refreshDB();
}
}

refreshDB() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ <h4 class="mat-subheading-1">Are you sure you want to refresh? By hitting the co
<div class="col-md-6 text-right">
<button mat-raised-button (click)="confirmDelete()" class="submit-button">Confirm</button>
</div>
<div class="col-md-6 text-center">
<div class="col-md-6 text-left">
<button mat-raised-button mat-dialog-close class="cancel-button">Cancel</button>
</div>
</div>
Expand Down
Loading

0 comments on commit d22730c

Please sign in to comment.