calpoly-csai / api

Official API for the NIMBUS Voice Assistant accessible via HTTP REST protocol.
https://nimbus.api.calpolycsai.com/
GNU General Public License v3.0
9 stars 4 forks source link

Autocomplete for entity synonyms and create get route to fetch entity structure #194

Closed masonmcelvain closed 3 years ago

masonmcelvain commented 3 years ago

What's New?

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Added a synonyms attribute to several entity classes. This is an array of synonym names that are used for matching text typed by the user on the front end, so that the synonym they typed can be replaced with the entity's actual name.

For example, lecturer or teacher would be replaced with Professor.

The get route is called entity_structure and retrieves those synonyms, as well as the names of all the columns for each entity so that we can perform autocomplete with column names as well.

Type of change (pick-one)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration (hardware/operating system/etc).

Ran get requests on Postman to verify that the correct data was being fetched.

Checklist (check-all-before-merge)

formatting help: - [x] means "checked' and - [ ] means "unchecked"

sonarcloud[bot] commented 3 years ago

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication