Investment Insights for Asset Managers is a Node.js application that uses IBM Financial services and Watson services.
The application is a modern portfolio manager that provides real-time insights into how news all around the world can impact any given investment portfolio.
The project deploys a node.js Cloud Foundry application and uses the following services:
- Investment Portfolio
- Discovery and the pre-enriched News dataset
- Predictive Market Scenarios
- Simulated Instrument Analytics
The application uses the financial services to analyze a stock portfolio in regards to various risk factors. Risk factors include things like currency fluctuations or changes in the price of oil and gold.
- User selects a risk factor to consider.
- Using Watson Discovery, the app looks for articles related to the risk factor.
- The app computes a shock value based on the sentiment of the articles.
- The app calls the Predictive Market Scenarios service to create conditional scenarios to model how, given a change to a subset of factors the broader set of market factors are expected to change.
- Finally it computes analytics on the portfolio stocks under the given scenarios.
The app comes with a toolchain you can use to deploy the solution with few clicks. If you want to deploy it manually, you can skip this section.
-
Ensure your organization has enough quota for one web application using 256MB of memory and 4 services.
-
Click Deploy to Bluemix to start the Bluemix DevOps wizard:
-
Select the GitHub box.
-
Decide whether you want to fork/clone the app repository.
-
If you decide to Clone, set a name for your GitHub repository.
-
Select the Delivery Pipeline box.
-
Select the region, organization and space where you want to deploy the app.
-
Click Create.
-
Select the Delivery Pipeline.
-
Wait for the Deploy job to complete.
-
Access the app when it's ready and start exploring.
-
If you do not already have a Bluemix account, sign up here
-
Download and install the Cloud Foundry CLI tool
-
Use this command to display or specify the URL of the API endpoint of Bluemix.
cf api https://api.ng.bluemix.net
-
Connect to Bluemix in the command line tool and follow the prompts to log in
cf login -a https://api.ng.bluemix.net
-
Clone the app to your local environment from your terminal using the following command:
git clone https://github.com/IBM-Bluemix/investment-insights-for-asset-managers.git
-
cd
into this newly created directory -
Navigate to manifest.yml file and change the NAME "investment-insights-for-sset-managers" to an unique name of your choice. The new name is your APP_NAME in the commands below.
-
Follow the above step for SERVICES as well.
-
Create services required for this app
cf create-service discovery lite <Discovery_Service_Name>
Discovery Service Name as mentioned in manifest.yml above
cf create-service fss-portfolio-service fss-portfolio-service-free-plan <Portfolio_Service_Name as in manifest.yml>
cf create-service fss-predictive-scenario-analytics-service fss-predictive-scenario-analytics-service-free-plan <Predictive_Scenario_Name as in manifest.yml>
cf create-service fss-scenario-analytics-service fss-scenario-analytics-service-free-plan <Scenario_Analytics_Name as in manifest.yml>
-
Push the app to Bluemix
cf push
This command uses the manifest.yml file in your directory to CREATE the app and BIND the services to the app
And voila! You now have your very own application running on Bluemix.
-
If you do not already have a Bluemix account, sign up here
-
If you have not already, download Node.js and install it on your local machine.
-
In the checkout directory, create a file
.env
and paste the below snippetINVESTMENT_PORFOLIO_BASE_URL=investment-portfolio.mybluemix.net INVESTMENT_PORFOLIO_USERNAME= INVESTMENT_PORFOLIO_PASSWORD= DISCOVERY_USERNAME= DISCOVERY_PASSWORD= PREDICTIVE_MARKET_SCENARIOS_URI=fss-analytics.mybluemix.net PREDICTIVE_MARKET_SCENARIOS_ACCESS_TOKEN= SIMULATED_INSTRUMENT_ANALYSIS_URI=fss-analytics.mybluemix.net SIMULATED_INSTRUMENT_ANALYSIS_ACCESS_TOKEN=
-
For credentials and access tokens, run this command
cf env APP_NAME
-
Run
npm install
-
Run
npm start
If you find a bug, please report it via the [Issues section][issues_url] or even better, fork the project and submit a pull request with your fix! We are more than happy to accept external contributions to this project if they address something noted in an existing issue. In order to be considered, pull requests must pass the initial Travis CI build and/or add substantial value to the sample application.
The primary source of debugging information for your Bluemix app is the logs. To see them, run the following command using the Cloud Foundry CLI:
$ cf logs APP_NAME --recent
For more detailed information on troubleshooting your application, see the Troubleshooting section in the Bluemix documentation.
See License.txt for license information.
This application is configured to track deployments to IBM Bluemix and other Cloud Foundry platforms. The following information is sent to a Deployment Tracker service on each deployment:
- Node.js package version
- Node.js repository URL
- Application Name (
application_name
) - Space ID (
space_id
) - Application Version (
application_version
) - Application URIs (
application_uris
) - Labels of bound services
- Number of instances for each bound service and associated plan information
This data is collected from the package.json
file in the application and the VCAP_APPLICATION
and VCAP_SERVICES
environment variables in IBM Bluemix and other Cloud Foundry platforms. This data is used by IBM to track metrics around deployments of sample applications to IBM Bluemix to measure the usefulness of our examples, so that we can continuously improve the content we offer to you. Only deployments of sample applications that include code to ping the Deployment Tracker service will be tracked.
Deployment tracking can be disabled by removing require("cf-deployment-tracker-client").track();
from the beginning of the app.js
file.