<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Ggarrid</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Ggarrid"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Ggarrid"/>
	<updated>2026-08-21T22:16:05Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145703</id>
		<title>PeerLogic Web Services: Python Web Service Template</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145703"/>
		<updated>2022-05-10T04:25:27Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Conclusion */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to provide a useful template for creating a new PeerLogic web service, and provide some guided steps in how to modify it for new needs. This template is specifically made for Python 3 web applications.&lt;br /&gt;
&lt;br /&gt;
==Video Walkthrough==&lt;br /&gt;
This is essentially a written alternative/supplement to a recorded video walking through the set up of the &amp;quot;AllReviewInterface&amp;quot; service. If you would like a more visual or hands-on demonstration of the information presented here, please check out the following link (or watch the video as you read through this written material): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
==Foreword: Necessary Tools and Permissions==&lt;br /&gt;
Before beginning to create a web service, you will need some tools and permissions. These are:&lt;br /&gt;
* '''A way to SSH to a remote server''': you can do this through the &amp;quot;ssh&amp;quot; command on Mac or Linux, or through the PuTTY application on Windows.&lt;br /&gt;
* '''A way to send API''': Any will do, but I personally recommend Insomnia, as I find its interface easy to use and good for troubleshooting.&lt;br /&gt;
* '''Sudo access to the Peer Logic web server''': You will need sudo access in order to modify the config files to set up the web service. Request this from CSC IT and CC Dr. Gehringer so he can agree to give you permission. In case it needs saying: don't abuse this access, or things will go poorly!&lt;br /&gt;
&lt;br /&gt;
With all of these tools, we can begin to create a web service.&lt;br /&gt;
&lt;br /&gt;
==Template: AllReviewInterface==&lt;br /&gt;
The template being used for this tutorial is the &amp;quot;AllReviewInterface&amp;quot; web service. This is a working web service on PeerLogic, accessible at peerlogic.csc.ncsu.edu/allreviewinterface/call_models, which has its functionality limited to a single short python file, making it easy to understand and use. The GitHub for this project can be found here: [https://github.com/peerlogic/AllReviewInterface https://github.com/peerlogic/AllReviewInterface].&lt;br /&gt;
&lt;br /&gt;
To begin with, clone this repository and rename it to the name of the project you intend to create. You should also (whether now or after writing the code) update the README for your project. The README for the AllReviewInterface serves as a good template for the basic information your README should provide (general summary of functionality, the port number and URL to access it from on PeerLogic, and the expected Input and Output with explanations and examples).&lt;br /&gt;
&lt;br /&gt;
==Using Flask==&lt;br /&gt;
This application works through utilizing Flask, a Python module which allows your application to accept API requests. As is, you should be able to run the AllReviewInterface program and launch a Flask application. You can then communicate with this application by sending it API (through the tool outlined in the foreword). The AllReviewInterface can be tested in this way by sending its example input (as shown in its README) to &amp;quot;localhost:3013/call_models&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
There are two important configuration details to modify within this application: the port number, and the URL route.&lt;br /&gt;
&lt;br /&gt;
The port number is described on line 53 of the AllReviewInterface's &amp;quot;flaskapp.py&amp;quot;, under &amp;quot;if __name__ == '__main__':&amp;quot;. This determines what port the application is run on, both on your computer and on PeerLogic. Set this to a new, unused port (to see which ports are unused, refer to the configuration spreadsheet here: [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing]).&lt;br /&gt;
&lt;br /&gt;
The URL route specifies the exact route necessary to reach particular code. In the case of AllReviewInterface, there is only one such route, &amp;quot;/call_models&amp;quot;, which is specified on line 15 by &amp;quot;@app.route('/call_models',methods=['POST']). When a user accesses this route, the function defined immediately after it (in the template's case, &amp;quot;call_models()&amp;quot;) is run. If the method specified is a POST method, the information within that POST can be accessed via flask.request.json. Rename the given route to one that better suits your use case, and feel free to create multiple routes if appropriate in order to have multiple supported methods.&lt;br /&gt;
&lt;br /&gt;
Note that, to return the results of your web service, you must return a flask.Response object, containing the string which is your results. This can be seen in the template by the return statement of call_models(), on line 50.&lt;br /&gt;
&lt;br /&gt;
Replace the code within this template with your own, renaming/reconfiguring the details described above, in order to create your own web service. You can also spread your code across multiple files, so long as the Flask code is contained within the given template file, and that is the file that is run on the PeerLogic server.&lt;br /&gt;
&lt;br /&gt;
==Setting Up a Virtual Environment==&lt;br /&gt;
A difficult issue when running Python code is the necessity for packages. In fact, the &amp;quot;flask&amp;quot; package itself is not part of Python's standard libraries, and must be installed manually. While a user can do this easily using the &amp;quot;pip&amp;quot; command, this will not work on the PeerLogic server, as the root user will not have the necessary packages (and we don't want to download them for the root, as it might corrupt the server).&lt;br /&gt;
&lt;br /&gt;
This problem can be alleviated through the use of virtual environments. A virtual environment can essentially be set up and contain all the packages necessary to run an application, without those packages needing to be installed by a user. This makes them great for sending code to be executed by others.&lt;br /&gt;
&lt;br /&gt;
Create a virtual environment for your application using the command: &lt;br /&gt;
&amp;lt;pre&amp;gt;python3 -m venv /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will create a virtual environment in the same directory as your application named &amp;quot;venv&amp;quot;. Activate this virtual environment using the command:&lt;br /&gt;
&amp;lt;pre&amp;gt;source venv/bin/activate&amp;lt;/pre&amp;gt;&lt;br /&gt;
(NOTE: this will only work on Unix or Mac. I would recommend installing WSL2 if on a Windows system, as virtual environments are difficult to use in Windows command line)&lt;br /&gt;
&lt;br /&gt;
Now that you are in the virtual environment, attempt to run your application (for example, by using the command &amp;quot;python3 flaskapp.py&amp;quot;). If there are any non-standard packages required for your application (such as flask), you will receive an import error naming the missing package. Install that package using &amp;quot;pip install &amp;lt;package_name&amp;gt;&amp;quot;, and continue doing so until you no longer receive errors.&lt;br /&gt;
&lt;br /&gt;
You have now created a virtual environment containing all the packages necessary to run your application, without downloading any onto your personal Python installation. However, you cannot send a virtual environment directly onto the PeerLogic server (it won't set up correctly). Instead, you will want to create a virtual environment on the server itself. You can make this easier by creating a &amp;quot;requirements.txt&amp;quot; file using your current virtual environment. Use this command after you have installed all the necessary packages for your application:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;pip freeze &amp;gt; requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will export all of the installed packages into a text file. I would recommend going into the text file and removing the version numbers from all of the packages, as this will make them easier to run on the older distribution of Python the server uses (for example, changing the line &amp;quot;flask==2.0.3&amp;quot; to just &amp;quot;flask&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
You can exit the virtual environment when you are done using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This concludes all of the code and work you need to do to set up the source code for your web service!&lt;br /&gt;
&lt;br /&gt;
==Getting Code Onto The Server==&lt;br /&gt;
Once you have completed the above, access the PeerLogic server (see the main documentation page for details on how to do this: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services]) and navigate to the webservices directory. Once there, clone your repository into the directory using a command like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;git clone https://github.com/peerlogic/&amp;lt;name_of_your_repo&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
(Note: if your repository is not currently part of the peerlogic group, change its ownership to the group! This will allow others to edit and upkeep your work in the future)&lt;br /&gt;
&lt;br /&gt;
This will clone over your code onto the server. However, your virtual environment will not be set up. To set it up, navigate to the directory containing your requirements.txt file and use the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;virtualenv --python=/usr/bin/python3.6 /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
(note: if this fails, you may need to install the virtualenv package. Do so with &amp;quot;pip install virtualenv&amp;quot; and repeat this step)&lt;br /&gt;
(double note: this command is different from the previous because the server runs an older version of Python)&lt;br /&gt;
&lt;br /&gt;
This will set up a new virtual environment. Activate the environment using the prior mentioned command. Now, you can install all of the required packages by simply using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;pip install -r requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will automatically install all listed packages. You can then test to make sure your application is working by running &amp;quot;python3 &amp;lt;your_app.py)&amp;quot;. If flask successfully launches, congratulations! You have set up your web service! Whenever you are done testing, you can leave the virtual environment using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
==Properly Configuring the Server==&lt;br /&gt;
A final important note is how to set up the server such that your application is properly set up and run. Doing this will require the server to not simply launch your application, but to first enter its virtual environment, run the application, and then exit the environment.&lt;br /&gt;
&lt;br /&gt;
Upon its daily reboot, the server will run the contents of the file runws_root.sh, located within the webservices directory. Edit this file (through a command such as &amp;quot;nano runws_root.sh&amp;quot;) and add a new line for your Flask application. The syntax for this line should be very similar to the existing code to set up the AllReviewInterface application, and should look like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;your_application_repo_name&amp;gt;/app/ &amp;amp;&amp;amp; source venv/bin/activate &amp;amp;&amp;amp; (python3 &amp;lt;your_app.py&amp;gt; &amp;amp;) &amp;amp;&amp;amp; deactivate&amp;lt;/pre&amp;gt;&lt;br /&gt;
To break down what this is doing, the root user will perform the following actions in order:&lt;br /&gt;
*navigate to where your Flask application is located&lt;br /&gt;
*activate the virtual environment&lt;br /&gt;
*run your application with the &amp;quot;&amp;amp;&amp;quot; character, allowing it to run in the background while the root user moves on&lt;br /&gt;
*deactivate the virtual environment&lt;br /&gt;
&lt;br /&gt;
It is important to exit the virtual environment at the end, so as to allow the root user to continue doing what it needs to do. With this, the server will now properly run your application at every reboot.&lt;br /&gt;
&lt;br /&gt;
The final step is to set up the route to call your application. Do this by editting NGINX's configuration file, located at /etc/nginx/nginx.conf (for example, using the command &amp;quot;sudo nano /etc/nginx/nginx.conf&amp;quot;). '''Be very careful editting this file!''' If you somehow break it beyond repair, a backup exists in the google drive with all the documentation.&lt;br /&gt;
&lt;br /&gt;
Go down to the bottom of this file and add in a line similar to the following, substituting in the name of the URL path you set up for your application and the port you set up for your application:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass http://localhost:&amp;lt;PORT_FOR_APPLICATION_YOU_SET_UP&amp;gt;/;&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The other existing locations within the file should be reasonable examples.&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
Congratulations! This concludes this tutorial, and this should be sufficient to let you set up and run your own Python Web Service on PeerLogic. Please check out the video walkthrough linked at the top of this page for a more visual demonstration of these steps, and if you run into any trouble, check out this document for some useful troubleshooting tips: [https://docs.google.com/document/d/1oI8TTMW_WzYdsDsWXuT5_3-H8hea3Rq-YWswoLBQ81k/edit?usp=sharing https://docs.google.com/document/d/1oI8TTMW_WzYdsDsWXuT5_3-H8hea3Rq-YWswoLBQ81k/edit?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
I hope you have success with this. Do good work!&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145702</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145702"/>
		<updated>2022-05-10T04:22:34Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Documentation and Backup Drive */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The PeerLogic web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Videos here].&lt;br /&gt;
&lt;br /&gt;
==Current Status of Web Services==&lt;br /&gt;
The status of all currently supported or developed web services can be found at this google sheet (note: this link is editable, as this document should be updated as new services are added or modified. Please edit responsibly!): [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
This sheet also notes the ports which are currently used by all services, and the URLs each service is accessible from.&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server. Ensure that your application is set up to run on a currently unoccupied port. The list of currently used ports can be found on the first sheet of the configuration sheet [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing linked here].&lt;br /&gt;
* Transfer that code over to the PeerLogic GitHub group (if you are not part of the group, join it!) This will ensure anyone in the future will be able to access and modify your code.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to where the web services are located, using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Located here are GitHub repos of all of the web services. If you intend to update an already-deployed service, simply enter the repository for that service and perform the following command to pull the changes:&lt;br /&gt;
&amp;lt;pre&amp;gt;git pull&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Make sure the changes are working by running the new version locally and testing using API (see demonstration videos for more details)&lt;br /&gt;
* Make sure the code still works the next day (after the server reset)&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
===Template and Walkthrough===&lt;br /&gt;
&lt;br /&gt;
If you are just starting out and are willing to work in Python, a web service template has been created with explicit instructions, in both written and video form. It is recommended to use this as your approach unless you have something else specific in mind. To find these resources, click here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template].&lt;br /&gt;
&lt;br /&gt;
===General Instructions===&lt;br /&gt;
* First, clone your remote PeerLogic GitHub repository into the webservices directory under /opt/webservices. This will put the application code onto the server.&lt;br /&gt;
* Next, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within (see the video demonstration for more details on this).&lt;br /&gt;
* After doing all this, navigate to and edit /etc/nginx/nginx.conf (you will need sudo access to do this)&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the spreadsheet to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service (this is very similar to the already existing mappings within the file):&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Reload nginx to update the changes to the config file and allow the new route to be properly redirected using the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
* After the next server restart, your service should be automatically started. You can test whether the new service is working immediately by running it yourself, and setting it to automatically run in the background. If you were running a python script, this may be something like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python3 &amp;lt;your_application_name.py&amp;gt; &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NOTE: it is highly recommended to watch the demonstration video for setting up a new WebService, particularly if working in Python, which can be viewed at the page linked in the above section, as well as by clicking this link (while logged into your NCState account): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
=Currently Active Web Services=&lt;br /&gt;
For the sake of this section, &amp;quot;currently active&amp;quot; means that these services are currently running on the PeerLogic web server and have known inputs, such that we can get useful results from them. Other web services may also technically be accessible, but may not currently have known inputs.&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This service is currently being used by the Expertiza website for forming project groups.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
The RainbowGraphService is actively used by collaborators outside the university for visualizations.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/peerlogic/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==reputation==&lt;br /&gt;
reputation is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
This web service is not currently utilized, though students have recently (in Spring of 2022) created a project to utilize this service on Expertiza.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. &lt;br /&gt;
&lt;br /&gt;
This web service is actively utilized by Expertiza for automated tagging of reviews. It should be noted that this service is not run on the PeerLogic web server, but is instead run on the active learning web server, at http://152.7.99.200:5000. Please see the README in the GitHub or the documentation below for more information.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
==AllReviewInterface==&lt;br /&gt;
AllReviewInterface is a Python-based service that allows one to send a collection of student reviews to several of the Peer-reviews-NLP services in one function call, returning the results from each.&lt;br /&gt;
&lt;br /&gt;
This web service is not intended for particular use (apart from perhaps being convenient for certain research applications), and was primarily created to serve as a template for future web services.&lt;br /&gt;
&lt;br /&gt;
This project does not have extended documentation, but the specifics of how to create a new web service using it as a template can be found [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template here], and necessary information to run the service can be found in its GitHub README.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AllReviewInterface].&lt;br /&gt;
&lt;br /&gt;
=Other Documented Services=&lt;br /&gt;
Besides the active web services listed above, several other services have existing documentation, despite their currently non-functional state. It is possible these services could be upgraded to &amp;quot;active&amp;quot; if one determined the input they required or fixed the deployment issues they may have.&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
=Legacy Resources=&lt;br /&gt;
All prior documentation was originally created by Geoff Garrido in Spring of 2022, to replace and expand upon existing documentation.&lt;br /&gt;
&lt;br /&gt;
The following are saved legacy resources of that prior documentation, in the case that the above documentation is insufficient or more nuanced information about how the PeerLogic server used to run is necessary.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
=Documentation and Backup Drive=&lt;br /&gt;
A Google Drive has been created containing all the videos, spreadsheets, presentations, and backups for the PeerLogic web services. It can be accessed here: [https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
In particular, because they are not backed up in any form of GitHub repositories (unlike the project code), this Google Drive contains backups of the most important configuration files for the PeerLogic web server: nginx.conf, runws_root.sh, runws_user.sh, and the contents of the cron jobs. Two versions of these files currently exist: the ones containing in their title &amp;quot;fall2021&amp;quot; refer to the state of the PeerLogic Web Services before the work done in Spring 2022 by Geoff Garrido. Those containing in their title &amp;quot;spring2022&amp;quot; refer to the state of the PeerLogic Web Services after the work done in Spring of 2022.&lt;br /&gt;
&lt;br /&gt;
The more recent versions should be used as backups in all cases, unless something about the new versions is wrong, in which case the legacy versions are also provided.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145701</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145701"/>
		<updated>2022-05-10T04:12:06Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Currently Active Web Services */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The PeerLogic web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Videos here].&lt;br /&gt;
&lt;br /&gt;
==Current Status of Web Services==&lt;br /&gt;
The status of all currently supported or developed web services can be found at this google sheet (note: this link is editable, as this document should be updated as new services are added or modified. Please edit responsibly!): [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
This sheet also notes the ports which are currently used by all services, and the URLs each service is accessible from.&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server. Ensure that your application is set up to run on a currently unoccupied port. The list of currently used ports can be found on the first sheet of the configuration sheet [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing linked here].&lt;br /&gt;
* Transfer that code over to the PeerLogic GitHub group (if you are not part of the group, join it!) This will ensure anyone in the future will be able to access and modify your code.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to where the web services are located, using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Located here are GitHub repos of all of the web services. If you intend to update an already-deployed service, simply enter the repository for that service and perform the following command to pull the changes:&lt;br /&gt;
&amp;lt;pre&amp;gt;git pull&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Make sure the changes are working by running the new version locally and testing using API (see demonstration videos for more details)&lt;br /&gt;
* Make sure the code still works the next day (after the server reset)&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
===Template and Walkthrough===&lt;br /&gt;
&lt;br /&gt;
If you are just starting out and are willing to work in Python, a web service template has been created with explicit instructions, in both written and video form. It is recommended to use this as your approach unless you have something else specific in mind. To find these resources, click here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template].&lt;br /&gt;
&lt;br /&gt;
===General Instructions===&lt;br /&gt;
* First, clone your remote PeerLogic GitHub repository into the webservices directory under /opt/webservices. This will put the application code onto the server.&lt;br /&gt;
* Next, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within (see the video demonstration for more details on this).&lt;br /&gt;
* After doing all this, navigate to and edit /etc/nginx/nginx.conf (you will need sudo access to do this)&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the spreadsheet to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service (this is very similar to the already existing mappings within the file):&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Reload nginx to update the changes to the config file and allow the new route to be properly redirected using the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
* After the next server restart, your service should be automatically started. You can test whether the new service is working immediately by running it yourself, and setting it to automatically run in the background. If you were running a python script, this may be something like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python3 &amp;lt;your_application_name.py&amp;gt; &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NOTE: it is highly recommended to watch the demonstration video for setting up a new WebService, particularly if working in Python, which can be viewed at the page linked in the above section, as well as by clicking this link (while logged into your NCState account): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
=Currently Active Web Services=&lt;br /&gt;
For the sake of this section, &amp;quot;currently active&amp;quot; means that these services are currently running on the PeerLogic web server and have known inputs, such that we can get useful results from them. Other web services may also technically be accessible, but may not currently have known inputs.&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This service is currently being used by the Expertiza website for forming project groups.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
The RainbowGraphService is actively used by collaborators outside the university for visualizations.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/peerlogic/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==reputation==&lt;br /&gt;
reputation is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
This web service is not currently utilized, though students have recently (in Spring of 2022) created a project to utilize this service on Expertiza.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. &lt;br /&gt;
&lt;br /&gt;
This web service is actively utilized by Expertiza for automated tagging of reviews. It should be noted that this service is not run on the PeerLogic web server, but is instead run on the active learning web server, at http://152.7.99.200:5000. Please see the README in the GitHub or the documentation below for more information.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
==AllReviewInterface==&lt;br /&gt;
AllReviewInterface is a Python-based service that allows one to send a collection of student reviews to several of the Peer-reviews-NLP services in one function call, returning the results from each.&lt;br /&gt;
&lt;br /&gt;
This web service is not intended for particular use (apart from perhaps being convenient for certain research applications), and was primarily created to serve as a template for future web services.&lt;br /&gt;
&lt;br /&gt;
This project does not have extended documentation, but the specifics of how to create a new web service using it as a template can be found [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template here], and necessary information to run the service can be found in its GitHub README.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AllReviewInterface].&lt;br /&gt;
&lt;br /&gt;
=Other Documented Services=&lt;br /&gt;
Besides the active web services listed above, several other services have existing documentation, despite their currently non-functional state. It is possible these services could be upgraded to &amp;quot;active&amp;quot; if one determined the input they required or fixed the deployment issues they may have.&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
=Legacy Resources=&lt;br /&gt;
All prior documentation was originally created by Geoff Garrido in Spring of 2022, to replace and expand upon existing documentation.&lt;br /&gt;
&lt;br /&gt;
The following are saved legacy resources of that prior documentation, in the case that the above documentation is insufficient or more nuanced information about how the PeerLogic server used to run is necessary.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
=Documentation and Backup Drive=&lt;br /&gt;
A Google Drive has been created containing all the videos, spreadsheets, presentations, and backups for the PeerLogic web services. It can be accessed here: [https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
In particular, because they are not backed up in any form of GitHub repositories (unlike the project code), this Google Drive contains backups of the most important configuration files for the PeerLogic web server: nginx.conf, runws_root.sh, runws_user.sh, and the contents of the cron jobs. These are accurate as of 2022-10-05.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145700</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145700"/>
		<updated>2022-05-10T03:59:41Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The PeerLogic web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Videos here].&lt;br /&gt;
&lt;br /&gt;
==Current Status of Web Services==&lt;br /&gt;
The status of all currently supported or developed web services can be found at this google sheet (note: this link is editable, as this document should be updated as new services are added or modified. Please edit responsibly!): [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
This sheet also notes the ports which are currently used by all services, and the URLs each service is accessible from.&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server. Ensure that your application is set up to run on a currently unoccupied port. The list of currently used ports can be found on the first sheet of the configuration sheet [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing linked here].&lt;br /&gt;
* Transfer that code over to the PeerLogic GitHub group (if you are not part of the group, join it!) This will ensure anyone in the future will be able to access and modify your code.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to where the web services are located, using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Located here are GitHub repos of all of the web services. If you intend to update an already-deployed service, simply enter the repository for that service and perform the following command to pull the changes:&lt;br /&gt;
&amp;lt;pre&amp;gt;git pull&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Make sure the changes are working by running the new version locally and testing using API (see demonstration videos for more details)&lt;br /&gt;
* Make sure the code still works the next day (after the server reset)&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
===Template and Walkthrough===&lt;br /&gt;
&lt;br /&gt;
If you are just starting out and are willing to work in Python, a web service template has been created with explicit instructions, in both written and video form. It is recommended to use this as your approach unless you have something else specific in mind. To find these resources, click here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template].&lt;br /&gt;
&lt;br /&gt;
===General Instructions===&lt;br /&gt;
* First, clone your remote PeerLogic GitHub repository into the webservices directory under /opt/webservices. This will put the application code onto the server.&lt;br /&gt;
* Next, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within (see the video demonstration for more details on this).&lt;br /&gt;
* After doing all this, navigate to and edit /etc/nginx/nginx.conf (you will need sudo access to do this)&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the spreadsheet to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service (this is very similar to the already existing mappings within the file):&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Reload nginx to update the changes to the config file and allow the new route to be properly redirected using the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
* After the next server restart, your service should be automatically started. You can test whether the new service is working immediately by running it yourself, and setting it to automatically run in the background. If you were running a python script, this may be something like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python3 &amp;lt;your_application_name.py&amp;gt; &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NOTE: it is highly recommended to watch the demonstration video for setting up a new WebService, particularly if working in Python, which can be viewed at the page linked in the above section, as well as by clicking this link (while logged into your NCState account): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
=Currently Active Web Services=&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. It is actively used by expertiza to do review tagging using ML.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145699</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145699"/>
		<updated>2022-05-10T03:49:51Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Videos here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* Transfer that code over to the PeerLogic GitHub group (if you are not part of the group, join it!) This will ensure anyone in the future will be able to access and modify your code.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to where the web services are located, using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Located here are GitHub repos of all of the web services. If you intend to update an already-deployed service, simply enter the repository for that service and perform the following command to pull the changes:&lt;br /&gt;
&amp;lt;pre&amp;gt;git pull&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Make sure the changes are working by running the new version locally and testing using API (see demonstration videos for more details)&lt;br /&gt;
* Make sure the code still works the next day (after the server reset)&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
===Template and Walkthrough===&lt;br /&gt;
&lt;br /&gt;
If you are just starting out and are willing to work in Python, a web service template has been created with explicit instructions, in both written and video form. It is recommended to use this as your approach unless you have something else specific in mind. To find these resources, click here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Python_Web_Service_Template].&lt;br /&gt;
&lt;br /&gt;
===General Instructions===&lt;br /&gt;
* First, clone your remote PeerLogic GitHub repository into the webservices directory under /opt/webservices. This will put the application code onto the server.&lt;br /&gt;
* Next, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within (see the video demonstration for more details on this).&lt;br /&gt;
* After doing all this, navigate to and edit /etc/nginx/nginx.conf (you will need sudo access to do this)&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the spreadsheet to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service (this is very similar to the already existing mappings within the file):&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Reload nginx to update the changes to the config file and allow the new route to be properly redirected using the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
* After the next server restart, your service should be automatically started. You can test whether the new service is working immediately by running it yourself, and setting it to automatically run in the background. If you were running a python script, this may be something like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python3 &amp;lt;your_application_name.py&amp;gt; &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
NOTE: it is highly recommended to watch the demonstration video for setting up a new WebService, particularly if working in Python, which can be viewed at the page linked in the above section, as well as by clicking this link (while logged into your NCState account): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. It is actively used by expertiza to do review tagging using ML.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145698</id>
		<title>PeerLogic Web Services: Python Web Service Template</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145698"/>
		<updated>2022-05-10T03:49:35Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to provide a useful template for creating a new PeerLogic web service, and provide some guided steps in how to modify it for new needs. This template is specifically made for Python 3 web applications.&lt;br /&gt;
&lt;br /&gt;
==Video Walkthrough==&lt;br /&gt;
This is essentially a written alternative/supplement to a recorded video walking through the set up of the &amp;quot;AllReviewInterface&amp;quot; service. If you would like a more visual or hands-on demonstration of the information presented here, please check out the following link (or watch the video as you read through this written material): [https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing https://drive.google.com/file/d/15Q5hBXU4umpJN8gStLryo5XdNiy1xZay/view?usp=sharing].&lt;br /&gt;
&lt;br /&gt;
==Foreword: Necessary Tools and Permissions==&lt;br /&gt;
Before beginning to create a web service, you will need some tools and permissions. These are:&lt;br /&gt;
* '''A way to SSH to a remote server''': you can do this through the &amp;quot;ssh&amp;quot; command on Mac or Linux, or through the PuTTY application on Windows.&lt;br /&gt;
* '''A way to send API''': Any will do, but I personally recommend Insomnia, as I find its interface easy to use and good for troubleshooting.&lt;br /&gt;
* '''Sudo access to the Peer Logic web server''': You will need sudo access in order to modify the config files to set up the web service. Request this from CSC IT and CC Dr. Gehringer so he can agree to give you permission. In case it needs saying: don't abuse this access, or things will go poorly!&lt;br /&gt;
&lt;br /&gt;
With all of these tools, we can begin to create a web service.&lt;br /&gt;
&lt;br /&gt;
==Template: AllReviewInterface==&lt;br /&gt;
The template being used for this tutorial is the &amp;quot;AllReviewInterface&amp;quot; web service. This is a working web service on PeerLogic, accessible at peerlogic.csc.ncsu.edu/allreviewinterface/call_models, which has its functionality limited to a single short python file, making it easy to understand and use. The GitHub for this project can be found here: [https://github.com/peerlogic/AllReviewInterface https://github.com/peerlogic/AllReviewInterface].&lt;br /&gt;
&lt;br /&gt;
To begin with, clone this repository and rename it to the name of the project you intend to create. You should also (whether now or after writing the code) update the README for your project. The README for the AllReviewInterface serves as a good template for the basic information your README should provide (general summary of functionality, the port number and URL to access it from on PeerLogic, and the expected Input and Output with explanations and examples).&lt;br /&gt;
&lt;br /&gt;
==Using Flask==&lt;br /&gt;
This application works through utilizing Flask, a Python module which allows your application to accept API requests. As is, you should be able to run the AllReviewInterface program and launch a Flask application. You can then communicate with this application by sending it API (through the tool outlined in the foreword). The AllReviewInterface can be tested in this way by sending its example input (as shown in its README) to &amp;quot;localhost:3013/call_models&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
There are two important configuration details to modify within this application: the port number, and the URL route.&lt;br /&gt;
&lt;br /&gt;
The port number is described on line 53 of the AllReviewInterface's &amp;quot;flaskapp.py&amp;quot;, under &amp;quot;if __name__ == '__main__':&amp;quot;. This determines what port the application is run on, both on your computer and on PeerLogic. Set this to a new, unused port (to see which ports are unused, refer to the configuration spreadsheet here: [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing]).&lt;br /&gt;
&lt;br /&gt;
The URL route specifies the exact route necessary to reach particular code. In the case of AllReviewInterface, there is only one such route, &amp;quot;/call_models&amp;quot;, which is specified on line 15 by &amp;quot;@app.route('/call_models',methods=['POST']). When a user accesses this route, the function defined immediately after it (in the template's case, &amp;quot;call_models()&amp;quot;) is run. If the method specified is a POST method, the information within that POST can be accessed via flask.request.json. Rename the given route to one that better suits your use case, and feel free to create multiple routes if appropriate in order to have multiple supported methods.&lt;br /&gt;
&lt;br /&gt;
Note that, to return the results of your web service, you must return a flask.Response object, containing the string which is your results. This can be seen in the template by the return statement of call_models(), on line 50.&lt;br /&gt;
&lt;br /&gt;
Replace the code within this template with your own, renaming/reconfiguring the details described above, in order to create your own web service. You can also spread your code across multiple files, so long as the Flask code is contained within the given template file, and that is the file that is run on the PeerLogic server.&lt;br /&gt;
&lt;br /&gt;
==Setting Up a Virtual Environment==&lt;br /&gt;
A difficult issue when running Python code is the necessity for packages. In fact, the &amp;quot;flask&amp;quot; package itself is not part of Python's standard libraries, and must be installed manually. While a user can do this easily using the &amp;quot;pip&amp;quot; command, this will not work on the PeerLogic server, as the root user will not have the necessary packages (and we don't want to download them for the root, as it might corrupt the server).&lt;br /&gt;
&lt;br /&gt;
This problem can be alleviated through the use of virtual environments. A virtual environment can essentially be set up and contain all the packages necessary to run an application, without those packages needing to be installed by a user. This makes them great for sending code to be executed by others.&lt;br /&gt;
&lt;br /&gt;
Create a virtual environment for your application using the command: &lt;br /&gt;
&amp;lt;pre&amp;gt;python3 -m venv /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will create a virtual environment in the same directory as your application named &amp;quot;venv&amp;quot;. Activate this virtual environment using the command:&lt;br /&gt;
&amp;lt;pre&amp;gt;source venv/bin/activate&amp;lt;/pre&amp;gt;&lt;br /&gt;
(NOTE: this will only work on Unix or Mac. I would recommend installing WSL2 if on a Windows system, as virtual environments are difficult to use in Windows command line)&lt;br /&gt;
&lt;br /&gt;
Now that you are in the virtual environment, attempt to run your application (for example, by using the command &amp;quot;python3 flaskapp.py&amp;quot;). If there are any non-standard packages required for your application (such as flask), you will receive an import error naming the missing package. Install that package using &amp;quot;pip install &amp;lt;package_name&amp;gt;&amp;quot;, and continue doing so until you no longer receive errors.&lt;br /&gt;
&lt;br /&gt;
You have now created a virtual environment containing all the packages necessary to run your application, without downloading any onto your personal Python installation. However, you cannot send a virtual environment directly onto the PeerLogic server (it won't set up correctly). Instead, you will want to create a virtual environment on the server itself. You can make this easier by creating a &amp;quot;requirements.txt&amp;quot; file using your current virtual environment. Use this command after you have installed all the necessary packages for your application:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;pip freeze &amp;gt; requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will export all of the installed packages into a text file. I would recommend going into the text file and removing the version numbers from all of the packages, as this will make them easier to run on the older distribution of Python the server uses (for example, changing the line &amp;quot;flask==2.0.3&amp;quot; to just &amp;quot;flask&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
You can exit the virtual environment when you are done using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This concludes all of the code and work you need to do to set up the source code for your web service!&lt;br /&gt;
&lt;br /&gt;
==Getting Code Onto The Server==&lt;br /&gt;
Once you have completed the above, access the PeerLogic server (see the main documentation page for details on how to do this: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services]) and navigate to the webservices directory. Once there, clone your repository into the directory using a command like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;git clone https://github.com/peerlogic/&amp;lt;name_of_your_repo&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
(Note: if your repository is not currently part of the peerlogic group, change its ownership to the group! This will allow others to edit and upkeep your work in the future)&lt;br /&gt;
&lt;br /&gt;
This will clone over your code onto the server. However, your virtual environment will not be set up. To set it up, navigate to the directory containing your requirements.txt file and use the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;virtualenv --python=/usr/bin/python3.6 /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
(note: if this fails, you may need to install the virtualenv package. Do so with &amp;quot;pip install virtualenv&amp;quot; and repeat this step)&lt;br /&gt;
(double note: this command is different from the previous because the server runs an older version of Python)&lt;br /&gt;
&lt;br /&gt;
This will set up a new virtual environment. Activate the environment using the prior mentioned command. Now, you can install all of the required packages by simply using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;pip install -r requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will automatically install all listed packages. You can then test to make sure your application is working by running &amp;quot;python3 &amp;lt;your_app.py)&amp;quot;. If flask successfully launches, congratulations! You have set up your web service! Whenever you are done testing, you can leave the virtual environment using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
==Properly Configuring the Server==&lt;br /&gt;
A final important note is how to set up the server such that your application is properly set up and run. Doing this will require the server to not simply launch your application, but to first enter its virtual environment, run the application, and then exit the environment.&lt;br /&gt;
&lt;br /&gt;
Upon its daily reboot, the server will run the contents of the file runws_root.sh, located within the webservices directory. Edit this file (through a command such as &amp;quot;nano runws_root.sh&amp;quot;) and add a new line for your Flask application. The syntax for this line should be very similar to the existing code to set up the AllReviewInterface application, and should look like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;your_application_repo_name&amp;gt;/app/ &amp;amp;&amp;amp; source venv/bin/activate &amp;amp;&amp;amp; (python3 &amp;lt;your_app.py&amp;gt; &amp;amp;) &amp;amp;&amp;amp; deactivate&amp;lt;/pre&amp;gt;&lt;br /&gt;
To break down what this is doing, the root user will perform the following actions in order:&lt;br /&gt;
*navigate to where your Flask application is located&lt;br /&gt;
*activate the virtual environment&lt;br /&gt;
*run your application with the &amp;quot;&amp;amp;&amp;quot; character, allowing it to run in the background while the root user moves on&lt;br /&gt;
*deactivate the virtual environment&lt;br /&gt;
&lt;br /&gt;
It is important to exit the virtual environment at the end, so as to allow the root user to continue doing what it needs to do. With this, the server will now properly run your application at every reboot.&lt;br /&gt;
&lt;br /&gt;
The final step is to set up the route to call your application. Do this by editting NGINX's configuration file, located at /etc/nginx/nginx.conf (for example, using the command &amp;quot;sudo nano /etc/nginx/nginx.conf&amp;quot;). '''Be very careful editting this file!''' If you somehow break it beyond repair, a backup exists in the google drive with all the documentation.&lt;br /&gt;
&lt;br /&gt;
Go down to the bottom of this file and add in a line similar to the following, substituting in the name of the URL path you set up for your application and the port you set up for your application:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass http://localhost:&amp;lt;PORT_FOR_APPLICATION_YOU_SET_UP&amp;gt;/;&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The other existing locations within the file should be reasonable examples.&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
Congratulations! This concludes this tutorial, and this should be sufficient to let you set up and run your own Python Web Service on PeerLogic. Please check out the video walkthrough linked at the top of this page for a more visual demonstration of these steps, and if you run into any trouble, check out this document for some useful troubleshooting tips: [set up link].&lt;br /&gt;
&lt;br /&gt;
I hope you have success with this. Do good work!&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145697</id>
		<title>PeerLogic Web Services: Python Web Service Template</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Python_Web_Service_Template&amp;diff=145697"/>
		<updated>2022-05-10T01:47:41Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;The purpose of this page is to provide a useful template for creating a new PeerLogic web service, and provide some guided steps in how to modify it for new needs. This templa...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The purpose of this page is to provide a useful template for creating a new PeerLogic web service, and provide some guided steps in how to modify it for new needs. This template is specifically made for Python 3 web applications.&lt;br /&gt;
&lt;br /&gt;
==Foreword: Necessary Tools and Permissions==&lt;br /&gt;
Before beginning to create a web service, you will need some tools and permissions. These are:&lt;br /&gt;
* '''A way to SSH to a remote server''': you can do this through the &amp;quot;ssh&amp;quot; command on Mac or Linux, or through the PuTTY application on Windows.&lt;br /&gt;
* '''A way to send API''': Any will do, but I personally recommend Insomnia, as I find its interface easy to use and good for troubleshooting.&lt;br /&gt;
* '''Sudo access to the Peer Logic web server''': You will need sudo access in order to modify the config files to set up the web service. Request this from CSC IT and CC Dr. Gehringer so he can agree to give you permission. In case it needs saying: don't abuse this access, or things will go poorly!&lt;br /&gt;
&lt;br /&gt;
With all of these tools, we can begin to create a web service.&lt;br /&gt;
&lt;br /&gt;
==Template: AllReviewInterface==&lt;br /&gt;
The template being used for this tutorial is the &amp;quot;AllReviewInterface&amp;quot; web service. This is a working web service on PeerLogic, accessible at peerlogic.csc.ncsu.edu/allreviewinterface/call_models, which has its functionality limited to a single short python file, making it easy to understand and use. The GitHub for this project can be found here: [https://github.com/peerlogic/AllReviewInterface https://github.com/peerlogic/AllReviewInterface].&lt;br /&gt;
&lt;br /&gt;
To begin with, clone this repository and rename it to the name of the project you intend to create. You should also (whether now or after writing the code) update the README for your project. The README for the AllReviewInterface serves as a good template for the basic information your README should provide (general summary of functionality, the port number and URL to access it from on PeerLogic, and the expected Input and Output with explanations and examples).&lt;br /&gt;
&lt;br /&gt;
==Using Flask==&lt;br /&gt;
This application works through utilizing Flask, a Python module which allows your application to accept API requests. As is, you should be able to run the AllReviewInterface program and launch a Flask application. You can then communicate with this application by sending it API (through the tool outlined in the foreword). The AllReviewInterface can be tested in this way by sending its example input (as shown in its README) to &amp;quot;localhost:3013/call_models&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
There are two important configuration details to modify within this application: the port number, and the URL route.&lt;br /&gt;
&lt;br /&gt;
The port number is described on line 53 of the AllReviewInterface's &amp;quot;flaskapp.py&amp;quot;, under &amp;quot;if __name__ == '__main__':&amp;quot;. This determines what port the application is run on, both on your computer and on PeerLogic. Set this to a new, unused port (to see which ports are unused, refer to the configuration spreadsheet here: [https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing https://docs.google.com/spreadsheets/d/1oMYqjaVInPEE4jE7C2iQmOTc0H6BsltnuXXf0UWvuPA/edit?usp=sharing]).&lt;br /&gt;
&lt;br /&gt;
The URL route specifies the exact route necessary to reach particular code. In the case of AllReviewInterface, there is only one such route, &amp;quot;/call_models&amp;quot;, which is specified on line 15 by &amp;quot;@app.route('/call_models',methods=['POST']). When a user accesses this route, the function defined immediately after it (in the template's case, &amp;quot;call_models()&amp;quot;) is run. If the method specified is a POST method, the information within that POST can be accessed via flask.request.json. Rename the given route to one that better suits your use case, and feel free to create multiple routes if appropriate in order to have multiple supported methods.&lt;br /&gt;
&lt;br /&gt;
Note that, to return the results of your web service, you must return a flask.Response object, containing the string which is your results. This can be seen in the template by the return statement of call_models(), on line 50.&lt;br /&gt;
&lt;br /&gt;
Replace the code within this template with your own, renaming/reconfiguring the details described above, in order to create your own web service. You can also spread your code across multiple files, so long as the Flask code is contained within the given template file, and that is the file that is run on the PeerLogic server.&lt;br /&gt;
&lt;br /&gt;
==Setting Up a Virtual Environment==&lt;br /&gt;
A difficult issue when running Python code is the necessity for packages. In fact, the &amp;quot;flask&amp;quot; package itself is not part of Python's standard libraries, and must be installed manually. While a user can do this easily using the &amp;quot;pip&amp;quot; command, this will not work on the PeerLogic server, as the root user will not have the necessary packages (and we don't want to download them for the root, as it might corrupt the server).&lt;br /&gt;
&lt;br /&gt;
This problem can be alleviated through the use of virtual environments. A virtual environment can essentially be set up and contain all the packages necessary to run an application, without those packages needing to be installed by a user. This makes them great for sending code to be executed by others.&lt;br /&gt;
&lt;br /&gt;
Create a virtual environment for your application using the command: &lt;br /&gt;
&amp;lt;pre&amp;gt;python3 -m venv /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will create a virtual environment in the same directory as your application named &amp;quot;venv&amp;quot;. Activate this virtual environment using the command:&lt;br /&gt;
&amp;lt;pre&amp;gt;source venv/bin/activate&amp;lt;/pre&amp;gt;&lt;br /&gt;
(NOTE: this will only work on Unix or Mac. I would recommend installing WSL2 if on a Windows system, as virtual environments are difficult to use in Windows command line)&lt;br /&gt;
&lt;br /&gt;
Now that you are in the virtual environment, attempt to run your application (for example, by using the command &amp;quot;python3 flaskapp.py&amp;quot;). If there are any non-standard packages required for your application (such as flask), you will receive an import error naming the missing package. Install that package using &amp;quot;pip install &amp;lt;package_name&amp;gt;&amp;quot;, and continue doing so until you no longer receive errors.&lt;br /&gt;
&lt;br /&gt;
You have now created a virtual environment containing all the packages necessary to run your application, without downloading any onto your personal Python installation. However, you cannot send a virtual environment directly onto the PeerLogic server (it won't set up correctly). Instead, you will want to create a virtual environment on the server itself. You can make this easier by creating a &amp;quot;requirements.txt&amp;quot; file using your current virtual environment. Use this command after you have installed all the necessary packages for your application:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;pip freeze &amp;gt; requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will export all of the installed packages into a text file. I would recommend going into the text file and removing the version numbers from all of the packages, as this will make them easier to run on the older distribution of Python the server uses (for example, changing the line &amp;quot;flask==2.0.3&amp;quot; to just &amp;quot;flask&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
You can exit the virtual environment when you are done using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
This concludes all of the code and work you need to do to set up the source code for your web service!&lt;br /&gt;
&lt;br /&gt;
==Getting Code Onto The Server==&lt;br /&gt;
Once you have completed the above, access the PeerLogic server (see the main documentation page for details on how to do this: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services]) and navigate to the webservices directory. Once there, clone your repository into the directory using a command like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;git clone https://github.com/peerlogic/&amp;lt;name_of_your_repo&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
(Note: if your repository is not currently part of the peerlogic group, change its ownership to the group! This will allow others to edit and upkeep your work in the future)&lt;br /&gt;
&lt;br /&gt;
This will clone over your code onto the server. However, your virtual environment will not be set up. To set it up, navigate to the directory containing your requirements.txt file and use the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;virtualenv --python=/usr/bin/python3.6 /venv&amp;lt;/pre&amp;gt;&lt;br /&gt;
(note: if this fails, you may need to install the virtualenv package. Do so with &amp;quot;pip install virtualenv&amp;quot; and repeat this step)&lt;br /&gt;
(double note: this command is different from the previous because the server runs an older version of Python)&lt;br /&gt;
&lt;br /&gt;
This will set up a new virtual environment. Activate the environment using the prior mentioned command. Now, you can install all of the required packages by simply using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;pip install -r requirements.txt&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This will automatically install all listed packages. You can then test to make sure your application is working by running &amp;quot;python3 &amp;lt;your_app.py)&amp;quot;. If flask successfully launches, congratulations! You have set up your web service! Whenever you are done testing, you can leave the virtual environment using the command &amp;quot;deactivate&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
==Properly Configuring the Server==&lt;br /&gt;
A final important note is how to set up the server such that your application is properly set up and run. Doing this will require the server to not simply launch your application, but to first enter its virtual environment, run the application, and then exit the environment.&lt;br /&gt;
&lt;br /&gt;
Upon its daily reboot, the server will run the contents of the file runws_root.sh, located within the webservices directory. Edit this file (through a command such as &amp;quot;nano runws_root.sh&amp;quot;) and add a new line for your Flask application. The syntax for this line should be very similar to the existing code to set up the AllReviewInterface application, and should look like the following:&lt;br /&gt;
&amp;lt;pre&amp;gt;cd /opt/webservices/&amp;lt;your_application_repo_name&amp;gt;/app/ &amp;amp;&amp;amp; source venv/bin/activate &amp;amp;&amp;amp; (python3 &amp;lt;your_app.py&amp;gt; &amp;amp;) &amp;amp;&amp;amp; deactivate&amp;lt;/pre&amp;gt;&lt;br /&gt;
To break down what this is doing, the root user will perform the following actions in order:&lt;br /&gt;
*navigate to where your Flask application is located&lt;br /&gt;
*activate the virtual environment&lt;br /&gt;
*run your application with the &amp;quot;&amp;amp;&amp;quot; character, allowing it to run in the background while the root user moves on&lt;br /&gt;
*deactivate the virtual environment&lt;br /&gt;
&lt;br /&gt;
It is important to exit the virtual environment at the end, so as to allow the root user to continue doing what it needs to do. With this, the server will now properly run your application at every reboot.&lt;br /&gt;
&lt;br /&gt;
The final step is to set up the route to call your application. Do this by editting NGINX's configuration file, located at /etc/nginx/nginx.conf (for example, using the command &amp;quot;sudo nano /etc/nginx/nginx.conf&amp;quot;). '''Be very careful editting this file!''' If you somehow break it beyond repair, a backup exists in the google drive with all the documentation.&lt;br /&gt;
&lt;br /&gt;
Go down to the bottom of this file and add in a line similar to the following, substituting in the name of the URL path you set up for your application and the port you set up for your application:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass http://localhost:&amp;lt;PORT_FOR_APPLICATION_YOU_SET_UP&amp;gt;/;&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The other existing locations within the file should be reasonable examples.&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
Congratulations! This concludes this tutorial, and this should be sufficient to let you set up and run your own Python Web Service on PeerLogic. Please check out the video walkthrough linked at the top of this page for a more visual demonstration of these steps, and if you run into any trouble, check out this document for some useful troubleshooting tips: [set up link].&lt;br /&gt;
&lt;br /&gt;
I hope you have success with this. Do good work!&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_All_Review_Interface&amp;diff=145696</id>
		<title>PeerLogic Web Services: All Review Interface</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_All_Review_Interface&amp;diff=145696"/>
		<updated>2022-05-10T01:07:45Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=Summary= This is a simple web service that allows a number of student reviews to be sent to various other web services and their results collected in an easy-to-parse form. T...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
This is a simple web service that allows a number of student reviews to be sent to various other web services and their results collected in an easy-to-parse form. The purpose of this is to make it easier to run student reviews against various review web services simultaneously.&lt;br /&gt;
&lt;br /&gt;
That being said, the primary purpose for the creation of this web service is to serve as a copyable template for future web services created for the PeerLogic web server. This README similarly serves as a template for a proper README for such services.&lt;br /&gt;
&lt;br /&gt;
Note that no more than 10 reviews should be passed in at a time for performance considerations, if possible.&lt;br /&gt;
&lt;br /&gt;
==URL Path==&lt;br /&gt;
This service can be reached at peerlogic.csc.ncsu.edu/allreviewinterface/call_models. It is set up on port 3013 of the PeerLogic web server. (Note that all services MUST have unique ports).&lt;br /&gt;
&lt;br /&gt;
=Input=&lt;br /&gt;
This service expects a GET request with the following JSON payload format:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
	&amp;quot;services&amp;quot;: the names of the PeerLogic web services to call. The following are currently supported:&lt;br /&gt;
		-intelligent_assignment_volume (measures the length and word count of the reviews)&lt;br /&gt;
		-intelligent_assignment_problems (determines whether the review mentioned the work having problems)&lt;br /&gt;
		-intelligent_assignment_suggestions (determines whether the review had suggestions)&lt;br /&gt;
	&lt;br /&gt;
	&amp;quot;input&amp;quot;: contains the input JSON to be passed to the review services. This web service assumes all services called can use the same input format, which is true for the currently supported services. This JSON component contains:&lt;br /&gt;
[&lt;br /&gt;
	{&lt;br /&gt;
		&amp;quot;reviews&amp;quot;: a list of the review objects to have NLP applied to. That list contains items of the following format:&lt;br /&gt;
			[&lt;br /&gt;
			&amp;quot;id&amp;quot;: the id number of the review. Should be unique between given reviews.&lt;br /&gt;
			&amp;quot;text&amp;quot;: the text of the review itself.&lt;br /&gt;
			]&lt;br /&gt;
			&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
==Example Input==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{ &amp;quot;services&amp;quot; : [&amp;quot;intelligent_assignment_volume&amp;quot;,&amp;quot;intelligent_assignment_problems&amp;quot;],&lt;br /&gt;
	&lt;br /&gt;
	&amp;quot;input&amp;quot; : &lt;br /&gt;
 { &amp;quot;reviews&amp;quot; : [&lt;br /&gt;
      {&lt;br /&gt;
      &amp;quot;id&amp;quot; : 1,&lt;br /&gt;
      &amp;quot;text&amp;quot; : &amp;quot;This is incredible! I can't find a single thing wrong with your project! This is simply great, you are amazing, great job! Only thing I can say is I might have made the font size larger.&amp;quot;&lt;br /&gt;
  },&lt;br /&gt;
      {&lt;br /&gt;
          &amp;quot;id&amp;quot; : 2,&lt;br /&gt;
          &amp;quot;text&amp;quot; : &amp;quot;I think your project is poorly put together and is missing most of the project requirements.&amp;quot;&lt;br /&gt;
      },&lt;br /&gt;
	    {&lt;br /&gt;
          &amp;quot;id&amp;quot; : 3,&lt;br /&gt;
          &amp;quot;text&amp;quot; : &amp;quot;It was good.&amp;quot;&lt;br /&gt;
      }&lt;br /&gt;
  ]&lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
==Example Output==&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{&lt;br /&gt;
	&amp;quot;intelligent_assignment_volume&amp;quot;: {&lt;br /&gt;
		&amp;quot;reviews&amp;quot;: [&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 1,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;This is incredible! I can't find a single thing wrong with your project! This is simply great, you are amazing, great job! Only thing I can say is I might have made the font size larger.&amp;quot;,&lt;br /&gt;
				&amp;quot;total_volume&amp;quot;: 43,&lt;br /&gt;
				&amp;quot;volume_without_stopwords&amp;quot;: 26&lt;br /&gt;
			},&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 2,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;I think your project is poorly put together and is missing most of the project requirements.&amp;quot;,&lt;br /&gt;
				&amp;quot;total_volume&amp;quot;: 17,&lt;br /&gt;
				&amp;quot;volume_without_stopwords&amp;quot;: 9&lt;br /&gt;
			},&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 3,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;It was good.&amp;quot;,&lt;br /&gt;
				&amp;quot;total_volume&amp;quot;: 4,&lt;br /&gt;
				&amp;quot;volume_without_stopwords&amp;quot;: 2&lt;br /&gt;
			}&lt;br /&gt;
		]&lt;br /&gt;
	},&lt;br /&gt;
	&amp;quot;intelligent_assignment_problems&amp;quot;: {&lt;br /&gt;
		&amp;quot;reviews&amp;quot;: [&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 1,&lt;br /&gt;
				&amp;quot;problems&amp;quot;: &amp;quot;Present&amp;quot;,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;This is incredible! I can't find a single thing wrong with your project! This is simply great, you are amazing, great job! Only thing I can say is I might have made the font size larger.&amp;quot;&lt;br /&gt;
			},&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 2,&lt;br /&gt;
				&amp;quot;problems&amp;quot;: &amp;quot;Present&amp;quot;,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;I think your project is poorly put together and is missing most of the project requirements.&amp;quot;&lt;br /&gt;
			},&lt;br /&gt;
			{&lt;br /&gt;
				&amp;quot;id&amp;quot;: 3,&lt;br /&gt;
				&amp;quot;problems&amp;quot;: &amp;quot;Absent&amp;quot;,&lt;br /&gt;
				&amp;quot;text&amp;quot;: &amp;quot;It was good.&amp;quot;&lt;br /&gt;
			}&lt;br /&gt;
		]&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145695</id>
		<title>PeerLogic Web Services: Videos</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145695"/>
		<updated>2022-05-10T00:48:38Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following link will take you to the Google Drive containing the demonstration videos. &lt;br /&gt;
&lt;br /&gt;
[https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing https://drive.google.com/drive/folders/1yfCSXfu9NMUyKxIsvIYEQZkVUISVWtwB?usp=sharing]&lt;br /&gt;
&lt;br /&gt;
Most are around 6 to 10 minutes long explaining numerous useful pieces of information, with the exception of the demonstration of setting up a webservice, which is around 30 minutes long. Some are additionally demonstrations, which showcase how to access the web services. Given here is an explanation of the contents of each video.&lt;br /&gt;
&lt;br /&gt;
* '''Ch1-Introduction.mkv''' - An introduction to Dr. Gehringer's Web Services. This explains what a web service is, why web services are used, and how to interact with web services.&lt;br /&gt;
* '''Ch2-Current_Webservices.mkv''' - An explanation of all currently known and operating web services, including where to find them, their purpose and use on Expertiza (or other places), where their code is, and where to see more documentation.&lt;br /&gt;
* '''Ch3-Accessing_Web_Servers.avi''' - A guide on how to access the web servers that the web services live at, including tools to use and references to necessary permissions.&lt;br /&gt;
* '''Ch4-Adding_And_Changing_Webservices.mkv''' - A walk through of the important components and files associated with setting up a new web service, editing a deployed web service, as well as how one would go about moving the current web services to a separate location.&lt;br /&gt;
* '''Ch5-Conclusions_And_Resources.mkv''' - A final wrap up, including where to look for future information, and a reference to the next development steps assumed for future work on the web services.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In addition to these explanation videos, the following demo videos have been created. These serve as a good example and reference to the more technical aspects of interfacing with web services.&lt;br /&gt;
&lt;br /&gt;
* '''Demo-Setting_Up_A_Web_Service.mkv''' - This 30 minute video demonstrates every step in creating and setting up a web service, from creating Python Flask code to final testing. It is recommended to only watch this video after watching all the videos above.&lt;br /&gt;
* '''Demo-Post_Requests_To_Web_Services.mkv''' - A demo demonstrating how to test that the web services are currently working and how to get output from them using Insomnia.&lt;br /&gt;
* '''Demo-Connecting_To_Web_Servers.mkv''' - A demo showcasing how to connect to the remote web servers, and how to find the files associated with each of the previously explained web services.&lt;br /&gt;
* '''Demo-Modifying_Web_Services.mkv''' - A demo showing the important files to modify and edit in order to modify or add new web services.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145694</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145694"/>
		<updated>2022-05-10T00:38:56Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Videos here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* Then, move your service code into a new folder within the /opt/webservices directory. It is recommended to do this by downloading your project from GitHub directly into a directory within /opt/webservices, as sending or receiving files would be difficult due to the SSH stack necessary to access the server.&lt;br /&gt;
* After doing all this, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. It is actively used by expertiza to do review tagging using ML.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145436</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145436"/>
		<updated>2022-04-26T04:12:25Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Documentation Videos (Start Here!)==&lt;br /&gt;
If you are just starting out accessing the PeerLogic Web Services, a series of videos have been created to explain the general premise of the web services, demonstrate some of the information expressed below, and more. This is a good way to get a general overview of how the Web Services work. To view these videos, click [ here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* Then, move your service code into a new folder within the /opt/webservices directory. It is recommended to do this by downloading your project from GitHub directly into a directory within /opt/webservices, as sending or receiving files would be difficult due to the SSH stack necessary to access the server.&lt;br /&gt;
* After doing all this, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. It is actively used by expertiza to do review tagging using ML.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145353</id>
		<title>PeerLogic Web Services: Videos</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145353"/>
		<updated>2022-04-26T01:17:37Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following link will take you to the Google Drive containing the demonstration videos. &lt;br /&gt;
&lt;br /&gt;
[https://drive.google.com/file/d/1BJ82qaCbWBCAdOCwfqpiDOU7PQfWwHly/view?usp=sharing https://drive.google.com/file/d/1BJ82qaCbWBCAdOCwfqpiDOU7PQfWwHly/view?usp=sharing]&lt;br /&gt;
&lt;br /&gt;
Each is around 6 to 10 minutes long explaining numerous useful pieces of information. Some are additionally demonstrations, which showcase how to access the web services. Given here is an explanation of the contents of each video.&lt;br /&gt;
&lt;br /&gt;
* '''Ch1-Introduction.mkv''' - An introduction to Dr. Gehringer's Web Services. This explains what a web service is, why web services are used, and how to interact with web services.&lt;br /&gt;
* '''Ch2-Current_Webservices.mkv''' - An explanation of all currently known and operating web services, including where to find them, their purpose and use on Expertiza (or other places), where their code is, and where to see more documentation.&lt;br /&gt;
* '''Ch3-Accessing_Web_Servers.avi''' - A guide on how to access the web servers that the web services live at, including tools to use and references to necessary permissions.&lt;br /&gt;
* '''Ch4-Adding_And_Changing_Webservices.mkv''' - A walk through of the important components and files associated with setting up a new web service, editing a deployed web service, as well as how one would go about moving the current web services to a separate location.&lt;br /&gt;
* '''Ch5-Conclusions_And_Resources.mkv''' - A final wrap up, including where to look for future information, and a reference to the next development steps assumed for future work on the web services.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In addition to these explanation videos, the following demo videos have been created. These serve as a good example and reference to the more technical aspects of interfacing with web services.&lt;br /&gt;
&lt;br /&gt;
* '''Demo-Post_Requests_To_Web_Services.mkv''' - A demo demonstrating how to test that the web services are currently working and how to get output from them using Insomnia.&lt;br /&gt;
* '''Demo-Connecting_To_Web_Servers.mkv''' - A demo showcasing how to connect to the remote web servers, and how to find the files associated with each of the previously explained web services.&lt;br /&gt;
* '''Demo-Modifying_Web_Services.mkv''' - A demo showing the important files to modify and edit in order to modify or add new web services.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145352</id>
		<title>PeerLogic Web Services: Videos</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145352"/>
		<updated>2022-04-26T01:17:23Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following link will take you to the Google Drive containing the demonstration videos. &lt;br /&gt;
&lt;br /&gt;
[https://drive.google.com/file/d/1BJ82qaCbWBCAdOCwfqpiDOU7PQfWwHly/view?usp=sharing https://drive.google.com/file/d/1BJ82qaCbWBCAdOCwfqpiDOU7PQfWwHly/view?usp=sharing]&lt;br /&gt;
Each is around 6 to 10 minutes long explaining numerous useful pieces of information. Some are additionally demonstrations, which showcase how to access the web services. Given here is an explanation of the contents of each video.&lt;br /&gt;
&lt;br /&gt;
* '''Ch1-Introduction.mkv''' - An introduction to Dr. Gehringer's Web Services. This explains what a web service is, why web services are used, and how to interact with web services.&lt;br /&gt;
* '''Ch2-Current_Webservices.mkv''' - An explanation of all currently known and operating web services, including where to find them, their purpose and use on Expertiza (or other places), where their code is, and where to see more documentation.&lt;br /&gt;
* '''Ch3-Accessing_Web_Servers.avi''' - A guide on how to access the web servers that the web services live at, including tools to use and references to necessary permissions.&lt;br /&gt;
* '''Ch4-Adding_And_Changing_Webservices.mkv''' - A walk through of the important components and files associated with setting up a new web service, editing a deployed web service, as well as how one would go about moving the current web services to a separate location.&lt;br /&gt;
* '''Ch5-Conclusions_And_Resources.mkv''' - A final wrap up, including where to look for future information, and a reference to the next development steps assumed for future work on the web services.&lt;br /&gt;
&lt;br /&gt;
In addition to these explanation videos, the following demo videos have been created. These serve as a good example and reference to the more technical aspects of interfacing with web services.&lt;br /&gt;
&lt;br /&gt;
* '''Demo-Post_Requests_To_Web_Services.mkv''' - A demo demonstrating how to test that the web services are currently working and how to get output from them using Insomnia.&lt;br /&gt;
* '''Demo-Connecting_To_Web_Servers.mkv''' - A demo showcasing how to connect to the remote web servers, and how to find the files associated with each of the previously explained web services.&lt;br /&gt;
* '''Demo-Modifying_Web_Services.mkv''' - A demo showing the important files to modify and edit in order to modify or add new web services.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145350</id>
		<title>PeerLogic Web Services: Videos</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145350"/>
		<updated>2022-04-26T01:16:39Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following link will take you to the Google Drive containing the demonstration videos. Each is around 6 to 10 minutes long explaining numerous useful pieces of information. Some are additionally demonstrations, which showcase how to access the web services. Given here is an explanation of the contents of each video.&lt;br /&gt;
&lt;br /&gt;
* '''Ch1-Introduction.mkv''' - An introduction to Dr. Gehringer's Web Services. This explains what a web service is, why web services are used, and how to interact with web services.&lt;br /&gt;
* '''Ch2-Current_Webservices.mkv''' - An explanation of all currently known and operating web services, including where to find them, their purpose and use on Expertiza (or other places), where their code is, and where to see more documentation.&lt;br /&gt;
* '''Ch3-Accessing_Web_Servers.avi''' - A guide on how to access the web servers that the web services live at, including tools to use and references to necessary permissions.&lt;br /&gt;
* '''Ch4-Adding_And_Changing_Webservices.mkv''' - A walk through of the important components and files associated with setting up a new web service, editing a deployed web service, as well as how one would go about moving the current web services to a separate location.&lt;br /&gt;
* '''Ch5-Conclusions_And_Resources.mkv''' - A final wrap up, including where to look for future information, and a reference to the next development steps assumed for future work on the web services.&lt;br /&gt;
&lt;br /&gt;
In addition to these explanation videos, the following demo videos have been created. These serve as a good example and reference to the more technical aspects of interfacing with web services.&lt;br /&gt;
&lt;br /&gt;
* '''Demo-Post_Requests_To_Web_Services.mkv''' - A demo demonstrating how to test that the web services are currently working and how to get output from them using Insomnia.&lt;br /&gt;
* '''Demo-Connecting_To_Web_Servers.mkv''' - A demo showcasing how to connect to the remote web servers, and how to find the files associated with each of the previously explained web services.&lt;br /&gt;
* '''Demo-Modifying_Web_Services.mkv''' - A demo showing the important files to modify and edit in order to modify or add new web services.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145348</id>
		<title>PeerLogic Web Services: Videos</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Videos&amp;diff=145348"/>
		<updated>2022-04-26T01:15:57Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;The following link will take you to the Google Drive containing the demonstration videos. Each is around 6 to 10 minutes long explaining numerous useful pieces of information....&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following link will take you to the Google Drive containing the demonstration videos. Each is around 6 to 10 minutes long explaining numerous useful pieces of information. Some are additionally demonstrations, which showcase how to access the web services. Given here is an explanation of the contents of each video.&lt;br /&gt;
&lt;br /&gt;
* Ch1-Introduction.mkv - An introduction to Dr. Gehringer's Web Services. This explains what a web service is, why web services are used, and how to interact with web services.&lt;br /&gt;
* Ch2-Current_Webservices.mkv - An explanation of all currently known and operating web services, including where to find them, their purpose and use on Expertiza (or other places), where their code is, and where to see more documentation.&lt;br /&gt;
* Ch3-Accessing_Web_Servers.avi - A guide on how to access the web servers that the web services live at, including tools to use and references to necessary permissions.&lt;br /&gt;
* Ch4-Adding_And_Changing_Webservices.mkv - A walk through of the important components and files associated with setting up a new web service, editing a deployed web service, as well as how one would go about moving the current web services to a separate location.&lt;br /&gt;
* Ch5-Conclusions_And_Resources.mkv - A final wrap up, including where to look for future information, and a reference to the next development steps assumed for future work on the web services.&lt;br /&gt;
&lt;br /&gt;
In addition to these explanation videos, the following demo videos have been created. These serve as a good example and reference to the more technical aspects of interfacing with web services.&lt;br /&gt;
&lt;br /&gt;
* Demo-Post_Requests_To_Web_Services.mkv - A demo demonstrating how to test that the web services are currently working and how to get output from them using Insomnia.&lt;br /&gt;
* Demo-Connecting_To_Web_Servers.mkv - A demo showcasing how to connect to the remote web servers, and how to find the files associated with each of the previously explained web services.&lt;br /&gt;
* Demo-Modifying_Web_Services.mkv - A demo showing the important files to modify and edit in order to modify or add new web services.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145026</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=145026"/>
		<updated>2022-04-18T23:57:39Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* Then, move your service code into a new folder within the /opt/webservices directory. It is recommended to do this by downloading your project from GitHub directly into a directory within /opt/webservices, as sending or receiving files would be difficult due to the SSH stack necessary to access the server.&lt;br /&gt;
* After doing all this, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Peer-reviews-NLP==&lt;br /&gt;
Peer-reviews-NLP is a Python-based program which is used to tag student reviews. It does so by performing NLP and identifying features such as the presence of suggestions, problems, and more. Currently, 5 options are known to be functioning and useful: volume, suggestions, suggestions_confidence, problems, and problems_confidence. It is actively used by expertiza to do review tagging using ML.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/Peer-reviews-NLP].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP&amp;diff=145025</id>
		<title>Peer-reviews-NLP</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP&amp;diff=145025"/>
		<updated>2022-04-18T23:41:50Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Peer-reviews-NLP to PeerLogic Web Services: Peer-reviews-NLP&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[PeerLogic Web Services: Peer-reviews-NLP]]&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Peer-reviews-NLP&amp;diff=145024</id>
		<title>PeerLogic Web Services: Peer-reviews-NLP</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Peer-reviews-NLP&amp;diff=145024"/>
		<updated>2022-04-18T23:41:50Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Peer-reviews-NLP to PeerLogic Web Services: Peer-reviews-NLP&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Summary==&lt;br /&gt;
The Peer Review NLP Web Service (PRWS) utilizes natural language processing to perform sentiment, volume, and emotion analysis upon student peer reviews.&lt;br /&gt;
&lt;br /&gt;
The service was created with the intention of being set up using Docker and with the HTTP server created using Gunicorn.&lt;br /&gt;
&lt;br /&gt;
The most recent Github featuring the work for this project can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
&lt;br /&gt;
==Components==&lt;br /&gt;
The project features the following primary directories:&lt;br /&gt;
* data: A storage space for tagged comments. Utilized for X.&lt;br /&gt;
* documentation: A number of Swagger-supported .yml files which outline the web service's API.&lt;br /&gt;
* metrics: A number of files which handle the input and output from the webservice, reading JSON input and returning it using different methods.&lt;br /&gt;
* model: Several non-human-readable files representing the compiled models utilized by the web service.&lt;br /&gt;
* preprocessing: The primary &amp;quot;runner&amp;quot; files which perform the actual prediction associated with the web service.&lt;br /&gt;
* templates: Contains a single, non-functional HTML page apparently meant for testing the NLP.&lt;br /&gt;
&lt;br /&gt;
In addition, it also contains a number of files associated with initial start up. Each of these sections will be discussed on independent pages, all linked here for ease of navigation.&lt;br /&gt;
&lt;br /&gt;
==Page Links==&lt;br /&gt;
Please click one of the following links to read more about PRWS's:&lt;br /&gt;
&lt;br /&gt;
* [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP:_Set-Up Set-Up]&lt;br /&gt;
* Input and Output Handling&lt;br /&gt;
* [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP:_Web_Service_API Web Service API]&lt;br /&gt;
* Prediction Code&lt;br /&gt;
* Model Details&lt;br /&gt;
* File Breakdown&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142918</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142918"/>
		<updated>2022-02-22T04:26:54Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Adding a New Web Service */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* Then, move your service code into a new folder within the /opt/webservices directory. It is recommended to do this by downloading your project from GitHub directly into a directory within /opt/webservices, as sending or receiving files would be difficult due to the SSH stack necessary to access the server.&lt;br /&gt;
* After doing all this, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142917</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142917"/>
		<updated>2022-02-22T04:24:56Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* RainbowGraphService */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142916</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142916"/>
		<updated>2022-02-22T04:24:15Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==RainbowGraphService==&lt;br /&gt;
RainbowGraphService is a primarily JavaScript application that visualizes the results of peer review criticisms.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Rainbow_Graph_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/ferryxo/RainbowGraphService https://github.com/ferryxo/RainbowGraphService].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application about explaining and summarizing reviews made by students.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Rainbow_Graph_Service&amp;diff=142915</id>
		<title>PeerLogic Web Services: Rainbow Graph Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Rainbow_Graph_Service&amp;diff=142915"/>
		<updated>2022-02-22T04:22:38Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=The Rainbow Graph= ==Critique Results Visualization== Created by David Tinapple, Dmytro Babik, Jaharsh Venkata Sadha, Ferry Pramudianto  In this overview, we show the current...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=The Rainbow Graph=&lt;br /&gt;
==Critique Results Visualization==&lt;br /&gt;
Created by David Tinapple, Dmytro Babik, Jaharsh Venkata Sadha, Ferry Pramudianto&lt;br /&gt;
&lt;br /&gt;
In this overview, we show the current state of our attempt at visualizing the results of peer review critique session including an explanation of how we arrived at the current design iteration.&lt;br /&gt;
&lt;br /&gt;
The data from this critique are from a single project assignment run in a real classroom using CritViz.com as the platform for running the peer review session.&lt;br /&gt;
&lt;br /&gt;
In this assignment for a “creative coding” course, students had to explore the creative possibilities using a specific type of programming language to create an interactive piece of artwork. The assignment required the students to learn the technical aspects of the coding language and techniques, but also implement their own project in a creative and engaging way. They uploaded their resulting projects and documentation for their peers to review.&lt;br /&gt;
&lt;br /&gt;
The critique session unfolded the the following way:&lt;br /&gt;
&lt;br /&gt;
* Students completed their projects and uploaded their work (code and documentation) to CritViz.com by a specific deadline, answering all of required questions in the assignment.&lt;br /&gt;
* A second “critique assignment” was initiated, including only those students who completed the first assignment. Students who didn’t complete the original assignment were not included in the critique.&lt;br /&gt;
* CritViz.com automatically assigned each critic a set of peer works to review. The procedure for assigning the critiques is randomized and non-reciprocal. The students were not placed into critique groups, but rather presented with a set of works to review. Each student has a unique randomized set of works to review. The matching algorithm ensures that each student receives their set of works to review, and also has their own work placed into the same number of sets being reviewed by others.&lt;br /&gt;
* Each critic was then presented with the critique assignment questions to answer about each of the works in their set. The identities of the authors of the works is temporarily hidden from the critics in order to afford more objectivity and focus on the work itself. These questions included some text feedback in response to prompts, and also a single “ranking” question asking them to rank order their set overall.&lt;br /&gt;
* Care was taken to explain to students that this ranking task had no bearing on the recipient’s actual grade, but rather was a way for the class to “self curate” the work. The ranking task was explained as a general ranking from “strongest to weakest” and to take into account both technical and conceptual/aesthetic considerations.&lt;br /&gt;
* Most (but not all) students completed this critique assignment by the deadline. Each student then received a number of reviews, although due to the fact that some critics did not complete their tasks by the deadline, not all students received the exact same number of reviews.&lt;br /&gt;
* As soon as the critique deadline is met, all the reviews become visible to the recipients of the reviews as well as the rest of the class, and all names of the authors and critics become visible. The ranking scores are visible too.&lt;br /&gt;
The ranking data received consists of a simple rank position number. No “point values” are assigned to the rank scores. A rank of “1” means their critic positioned them “first place” in their set of items to rank.&lt;br /&gt;
The resulting data, color coded (1=green, 5=red) is as follows:&lt;br /&gt;
&lt;br /&gt;
Each students' column is populated with their individual rank scores sorted so that weaker scores “sink” to the bottom of the column. The columns themselves are sorted left to right by the average of all the individual scores.&lt;br /&gt;
&lt;br /&gt;
This graph is a good starting place and is already useful as a diagnostic tool, however it fails to make visible the rank average scores, even though the columns are sorted by it.&lt;br /&gt;
&lt;br /&gt;
The spreadsheet above also has the disadvantage of appearing to be a bar chart, when in fact the different heights for the different columns is only due to the differing numbers of critiques received by each students (remember, some students don’t complete their critiques). In the spreadsheet above, some students received 14 critiques, and others only 10.&lt;br /&gt;
&lt;br /&gt;
To alleviate this false appearance of a bar chart, we could visually normalize the height of each column by showing the following:&lt;br /&gt;
&lt;br /&gt;
The data is the same as the initial spreadsheet view, but each column is adjusted to be the same height, leading to some individual cells appearing bigger than others.&lt;br /&gt;
&lt;br /&gt;
This graphic is an improvement, and is informative, but it fails to visually depict the overall rank average score for each column.&lt;br /&gt;
&lt;br /&gt;
A simple bar chart of the rank averages, looks like this:&lt;br /&gt;
&lt;br /&gt;
A rank average bar chart makes visible the pattern in rank averages, making it obvious that the columns are sorted by the average score, and also making visible the shape of the downward slope of the graph. For instance, it’s clear that the first three students received very high averages, with a drop off and then a gradual decline.&lt;br /&gt;
&lt;br /&gt;
The advantage of the bar chart of average scores is that it makes the sorting clear, and shows the larger trends well, but it occludes the individual scores that go into determining these averages. Some students averages might be influenced by one outlier score, while others with a similar average might consist of uniform scores.&lt;br /&gt;
&lt;br /&gt;
Our solution was to combine the raw spreadsheet view and the rank average chart into a “decomposable average” chart view.&lt;br /&gt;
&lt;br /&gt;
This shows the same data as the initial spreadsheet, but each of the columns is sized according to the average of the scores received in that column. In this way we are looking at the bar chart of the rank average, but can also see the individual scores that are included in that average. This has the advantage of the average, but also depicting the variance of the scores that determine the average. For instance, the “Kyle” column has a strong variability in the scores received, whereas the “Alisha” column has a more consistent distribution of scores, even though their overall averages are quite similar.&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
==How to use the Rainbow Graph web service==&lt;br /&gt;
This section describes how to use the rainbow graph web service and how to format the JSON data file appropriately given the kind of data your peer review system uses.&lt;br /&gt;
&lt;br /&gt;
This web service is used by sending a POST request with a properly formatted JSON data to the web service host at this link: http://peerlogic.csc.ncsu.edu/rainbowgraph/configure. What will be returned to you is the unique URL of a page with the resulting graph rendered as a 100% width interactive SVG. The URL is returned in a JSON format as the following: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;{&lt;br /&gt;
    &amp;quot;url&amp;quot;:&amp;quot;http://peerlogic.csc.ncsu.edu/rainbowgraph/xxxx-xxxx-xxxx-xxxx&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once you extract the URL, you can render this graph in your system by placing the returned URL in an IFRAME in your website as the following example.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;lt;iframe id=&amp;quot;rainbowGraph&amp;quot; src=&amp;quot;http://peerlogic.csc.ncsu.edu/rainbowgraph/viz/dd4343b1-29e2-4a27-aed4-888fa3b6a2a2&amp;quot; width=&amp;quot;800&amp;quot; height=&amp;quot;380&amp;quot; frameborder=&amp;quot;0&amp;quot; scrolling=&amp;quot;no&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
The following code snippet is an example of a Javascript function that uses JQuery Ajax to call the web service:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;lt;html lang=&amp;quot;en&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;head&amp;gt;&lt;br /&gt;
    &amp;lt;script src=&amp;quot;https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js&amp;quot;&amp;gt;&amp;lt;/script&amp;gt;&lt;br /&gt;
&amp;lt;/head&amp;gt;&lt;br /&gt;
&amp;lt;body&amp;gt;&lt;br /&gt;
&amp;lt;script&amp;gt;&lt;br /&gt;
    sendJson = function(json_file){&lt;br /&gt;
        $.getJSON(json_file, function(json){&lt;br /&gt;
            $.ajax({&lt;br /&gt;
                type: &amp;quot;POST&amp;quot;,&lt;br /&gt;
                url: &amp;quot;http://peerlogic.csc.ncsu.edu/rainbowgraph/configure&amp;quot;,&lt;br /&gt;
                dataType: &amp;quot;json&amp;quot;,&lt;br /&gt;
                contentType: &amp;quot;application/json&amp;quot;,&lt;br /&gt;
                data: JSON.stringify(json),&lt;br /&gt;
                success: function (resp) {&lt;br /&gt;
                    if (resp.url) {&lt;br /&gt;
                        $('#chart').append('&amp;lt;iframe id=&amp;quot;rainbowGraph&amp;quot; src=&amp;quot;' + resp.url + '&amp;quot; width=&amp;quot;800&amp;quot; height=&amp;quot;380&amp;quot; frameborder=&amp;quot;0&amp;quot; scrolling=&amp;quot;no&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;')&lt;br /&gt;
                    }else&lt;br /&gt;
                        $('#chart').append(resp.error);&lt;br /&gt;
                },&lt;br /&gt;
            });&lt;br /&gt;
        });&lt;br /&gt;
    }&lt;br /&gt;
&amp;lt;/script&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;button onclick=&amp;quot;sendJson('data.json')&amp;quot;&amp;gt;Get Rainbow Graph&amp;lt;/button&amp;gt;&lt;br /&gt;
&amp;lt;div id=&amp;quot;chart&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
see a demo here : http://peerlogic.csc.ncsu.edu/rainbowgraph/developer&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
==JSON Data Format==&lt;br /&gt;
The JSON configuration that you have to POST to the service have two sections:&lt;br /&gt;
&lt;br /&gt;
(See an example of a valid JSON file at this link, if your system is ranking based. If your system is rating based, you can forego the “student_id” and critic_comparer_vector element in each student, as they are not relevant for you at the moment.)&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[{&lt;br /&gt;
&amp;quot;metadata&amp;quot;: {&lt;br /&gt;
    &amp;quot;title&amp;quot;: &amp;quot;Intro to Digital Media, Assignment 1&amp;quot;,  &lt;br /&gt;
    //primary value is the main score (rank average)&lt;br /&gt;
     &amp;quot;primary_value_label&amp;quot;: &amp;quot;rank average&amp;quot;,&lt;br /&gt;
     &amp;quot;higher_primary_value_better&amp;quot;: false,&lt;br /&gt;
    //values array (the individual received scores)&lt;br /&gt;
     &amp;quot;values_label&amp;quot;: &amp;quot;ranks&amp;quot;,&lt;br /&gt;
     &amp;quot;best_value_possible&amp;quot;: 1, //denotes the color transition from e.g., green (best value) to red (worst value)&lt;br /&gt;
     &amp;quot;worst_value_possible&amp;quot;: 5, //denotes the color transition from e.g., green (best value) to red (worst value)&lt;br /&gt;
     &amp;quot;best_primary_value_possible&amp;quot;: 1, //denotes the top range of the Y-axis&lt;br /&gt;
     &amp;quot;worst_primary_value_possible&amp;quot;: 5, //denotes the bottom range of the Y-axis&lt;br /&gt;
     &amp;quot;y_axis_label&amp;quot;: &amp;quot;Rank Average&amp;quot;,&lt;br /&gt;
     &amp;quot;x_axis_label&amp;quot;: &amp;quot;Students&amp;quot;,&lt;br /&gt;
     &amp;quot;color_scheme&amp;quot;: 5b,&lt;br /&gt;
    //secondary value is just an additional&lt;br /&gt;
     &amp;quot;secondary_value_label&amp;quot;: &amp;quot;variance&amp;quot;,&lt;br /&gt;
     &amp;quot;critic_comparer_flag&amp;quot;: &amp;quot;yes&amp;quot;,&lt;br /&gt;
     &amp;quot;self_assess_flag&amp;quot;: &amp;quot;yes&amp;quot;&lt;br /&gt;
},&amp;quot;data&amp;quot;: [{&lt;br /&gt;
    // a student's data&lt;br /&gt;
   }, {&lt;br /&gt;
    // another student's data, see below....&lt;br /&gt;
   }]&lt;br /&gt;
}]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
The first section of the JSON is the “metadata”. Here is where you describe some properties of the graph and the meanings of the numbers in your data section.&lt;br /&gt;
&lt;br /&gt;
The first element in the metadata section is “title”. This is simply the title label drawn at the top of the graph. You can leave this blank if you prefer no title.&lt;br /&gt;
&lt;br /&gt;
     &amp;lt;pre&amp;gt;&amp;quot;title&amp;quot;:&amp;quot;Intro to Digital Media, Assignment 1&amp;quot;&amp;lt;/pre&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
The next entries in the JSON file refer to the “primary-value” data and “values” data that will appear for each column (each student) in the graph. It’s important to understand what these two things mean. To understand why these are important, let’s look at the graph itself.&lt;br /&gt;
&lt;br /&gt;
At it’s core, this graph is simply a bar graph. Each student is represented by a column, and the height of the column is determined by that student’s “primary-value” entry in the JSON file. Think of “primary-value” as their overall aggregate score. This isn’t calculated by the web service but rather is provided by you.&lt;br /&gt;
&lt;br /&gt;
Primary-value determines two things:&lt;br /&gt;
&lt;br /&gt;
*The height of each column&lt;br /&gt;
*The order in which the columns are drawn.&lt;br /&gt;
&lt;br /&gt;
In addition, each of these columns consists of a number of smaller elements stacked together. These elements refer to the individual scores that student received from other peers in a peer review session. These individual scores we call simply “values”. They are stored as a list of numbers that can be any length, and can be listed in any order. Some students may have more “values” than other students and that’s OK. The overall column height will always be drawn such that its height corresponds to the “primary-value” provided by you.&lt;br /&gt;
&lt;br /&gt;
Primary-value is not derived automatically from the individual values you submit since your system might have a unique way to calculate this value such as weighted average based on the reviewer competencies. Thus, you have to provide the primary values in addition to the individual values in the data section of the JSON configuration.&lt;br /&gt;
&lt;br /&gt;
In the example above, each student receives a few rank scores from peers, and the “primary-value” is simply the average of those ranks. Your system might use ratings instead of rankings, or if it uses ranks it might use a formula more complex than simple rank average to determine “primary-value”. How you decide to calculate “primary-value” is entirely up to you, however it’s important that you indicate in the JSON metadata whether a higher or a lower primary-value is “better”. You can do this by defining the “best_primary_value_possible” and “worst_primary_value_possible”, which helps us to understand whether the Y-axis should be rendered with an increasing / decreasing scale. These two values will also set the lower and upper bound of the Y-axis&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;best_primary_value_possible&amp;quot;: 1, &lt;br /&gt;
&amp;quot;worst_primary_value_possible&amp;quot;: 5,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can set “higher_primary_value_better” instead of those two values, which still help us to understand how we should render the Y-axis. However, we will try to determine the lower and upper bound of the scale based on highest (max) and lowest (min) primary values in the data section.&lt;br /&gt;
&lt;br /&gt;
In our case, we set “higher_primary_value_better” to false because a lower rank average is better (the best score is 1, the worst is 5). You can put any label you want. Other labels for primary-value might be things like “cumulative rating”, “average rating” or something else entirely.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;primary_value_label&amp;quot;: &amp;quot;rank average&amp;quot;,&lt;br /&gt;
&amp;quot;higher_primary_value_better&amp;quot;: false,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Likewise, we give a label describing what the individual values that comprise a column are. In the example graph above, each student receives a few rank scores from peers, where lower ranks are better than higher ranks. (1 = first place). This is depicted by the color of individual cell in the graph, which changes from “best” to “worst” colors. The color scheme can be seen as explained in the Color Scheme section. To help us map the values to the right color, you have to let us know whether the higher values are better or worst than the lower values. This can be done by setting the “best_value_possible” and “worst_value_possible” elements as shown below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;best_value_possible&amp;quot;: 1, //this is rendered as green cell, when 5b color scheme is used&lt;br /&gt;
&amp;quot;worst_value_possible&amp;quot;: 5, //this is rendered as red cell, when 5b color scheme is used&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can just use “higher_values_better” element and let the us figure out the best and worst values from the values in the data section. Please note that this method will spread the worst to best colors only to the worst to best values in your data.&lt;br /&gt;
&lt;br /&gt;
In our example, we define “higher_values_better” as false because actually lower numbers are better.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;values_label&amp;quot;: &amp;quot;ranks&amp;quot;,&lt;br /&gt;
&amp;quot;higher_values_better&amp;quot;: false,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Next you can set a label for the x and the y axis, or simply leave them blank.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;y_axis_label&amp;quot;: &amp;quot;Rank Average&amp;quot;,&lt;br /&gt;
&amp;quot;x_axis_label&amp;quot;: &amp;quot;Students&amp;quot;,&amp;lt;/pre&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
The “color_scheme” element allow you to change the colors of the rectangles that represent student’s scores by entering the color scheme code as defined below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;color_scheme&amp;quot;: 5b,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Color Scheme:==&lt;br /&gt;
&amp;lt;pre&amp;gt;“2a”:[“#636363“,”#bdbdbd“],&lt;br /&gt;
“2b”:[“#99d594“,”#fc8d59“],&lt;br /&gt;
“2c”:[“#91bfdb“,”#fc8d59“],&lt;br /&gt;
“2d”:[“#31a354“,”#a1d99b“],&lt;br /&gt;
“2e”:[“#e6550d“,”#a1d99b“],&lt;br /&gt;
“2f”:[“#3182bd“,”#9ecae1“],&lt;br /&gt;
“3a”:[“#636363“,”#f0f0f0“,”#bdbdbd“],&lt;br /&gt;
“3b”:[“#91cf60“,”#fee090“,”#fc8d59“],&lt;br /&gt;
“3c”:[“#3288bd“,”#99d594“,”#fc8d59“],&lt;br /&gt;
“3d”:[“#238b45“,”#66c2a4“,”#b2e2e2“],&lt;br /&gt;
“3e”:[“#fb6a4a“,”#fcae91“,”#fee5d9“],&lt;br /&gt;
“3f”:[“#2171b5“,”#6baed6“,”#bdd7e7“],&lt;br /&gt;
“4a”:[“#252525“,”#636363“,”#969696“,”#bdbdbd“],&lt;br /&gt;
“4b”:[“#91cf60“,”#d9ef8b“,”#fee08b“,”#fc8d59“],&lt;br /&gt;
“4c”:[“#4575b4“,”#91bfdb“,”#fc8d59“,”#d73027“],&lt;br /&gt;
“4d”:[“#006d2c“,”#31a354“,”#74c476“,”#a1d99b“],&lt;br /&gt;
“4e”:[“#fb6a4a“,”#fc9272“,”#fcbba1“,”#fee5d9“],&lt;br /&gt;
“4f”:[“#3182bd“,”#6baed6“,”#9ecae1“,”#c6dbef“],&lt;br /&gt;
“5a”: [“#252525“,”#525252“,”#737373“,”#969696“,”#bdbdbd“],&lt;br /&gt;
“5b”: [“#1a9850“,”#a6d96a“,”#d9ef8b“,”#fdae61“,”#f46d43“],&lt;br /&gt;
“5c”: [“#4575b4“,”#abd9e9“,”#fee090“,”#fdae61“,”#f46d43“],&lt;br /&gt;
“5d”: [“#00441b“,”#238b45“,”#41ab5d“,”#74c476“,”#c7e9c0“],&lt;br /&gt;
“5e”: [“#67000d“,”#a50f15“,”#ef3b2c“,”#fc9272“,”#fee0d2“],&lt;br /&gt;
“5f”: [“#08306b“,”#08519c“,”#4292c6“,”#9ecae1“,”#deebf7“],&lt;br /&gt;
“5x”: [“rgb(178,220,143)“,”rgb(235,241,149)“,”rgb(255,247,154)“,”rgb(254,215,125)“,”rgb(252,99,86)“],&lt;br /&gt;
“5z”: [“#d7191c“,”#fdae61“,”#ffffbf“,”#fc9272“,”#fee0d2“],&lt;br /&gt;
“7b”: [“#1A9850“,”#1FA728“,”#51B625“,”#92C62C“,”#D5D033“,”#E4A13A“,”#F46C43“],&lt;br /&gt;
“11b”: [“#1A9850“,”#1DA138“,”#22AA20“,”#45B324“,”#6BBC28“,”#93C62C“,”#BDCF30“,”#D8C634“,”#E1AA39“,”#EA8C3E“, “#F46B43“]&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Finally, we left room for a “secondary_value_label” in order to show some other data to the students when they roll over the columns in the display. This secondary value might have something to do with the variance in the values they received from peers, or the uncertainty level in calculating their primary-value. It may be something altogether different, such as their overall current percentile standing in the course. You can choose to ignore this “secondary-value” for the students, and ignore the “secondary_value_label”.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;secondary_value_label&amp;quot;: &amp;quot;Variance&amp;quot;,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The last two elements,”critic_comparer_flag” and”self_assess_flag” are flags to activate the new features. Now, the graph is able to show ranking data with more details. When you mouse over a rectangle that shows the ranking that a student gets, the graphs can show the peer who performed the assessment (marked with a purple circle), and the peers that this student was compared with (marked with blue circles). To enable this function, you have to set “critic_comparer_flag” to “yes”, and provide detailed information in the data section.&lt;br /&gt;
&lt;br /&gt;
The second feature “self_assess_flag” is used to display the score that the student estimated for their own performance, we called it simply the self-assessment data. To enable this, you have to set “self_assess_flag” to “yes” in the metadata, and add an “self_assess_value” element for each student with their self assessment score.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;quot;critic_comparer_flag&amp;quot;: &amp;quot;yes&amp;quot;,&lt;br /&gt;
&amp;quot;self_assess_flag&amp;quot;: &amp;quot;yes&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Data==&lt;br /&gt;
With the metadata section finished, the rest of the JSON file will consist of elements, one per students, in the following format.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[{&lt;br /&gt;
&amp;quot;metadata&amp;quot;: {&lt;br /&gt;
   //metadata.. see example above&lt;br /&gt;
},&amp;quot;data&amp;quot;: [{&lt;br /&gt;
&amp;quot;first_name&amp;quot;: &amp;quot;John&amp;quot;,&lt;br /&gt;
 &amp;quot;last_name&amp;quot;: &amp;quot;Doe&amp;quot;,&lt;br /&gt;
 &amp;quot;column_url&amp;quot;: &amp;quot;http://localhost:3000/assignments/584/responses/42846/showcrit?crit_assignment_id=102&amp;quot;,&lt;br /&gt;
 &amp;quot;primary_value&amp;quot;: 1.0,&lt;br /&gt;
 &amp;quot;secondary_value&amp;quot;: 0.0,&lt;br /&gt;
 &amp;quot;values&amp;quot;: [1, 1, 1, 1, 1], &lt;br /&gt;
 &amp;quot;self_assess_value&amp;quot;: 3,&lt;br /&gt;
 &amp;quot;student_id&amp;quot;: 744,&lt;br /&gt;
 &amp;quot;critic_comparer_vector&amp;quot;: [{&lt;br /&gt;
    &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
    &amp;quot;critic_id&amp;quot;: 1222,&lt;br /&gt;
    &amp;quot;critic_peers&amp;quot;: [679, 744, 708, 1360, 724]&lt;br /&gt;
   }, {&lt;br /&gt;
    &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
    &amp;quot;critic_id&amp;quot;: 797,&lt;br /&gt;
    &amp;quot;critic_peers&amp;quot;: [1238, 81, 1245, 679, 744]&lt;br /&gt;
   }, {&lt;br /&gt;
    &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
    &amp;quot;critic_id&amp;quot;: 1223,&lt;br /&gt;
    &amp;quot;critic_peers&amp;quot;: [1225, 679, 744, 708, 1360]&lt;br /&gt;
   }, {&lt;br /&gt;
    &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
    &amp;quot;critic_id&amp;quot;: 1249,&lt;br /&gt;
    &amp;quot;critic_peers&amp;quot;: [744, 708, 1360, 1222, 724]&lt;br /&gt;
   }, {&lt;br /&gt;
    &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
    &amp;quot;critic_id&amp;quot;: 1252,&lt;br /&gt;
    &amp;quot;critic_peers&amp;quot;: [1238, 1245, 679, 744, 708]&lt;br /&gt;
   }]&lt;br /&gt;
  },{ //another student's data }&lt;br /&gt;
 ]&lt;br /&gt;
}]&amp;lt;/pre&amp;gt;&lt;br /&gt;
The “self_assess_flag” attribute is used for showing self assessment data that is depicted as a dark grey rounded rectangle on each column&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&amp;quot;self_assess_value&amp;quot;: 3,&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To enable the graph showing more detailed information about how a student was ranked, you have to provide the needed information that is the student_id, and the critic_comparer_vector element that contains the id of the reviewer and the ID of the peers that this student was compared against. The critic_comparer_vector element include (1) “rank”, which is the rank that this student gets compared to his/her peers. (2) “critic_id”, which is the ID of the student who performed the assessment and ranked the students in that group. (3) “critic_peers”, which is an array of student_ids, belong to the other students (peers) to whom this student was compared against.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;pre&amp;gt;&lt;br /&gt;
 &amp;quot;student_id&amp;quot;: 744,&lt;br /&gt;
 &amp;quot;critic_comparer_vector&amp;quot;: [&lt;br /&gt;
 {&lt;br /&gt;
 &amp;quot;rank&amp;quot;: 1,&lt;br /&gt;
 &amp;quot;critic_id&amp;quot;: 1222,&lt;br /&gt;
 &amp;quot;critic_peers&amp;quot;: [ 679, 744, 708, 1360, 724 ]&lt;br /&gt;
 }, &lt;br /&gt;
 { .. }]&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142914</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142914"/>
		<updated>2022-02-22T02:39:12Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Intelligent_Assignment here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/PeerLogic_Web_Services:_Summarization_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service here].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Intelligent_Assignment&amp;diff=142913</id>
		<title>Web-services: Intelligent Assignment</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Intelligent_Assignment&amp;diff=142913"/>
		<updated>2022-02-22T02:35:39Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Intelligent Assignment to PeerLogic Web Services: Intelligent Assignment&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[PeerLogic Web Services: Intelligent Assignment]]&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142912</id>
		<title>PeerLogic Web Services: Intelligent Assignment</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142912"/>
		<updated>2022-02-22T02:35:39Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Intelligent Assignment to PeerLogic Web Services: Intelligent Assignment&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intelligent Team and Topic Assignment=&lt;br /&gt;
Intelligent assignment creates teams based off of each individual users ranking of topic preference, using k-means clustering. This webservice requires an input of each users ranks [1 being most preferred, and 0 indicating no preference] and unique id [pid], as well as the max team size. This also uses top trading cycles to switch members of teams who have already worked with other members on that team.&lt;br /&gt;
&lt;br /&gt;
==Accessing the service==&lt;br /&gt;
===Access the Webservice online===&lt;br /&gt;
This service is hosted at: http://peerlogic.csc.ncsu.edu/intelligent_assignment/[method name]. This service can be called without copying the code onto your local machine, simply make a post request to this url with one of the method names mentioned below.&lt;br /&gt;
&lt;br /&gt;
===Run it on your local machine===&lt;br /&gt;
The service can be copied from its github repository (https://github.com/peerlogic/IntelligentAssignment). It should be deployed as a webservice; though, it will also require the python libraries flask and scipy:&lt;br /&gt;
&lt;br /&gt;
-[Scipy](https://www.scipy.org/scipylib/download.html)&lt;br /&gt;
&lt;br /&gt;
-[Flask](https://pypi.python.org/pypi/Flask)&lt;br /&gt;
&lt;br /&gt;
==Methods==&lt;br /&gt;
===Creating teams (/merge_teams):===&lt;br /&gt;
Uses K-means clustering to group users with similar topic interests. Works to eliminate competition for any single topic and increase the likelihood that each user obtains their most preferred topic.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “pid”:9841}],&lt;br /&gt;
“max_team_size”:4}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1,0,2,3],”pid”: 1023},&lt;br /&gt;
{“ranks”: [1,2,0,3],”pid”: 4535},&lt;br /&gt;
{“ranks”: [0,2,3,1],”pid”: 1363},&lt;br /&gt;
{“ranks”: [2,1,0,3],”pid”: 9841}],&lt;br /&gt;
“teams”: [[1363,9841],[1023,4535]]}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Swapping Team Members (/swap_team_members):===&lt;br /&gt;
Uses Top Trading Cycles to swap members, that have already worked with members on their team, with other teams’ members. This method only swaps a max of one member per team per run. Begins by first sorting the list of available members by distance from the teams centroid and then by whether or not other members of the team have worked with them. This method requires a history of users that each user has worked with, along with the general information.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output:===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “history”:[4535,9841,9843], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “history”:[1023,9843,8542], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “history”:[3649,9841,9843], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “history”:[1363,1023,3649], “pid”:9841}],&lt;br /&gt;
“teams”: [[1023,2549],[4535,9843],[1363,1867,3649],[9841,8542,7521]]}&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1, 0, 2, 3], “pid”: 1023, “history”: [4535, 9841, 9843]},&lt;br /&gt;
{“ranks”: [1, 2, 0, 3], “pid”: 4535, “history”: [1023, 9843, 8542]},&lt;br /&gt;
{“ranks”: [0, 2, 3, 1], “pid”: 1363, “history”: [3649, 9841, 9843]},&lt;br /&gt;
{“ranks”: [2, 1, 0, 3], “pid”: 9841, “history”: [1363, 1023, 3649]}],&lt;br /&gt;
“teams”: [[9841, 4535], [1023, 1363]]}&lt;br /&gt;
&lt;br /&gt;
Client Code Example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python&lt;br /&gt;
import requests&lt;br /&gt;
import json&lt;br /&gt;
&lt;br /&gt;
#Test data&lt;br /&gt;
data = json.dumps(&lt;br /&gt;
           {&amp;quot;users&amp;quot;:[&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,0,2,3], &amp;quot;history&amp;quot;:[4535,9841,9843], &amp;quot;pid&amp;quot;:1023},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,2,0,3], &amp;quot;history&amp;quot;:[1023,9843,8542], &amp;quot;pid&amp;quot;:4535},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[0,2,3,1], &amp;quot;history&amp;quot;:[3649,9841,9843], &amp;quot;pid&amp;quot;:1363},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[2,1,0,3], &amp;quot;history&amp;quot;:[1363,1023,3649], &amp;quot;pid&amp;quot;:9841}],&lt;br /&gt;
            &amp;quot;max_team_size&amp;quot;:2}&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
header = {'content-type': 'application/json'}&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/merge_teams&amp;quot;,data= data,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&lt;br /&gt;
#The response from merge teams can be used in swap team members if&lt;br /&gt;
#history was given in the body of the request to merge teams&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/swap_team_members&amp;quot;, data=response.text,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Summarization_Service&amp;diff=142911</id>
		<title>Web-services: Summarization Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Summarization_Service&amp;diff=142911"/>
		<updated>2022-02-22T02:34:55Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Summarization Service to PeerLogic Web Services: Summarization Service&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[PeerLogic Web Services: Summarization Service]]&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Summarization_Service&amp;diff=142910</id>
		<title>PeerLogic Web Services: Summarization Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Summarization_Service&amp;diff=142910"/>
		<updated>2022-02-22T02:34:55Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Summarization Service to PeerLogic Web Services: Summarization Service&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summarization Service=&lt;br /&gt;
The extent of feedback in peer review applications could easily overwhelm the student, which may cancel out the desired effects of helping students to identify their strengths and weaknesses related to the assignment. Our preliminary study shows that within traditional classes that are enrolled in Expertiza, the students get feedback from 3-5 reviewers. In a few cases, students could even get feedback from more than 10 reviewers. Each feedback could be very extensive depending on the given rubric. In Expertiza, we found that the rubric contains on average, 8-9 criteria, with two courses even having 159 criteria. Each student / team receives reviews from 5 reviewers on average, and the highest number of reviews was from 72 reviewers, within multiple rounds. The number of words in the feedback that each student / team receives from multiple reviewers on average is 175 words, and the most extensive feedback reaching 8500 words. When assuming that a sentence in average consist of 15 words, it means that each reviewee gets approximately 11-12 sentences, but it could also reach 566 sentences, which would clearly be overwhelming. It is even worse when the students have to read feedback from multiple reviewers that sounds repetitive.&lt;br /&gt;
&lt;br /&gt;
One way to improve this situation is to provide a summary of feedback when the amount has grown extensive. There are a few different ways that summaries could be used in peer review systems. First, the instructor could benefit from having a summary of the qualitative feedback that his students get from their peers. It allows the instructor to sense the general of the problems of his class in that particular assignment. On the student side, having a summary of the feedback could also help them to get a quick glimpse of their strength and weaknesses. This paper focuses on studying providing the summaries for the students.&lt;br /&gt;
&lt;br /&gt;
==Summarization==&lt;br /&gt;
&lt;br /&gt;
A summary for the students could be visualized differently. For instance, when the peer review systems rely on rubrics, a summary could be provided for each piece of feedback given for a criterion such as depicted in figure above. Alternatively, the summary could be presented as a holistic narrative that includes the rubric and the feedback. The summary could also be presented as bullet points grouped under the tone polarity that may resemble the pros and cons of the work. For this study, we choose to show the summary as a narrative since it is the most compact form to show the summary.&lt;br /&gt;
&lt;br /&gt;
To help implement automatic summarization in peer review applications, we provide a web service that can be used to generate summaries automatically. The summarization web service uses python sumy library, which already integrated the following algorithms:&lt;br /&gt;
&lt;br /&gt;
Luhn – heurestic method, [http://web.archive.org/web/20210125175312/http://ieeexplore.ieee.org/xpl/articleDetails.jsp?arnumber=5392672 reference]&lt;br /&gt;
Edmundson heurestic method with previous statistic research, [http://web.archive.org/web/20210125175312/http://dl.acm.org/citation.cfm?doid=321510.321519 reference]&lt;br /&gt;
Latent Semantic Analysis, LSA – one of the algorithm from http://scholar.google.com/citations?user=0fTuW_YAAAAJ&amp;amp;hl=enI think the author is using more advanced algorithms now. [http://web.archive.org/web/20210125175312/http://www.kiv.zcu.cz/~jstein/publikace/isim2004.pdf Steinberger, J. a JeĹľek, K. Using latent semantic an and summary evaluation. In In Proceedings ISIM ‘04. 2004. S. 93-100].&lt;br /&gt;
LexRank – Unsupervised approach inspired by algorithms PageRank and HITS, [http://web.archive.org/web/20210125175312/http://tangra.si.umich.edu/~radev/lexrank/lexrank.pdf reference]&lt;br /&gt;
TextRank – some sort of combination of a few resources that I found on the internet. I really don’t remember the sources. Probably Wikipedia and some papers in 1st page of Google 🙂&lt;br /&gt;
SumBasic – Method that is often used as a baseline in the literature. Source: [http://web.archive.org/web/20210125175312/http://www.cis.upenn.edu/~nenkova/papers/ipm.pdf Read about SumBasic]&lt;br /&gt;
KL-Sum – Method that greedily adds sentences to a summary so long as it decreases the KL Divergence. Source: [http://web.archive.org/web/20210125175312/http://www.aclweb.org/anthology/N09-1041 Read about KL-Sum]&lt;br /&gt;
&lt;br /&gt;
At the moment, we focus on providing a hosted web service, since we haven’t prepared an easy way for doing a local installation.&lt;br /&gt;
&lt;br /&gt;
To use the web service to summarize reviews, it requires that reviews to an artifact (submission) to be splitted up into sentences and put into an array. The array should be serialized into Json and send to the following URL via POST message: “http://peerlogic.csc.ncsu.edu/sum/[suffix]”. The following is an example of the input and output of the web service:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
input JSON : {“sentences”:[“sentence1”, “sentence2”, “sentence3”]}&lt;br /&gt;
output JSON :{ “summary“: “summary1” }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
the suffix could be one of the following :&lt;br /&gt;
&lt;br /&gt;
/sum/v1.0/summary&lt;br /&gt;
    Summarize a given set of sentences&lt;br /&gt;
/sum/v1.0/summary/{length}&lt;br /&gt;
    Summarize a given set of sentences and length of the summary&lt;br /&gt;
    {length} determines the length of the output summary&lt;br /&gt;
/sum/v1.0/summary/{length}/{algorithm}&lt;br /&gt;
    Summarize a given set of sentences, length of the summary, and type of algorithm&lt;br /&gt;
    {length} determines the length of the output summary&lt;br /&gt;
    {algorithm} determines the algorithm to be used. please choose on of these: textrank, lexrank, luhn, edmonson, kl, lsa, sumbasic, random&lt;br /&gt;
&lt;br /&gt;
Code Example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
import java.io.BufferedReader;&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
import java.io.InputStreamReader;&lt;br /&gt;
import java.io.OutputStream;&lt;br /&gt;
import java.net.HttpURLConnection;&lt;br /&gt;
import java.net.MalformedURLException;&lt;br /&gt;
import java.net.ProtocolException;&lt;br /&gt;
import java.net.URL;&lt;br /&gt;
&lt;br /&gt;
import com.google.gson.Gson;&lt;br /&gt;
&lt;br /&gt;
public class SummarizationClient {&lt;br /&gt;
 &lt;br /&gt;
 public SummarizationClient(){&lt;br /&gt;
 &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 public static void main(String[] args) {&lt;br /&gt;
   Sentences s = new Sentences();&lt;br /&gt;
 &lt;br /&gt;
   //prepare input array of sentences&lt;br /&gt;
   String[] arrayOfSentences = {&amp;quot;I'll start by saying that the rose gold 6S is very much pink color.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's not a yellow-pink color as the name rose gold would suggest.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's a dusty rose pink.&amp;quot;, &lt;br /&gt;
   &amp;quot;Today everyone I've talked to has asked me if the pink 6S was actually a pretty pink color, or a yellowish-pink shade.&amp;quot;, &lt;br /&gt;
   &amp;quot;Yep, it's pink!&amp;quot;, &lt;br /&gt;
   &amp;quot;The timing couldn't have been more perfect for me this year, with the announcement of the new iPhone 6S.&amp;quot;, &lt;br /&gt;
   &amp;quot;I got my 4S a few years back, just months before the iPhone 5 was announced.&amp;quot;, &lt;br /&gt;
   &amp;quot;I've loved my little 4S, and up until recently, I had not really been planing on upgrading to a newer model.&amp;quot;, &lt;br /&gt;
   &amp;quot;I'm on an endless mission to lower my family's ever growing cell phone bill, not raise it.&amp;quot;, &lt;br /&gt;
   &amp;quot;So the added length of the 5 models weren't enough of a size difference to make me want to upgrade.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then when the new larger size of the iPhone 6 came out, my first reaction was that I wanted it.&amp;quot;, &lt;br /&gt;
   &amp;quot;However there was a bit of a concern last year with how bendable the iPhone 6 was, and also that Apple had not included a more durable glass that some had originally thought they might.&amp;quot;, &lt;br /&gt;
   &amp;quot;This stronger glass was a feature I had been looking forward to.&amp;quot;, &lt;br /&gt;
   &amp;quot;My husband and teenage son both use ruggedized smartphones by Casio and Kyocera, and I've seen what those phones can survive.&amp;quot;, &lt;br /&gt;
   &amp;quot;My husband has dropped his phone in a lake while fishing, tosses his phone anywhere without the slightest concern for the glass, and my son drops his phone on every hard surface possible, and the screens not only stay in one piece, but without a scratch on them and work just fine even after being completely under water.&amp;quot;, &lt;br /&gt;
   &amp;quot;While I didn't need the extreme toughness of being waterproof, years of seeing my friend's iPhones with spider web cracks covering their screens made me want to hold out a little longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;My 4S was still small enough and thick/bulky enough that I hadn't damaged the screen.&amp;quot;, &lt;br /&gt;
   &amp;quot;Rumors of an iPhone with a stronger glass made me want to hold out just a little longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then last month my old 4S started acting up.&amp;quot;, &lt;br /&gt;
   &amp;quot;I stopped getting notifications of any kind, my phone would drop calls and the internet was getting painfully slow.&amp;quot;, &lt;br /&gt;
   &amp;quot;I knew it was time.&amp;quot;, &lt;br /&gt;
   &amp;quot;I thought maybe when Apple released their new phones, I could pick up last years model a bit cheaper.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then I saw it.&amp;quot;, &lt;br /&gt;
   &amp;quot;ROSE GOLD.&amp;quot;, &lt;br /&gt;
   &amp;quot;That was the shiny bait that made me look closer.&amp;quot;, &lt;br /&gt;
   &amp;quot;What a beautiful color.&amp;quot;, &lt;br /&gt;
   &amp;quot;And then I saw the words I had been waiting for.&amp;quot;, &lt;br /&gt;
   &amp;quot;That the glass on the iPhone 6S is made using a process that makes it stronger and the most durable in the smartphone industry.&amp;quot;, &lt;br /&gt;
   &amp;quot;The best of both worlds, large phone/screen and strong glass.&amp;quot;, &lt;br /&gt;
   &amp;quot;And of course....pink.&amp;quot;, &lt;br /&gt;
   &amp;quot;So I pre-ordered it and from the moment I received it, have been blown away by the features.&amp;quot;, &lt;br /&gt;
   &amp;quot;The screen resolution is stunning, the photos it takes are beautiful and the processor works FAST.&amp;quot;, &lt;br /&gt;
   &amp;quot;The Live Photos feature surprised me the first time I was looking through my pictures.&amp;quot;, &lt;br /&gt;
   &amp;quot;I took a photo of one of our dogs to send to my daughter via a text and when I went to select it, my dog's tail was wagging! Describing it, it sounds like it's just a clip of a short video, but it really is a little different.&amp;quot;, &lt;br /&gt;
   &amp;quot;When you're scrolling through photos and each one has a second of movement to it, it's wild.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's almost like looking through a living photo album.&amp;quot;, &lt;br /&gt;
   &amp;quot;The fingerprint touch ID to unlock the phone and order iTunes music works really well.&amp;quot;, &lt;br /&gt;
   &amp;quot;I was a bit concerned at first I was adding even more steps to unlock my phone each time I wanted to do some small task, like check the time.&amp;quot;, &lt;br /&gt;
   &amp;quot;But using the fingerprint ID gets me in even faster, since I'm not swiping my finger across the screen to unlock it any longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;For me, the most disappointing feature of the phone was putting a case on it! Having to cover the beautiful rose gold color.&amp;quot;, &lt;br /&gt;
   &amp;quot;However I've ordered a new clear case to help with that.&amp;quot;, &lt;br /&gt;
   &amp;quot;Extra protection and I can still see the gorgeous phone color.&amp;quot;, &lt;br /&gt;
   &amp;quot;Upgrading to this new 6S has been worth every penny.&amp;quot;, &lt;br /&gt;
   &amp;quot;With the super fast processor, beautiful rose gold color, Live Pictures and stronger glass, I'm so glad I waited the extra year.&amp;quot;, &lt;br /&gt;
   &amp;quot;Loving everything about it.&amp;quot;};&lt;br /&gt;
   &lt;br /&gt;
   &lt;br /&gt;
   Gson gson = new Gson();   &lt;br /&gt;
   // put the array of sentences into the input object&lt;br /&gt;
   s.sentences = arrayOfSentences;&lt;br /&gt;
   //serialize the input object into json&lt;br /&gt;
   String input = gson.toJson(s); &lt;br /&gt;
 &lt;br /&gt;
   try {&lt;br /&gt;
     //call summarization web service and tell it to produce a summary with a length of 3 sentences (the number in the end of the URL is the expected length)&lt;br /&gt;
     URL url = new URL(&amp;quot;http://peerlogic.csc.ncsu.edu/sum/v1.0/summary/3&amp;quot;); &lt;br /&gt;
     //call the web service&lt;br /&gt;
     String response = invokeSummarizationSvc(input, url);&lt;br /&gt;
     //print the json result&lt;br /&gt;
     System.out.println(&amp;quot;Output from Server : &amp;quot; + response);&lt;br /&gt;
 &lt;br /&gt;
   } catch (MalformedURLException e) {&lt;br /&gt;
     e.printStackTrace();&lt;br /&gt;
   } catch (IOException e) {&lt;br /&gt;
     e.printStackTrace();&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 private static String invokeSummarizationSvc(String input, URL url) throws IOException, ProtocolException {&lt;br /&gt;
   HttpURLConnection conn = (HttpURLConnection) url.openConnection();&lt;br /&gt;
   conn.setDoOutput(true);&lt;br /&gt;
   conn.setRequestMethod(&amp;quot;POST&amp;quot;);&lt;br /&gt;
   //content type must be set to Json, otherwise the server doesn't know how to parse the input&lt;br /&gt;
   conn.setRequestProperty(&amp;quot;Content-Type&amp;quot;, &amp;quot;application/json&amp;quot;);&lt;br /&gt;
   OutputStream os = conn.getOutputStream();&lt;br /&gt;
   os.write(input.getBytes());&lt;br /&gt;
&lt;br /&gt;
   if (conn.getResponseCode() != HttpURLConnection.HTTP_OK) {&lt;br /&gt;
     throw new RuntimeException(&amp;quot;Failed : HTTP error code : &amp;quot;&lt;br /&gt;
       + conn.getResponseCode());&lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
   BufferedReader br = new BufferedReader(new InputStreamReader((conn.getInputStream())));&lt;br /&gt;
&lt;br /&gt;
   String line = &amp;quot;&amp;quot;, lines = &amp;quot;&amp;quot;; &lt;br /&gt;
   while ((line = br.readLine()) != null){&lt;br /&gt;
     lines += line + &amp;quot;\n&amp;quot;;&lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
   conn.disconnect();&lt;br /&gt;
 &lt;br /&gt;
   return lines;&lt;br /&gt;
 }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//class to serialize the text into Json&lt;br /&gt;
class Sentences {&lt;br /&gt;
 public String[] sentences;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Reputation_Web_Service&amp;diff=142909</id>
		<title>Web-services: Reputation Web Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Reputation_Web_Service&amp;diff=142909"/>
		<updated>2022-02-22T02:34:11Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Reputation Web Service to PeerLogic Web Services: Reputation Web Service&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[PeerLogic Web Services: Reputation Web Service]]&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Reputation_Web_Service&amp;diff=142908</id>
		<title>PeerLogic Web Services: Reputation Web Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Reputation_Web_Service&amp;diff=142908"/>
		<updated>2022-02-22T02:34:11Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services: Reputation Web Service to PeerLogic Web Services: Reputation Web Service&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Reputation Web Service=&lt;br /&gt;
&lt;br /&gt;
==How to get students' reputation==&lt;br /&gt;
Alternative 1: Consume our hosted web service&lt;br /&gt;
we have the service hosted at : http://peerlogic.csc.ncsu.edu/reputation. you can use this service without building the code on your local machine&lt;br /&gt;
 &lt;br /&gt;
Alternative 2: Deploy it on your local machine&lt;br /&gt;
1.	Clone the code here : https://github.com/Winbobob/reputation_web_service.git&lt;br /&gt;
2.	You need to install ruby environment on you machine. Here is the instruction for different OS.&lt;br /&gt;
3.	Then you need to install rails Here is the instruction.&lt;br /&gt;
4.	You need to run bundle install to install all required gems.&lt;br /&gt;
5.	After that you need to run rake db:migrate to build the DB structure.&lt;br /&gt;
6.	Run rails s to start the server&lt;br /&gt;
&lt;br /&gt;
==How to communicate reputation web==&lt;br /&gt;
Alternative 1: call the hosted web service&lt;br /&gt;
TODO&lt;br /&gt;
Alternative 2: consume the service via Expertiza UI&lt;br /&gt;
This is only to get reputations of users registered in Expertiza. If you have teaching staff account of Expertiza, you can go to https://expertiza.ncsu.edu/reputation_web_service/client and follow the instructions below and get the results.&lt;br /&gt;
&lt;br /&gt;
==Web Service Structure==&lt;br /&gt;
The reputation web service consists of three main parts, that is client side, server side and the standard transmission format. Figure 1.1 shows the structure of the web service in general. Several client systems are communicating with reputation web service. Since each system has its unique DB schema, different data wrappers are needed to convert raw data into standard transmission format. And on the server side, another data wrapper is used to parse the request and generate adjacency matrices, which indicate what score each reviewer has given to each submission, and are the inputs to reputation algorithms. Finally, the reputation web service sends the results back to client systems.&lt;br /&gt;
&lt;br /&gt;
==Peer-Review Markup Language==&lt;br /&gt;
Peer-Review Markup Language (PRML) is a generic schema for encapsulating the raw data into standard data transmission format. In this way, different client systems can communicate with the reputation web service without changing their database schemas.&lt;br /&gt;
This language defines some entities commonly used in different peer-review systems. The entities used in the reputation web service are a subset of the data defined in PRML, including clients, assignments, tasks, reviewers, reviewed entities and peer-review grade. Table 1.1 explains each entity in detail.&lt;br /&gt;
&lt;br /&gt;
Answer The number of points each reviewer gives to each artifact. Each peer-review record contains identifier of artifact, identifier of reviewer and peer-review grade.&lt;br /&gt;
PRML is a JSON-based format with compact structure, which has three parts. The first part is the information related to assignment(s) and task(s). Figure 1.2 shows the first part, assignment information, with sample data. It allows data coming from multiple assignments and appointing one task for each assignment. According to the sample data, two assignments’ second-round peer-review records will be sent to reputation web service. And maximum and minimum grades of each assignment are also mentioned to help calculate the reputation values.&lt;br /&gt;
&lt;br /&gt;
The second part of standard JSON format is the additional information. They can be initial Hamer reputation values, initial Lauw reputation values, expert grades or quiz scores. Data presented in Figure 1.3 is used for different reputation algorithms. For instance, expert grades are extra inputs of Hamer-expert algorithm and Lauw-expert algorithm; quiz scores are additional inputs of Quiz-based algorithm. Details of each algorithm will be stated in next chapter.&lt;br /&gt;
&lt;br /&gt;
The last part is the review records. It is the most important part because each line records how many points each peer reviewer giving to certain artifact. Figure 1.4 presents the sample peer-review records.&lt;br /&gt;
&lt;br /&gt;
==Server Side Design==&lt;br /&gt;
The server side uses Ruby on Rails framework and follows the MVC design pattern strictly. Each algorithm was implemented in a model file. And the controller focuses on parsing JSON request to adjacency matrices, building data structure, calling different algorithms and sending results back to client system. In reputation web service there is no need to create views because all messages will be transmitted via JSON format. In Figure 1.1, there is only one data wrapper needed for server side. It is a big advantage of reputation web service, that is using standard JSON transmission format can not only unify the interface, but also satisfy the needs of different client systems.&lt;br /&gt;
&lt;br /&gt;
==Client Side Design in Expertiza==&lt;br /&gt;
Figure 1.1 also presents that each peer-review system needs one specific data wrapper. It is because database structure of each system is different. However, the data wrapper is the only thing each client system need to build. So comparing with understanding the logic of reputation algorithms and implementing them, just building a data wrapper can save lots of time and effort. Currently, one data wrapper has already been built and been embedded into Expertiza with a user interface.&lt;br /&gt;
&lt;br /&gt;
The basic user interface of the client side is presented in Figure 1.5. The instructor follows four simple steps to send the standard JSON request. The first step is to type in identifier(s) of assignment(s). These text fields only accept numerical values in order to avoid mistyping. The second assignment identifier text field is optional, which is designed for writing assignments (writing assignment 1a and 1b). Normally, in CSC 517 course, there are two writing assignments. Since they are similar to each other, I tend to merge these two assignments into one sometimes. The last text field is used to specify round number of assignment. The default round number is 2, which means to use the second-round peer-review records as inputs. This bases the reviewer’s reputation on that reviewer’s second-round reviews only.&lt;br /&gt;
&lt;br /&gt;
The second step is to choose different kinds of reputation algorithms. They are Hamer’s algorithm, Lauw’s algorithm, Hamer-expert algorithm, Lauw-expert algorithm and Quiz-based algorithm. Thirdly, instructor needs to choose some additional information. It can be expert grades, initial reputation values or quiz scores. For initial reputation values, instructor can choose either from Hamer-expert algorithm or Lauw-expert algorithm. And the final step is to click the “Send request” button.&lt;br /&gt;
&lt;br /&gt;
The results of writing assignments using Hamer-expert algorithm with expert grades are shown in Figure 1.7. The checkbox before “Add expert grades” is gray, which means it is disabled, cannot be unchecked. The reason is that when instructor chose the Hamer-expert algorithm, the data wrapper needed to add expert grades into request information by default. If instructor unchecks the “Add expert grades” for some reason, it will lead to a conflict. So in order to avoid it, some constraints have been added to this user interface. When the instructor chooses Hamer-expert algorithm or Lauw-expert algorithm, the “Add expert grades” checkbox will be checked and disabled; when instructor chooses the Quiz-based algorithm, the “Add quiz scores” will be checked and disabled and so on.&lt;br /&gt;
&lt;br /&gt;
==Security of Web Service==&lt;br /&gt;
Security is also an important issue, since expert grades and peer-review grades are sensitive data and should not be revealed to unauthorized people. However, according to the design, the reputation web service sends the data in plaintext. In order to protect these sensitive data, encryption algorithms are needed.&lt;br /&gt;
The first solution is to use public-key cryptography. It is an asymmetric key encryption algorithm and cryptographic keys are paired. One is public key, which is disseminated widely and anyone with public key can encrypt messages. The other one is the private key, which can only be used by the keyholder to decrypt private messages [10]. By implementing this solution, client sides can use public key to encrypt the JSON data and server side can use corresponding private key to decrypt the encrypted data. However, there is a maximum message length restriction for public-key cryptography. Since it is possible that request data exceeds the maximum length restriction, another method is needed to apply to all situations.&lt;br /&gt;
&lt;br /&gt;
The second solution is the combination asymmetric key encryption algorithm and symmetric key encryption algorithm, which does not have restriction mentioned above. Procedure of sending encrypted request is presented in Figure 1.9. The client side uses a newly generated symmetric key to encrypt the JSON data and then encrypts the symmetric key with the public key from the asymmetric key encryption algorithm. After that, it sends the encrypted request to the server side. Then the server side decrypts the symmetric key with the private key. Secondly, it obtains the JSON data by using the symmetric key. And sending the response back to client side is the reverse process. In practice, AES is chosen the as symmetric encryption algorithm, and RSA is chosen as the asymmetric encryption algorithm.&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
In summary, the “pluggable” reputation web service can make peer review systems access to multiple reputation algorithms and compare with each other. So there is no need to implement reputation algorithms locally. But each client system needs a specific data wrapper. The data wrapper can convert client system’s database schema into a standard JSON transmission format, which is the subset of PRML. After reputation web service receives the JSON request, it will do calculation and send the JSON response back to client system. What’s more, the reputation web service also uses cryptography to protect the sensitive data.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services&amp;diff=142907</id>
		<title>Web-services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services&amp;diff=142907"/>
		<updated>2022-02-22T02:33:45Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services to PeerLogic Web Services: Fix capitalization&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#REDIRECT [[PeerLogic Web Services]]&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142906</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142906"/>
		<updated>2022-02-22T02:33:45Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Ggarrid moved page Web-services to PeerLogic Web Services: Fix capitalization&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142905</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142905"/>
		<updated>2022-02-22T02:31:07Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* reputation_web_service */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142904</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142904"/>
		<updated>2022-02-22T02:30:33Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;br /&gt;
&lt;br /&gt;
==Other Resources==&lt;br /&gt;
The following are older resources with a bit more depth into specifics, left here for the sake of not losing any information.&lt;br /&gt;
&lt;br /&gt;
Original PeerLogic web service set up: [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
NLP Web Service Setup: [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142903</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142903"/>
		<updated>2022-02-22T02:28:53Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Getting Started on Updating the Server */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the directory opt/webservices, so navigate to that directory to make your changes.&lt;br /&gt;
&lt;br /&gt;
==Adding a New Web Service==&lt;br /&gt;
&lt;br /&gt;
* If your intention is to add a new web service, you will need to edit one of the two startup scripts in /opt/webservices: runws_root.sh, and runws_user.sh.&lt;br /&gt;
* runws_user.sh belongs to the &amp;quot;railsadmin&amp;quot; user and runs ruby 2.3.0p0. This file should be modified in order to start up any Ruby services.&lt;br /&gt;
* runws_root.sh, meanwhile, is run by the root access user, and should be used for any Python scripts or anything needing root access.&lt;br /&gt;
* Pick the appropriate script and add the code to start your application within&lt;br /&gt;
* After doing so, navigate back to the top directory and access /etc/nginx/nginx.conf&lt;br /&gt;
* Within this config file, each service is assigned to a unique port on the machine. Your application must be configured to run on one of these ports, and on a port not already in use (please see the config file to see which ports are already in use).&lt;br /&gt;
* To add your application to these url mappings, add this code to the config file, substituting the urls relevant to your service:&lt;br /&gt;
&amp;lt;pre&amp;gt;location ^~ /[URL_PATH_TOBE_EXPOSED_EXTERNALLY] {&lt;br /&gt;
        	proxy_pass [YOUR_SERVICE_LOCAL_URL];&lt;br /&gt;
}&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once this is done, start your service and set it up to run after you've finished ssh'ing by running the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo nohup python _yourscript_.py &amp;amp;&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Finally, reload nginx to update the changes to the config file using the following command:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo service nginx reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142902</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142902"/>
		<updated>2022-02-22T02:02:45Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted at peerlogic.csc.ncsu.edu and are externally called for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Getting Started on Updating the Server==&lt;br /&gt;
If for some reason, you need to modify, change, or update the code hosted at peerlogic.csc.ncsu.edu, you may follow these steps to do so.&lt;br /&gt;
* Submit a request to CSC IT in order to be given access to the server. You can do this by emailing them at csc_help@ncsu.edu and cc'ing Dr. Gehringer so he may verify you have permission to do so.&lt;br /&gt;
* Prepare the code you intend to add or modify in a GitHub repository. This will make it as simple as possible to transport your code to the web server.&lt;br /&gt;
* The server can only be accessed from within the internal NCState network. In order to gain this access, create a VCL reservation [https://vcl.ncsu.edu/ here], and SSH or remote desktop into the VCL. For the purposes of this explanation, I will assume you are doing this using Unix for your VCL.&lt;br /&gt;
* Now that you are within the network, you can access the server via the SSH command, using your unityid. You will also be asked to provide your password upon connecting to the server. The command to ssh is given below:&lt;br /&gt;
&amp;lt;pre&amp;gt;ssh &amp;lt;unityid&amp;gt;@peerlogic.csc.ncsu.edu&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Once you have successfully connected to the server, you will be placed in a directory named after your Unity ID. Navigate up and out of this directory until you reach the top directory level (as far out as you can go).&lt;br /&gt;
* Webservices are hosted within the &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Data_Warehouse&amp;diff=142901</id>
		<title>Web-services: Data Warehouse</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Data_Warehouse&amp;diff=142901"/>
		<updated>2022-02-15T02:47:44Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Data Warehouse=&lt;br /&gt;
==Mapping Individual database to PRML schema==&lt;br /&gt;
IUSE project aims at unifying peer review data across different systems to enable data analysis across wider users and different set of peer review approaches. In the consortium, we have 4 systems, whose data is to be unified (Expertiza, Crowd Grader, Mobius SLIP, CritViz). In addition, data from 2 other bigger systems, Perceptive and CPR, where the the project advisors should also be integrated to some extent.&lt;br /&gt;
&lt;br /&gt;
We choose to use an existing open source ETL (Extract, Transform, Load) tool, called Pentaho, for extracting data from the database of individual system, transform this data according to PRML schema and store the result to a centralized PRML DB. Figure 1 shows the architecture how we plan to extract data from expertiza database, then we transform the data according to the PRML schema. However, since PRML is normalized in 3NF, it might not be easy to extract some information for data analysis purposes. Thus, we plan to denormalize the PRML data and store them in a data warehouse.&lt;br /&gt;
&lt;br /&gt;
==Initial Step==&lt;br /&gt;
&lt;br /&gt;
The Pentaho Kettle tool extracts data from the expertise schema, performs transformation on it and load the data in the PRML format. The tables are mapped as shown in the schema map above. The operations performed by the ETL tool:&lt;br /&gt;
&lt;br /&gt;
Extraction The data is extracted from the expertise database and brought into the staging area by this operation of the ETL tool. It is the staging area in which all the transformation are done.&lt;br /&gt;
&lt;br /&gt;
Transformation Many operations are performed on the data in the staging area so that the expertise schema can be converted to the PRML schema. This is called transformation of the data. An example of transformation is while mapping of participants table in the expertiza database to actors table in the PRML database. Each value of the id field is incremented by 1000 while inserting in the participants table.&lt;br /&gt;
&lt;br /&gt;
Loading: The transformed data when moved from the staging area to the PRML database is called as loading. There are three types of loading implemented on the tables depending on the size of the table – initial load,partial loading and full loading. Partial Loading: Only the new or updated entries in the expertiza table are transformed and loaded in the corresponding PRML table. This is generally done for table with very large number of entries. Eg: Reviews&lt;br /&gt;
&lt;br /&gt;
Partial loading is implemented with the help of timestamps and checksums.&lt;br /&gt;
&lt;br /&gt;
Timestamp: One way to perform partial loading is to have a ‘modified’ time stamp in the source table. The destination table should mirror this ‘modified’ time stamp. Then while loading the destination table we extract only those records from the source table which has a ‘modified’ time stamp value greater than the latest ‘modified’ time stamp value in the destination table. The advantage is that we need not fetch all records from the source table. Only those records which needs to be updated in the destination table will be retrieved. (refer load_prml_ModifiedTimeStampTable transformation)&lt;br /&gt;
&lt;br /&gt;
Checksum: Another way to perform partial loading is using checksum. A checksum is computed for each record, on selected field values, of the source table and added to the destination table while initial loading. Loading which follow would again compute the checksum for source table records and if there is no matching checksum in the destination table an update or an insert would be performed. (refer load_prml_checksumtable transformation)&lt;br /&gt;
&lt;br /&gt;
Full Loading: All the entries from the expertiza table are transformed and loaded in the corresponding PRML table. This is generally done for tables with less number of entries. Eg: Courses&lt;br /&gt;
&lt;br /&gt;
===Pentaho, Spoon ETL===&lt;br /&gt;
&lt;br /&gt;
Pentaho provides a GUI to define the ETL process. as shown in figure 3, first we define the DB connections to Expertiza database and PRML database, then we use a table input component to query the necessary data for each PRML table. Figure 3 also shows an example of the SQL query that extract course data from expertiza and map each column to the corresponding PRML column. we then use Insert/Update component to insert the queried data into the corresponding PRML table. since the mapping has done in the initial query, we only need to map the ID of the queried record. A similar step is defined for each PRML table.&lt;br /&gt;
&lt;br /&gt;
==Data Warehouse Schema==&lt;br /&gt;
&lt;br /&gt;
PRML was used to define a data warehouse model that can be used to share data from different peer-review systems. We designed the schema based on  dimensional modeling approach[] Dimensional modeling requires the data that contains measurements, metrics, or facts of the business process to be stored as Fact tables. The Fact tables also contains foreign keys to the dimension tables that can be used to group the facts into multidimensional arrays of data, known as OLAP cube or hypercube. Dimensional modeling encourages data warehouse schema to follow a star topology, in which fact tables are placed in the center.&lt;br /&gt;
&lt;br /&gt;
Following this approach, our schema is centered around the Critique table. It contains reviewer’s qualitative and quantitative feedback. The quantitative feedback can be expressed in rating, ranking or the combination of both. As depicted in Figure 4, the Critiques can be sliced based on different dimensions including the Criterion, Eval_Mode,  Task, Actor, and Course_Setting.  The criterion table contains criteria questions, the scale used to rank or rate the work, and the weighting that is used to calculate the final score. The eval_mode determines whether ranking, rating or both are used to evaluate the artifact. The Task table contains information such as when the task starts and ends, the CIP (Classification of Instructional Programs) codes, whether it is an assignment, reviewing, or meta-reviewing task. The actor table contains the actors involved in the assignment and their roles, whether it is student, instructor, or administrator. The actor table is linked to the participant table in the actor_participant table to maintain the group memberships of each participant.&lt;br /&gt;
&lt;br /&gt;
The Artifact table contains information about the student’s work in response to the assignments, which is usually a url to uploaded files or web pages. Course_setting table contains meta information about how the peer review was conducted. For instance, anonymity could be none, single blind, double blind, partial (critiques and artifacts are public after the review process is done). The workflow, could be single loop, double loop, or n rounds. The rubric mode, could be holistic or specific, and assignment style could be assignment based, where a set of activities are fixed or task based where activities may varies from assignment to assignment. The Course_setting table is used to compare the effect of different features adopted by peer review systems to the learning gains as well as the quality of the peer review process itself.&lt;br /&gt;
&lt;br /&gt;
==Accessing the data==&lt;br /&gt;
If you are familiar with SQL, you can query the data on our MySQL database directly. You’ll need a mysql client such as MySQL Workbench (http://dev.mysql.com/downloads/workbench/). You can reach our server using the following read-only credential:&lt;br /&gt;
&lt;br /&gt;
mysql server: peerlogic.csc.ncsu.edu (port three three zero six)&lt;br /&gt;
username : readonly&lt;br /&gt;
password : readpassword&lt;br /&gt;
Alternatively, if you are not familiar with SQL, you can also use REST API to query the data. please be aware that our REST API currently is only able to retrieve a limited set of data from the data warehouse, as documented here. But we’d love to hear your feedback, and if you need to retrieve some data that is currently not supported, please do let us know. We’ll try to have it implemented within 1-2 days.&lt;br /&gt;
&lt;br /&gt;
The REST API can be accessed from this URL: http://peerlogic.csc.ncsu.edu/datawarehouse/&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Data_Warehouse&amp;diff=142900</id>
		<title>Web-services: Data Warehouse</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Web-services:_Data_Warehouse&amp;diff=142900"/>
		<updated>2022-02-15T02:47:16Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=Data Warehouse= ==Mapping Individual database to PRML schema== IUSE project aims at unifying peer review data across different systems to enable data analysis across wider us...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Data Warehouse=&lt;br /&gt;
==Mapping Individual database to PRML schema==&lt;br /&gt;
IUSE project aims at unifying peer review data across different systems to enable data analysis across wider users and different set of peer review approaches. In the consortium, we have 4 systems, whose data is to be unified (Expertiza, Crowd Grader, Mobius SLIP, CritViz). In addition, data from 2 other bigger systems, Perceptive and CPR, where the the project advisors should also be integrated to some extent.&lt;br /&gt;
&lt;br /&gt;
We choose to use an existing open source ETL (Extract, Transform, Load) tool, called Pentaho, for extracting data from the database of individual system, transform this data according to PRML schema and store the result to a centralized PRML DB. Figure 1 shows the architecture how we plan to extract data from expertiza database, then we transform the data according to the PRML schema. However, since PRML is normalized in 3NF, it might not be easy to extract some information for data analysis purposes. Thus, we plan to denormalize the PRML data and store them in a data warehouse.&lt;br /&gt;
&lt;br /&gt;
===Initial Step===&lt;br /&gt;
===ETL===&lt;br /&gt;
&lt;br /&gt;
The Pentaho Kettle tool extracts data from the expertise schema, performs transformation on it and load the data in the PRML format. The tables are mapped as shown in the schema map above. The operations performed by the ETL tool:&lt;br /&gt;
&lt;br /&gt;
Extraction The data is extracted from the expertise database and brought into the staging area by this operation of the ETL tool. It is the staging area in which all the transformation are done.&lt;br /&gt;
&lt;br /&gt;
Transformation Many operations are performed on the data in the staging area so that the expertise schema can be converted to the PRML schema. This is called transformation of the data. An example of transformation is while mapping of participants table in the expertiza database to actors table in the PRML database. Each value of the id field is incremented by 1000 while inserting in the participants table.&lt;br /&gt;
&lt;br /&gt;
Loading: The transformed data when moved from the staging area to the PRML database is called as loading. There are three types of loading implemented on the tables depending on the size of the table – initial load,partial loading and full loading. Partial Loading: Only the new or updated entries in the expertiza table are transformed and loaded in the corresponding PRML table. This is generally done for table with very large number of entries. Eg: Reviews&lt;br /&gt;
&lt;br /&gt;
Partial loading is implemented with the help of timestamps and checksums.&lt;br /&gt;
&lt;br /&gt;
Timestamp: One way to perform partial loading is to have a ‘modified’ time stamp in the source table. The destination table should mirror this ‘modified’ time stamp. Then while loading the destination table we extract only those records from the source table which has a ‘modified’ time stamp value greater than the latest ‘modified’ time stamp value in the destination table. The advantage is that we need not fetch all records from the source table. Only those records which needs to be updated in the destination table will be retrieved. (refer load_prml_ModifiedTimeStampTable transformation)&lt;br /&gt;
&lt;br /&gt;
Checksum: Another way to perform partial loading is using checksum. A checksum is computed for each record, on selected field values, of the source table and added to the destination table while initial loading. Loading which follow would again compute the checksum for source table records and if there is no matching checksum in the destination table an update or an insert would be performed. (refer load_prml_checksumtable transformation)&lt;br /&gt;
&lt;br /&gt;
Full Loading: All the entries from the expertiza table are transformed and loaded in the corresponding PRML table. This is generally done for tables with less number of entries. Eg: Courses&lt;br /&gt;
&lt;br /&gt;
===Pentaho, Spoon ETL===&lt;br /&gt;
&lt;br /&gt;
Pentaho provides a GUI to define the ETL process. as shown in figure 3, first we define the DB connections to Expertiza database and PRML database, then we use a table input component to query the necessary data for each PRML table. Figure 3 also shows an example of the SQL query that extract course data from expertiza and map each column to the corresponding PRML column. we then use Insert/Update component to insert the queried data into the corresponding PRML table. since the mapping has done in the initial query, we only need to map the ID of the queried record. A similar step is defined for each PRML table.&lt;br /&gt;
&lt;br /&gt;
==Data Warehouse Schema==&lt;br /&gt;
&lt;br /&gt;
PRML was used to define a data warehouse model that can be used to share data from different peer-review systems. We designed the schema based on  dimensional modeling approach[] Dimensional modeling requires the data that contains measurements, metrics, or facts of the business process to be stored as Fact tables. The Fact tables also contains foreign keys to the dimension tables that can be used to group the facts into multidimensional arrays of data, known as OLAP cube or hypercube. Dimensional modeling encourages data warehouse schema to follow a star topology, in which fact tables are placed in the center.&lt;br /&gt;
&lt;br /&gt;
Following this approach, our schema is centered around the Critique table. It contains reviewer’s qualitative and quantitative feedback. The quantitative feedback can be expressed in rating, ranking or the combination of both. As depicted in Figure 4, the Critiques can be sliced based on different dimensions including the Criterion, Eval_Mode,  Task, Actor, and Course_Setting.  The criterion table contains criteria questions, the scale used to rank or rate the work, and the weighting that is used to calculate the final score. The eval_mode determines whether ranking, rating or both are used to evaluate the artifact. The Task table contains information such as when the task starts and ends, the CIP (Classification of Instructional Programs) codes, whether it is an assignment, reviewing, or meta-reviewing task. The actor table contains the actors involved in the assignment and their roles, whether it is student, instructor, or administrator. The actor table is linked to the participant table in the actor_participant table to maintain the group memberships of each participant.&lt;br /&gt;
&lt;br /&gt;
The Artifact table contains information about the student’s work in response to the assignments, which is usually a url to uploaded files or web pages. Course_setting table contains meta information about how the peer review was conducted. For instance, anonymity could be none, single blind, double blind, partial (critiques and artifacts are public after the review process is done). The workflow, could be single loop, double loop, or n rounds. The rubric mode, could be holistic or specific, and assignment style could be assignment based, where a set of activities are fixed or task based where activities may varies from assignment to assignment. The Course_setting table is used to compare the effect of different features adopted by peer review systems to the learning gains as well as the quality of the peer review process itself.&lt;br /&gt;
&lt;br /&gt;
==Accessing the data==&lt;br /&gt;
If you are familiar with SQL, you can query the data on our MySQL database directly. You’ll need a mysql client such as MySQL Workbench (http://dev.mysql.com/downloads/workbench/). You can reach our server using the following read-only credential:&lt;br /&gt;
&lt;br /&gt;
mysql server: peerlogic.csc.ncsu.edu (port three three zero six)&lt;br /&gt;
username : readonly&lt;br /&gt;
password : readpassword&lt;br /&gt;
Alternatively, if you are not familiar with SQL, you can also use REST API to query the data. please be aware that our REST API currently is only able to retrieve a limited set of data from the data warehouse, as documented here. But we’d love to hear your feedback, and if you need to retrieve some data that is currently not supported, please do let us know. We’ll try to have it implemented within 1-2 days.&lt;br /&gt;
&lt;br /&gt;
The REST API can be accessed from this URL: http://peerlogic.csc.ncsu.edu/datawarehouse/&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142899</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142899"/>
		<updated>2022-02-15T02:43:57Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* AutoSummaryV1 */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Summarization_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Summarization_Service&amp;diff=142898</id>
		<title>PeerLogic Web Services: Summarization Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Summarization_Service&amp;diff=142898"/>
		<updated>2022-02-15T02:43:06Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=Summarization Service= The extent of feedback in peer review applications could easily overwhelm the student, which may cancel out the desired effects of helping students to...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summarization Service=&lt;br /&gt;
The extent of feedback in peer review applications could easily overwhelm the student, which may cancel out the desired effects of helping students to identify their strengths and weaknesses related to the assignment. Our preliminary study shows that within traditional classes that are enrolled in Expertiza, the students get feedback from 3-5 reviewers. In a few cases, students could even get feedback from more than 10 reviewers. Each feedback could be very extensive depending on the given rubric. In Expertiza, we found that the rubric contains on average, 8-9 criteria, with two courses even having 159 criteria. Each student / team receives reviews from 5 reviewers on average, and the highest number of reviews was from 72 reviewers, within multiple rounds. The number of words in the feedback that each student / team receives from multiple reviewers on average is 175 words, and the most extensive feedback reaching 8500 words. When assuming that a sentence in average consist of 15 words, it means that each reviewee gets approximately 11-12 sentences, but it could also reach 566 sentences, which would clearly be overwhelming. It is even worse when the students have to read feedback from multiple reviewers that sounds repetitive.&lt;br /&gt;
&lt;br /&gt;
One way to improve this situation is to provide a summary of feedback when the amount has grown extensive. There are a few different ways that summaries could be used in peer review systems. First, the instructor could benefit from having a summary of the qualitative feedback that his students get from their peers. It allows the instructor to sense the general of the problems of his class in that particular assignment. On the student side, having a summary of the feedback could also help them to get a quick glimpse of their strength and weaknesses. This paper focuses on studying providing the summaries for the students.&lt;br /&gt;
&lt;br /&gt;
==Summarization==&lt;br /&gt;
&lt;br /&gt;
A summary for the students could be visualized differently. For instance, when the peer review systems rely on rubrics, a summary could be provided for each piece of feedback given for a criterion such as depicted in figure above. Alternatively, the summary could be presented as a holistic narrative that includes the rubric and the feedback. The summary could also be presented as bullet points grouped under the tone polarity that may resemble the pros and cons of the work. For this study, we choose to show the summary as a narrative since it is the most compact form to show the summary.&lt;br /&gt;
&lt;br /&gt;
To help implement automatic summarization in peer review applications, we provide a web service that can be used to generate summaries automatically. The summarization web service uses python sumy library, which already integrated the following algorithms:&lt;br /&gt;
&lt;br /&gt;
Luhn – heurestic method, [http://web.archive.org/web/20210125175312/http://ieeexplore.ieee.org/xpl/articleDetails.jsp?arnumber=5392672 reference]&lt;br /&gt;
Edmundson heurestic method with previous statistic research, [http://web.archive.org/web/20210125175312/http://dl.acm.org/citation.cfm?doid=321510.321519 reference]&lt;br /&gt;
Latent Semantic Analysis, LSA – one of the algorithm from http://scholar.google.com/citations?user=0fTuW_YAAAAJ&amp;amp;hl=enI think the author is using more advanced algorithms now. [http://web.archive.org/web/20210125175312/http://www.kiv.zcu.cz/~jstein/publikace/isim2004.pdf Steinberger, J. a JeĹľek, K. Using latent semantic an and summary evaluation. In In Proceedings ISIM ‘04. 2004. S. 93-100].&lt;br /&gt;
LexRank – Unsupervised approach inspired by algorithms PageRank and HITS, [http://web.archive.org/web/20210125175312/http://tangra.si.umich.edu/~radev/lexrank/lexrank.pdf reference]&lt;br /&gt;
TextRank – some sort of combination of a few resources that I found on the internet. I really don’t remember the sources. Probably Wikipedia and some papers in 1st page of Google 🙂&lt;br /&gt;
SumBasic – Method that is often used as a baseline in the literature. Source: [http://web.archive.org/web/20210125175312/http://www.cis.upenn.edu/~nenkova/papers/ipm.pdf Read about SumBasic]&lt;br /&gt;
KL-Sum – Method that greedily adds sentences to a summary so long as it decreases the KL Divergence. Source: [http://web.archive.org/web/20210125175312/http://www.aclweb.org/anthology/N09-1041 Read about KL-Sum]&lt;br /&gt;
&lt;br /&gt;
At the moment, we focus on providing a hosted web service, since we haven’t prepared an easy way for doing a local installation.&lt;br /&gt;
&lt;br /&gt;
To use the web service to summarize reviews, it requires that reviews to an artifact (submission) to be splitted up into sentences and put into an array. The array should be serialized into Json and send to the following URL via POST message: “http://peerlogic.csc.ncsu.edu/sum/[suffix]”. The following is an example of the input and output of the web service:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
input JSON : {“sentences”:[“sentence1”, “sentence2”, “sentence3”]}&lt;br /&gt;
output JSON :{ “summary“: “summary1” }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
the suffix could be one of the following :&lt;br /&gt;
&lt;br /&gt;
/sum/v1.0/summary&lt;br /&gt;
    Summarize a given set of sentences&lt;br /&gt;
/sum/v1.0/summary/{length}&lt;br /&gt;
    Summarize a given set of sentences and length of the summary&lt;br /&gt;
    {length} determines the length of the output summary&lt;br /&gt;
/sum/v1.0/summary/{length}/{algorithm}&lt;br /&gt;
    Summarize a given set of sentences, length of the summary, and type of algorithm&lt;br /&gt;
    {length} determines the length of the output summary&lt;br /&gt;
    {algorithm} determines the algorithm to be used. please choose on of these: textrank, lexrank, luhn, edmonson, kl, lsa, sumbasic, random&lt;br /&gt;
&lt;br /&gt;
Code Example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
import java.io.BufferedReader;&lt;br /&gt;
import java.io.IOException;&lt;br /&gt;
import java.io.InputStreamReader;&lt;br /&gt;
import java.io.OutputStream;&lt;br /&gt;
import java.net.HttpURLConnection;&lt;br /&gt;
import java.net.MalformedURLException;&lt;br /&gt;
import java.net.ProtocolException;&lt;br /&gt;
import java.net.URL;&lt;br /&gt;
&lt;br /&gt;
import com.google.gson.Gson;&lt;br /&gt;
&lt;br /&gt;
public class SummarizationClient {&lt;br /&gt;
 &lt;br /&gt;
 public SummarizationClient(){&lt;br /&gt;
 &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 public static void main(String[] args) {&lt;br /&gt;
   Sentences s = new Sentences();&lt;br /&gt;
 &lt;br /&gt;
   //prepare input array of sentences&lt;br /&gt;
   String[] arrayOfSentences = {&amp;quot;I'll start by saying that the rose gold 6S is very much pink color.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's not a yellow-pink color as the name rose gold would suggest.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's a dusty rose pink.&amp;quot;, &lt;br /&gt;
   &amp;quot;Today everyone I've talked to has asked me if the pink 6S was actually a pretty pink color, or a yellowish-pink shade.&amp;quot;, &lt;br /&gt;
   &amp;quot;Yep, it's pink!&amp;quot;, &lt;br /&gt;
   &amp;quot;The timing couldn't have been more perfect for me this year, with the announcement of the new iPhone 6S.&amp;quot;, &lt;br /&gt;
   &amp;quot;I got my 4S a few years back, just months before the iPhone 5 was announced.&amp;quot;, &lt;br /&gt;
   &amp;quot;I've loved my little 4S, and up until recently, I had not really been planing on upgrading to a newer model.&amp;quot;, &lt;br /&gt;
   &amp;quot;I'm on an endless mission to lower my family's ever growing cell phone bill, not raise it.&amp;quot;, &lt;br /&gt;
   &amp;quot;So the added length of the 5 models weren't enough of a size difference to make me want to upgrade.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then when the new larger size of the iPhone 6 came out, my first reaction was that I wanted it.&amp;quot;, &lt;br /&gt;
   &amp;quot;However there was a bit of a concern last year with how bendable the iPhone 6 was, and also that Apple had not included a more durable glass that some had originally thought they might.&amp;quot;, &lt;br /&gt;
   &amp;quot;This stronger glass was a feature I had been looking forward to.&amp;quot;, &lt;br /&gt;
   &amp;quot;My husband and teenage son both use ruggedized smartphones by Casio and Kyocera, and I've seen what those phones can survive.&amp;quot;, &lt;br /&gt;
   &amp;quot;My husband has dropped his phone in a lake while fishing, tosses his phone anywhere without the slightest concern for the glass, and my son drops his phone on every hard surface possible, and the screens not only stay in one piece, but without a scratch on them and work just fine even after being completely under water.&amp;quot;, &lt;br /&gt;
   &amp;quot;While I didn't need the extreme toughness of being waterproof, years of seeing my friend's iPhones with spider web cracks covering their screens made me want to hold out a little longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;My 4S was still small enough and thick/bulky enough that I hadn't damaged the screen.&amp;quot;, &lt;br /&gt;
   &amp;quot;Rumors of an iPhone with a stronger glass made me want to hold out just a little longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then last month my old 4S started acting up.&amp;quot;, &lt;br /&gt;
   &amp;quot;I stopped getting notifications of any kind, my phone would drop calls and the internet was getting painfully slow.&amp;quot;, &lt;br /&gt;
   &amp;quot;I knew it was time.&amp;quot;, &lt;br /&gt;
   &amp;quot;I thought maybe when Apple released their new phones, I could pick up last years model a bit cheaper.&amp;quot;, &lt;br /&gt;
   &amp;quot;Then I saw it.&amp;quot;, &lt;br /&gt;
   &amp;quot;ROSE GOLD.&amp;quot;, &lt;br /&gt;
   &amp;quot;That was the shiny bait that made me look closer.&amp;quot;, &lt;br /&gt;
   &amp;quot;What a beautiful color.&amp;quot;, &lt;br /&gt;
   &amp;quot;And then I saw the words I had been waiting for.&amp;quot;, &lt;br /&gt;
   &amp;quot;That the glass on the iPhone 6S is made using a process that makes it stronger and the most durable in the smartphone industry.&amp;quot;, &lt;br /&gt;
   &amp;quot;The best of both worlds, large phone/screen and strong glass.&amp;quot;, &lt;br /&gt;
   &amp;quot;And of course....pink.&amp;quot;, &lt;br /&gt;
   &amp;quot;So I pre-ordered it and from the moment I received it, have been blown away by the features.&amp;quot;, &lt;br /&gt;
   &amp;quot;The screen resolution is stunning, the photos it takes are beautiful and the processor works FAST.&amp;quot;, &lt;br /&gt;
   &amp;quot;The Live Photos feature surprised me the first time I was looking through my pictures.&amp;quot;, &lt;br /&gt;
   &amp;quot;I took a photo of one of our dogs to send to my daughter via a text and when I went to select it, my dog's tail was wagging! Describing it, it sounds like it's just a clip of a short video, but it really is a little different.&amp;quot;, &lt;br /&gt;
   &amp;quot;When you're scrolling through photos and each one has a second of movement to it, it's wild.&amp;quot;, &lt;br /&gt;
   &amp;quot;It's almost like looking through a living photo album.&amp;quot;, &lt;br /&gt;
   &amp;quot;The fingerprint touch ID to unlock the phone and order iTunes music works really well.&amp;quot;, &lt;br /&gt;
   &amp;quot;I was a bit concerned at first I was adding even more steps to unlock my phone each time I wanted to do some small task, like check the time.&amp;quot;, &lt;br /&gt;
   &amp;quot;But using the fingerprint ID gets me in even faster, since I'm not swiping my finger across the screen to unlock it any longer.&amp;quot;, &lt;br /&gt;
   &amp;quot;For me, the most disappointing feature of the phone was putting a case on it! Having to cover the beautiful rose gold color.&amp;quot;, &lt;br /&gt;
   &amp;quot;However I've ordered a new clear case to help with that.&amp;quot;, &lt;br /&gt;
   &amp;quot;Extra protection and I can still see the gorgeous phone color.&amp;quot;, &lt;br /&gt;
   &amp;quot;Upgrading to this new 6S has been worth every penny.&amp;quot;, &lt;br /&gt;
   &amp;quot;With the super fast processor, beautiful rose gold color, Live Pictures and stronger glass, I'm so glad I waited the extra year.&amp;quot;, &lt;br /&gt;
   &amp;quot;Loving everything about it.&amp;quot;};&lt;br /&gt;
   &lt;br /&gt;
   &lt;br /&gt;
   Gson gson = new Gson();   &lt;br /&gt;
   // put the array of sentences into the input object&lt;br /&gt;
   s.sentences = arrayOfSentences;&lt;br /&gt;
   //serialize the input object into json&lt;br /&gt;
   String input = gson.toJson(s); &lt;br /&gt;
 &lt;br /&gt;
   try {&lt;br /&gt;
     //call summarization web service and tell it to produce a summary with a length of 3 sentences (the number in the end of the URL is the expected length)&lt;br /&gt;
     URL url = new URL(&amp;quot;http://peerlogic.csc.ncsu.edu/sum/v1.0/summary/3&amp;quot;); &lt;br /&gt;
     //call the web service&lt;br /&gt;
     String response = invokeSummarizationSvc(input, url);&lt;br /&gt;
     //print the json result&lt;br /&gt;
     System.out.println(&amp;quot;Output from Server : &amp;quot; + response);&lt;br /&gt;
 &lt;br /&gt;
   } catch (MalformedURLException e) {&lt;br /&gt;
     e.printStackTrace();&lt;br /&gt;
   } catch (IOException e) {&lt;br /&gt;
     e.printStackTrace();&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 private static String invokeSummarizationSvc(String input, URL url) throws IOException, ProtocolException {&lt;br /&gt;
   HttpURLConnection conn = (HttpURLConnection) url.openConnection();&lt;br /&gt;
   conn.setDoOutput(true);&lt;br /&gt;
   conn.setRequestMethod(&amp;quot;POST&amp;quot;);&lt;br /&gt;
   //content type must be set to Json, otherwise the server doesn't know how to parse the input&lt;br /&gt;
   conn.setRequestProperty(&amp;quot;Content-Type&amp;quot;, &amp;quot;application/json&amp;quot;);&lt;br /&gt;
   OutputStream os = conn.getOutputStream();&lt;br /&gt;
   os.write(input.getBytes());&lt;br /&gt;
&lt;br /&gt;
   if (conn.getResponseCode() != HttpURLConnection.HTTP_OK) {&lt;br /&gt;
     throw new RuntimeException(&amp;quot;Failed : HTTP error code : &amp;quot;&lt;br /&gt;
       + conn.getResponseCode());&lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
   BufferedReader br = new BufferedReader(new InputStreamReader((conn.getInputStream())));&lt;br /&gt;
&lt;br /&gt;
   String line = &amp;quot;&amp;quot;, lines = &amp;quot;&amp;quot;; &lt;br /&gt;
   while ((line = br.readLine()) != null){&lt;br /&gt;
     lines += line + &amp;quot;\n&amp;quot;;&lt;br /&gt;
   }&lt;br /&gt;
 &lt;br /&gt;
   conn.disconnect();&lt;br /&gt;
 &lt;br /&gt;
   return lines;&lt;br /&gt;
 }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
//class to serialize the text into Json&lt;br /&gt;
class Sentences {&lt;br /&gt;
 public String[] sentences;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142897</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142897"/>
		<updated>2022-02-15T02:36:34Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* IntelligentAssignment */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment https://expertiza.csc.ncsu.edu/index.php/Web-services:_Intelligent_Assignment].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142896</id>
		<title>PeerLogic Web Services: Intelligent Assignment</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142896"/>
		<updated>2022-02-15T02:35:57Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Accessing the service */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intelligent Team and Topic Assignment=&lt;br /&gt;
Intelligent assignment creates teams based off of each individual users ranking of topic preference, using k-means clustering. This webservice requires an input of each users ranks [1 being most preferred, and 0 indicating no preference] and unique id [pid], as well as the max team size. This also uses top trading cycles to switch members of teams who have already worked with other members on that team.&lt;br /&gt;
&lt;br /&gt;
==Accessing the service==&lt;br /&gt;
===Access the Webservice online===&lt;br /&gt;
This service is hosted at: http://peerlogic.csc.ncsu.edu/intelligent_assignment/[method name]. This service can be called without copying the code onto your local machine, simply make a post request to this url with one of the method names mentioned below.&lt;br /&gt;
&lt;br /&gt;
===Run it on your local machine===&lt;br /&gt;
The service can be copied from its github repository (https://github.com/peerlogic/IntelligentAssignment). It should be deployed as a webservice; though, it will also require the python libraries flask and scipy:&lt;br /&gt;
&lt;br /&gt;
-[Scipy](https://www.scipy.org/scipylib/download.html)&lt;br /&gt;
&lt;br /&gt;
-[Flask](https://pypi.python.org/pypi/Flask)&lt;br /&gt;
&lt;br /&gt;
==Methods==&lt;br /&gt;
===Creating teams (/merge_teams):===&lt;br /&gt;
Uses K-means clustering to group users with similar topic interests. Works to eliminate competition for any single topic and increase the likelihood that each user obtains their most preferred topic.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “pid”:9841}],&lt;br /&gt;
“max_team_size”:4}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1,0,2,3],”pid”: 1023},&lt;br /&gt;
{“ranks”: [1,2,0,3],”pid”: 4535},&lt;br /&gt;
{“ranks”: [0,2,3,1],”pid”: 1363},&lt;br /&gt;
{“ranks”: [2,1,0,3],”pid”: 9841}],&lt;br /&gt;
“teams”: [[1363,9841],[1023,4535]]}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Swapping Team Members (/swap_team_members):===&lt;br /&gt;
Uses Top Trading Cycles to swap members, that have already worked with members on their team, with other teams’ members. This method only swaps a max of one member per team per run. Begins by first sorting the list of available members by distance from the teams centroid and then by whether or not other members of the team have worked with them. This method requires a history of users that each user has worked with, along with the general information.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output:===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “history”:[4535,9841,9843], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “history”:[1023,9843,8542], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “history”:[3649,9841,9843], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “history”:[1363,1023,3649], “pid”:9841}],&lt;br /&gt;
“teams”: [[1023,2549],[4535,9843],[1363,1867,3649],[9841,8542,7521]]}&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1, 0, 2, 3], “pid”: 1023, “history”: [4535, 9841, 9843]},&lt;br /&gt;
{“ranks”: [1, 2, 0, 3], “pid”: 4535, “history”: [1023, 9843, 8542]},&lt;br /&gt;
{“ranks”: [0, 2, 3, 1], “pid”: 1363, “history”: [3649, 9841, 9843]},&lt;br /&gt;
{“ranks”: [2, 1, 0, 3], “pid”: 9841, “history”: [1363, 1023, 3649]}],&lt;br /&gt;
“teams”: [[9841, 4535], [1023, 1363]]}&lt;br /&gt;
&lt;br /&gt;
Client Code Example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python&lt;br /&gt;
import requests&lt;br /&gt;
import json&lt;br /&gt;
&lt;br /&gt;
#Test data&lt;br /&gt;
data = json.dumps(&lt;br /&gt;
           {&amp;quot;users&amp;quot;:[&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,0,2,3], &amp;quot;history&amp;quot;:[4535,9841,9843], &amp;quot;pid&amp;quot;:1023},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,2,0,3], &amp;quot;history&amp;quot;:[1023,9843,8542], &amp;quot;pid&amp;quot;:4535},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[0,2,3,1], &amp;quot;history&amp;quot;:[3649,9841,9843], &amp;quot;pid&amp;quot;:1363},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[2,1,0,3], &amp;quot;history&amp;quot;:[1363,1023,3649], &amp;quot;pid&amp;quot;:9841}],&lt;br /&gt;
            &amp;quot;max_team_size&amp;quot;:2}&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
header = {'content-type': 'application/json'}&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/merge_teams&amp;quot;,data= data,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&lt;br /&gt;
#The response from merge teams can be used in swap team members if&lt;br /&gt;
#history was given in the body of the request to merge teams&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/swap_team_members&amp;quot;, data=response.text,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142895</id>
		<title>PeerLogic Web Services: Intelligent Assignment</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Intelligent_Assignment&amp;diff=142895"/>
		<updated>2022-02-15T02:35:36Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=Intelligent Team and Topic Assignment= Intelligent assignment creates teams based off of each individual users ranking of topic preference, using k-means clustering. This web...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Intelligent Team and Topic Assignment=&lt;br /&gt;
Intelligent assignment creates teams based off of each individual users ranking of topic preference, using k-means clustering. This webservice requires an input of each users ranks [1 being most preferred, and 0 indicating no preference] and unique id [pid], as well as the max team size. This also uses top trading cycles to switch members of teams who have already worked with other members on that team.&lt;br /&gt;
&lt;br /&gt;
==Accessing the service==&lt;br /&gt;
===Access the Webservice online===&lt;br /&gt;
This service is hosted at: http://peerlogic.csc.ncsu.edu/intelligent_assignment/[method name]. This service can be called without copying the code onto your local machine, simply make a post request to this url with one of the method names mentioned below.&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
===Run it on your local machine===&lt;br /&gt;
The service can be copied from its github repository (https://github.com/peerlogic/IntelligentAssignment). It should be deployed as a webservice; though, it will also require the python libraries flask and scipy:&lt;br /&gt;
&lt;br /&gt;
-[Scipy](https://www.scipy.org/scipylib/download.html)&lt;br /&gt;
&lt;br /&gt;
-[Flask](https://pypi.python.org/pypi/Flask)&lt;br /&gt;
&lt;br /&gt;
==Methods==&lt;br /&gt;
===Creating teams (/merge_teams):===&lt;br /&gt;
Uses K-means clustering to group users with similar topic interests. Works to eliminate competition for any single topic and increase the likelihood that each user obtains their most preferred topic.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “pid”:9841}],&lt;br /&gt;
“max_team_size”:4}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1,0,2,3],”pid”: 1023},&lt;br /&gt;
{“ranks”: [1,2,0,3],”pid”: 4535},&lt;br /&gt;
{“ranks”: [0,2,3,1],”pid”: 1363},&lt;br /&gt;
{“ranks”: [2,1,0,3],”pid”: 9841}],&lt;br /&gt;
“teams”: [[1363,9841],[1023,4535]]}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Swapping Team Members (/swap_team_members):===&lt;br /&gt;
Uses Top Trading Cycles to swap members, that have already worked with members on their team, with other teams’ members. This method only swaps a max of one member per team per run. Begins by first sorting the list of available members by distance from the teams centroid and then by whether or not other members of the team have worked with them. This method requires a history of users that each user has worked with, along with the general information.&lt;br /&gt;
&lt;br /&gt;
===Sample input and output:===&lt;br /&gt;
&lt;br /&gt;
Input:&lt;br /&gt;
{“users”:[&lt;br /&gt;
{“ranks”:[1,0,2,3], “history”:[4535,9841,9843], “pid”:1023},&lt;br /&gt;
{“ranks”:[1,2,0,3], “history”:[1023,9843,8542], “pid”:4535},&lt;br /&gt;
{“ranks”:[0,2,3,1], “history”:[3649,9841,9843], “pid”:1363},&lt;br /&gt;
{“ranks”:[2,1,0,3], “history”:[1363,1023,3649], “pid”:9841}],&lt;br /&gt;
“teams”: [[1023,2549],[4535,9843],[1363,1867,3649],[9841,8542,7521]]}&lt;br /&gt;
&lt;br /&gt;
Output:&lt;br /&gt;
{“users”: [&lt;br /&gt;
{“ranks”: [1, 0, 2, 3], “pid”: 1023, “history”: [4535, 9841, 9843]},&lt;br /&gt;
{“ranks”: [1, 2, 0, 3], “pid”: 4535, “history”: [1023, 9843, 8542]},&lt;br /&gt;
{“ranks”: [0, 2, 3, 1], “pid”: 1363, “history”: [3649, 9841, 9843]},&lt;br /&gt;
{“ranks”: [2, 1, 0, 3], “pid”: 9841, “history”: [1363, 1023, 3649]}],&lt;br /&gt;
“teams”: [[9841, 4535], [1023, 1363]]}&lt;br /&gt;
&lt;br /&gt;
Client Code Example&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
python&lt;br /&gt;
import requests&lt;br /&gt;
import json&lt;br /&gt;
&lt;br /&gt;
#Test data&lt;br /&gt;
data = json.dumps(&lt;br /&gt;
           {&amp;quot;users&amp;quot;:[&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,0,2,3], &amp;quot;history&amp;quot;:[4535,9841,9843], &amp;quot;pid&amp;quot;:1023},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[1,2,0,3], &amp;quot;history&amp;quot;:[1023,9843,8542], &amp;quot;pid&amp;quot;:4535},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[0,2,3,1], &amp;quot;history&amp;quot;:[3649,9841,9843], &amp;quot;pid&amp;quot;:1363},&lt;br /&gt;
                {&amp;quot;ranks&amp;quot;:[2,1,0,3], &amp;quot;history&amp;quot;:[1363,1023,3649], &amp;quot;pid&amp;quot;:9841}],&lt;br /&gt;
            &amp;quot;max_team_size&amp;quot;:2}&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
header = {'content-type': 'application/json'}&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/merge_teams&amp;quot;,data= data,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&lt;br /&gt;
#The response from merge teams can be used in swap team members if&lt;br /&gt;
#history was given in the body of the request to merge teams&lt;br /&gt;
&lt;br /&gt;
response = requests.post(&amp;quot;http://127.0.0.1:5000/swap_team_members&amp;quot;, data=response.text,headers=header)&lt;br /&gt;
&lt;br /&gt;
print response.text&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142894</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142894"/>
		<updated>2022-02-15T02:28:16Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment]. &lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
Please see the extended documentation for this project here: [https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service https://expertiza.csc.ncsu.edu/index.php/Web-services:_Reputation_Web_Service].&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Reputation_Web_Service&amp;diff=142893</id>
		<title>PeerLogic Web Services: Reputation Web Service</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services:_Reputation_Web_Service&amp;diff=142893"/>
		<updated>2022-02-12T22:38:25Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;=Reputation Web Service=  ==How to get students' reputation== Alternative 1: Consume our hosted web service we have the service hosted at : http://peerlogic.csc.ncsu.edu/reput...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Reputation Web Service=&lt;br /&gt;
&lt;br /&gt;
==How to get students' reputation==&lt;br /&gt;
Alternative 1: Consume our hosted web service&lt;br /&gt;
we have the service hosted at : http://peerlogic.csc.ncsu.edu/reputation. you can use this service without building the code on your local machine&lt;br /&gt;
 &lt;br /&gt;
Alternative 2: Deploy it on your local machine&lt;br /&gt;
1.	Clone the code here : https://github.com/Winbobob/reputation_web_service.git&lt;br /&gt;
2.	You need to install ruby environment on you machine. Here is the instruction for different OS.&lt;br /&gt;
3.	Then you need to install rails Here is the instruction.&lt;br /&gt;
4.	You need to run bundle install to install all required gems.&lt;br /&gt;
5.	After that you need to run rake db:migrate to build the DB structure.&lt;br /&gt;
6.	Run rails s to start the server&lt;br /&gt;
&lt;br /&gt;
==How to communicate reputation web==&lt;br /&gt;
Alternative 1: call the hosted web service&lt;br /&gt;
TODO&lt;br /&gt;
Alternative 2: consume the service via Expertiza UI&lt;br /&gt;
This is only to get reputations of users registered in Expertiza. If you have teaching staff account of Expertiza, you can go to https://expertiza.ncsu.edu/reputation_web_service/client and follow the instructions below and get the results.&lt;br /&gt;
&lt;br /&gt;
==Web Service Structure==&lt;br /&gt;
The reputation web service consists of three main parts, that is client side, server side and the standard transmission format. Figure 1.1 shows the structure of the web service in general. Several client systems are communicating with reputation web service. Since each system has its unique DB schema, different data wrappers are needed to convert raw data into standard transmission format. And on the server side, another data wrapper is used to parse the request and generate adjacency matrices, which indicate what score each reviewer has given to each submission, and are the inputs to reputation algorithms. Finally, the reputation web service sends the results back to client systems.&lt;br /&gt;
&lt;br /&gt;
==Peer-Review Markup Language==&lt;br /&gt;
Peer-Review Markup Language (PRML) is a generic schema for encapsulating the raw data into standard data transmission format. In this way, different client systems can communicate with the reputation web service without changing their database schemas.&lt;br /&gt;
This language defines some entities commonly used in different peer-review systems. The entities used in the reputation web service are a subset of the data defined in PRML, including clients, assignments, tasks, reviewers, reviewed entities and peer-review grade. Table 1.1 explains each entity in detail.&lt;br /&gt;
&lt;br /&gt;
Answer The number of points each reviewer gives to each artifact. Each peer-review record contains identifier of artifact, identifier of reviewer and peer-review grade.&lt;br /&gt;
PRML is a JSON-based format with compact structure, which has three parts. The first part is the information related to assignment(s) and task(s). Figure 1.2 shows the first part, assignment information, with sample data. It allows data coming from multiple assignments and appointing one task for each assignment. According to the sample data, two assignments’ second-round peer-review records will be sent to reputation web service. And maximum and minimum grades of each assignment are also mentioned to help calculate the reputation values.&lt;br /&gt;
&lt;br /&gt;
The second part of standard JSON format is the additional information. They can be initial Hamer reputation values, initial Lauw reputation values, expert grades or quiz scores. Data presented in Figure 1.3 is used for different reputation algorithms. For instance, expert grades are extra inputs of Hamer-expert algorithm and Lauw-expert algorithm; quiz scores are additional inputs of Quiz-based algorithm. Details of each algorithm will be stated in next chapter.&lt;br /&gt;
&lt;br /&gt;
The last part is the review records. It is the most important part because each line records how many points each peer reviewer giving to certain artifact. Figure 1.4 presents the sample peer-review records.&lt;br /&gt;
&lt;br /&gt;
==Server Side Design==&lt;br /&gt;
The server side uses Ruby on Rails framework and follows the MVC design pattern strictly. Each algorithm was implemented in a model file. And the controller focuses on parsing JSON request to adjacency matrices, building data structure, calling different algorithms and sending results back to client system. In reputation web service there is no need to create views because all messages will be transmitted via JSON format. In Figure 1.1, there is only one data wrapper needed for server side. It is a big advantage of reputation web service, that is using standard JSON transmission format can not only unify the interface, but also satisfy the needs of different client systems.&lt;br /&gt;
&lt;br /&gt;
==Client Side Design in Expertiza==&lt;br /&gt;
Figure 1.1 also presents that each peer-review system needs one specific data wrapper. It is because database structure of each system is different. However, the data wrapper is the only thing each client system need to build. So comparing with understanding the logic of reputation algorithms and implementing them, just building a data wrapper can save lots of time and effort. Currently, one data wrapper has already been built and been embedded into Expertiza with a user interface.&lt;br /&gt;
&lt;br /&gt;
The basic user interface of the client side is presented in Figure 1.5. The instructor follows four simple steps to send the standard JSON request. The first step is to type in identifier(s) of assignment(s). These text fields only accept numerical values in order to avoid mistyping. The second assignment identifier text field is optional, which is designed for writing assignments (writing assignment 1a and 1b). Normally, in CSC 517 course, there are two writing assignments. Since they are similar to each other, I tend to merge these two assignments into one sometimes. The last text field is used to specify round number of assignment. The default round number is 2, which means to use the second-round peer-review records as inputs. This bases the reviewer’s reputation on that reviewer’s second-round reviews only.&lt;br /&gt;
&lt;br /&gt;
The second step is to choose different kinds of reputation algorithms. They are Hamer’s algorithm, Lauw’s algorithm, Hamer-expert algorithm, Lauw-expert algorithm and Quiz-based algorithm. Thirdly, instructor needs to choose some additional information. It can be expert grades, initial reputation values or quiz scores. For initial reputation values, instructor can choose either from Hamer-expert algorithm or Lauw-expert algorithm. And the final step is to click the “Send request” button.&lt;br /&gt;
&lt;br /&gt;
The results of writing assignments using Hamer-expert algorithm with expert grades are shown in Figure 1.7. The checkbox before “Add expert grades” is gray, which means it is disabled, cannot be unchecked. The reason is that when instructor chose the Hamer-expert algorithm, the data wrapper needed to add expert grades into request information by default. If instructor unchecks the “Add expert grades” for some reason, it will lead to a conflict. So in order to avoid it, some constraints have been added to this user interface. When the instructor chooses Hamer-expert algorithm or Lauw-expert algorithm, the “Add expert grades” checkbox will be checked and disabled; when instructor chooses the Quiz-based algorithm, the “Add quiz scores” will be checked and disabled and so on.&lt;br /&gt;
&lt;br /&gt;
==Security of Web Service==&lt;br /&gt;
Security is also an important issue, since expert grades and peer-review grades are sensitive data and should not be revealed to unauthorized people. However, according to the design, the reputation web service sends the data in plaintext. In order to protect these sensitive data, encryption algorithms are needed.&lt;br /&gt;
The first solution is to use public-key cryptography. It is an asymmetric key encryption algorithm and cryptographic keys are paired. One is public key, which is disseminated widely and anyone with public key can encrypt messages. The other one is the private key, which can only be used by the keyholder to decrypt private messages [10]. By implementing this solution, client sides can use public key to encrypt the JSON data and server side can use corresponding private key to decrypt the encrypted data. However, there is a maximum message length restriction for public-key cryptography. Since it is possible that request data exceeds the maximum length restriction, another method is needed to apply to all situations.&lt;br /&gt;
&lt;br /&gt;
The second solution is the combination asymmetric key encryption algorithm and symmetric key encryption algorithm, which does not have restriction mentioned above. Procedure of sending encrypted request is presented in Figure 1.9. The client side uses a newly generated symmetric key to encrypt the JSON data and then encrypts the symmetric key with the public key from the asymmetric key encryption algorithm. After that, it sends the encrypted request to the server side. Then the server side decrypts the symmetric key with the private key. Secondly, it obtains the JSON data by using the symmetric key. And sending the response back to client side is the reverse process. In practice, AES is chosen the as symmetric encryption algorithm, and RSA is chosen as the asymmetric encryption algorithm.&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
In summary, the “pluggable” reputation web service can make peer review systems access to multiple reputation algorithms and compare with each other. So there is no need to implement reputation algorithms locally. But each client system needs a specific data wrapper. The data wrapper can convert client system’s database schema into a standard JSON transmission format, which is the subset of PRML. After reputation web service receives the JSON request, it will do calculation and send the JSON response back to client system. What’s more, the reputation web service also uses cryptography to protect the sensitive data.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142892</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142892"/>
		<updated>2022-02-12T22:14:50Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==Server Setup==&lt;br /&gt;
The Peerlogic webservices setup can be accessed [https://docs.google.com/document/d/1270jOLqVHV9iojAf9jwd2WJlOr9PNCZChDz1-sEzkhM/edit?usp=sharing here]. This material is not publicly posted for the purposes of protecting the server's integrity.&lt;br /&gt;
&lt;br /&gt;
An additional document for how to set up the NLP webservice in particular can be found [https://docs.google.com/document/d/1QAMVLu6whaJ8fSkwxY_Z-Hq7lHwXj40X-_xWd6F-FOM/edit?usp=sharing here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/PeerAssessmentWeb].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment]. &lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142891</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142891"/>
		<updated>2022-02-08T05:02:29Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Summary=&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment]. &lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142890</id>
		<title>PeerLogic Web Services</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=PeerLogic_Web_Services&amp;diff=142890"/>
		<updated>2022-02-08T05:02:12Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: Created page with &amp;quot;==Summary== The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on ex...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Summary==&lt;br /&gt;
The expertiza web services are a group of scripts and programs utilized by the expertiza website for performing various functions. These functions are hosted on external web services for the purposes of better performance, flexibility, and modularity.&lt;br /&gt;
&lt;br /&gt;
This page is documenting all of these services, including where they are located, the code they utilize, and theoretical explanations of what they are performing.&lt;br /&gt;
&lt;br /&gt;
The collection of the code for all of these web services can be found [https://github.com/peerlogic here].&lt;br /&gt;
&lt;br /&gt;
==PeerAssessmentWeb==&lt;br /&gt;
PeerAssessmentWeb is a Ruby application. It's not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/PeerAssessmentWeb https://github.com/peerlogic/IntelligentAssignment].&lt;br /&gt;
&lt;br /&gt;
==IntelligentAssignment==&lt;br /&gt;
IntelligentAssignment is a Python application which has the stated purpose of forming project groups by performing k-means clustering on their topics of interest.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in March of 2018.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/IntelligentAssignment https://github.com/peerlogic/IntelligentAssignment]. &lt;br /&gt;
&lt;br /&gt;
==AutoSummaryV1==&lt;br /&gt;
AutoSummaryV1 is a Javascript application. It is not currently known what the purpose of this web service is.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in February of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here: [https://github.com/peerlogic/AutoSummaryV1 https://github.com/peerlogic/AutoSummaryV1].&lt;br /&gt;
&lt;br /&gt;
==reputation_web_service==&lt;br /&gt;
reputation_web_service is a Javascript application with extensive documentation, detailing the web service's use for determining user reputation.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/reputation_web_service https://github.com/peerlogic/reputation_web_service].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Data-Warehouse-Object-Relational-Mapping==&lt;br /&gt;
This is a Ruby application. It is not currently known what the specific purpose of this web service is, though presumably it assists in the accessing of data warehouse relational objects and tables.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2017.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping https://github.com/peerlogic/Data-Warehouse-Object-Relational-Mapping].&lt;br /&gt;
&lt;br /&gt;
==autometareviews0.1==&lt;br /&gt;
This project is a Ruby application for the purpose of natural language processing, including sentiment analysis, volume, tone, etc.&lt;br /&gt;
&lt;br /&gt;
This project was last updated in April of 2016.&lt;br /&gt;
&lt;br /&gt;
The code for this project can be accessed here [https://github.com/peerlogic/autometareviews0.1 https://github.com/peerlogic/autometareviews0.1].&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142889</id>
		<title>Peer-reviews-NLP: Set-Up</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142889"/>
		<updated>2022-02-01T00:59:45Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: /* Alternative 1: Installation on Deployed Ubuntu */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Overview==&lt;br /&gt;
The purpose of this page is to describe the steps necessary to set up and run the peer-reviews-NLP web service, as well as what is actually happening during those steps (should they need to change). This page will assume a reader who is familiar with Python programming, but not with any particular technical tool used for application or web service hosting (such as Docker, etc.)&lt;br /&gt;
&lt;br /&gt;
To read more about the peer-review-NLP project, [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP see the main page on the project here.]&lt;br /&gt;
&lt;br /&gt;
Two separate scenarios will be explained&lt;br /&gt;
&lt;br /&gt;
=Step-by-Step Installation=&lt;br /&gt;
&lt;br /&gt;
Two alternatives will be outlined for installation of the peer-review-NLP web service. The first will assume you are installing the web service onto a deployed Ubuntu environment, for the purposes of deploying the project for use on the Expertiza website. The second will assume you wish to run the webservice on your local machine for the sake of testing and development.&lt;br /&gt;
&lt;br /&gt;
==Alternative 1: Installation on Deployed Ubuntu==&lt;br /&gt;
* Clone the public Github for the project to the machine you are deploying to. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker and Docker Compose onto the machine by running the following code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -&lt;br /&gt;
sudo add-apt-repository &amp;quot;deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable&amp;quot;&lt;br /&gt;
sudo apt-get update&lt;br /&gt;
apt-cache policy docker-ce&lt;br /&gt;
sudo apt-get install -y docker-ce&lt;br /&gt;
sudo systemctl status docker&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note: if the given code did not successfully install Docker, refer to the following [https://docs.docker.com/engine/install/ubuntu/ official documentation for proper download instructions].&lt;br /&gt;
* Check to make sure docker has been properly installed by using the command &amp;lt;pre&amp;gt;docker-compose --version&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Alternative 2: Installation on Deployed CentOS (RedHat)==&lt;br /&gt;
First, install yum and git.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo yum install -y yum-utils&lt;br /&gt;
sudo yum install git&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Next, clone the git repo&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
git clone https://github.com/Aeront39/Peer-reviews-NLP&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Then, navigate to within the downloaded directory, and perform the following commands:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo&lt;br /&gt;
sudo yum install docker-ce docker-ce-cli containerd.io --allowerasing&lt;br /&gt;
sudo dnf --disablerepo '*' --enablerepo=extras swap centos-linux-repos centos-stream-repos&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
sudo ln -s /usr/local/bin/docker-compose /usr/bin/docker-compose&lt;br /&gt;
sudo systemctl start docker&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Finally, run the following command to begin the webservice:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo docker-compose up&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Alternative 3: Installation on Local Machine==&lt;br /&gt;
* Clone the public Github for the project to your local machine. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker to your local machine. Please refer to the [https://docs.docker.com/get-docker/ official Docker documentation for installation instructions for your specific OS.]&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Testing Set-Up=&lt;br /&gt;
To ensure the installation was successful and that the web service is functioning properly, this section will outline how to send some basic test input to the web service.&lt;br /&gt;
&lt;br /&gt;
Those familiar with a particular API tool should feel free to use whatever they prefer. However, these instructions assume no familiarity with such tools, and so will recommend the download and use of Insomnia, a tool which allows API requests to be made to both localhosts and deployed addresses.&lt;br /&gt;
&lt;br /&gt;
The initial steps for both alternatives are the same, and so will be said here before splitting into specifics:&lt;br /&gt;
* Download [https://insomnia.rest/product/automated-testing Insomnia].&lt;br /&gt;
* Open Insomnia and click the button in the top-right labelled &amp;quot;Create&amp;quot;. From the dropdown, choose to create a new &amp;quot;Request Collection.&amp;quot; Name it whatever you prefer.&lt;br /&gt;
* Click the &amp;quot;+&amp;quot; symbol near the top-left and choose to make a new request. Name it as you prefer.&lt;br /&gt;
* Once the request is created, change its type to a &amp;quot;POST&amp;quot; request in the bar near the top, and just beneath, click the word &amp;quot;Body&amp;quot; and select &amp;quot;JSON&amp;quot; from the dropdown.&lt;br /&gt;
&lt;br /&gt;
You may now post into the text area whatever JSON payload you may wish to send to the web service. In order to do so, however, you must send the POST request to the proper address, which must be put in at the top (next to POST).&lt;br /&gt;
&lt;br /&gt;
If you are testing locally, this address will start with &amp;quot;127.0.0.1&amp;quot;, followed by the particular call you would like to make (for example, &amp;quot;127.0.0.1/volume&amp;quot;). If you are testing in the deployed environment, you should send your request to the address or url of the deployed machine.&lt;br /&gt;
&lt;br /&gt;
For more information on what API calls you can make and what payloads to expect to send and receive, including testing examples, see [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP:_Web_Service_API this page on web service API].&lt;br /&gt;
&lt;br /&gt;
=Technical Explanation of Set Up=&lt;br /&gt;
The following is a documentation of the specific steps that occur when the web service is set up. More specifically, this section will explain what the Dockerfile and subsequent scripts do to set up the server when the docker-compose command is called. These steps are documented in the case that they need future repair or refactoring.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142888</id>
		<title>Peer-reviews-NLP: Set-Up</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142888"/>
		<updated>2022-02-01T00:07:49Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Overview==&lt;br /&gt;
The purpose of this page is to describe the steps necessary to set up and run the peer-reviews-NLP web service, as well as what is actually happening during those steps (should they need to change). This page will assume a reader who is familiar with Python programming, but not with any particular technical tool used for application or web service hosting (such as Docker, etc.)&lt;br /&gt;
&lt;br /&gt;
To read more about the peer-review-NLP project, [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP see the main page on the project here.]&lt;br /&gt;
&lt;br /&gt;
Two separate scenarios will be explained&lt;br /&gt;
&lt;br /&gt;
=Step-by-Step Installation=&lt;br /&gt;
&lt;br /&gt;
Two alternatives will be outlined for installation of the peer-review-NLP web service. The first will assume you are installing the web service onto a deployed Ubuntu environment, for the purposes of deploying the project for use on the Expertiza website. The second will assume you wish to run the webservice on your local machine for the sake of testing and development.&lt;br /&gt;
&lt;br /&gt;
==Alternative 1: Installation on Deployed Ubuntu==&lt;br /&gt;
* Clone the public Github for the project to the machine you are deploying to. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker and Docker Compose onto the machine by running the following code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -&lt;br /&gt;
sudo add-apt-repository &amp;quot;deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable&amp;quot;&lt;br /&gt;
sudo apt-get update&lt;br /&gt;
apt-cache policy docker-ce&lt;br /&gt;
sudo apt-get install -y docker-ce&lt;br /&gt;
sudo systemctl status docker&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note: if the given code did not successfully install Docker, refer to the following [https://docs.docker.com/engine/install/ubuntu/ official documentation for proper download instructions].&lt;br /&gt;
* Check to make sure docker has been properly installed by using the command &amp;lt;pre&amp;gt;docker-compose --version&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Alternative 2: Installation on Deployed CentOS (RedHat)&lt;br /&gt;
* Clone the public Github for the project&lt;br /&gt;
* Install docker and docker-compose using the following command line code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo yum install -y yum-utils&lt;br /&gt;
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo&lt;br /&gt;
sudo yum install docker-ce docker-ce-cli containerd.io --allowerasing&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
==Alternative 3: Installation on Local Machine==&lt;br /&gt;
* Clone the public Github for the project to your local machine. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker to your local machine. Please refer to the [https://docs.docker.com/get-docker/ official Docker documentation for installation instructions for your specific OS.]&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Testing Set-Up=&lt;br /&gt;
To ensure the installation was successful and that the web service is functioning properly, this section will outline how to send some basic test input to the web service.&lt;br /&gt;
&lt;br /&gt;
Those familiar with a particular API tool should feel free to use whatever they prefer. However, these instructions assume no familiarity with such tools, and so will recommend the download and use of Insomnia, a tool which allows API requests to be made to both localhosts and deployed addresses.&lt;br /&gt;
&lt;br /&gt;
The initial steps for both alternatives are the same, and so will be said here before splitting into specifics:&lt;br /&gt;
* Download [https://insomnia.rest/product/automated-testing Insomnia].&lt;br /&gt;
* Open Insomnia and click the button in the top-right labelled &amp;quot;Create&amp;quot;. From the dropdown, choose to create a new &amp;quot;Request Collection.&amp;quot; Name it whatever you prefer.&lt;br /&gt;
* Click the &amp;quot;+&amp;quot; symbol near the top-left and choose to make a new request. Name it as you prefer.&lt;br /&gt;
* Once the request is created, change its type to a &amp;quot;POST&amp;quot; request in the bar near the top, and just beneath, click the word &amp;quot;Body&amp;quot; and select &amp;quot;JSON&amp;quot; from the dropdown.&lt;br /&gt;
&lt;br /&gt;
You may now post into the text area whatever JSON payload you may wish to send to the web service. In order to do so, however, you must send the POST request to the proper address, which must be put in at the top (next to POST).&lt;br /&gt;
&lt;br /&gt;
If you are testing locally, this address will start with &amp;quot;127.0.0.1&amp;quot;, followed by the particular call you would like to make (for example, &amp;quot;127.0.0.1/volume&amp;quot;). If you are testing in the deployed environment, you should send your request to the address or url of the deployed machine.&lt;br /&gt;
&lt;br /&gt;
For more information on what API calls you can make and what payloads to expect to send and receive, including testing examples, see [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP:_Web_Service_API this page on web service API].&lt;br /&gt;
&lt;br /&gt;
=Technical Explanation of Set Up=&lt;br /&gt;
The following is a documentation of the specific steps that occur when the web service is set up. More specifically, this section will explain what the Dockerfile and subsequent scripts do to set up the server when the docker-compose command is called. These steps are documented in the case that they need future repair or refactoring.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142887</id>
		<title>Peer-reviews-NLP: Set-Up</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Peer-reviews-NLP:_Set-Up&amp;diff=142887"/>
		<updated>2022-01-31T03:59:38Z</updated>

		<summary type="html">&lt;p&gt;Ggarrid: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Overview==&lt;br /&gt;
The purpose of this page is to describe the steps necessary to set up and run the peer-reviews-NLP web service, as well as what is actually happening during those steps (should they need to change). This page will assume a reader who is familiar with Python programming, but not with any particular technical tool used for application or web service hosting (such as Docker, etc.)&lt;br /&gt;
&lt;br /&gt;
To read more about the peer-review-NLP project, [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP see the main page on the project here.]&lt;br /&gt;
&lt;br /&gt;
Two separate scenarios will be explained&lt;br /&gt;
&lt;br /&gt;
=Step-by-Step Installation=&lt;br /&gt;
&lt;br /&gt;
Two alternatives will be outlined for installation of the peer-review-NLP web service. The first will assume you are installing the web service onto a deployed Ubuntu environment, for the purposes of deploying the project for use on the Expertiza website. The second will assume you wish to run the webservice on your local machine for the sake of testing and development.&lt;br /&gt;
&lt;br /&gt;
==Alternative 1: Installation on Deployed Ubuntu==&lt;br /&gt;
* Clone the public Github for the project to the machine you are deploying to. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker and Docker Compose onto the machine by running the following code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -&lt;br /&gt;
sudo add-apt-repository &amp;quot;deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable&amp;quot;&lt;br /&gt;
sudo apt-get update&lt;br /&gt;
apt-cache policy docker-ce&lt;br /&gt;
sudo apt-get install -y docker-ce&lt;br /&gt;
sudo systemctl status docker&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
Note: if the given code did not successfully install Docker, refer to the following [https://docs.docker.com/engine/install/ubuntu/ official documentation for proper download instructions].&lt;br /&gt;
* Check to make sure docker has been properly installed by using the command &amp;lt;pre&amp;gt;docker-compose --version&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
==Alternative 2: Installation on Deployed CentOS (RedHat)&lt;br /&gt;
* Clone the public Github for the project&lt;br /&gt;
* Install docker and docker-compose using the following command line code:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
sudo yum install -y yum-utils&lt;br /&gt;
sudo yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo&lt;br /&gt;
sudo yum install docker-ce docker-ce-cli containerd.io --allowerasing&lt;br /&gt;
sudo curl -L https://github.com/docker/compose/releases/download/1.26.0/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose&lt;br /&gt;
sudo chmod +x /usr/local/bin/docker-compose&lt;br /&gt;
&lt;br /&gt;
==Alternative 3: Installation on Local Machine==&lt;br /&gt;
* Clone the public Github for the project to your local machine. A link to the Github can be found [https://github.com/koushik1/Peer-reviews-NLP here].&lt;br /&gt;
* Install Docker to your local machine. Please refer to the [https://docs.docker.com/get-docker/ official Docker documentation for installation instructions for your specific OS.]&lt;br /&gt;
* Navigate to the directory &amp;quot;~/Peer-reviews-NLP&amp;quot; and run &amp;quot;sudo docker-compose up&amp;quot; to start the web service&lt;br /&gt;
* If the web service goes down and needs to be rebuilt, utilize the command &amp;quot;sudo docker-compose up --build&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Testing Set-Up=&lt;br /&gt;
To ensure the installation was successful and that the web service is functioning properly, this section will outline how to send some basic test input to the web service.&lt;br /&gt;
&lt;br /&gt;
Those familiar with a particular API tool should feel free to use whatever they prefer. However, these instructions assume no familiarity with such tools, and so will recommend the download and use of Insomnia, a tool which allows API requests to be made to both localhosts and deployed addresses.&lt;br /&gt;
&lt;br /&gt;
The initial steps for both alternatives are the same, and so will be said here before splitting into specifics:&lt;br /&gt;
* Download [https://insomnia.rest/product/automated-testing Insomnia].&lt;br /&gt;
* Open Insomnia and click the button in the top-right labelled &amp;quot;Create&amp;quot;. From the dropdown, choose to create a new &amp;quot;Request Collection.&amp;quot; Name it whatever you prefer.&lt;br /&gt;
* Click the &amp;quot;+&amp;quot; symbol near the top-left and choose to make a new request. Name it as you prefer.&lt;br /&gt;
* Once the request is created, change its type to a &amp;quot;POST&amp;quot; request in the bar near the top, and just beneath, click the word &amp;quot;Body&amp;quot; and select &amp;quot;JSON&amp;quot; from the dropdown.&lt;br /&gt;
&lt;br /&gt;
You may now post into the text area whatever JSON payload you may wish to send to the web service. In order to do so, however, you must send the POST request to the proper address, which must be put in at the top (next to POST).&lt;br /&gt;
&lt;br /&gt;
If you are testing locally, this address will start with &amp;quot;127.0.0.1&amp;quot;, followed by the particular call you would like to make (for example, &amp;quot;127.0.0.1/volume&amp;quot;). If you are testing in the deployed environment, you should send your request to the address or url of the deployed machine.&lt;br /&gt;
&lt;br /&gt;
For more information on what API calls you can make and what payloads to expect to send and receive, including testing examples, see [https://expertiza.csc.ncsu.edu/index.php/Peer-reviews-NLP:_Web_Service_API this page on web service API].&lt;br /&gt;
&lt;br /&gt;
=Technical Explanation of Set Up=&lt;br /&gt;
The following is a documentation of the specific steps that occur when the web service is set up. More specifically, this section will explain what the Dockerfile and subsequent scripts do to set up the server when the docker-compose command is called. These steps are documented in the case that they need future repair or refactoring.&lt;/div&gt;</summary>
		<author><name>Ggarrid</name></author>
	</entry>
</feed>