Git Product home page Git Product logo

aggie2's Introduction

Installation

  1. Install node.js on the system. Check out http://nodejs.org/download/ to download an installer/source

  2. Install MongoDB which serves as the primary database for the system. http://www.mongodb.org/downloads

  3. Download the Aggie-2.0 project source from Github => https://github.com/alexstelea/Aggie2.0

  4. Create a data directory for MongoDB with the structure /data/db/

  5. Start MongoDB server instance by running $ mongod --dbpath=”path-to/data/db/”

  6. Go to the project folder (the one that contains app.js & package.json) and run npm install

  7. Run node app.js

  8. Open a browser and go to http://localhost:9000 to check if the login screen comes up.

  9. Use the admin credentials {admin:adminadmin} to login.

  10. New Tweet Bots can be started by typing in search terms in the input box on the top right corner and the result can be observed in the live feed.

Understanding the Code

This section provides an overview of the implementation of Aggie-2.0 platform. The primary technologies used in the implementation are

  1. Node.js - which provides the basic framework for all the search bots (Twitter, RSS and Facebook) and for the web front end.

  2. Express - the web framework we used to provide a REST API for Aggie-2.0

  3. MongoDB/Mongoose - provided the database to store feed from various data sources.

  4. Twit - javascript wrappers over Twitter API

  5. Feedparser - node.js module to parse RSS feeds

  6. Bootstrap 3.0 - the UI framework used on the front end

  7. jQuery - UI library used on the web front end which provides functionality for dynamic HTML insertion and making AJAX calls to the server.

We have also used a number of Node.js modules/libraries to assist us in various book-keeping operations like login/session management and password encryption.

Code Structure

./app.js : This is the primary script that begins the Aggie-2.0 web service by connecting it to the MongoDB database (URL specified in ./config/config.js) and exposing a set of routes that can be queried by a HTTP client.

./package.json : This file contains all the dependencies of Aggie-2.0.

./controllers/aggie.js : Contains all the core functionality of Aggie. Most of this functionality is exposed as REST API in ./app.js ./controllers/chart-controller.js : Contains functionality to extract analytics data from the database ./controllers/bots/twitterbot/twitter-bot-controller.js : Contains methods to start and stop keyword searches on Twitter ./controllers/bots/rss/rss-controller.js : Wrapper over the node library - Feedparser to crawl RSS feed for specific search terms

./models/data.js : Data model for data feeds ./models/user.js : Data model for users - contains built in methods for password encryption

./views/ : This folder contains all the static content like HTML markup, CSS stylesheets and client side JavaScript.

./config/config.js : Contains all the configuration settings for the application such as Database URL and server port number. ./config/express.js : Bootstrapping code for the Express server.

aggie2's People

Contributors

natrajkaushik avatar sesgoe avatar alexstelea avatar siddharthc avatar jhale9 avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.