LIRI bot is a Language Interpretation and Recognition Interface. It is a command line node application that takes in parameters such as song names, singer's name and movie name and gives back a curated list of related data.
Well I'm glad you asked! In the information age that is today, there are too many search engines that do not give you information that you were looking for. LIRI aims to help solve that problem:
-
With LIRI, you can input and search what you want from the comfort of your local terminal.
-
LIRI takes care of the formatting and gives you only the important information regarding your search target and nothing extra.
-
LIRI is simple to use, with only 4 commands, you can get crucial information about songs, singers or movies.
- The application uses a main
liri.js
file to house the main codes. - The
package.json
houses information about the npm packages that were utilized in this application. - The
package-lock.json
helps users to install the identical package version as were used in this application. - The
random.txt
file houses a single string of text that serves as the input for one of the commands. - The
keys.js
file houses the API key for the Song Search command. - The main
liri.js
is a javascript file that utilizes all of the above files for functionality of this application.
- The application utilize the command line terminal for user input.
- The terminal then takes a user's input and utilizes LIRI to make requests with specific queries to appropriate databases.
- The databases then returns related data, where LIRI receives and parse the resulting data into a curated list of related information about what the user requested.
- LIRI then displays the list onto the command line terminal as well as logging the inputed command, the date and time the command was entered, as well as the resulting data list into a log.txt file.
- As the session data gets logged, LIRI informs the user that the data has been logged successfully.
-
Clone this repository onto your local machine.
-
Open up your GitBash terminal, or just the terminal if you are using Linux or Mac.
-
Type
npm i
ornpm install
(as shown below), and the related packages as well as their dependencies will be installed. -
In the root file, create a
.env
file either by manually creating it, or by typingtouch .env
. -
In the
.env
file, drop the following texts (you will have to drop your own spotify api keys in place of theyour-spotify-id
andyour-spotify-secret
):# Spotify API keys SPOTIFY_ID=your-spotify-id SPOTIFY_SECRET=your-spotify-secret
-
After setting everything up, go back to the command terminal and choose one of the four following commands to type in (you will have to replace the text in quotes with your own search targets):
node liri.js spotify-this-song "song name" node liri.js concert-this "singer name" node liri.js movie-this "movie title" node liri.js do-what-it-says
-
If you chose
node liri.js spotify-this-song "song name"
, LIRI will search thespotify web api
database for data relating to your search target, and will format and output the resulting data in a readable format as shown below: -
If you chose
node liri.js concert-this "singer name"
, LIRI will search theBandsintown api
database for event data relating to the singer you are searching, and will format and output the resulting data in a readable format as shown below: -
If you chose
node liri.js movie-this "movie title"
, LIRI will search theOMDB api
database for data relating to the movie that you are searching, and will output the movie information in a readable format as shown below: -
Finally, if you chose 'node liri.js do-what-it-says', LIRI will run command and search target according to the text string inside the
random.txt
file, and you can manipulate the string inside the file to run different commands, as shown below:-
For example, to run
spotify-this "Song Name"
command, input the following text in therandom.txt
file:spotify-this-song,"Song Name Here"
-
as shown below:
-
Then type the command
node liri.js do-what-it-says
in the terminal to get data automatically. Sample result shown below: -
log.txt
display: -
Note: the session logger logs what LIRI interprets from the command string inside of
random.txt
-
As another example, to run
movie-this "Movie Title"
command, input the following text in therandom.txt
file:movie-this,"Movie Title"
-
as shown below:
-
Then type the command
node liri.js do-what-it-says
in the terminal to get data automatically. Sample result shown below: -
log.txt
display:
-
-
- Project Manager
- Lead Logic Designer
- Lead Application Developer
- Lead README Editor
- Lead Screenshotter
- Lead Content Curator
“Talk is cheap. Show me the code.” ― Linus Torvalds