Skip to content

Commit

Permalink
Data Mines related modules moved to Data-Mining Project
Browse files Browse the repository at this point in the history
  • Loading branch information
Luis-Fernando-Molina committed Sep 25, 2021
1 parent 7df98bd commit cb010fb
Show file tree
Hide file tree
Showing 23 changed files with 197 additions and 143 deletions.
4 changes: 2 additions & 2 deletions Environment.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ exports.newEnvironment = function () {
WEB_SERVER_URL: 'localhost',
CLIENT_WEB_SOCKETS_INTERFACE_PORT: 18041,
CLIENT_HTTP_INTERFACE_PORT: 34248,
PATH_TO_DATA_STORAGE: './Data-Storage',
PATH_TO_DATA_STORAGE: './Platform/Data-Storage',
PATH_TO_LOG_FILES: './Platform/Log-Files',
PATH_TO_PROJECTS: './Projects',
PATH_TO_LOG_FILES: './Log-Files',
PATH_TO_PROJECTS_REQUIRED: './Projects',
PATH_TO_PROJECT_SCHEMA: './Projects/ProjectsSchema.json',
PATH_TO_CLIENT: './Platform',
Expand Down
4 changes: 2 additions & 2 deletions EnvironmentForDebug.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ exports.newEnvironment = function () {
DESKTOP_WEB_SOCKETS_INTERFACE_HOST: 'localhost',
CLIENT_HTTP_INTERFACE_PORT: 34248,
DESKTOP_HTTP_INTERFACE_PORT: 34249,
PATH_TO_DATA_STORAGE: './Data-Storage',
PATH_TO_DATA_STORAGE: './Platform/Data-Storage',
PATH_TO_LOG_FILES: './Platform/Log-Files',
PATH_TO_PROJECTS: './Projects',
PATH_TO_LOG_FILES: './Log-Files',
PATH_TO_PROJECTS_REQUIRED: './Projects',
PATH_TO_PROJECT_SCHEMA: './Projects/ProjectsSchema.json',
PATH_TO_CLIENT: './Platform',
Expand Down
Binary file added Projects/Data-Mining/Icons/data-mining.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
42 changes: 42 additions & 0 deletions Projects/Data-Mining/Schemas/App-Schema/data-mining-project.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"type": "Data-Mining Project",
"menuItems": [
{
"action": "Add Missing Children",
"label": "Add Missing Children",
"relatedUiObject": "Foundations Project",
"actionFunction": "payload.executeAction"
},
{
"action": "Delete UI Object",
"askConfirmation": true,
"confirmationLabel": "Confirm to Delete",
"actionFunction": "payload.executeAction",
"label": "Delete",
"iconPathOn": "delete-entity",
"iconPathOff": "delete-entity"
}
],
"isProjectHead": true,
"isTitleAllwaysVisible": false,
"addLeftIcons": true,
"isPinned": true,
"positionLocked": true,
"icon": "data-mining",
"childrenNodesProperties": [
{
"name": "projectDefinition",
"type": "node",
"childType": "Project Definition",
"project": "Foundations",
"autoAdd": true
},
{
"name": "mines",
"type": "node",
"childType": "Mines",
"project": "Foundations",
"autoAdd": true
}
]
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

exports.newFoundationsBotModulesFetchingProcess = function (processIndex) {
exports.newDataMiningBotModulesFetchingProcess = function (processIndex) {

const MODULE_NAME = "Fetching Process";

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesSingleMarketAPIDataFetcherBot = function (processIndex) {
exports.newDataMiningBotModulesSingleMarketAPIDataFetcherBot = function (processIndex) {

const MODULE_NAME = "Single Market API Data Fetcher Bot";

Expand Down Expand Up @@ -41,7 +41,8 @@ exports.newFoundationsBotModulesSingleMarketAPIDataFetcherBot = function (proces
let botModuleDefinition = TS.projects.foundations.functionLibraries.taskFunctions.getBotModuleByName(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.config.botModule
)
let project = TS.projects[TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName.toLowerCase()]
let projectCodeName = TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName
let project = TS.projects[PROJECTS_SCHEMA_MAP.get(projectCodeName).propertyName]
let botModule = project.botModules[botModuleDefinition.propertyName]
let moduleFunction = botModule[botModuleDefinition.functionName]
botModuleObject = moduleFunction(processIndex)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesBollingerBandsMultiTimeFrameDaily = function (processIndex) {
exports.newDataMiningBotModulesBollingerBandsMultiTimeFrameDaily = function (processIndex) {

const MODULE_NAME = "Bollinger Bands Multi Time Frame Daily"
const CANDLES_FOLDER_NAME = "Candles"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesBollingerBandsMultiTimeFrameMarket = function (processIndex) {
exports.newDataMiningBotModulesBollingerBandsMultiTimeFrameMarket = function (processIndex) {

const MODULE_NAME = "Bollinger Bands Multi Time Frame Market"
const CANDLES_FOLDER_NAME = "Candles"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesCandlesVolumesMultiTimeFrameDaily = function (processIndex) {
exports.newDataMiningBotModulesCandlesVolumesMultiTimeFrameDaily = function (processIndex) {

const MODULE_NAME = "Candles Volumes Multi Time Frame Daily";
const CANDLES_FOLDER_NAME = "Candles";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesCandlesVolumesMultiTimeFrameMarket = function (processIndex) {
exports.newDataMiningBotModulesCandlesVolumesMultiTimeFrameMarket = function (processIndex) {

const MODULE_NAME = "Candles Volumes Multi Time Frame Market"
const CANDLES_FOLDER_NAME = "Candles"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesFromOneMinToMultiTimeFrameDaily = function (processIndex) {
exports.newDataMiningBotModulesFromOneMinToMultiTimeFrameDaily = function (processIndex) {
/*
This module is about converting a One-Min Daily typeo of data set into a Multi Time Frame Daily type.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesFromOneMinToMultiTimeFrameMarket = function (processIndex) {
exports.newDataMiningBotModulesFromOneMinToMultiTimeFrameMarket = function (processIndex) {
/*
This module is about converting a One-Min Daily typeo of data set into a Multi Time Frame Market type.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesIndicatorOutput = function (processIndex) {
exports.newDataMiningBotModulesIndicatorOutput = function (processIndex) {
/*
This module coordinates the actions to be taken to generate an indicator output.
It is used from both Multi-Time-Frame-Market and Multi-Time-Frame-Daily frameworks.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesMultiTimeFrameDaily = function (processIndex) {
exports.newDataMiningBotModulesMultiTimeFrameDaily = function (processIndex) {
const MODULE_NAME = "Multi Time Frame Daily"
/*
This module deals with Daily Files, that are data files for Time Frames below 1 hour.
Expand All @@ -25,7 +25,7 @@
statusDependenciesModule = pStatusDependencies;
dataDependenciesModule = pStatusDependenciesModule;

indicatorOutputModule = TS.projects.foundations.botModules.indicatorOutput.newFoundationsBotModulesIndicatorOutput(processIndex)
indicatorOutputModule = TS.projects.foundations.botModules.indicatorOutput.newDataMiningBotModulesIndicatorOutput(processIndex)
indicatorOutputModule.initialize(callBackFunction)
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesMultiTimeFrameMarket = function (processIndex) {
exports.newDataMiningBotModulesMultiTimeFrameMarket = function (processIndex) {
const MODULE_NAME = "Multi Time Frame Market"
/*
This module deals with Market Files, that are data files for Time Frames of 1 hour and above.
Expand All @@ -24,7 +24,7 @@
statusDependenciesModule = pStatusDependencies
dataDependenciesModule = pStatusDependenciesModule

indicatorOutputModule = TS.projects.foundations.botModules.indicatorOutput.newFoundationsBotModulesIndicatorOutput(processIndex)
indicatorOutputModule = TS.projects.foundations.botModules.indicatorOutput.newDataMiningBotModulesIndicatorOutput(processIndex)
indicatorOutputModule.initialize(callBackFunction)
}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesSingleMarketIndicatorBot = function (processIndex) {
exports.newDataMiningBotModulesSingleMarketIndicatorBot = function (processIndex) {

const MODULE_NAME = "Single Market Indicator Bot";

Expand Down Expand Up @@ -40,7 +40,8 @@
let botModuleDefinition = TS.projects.foundations.functionLibraries.taskFunctions.getBotModuleByName(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.config.botModule
)
let project = TS.projects[TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName.toLowerCase()]
let projectCodeName = TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName
let project = TS.projects[PROJECTS_SCHEMA_MAP.get(projectCodeName).propertyName]
let botModule = project.botModules[botModuleDefinition.propertyName]
let moduleFunction = botModule[botModuleDefinition.functionName]
botModuleObject = moduleFunction(processIndex)
Expand Down Expand Up @@ -276,22 +277,22 @@

switch (TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.config.framework.name) {
case 'Multi-Time-Frame-Market': {
processFramework = TS.projects.foundations.botModules.multiTimeFrameMarket.newFoundationsBotModulesMultiTimeFrameMarket(processIndex)
processFramework = TS.projects.foundations.botModules.multiTimeFrameMarket.newDataMiningBotModulesMultiTimeFrameMarket(processIndex)
intitializeProcessFramework()
break;
}
case 'Multi-Time-Frame-Daily': {
processFramework = TS.projects.foundations.botModules.multiTimeFrameDaily.newFoundationsBotModulesMultiTimeFrameDaily(processIndex)
processFramework = TS.projects.foundations.botModules.multiTimeFrameDaily.newDataMiningBotModulesMultiTimeFrameDaily(processIndex)
intitializeProcessFramework()
break;
}
case 'From-One-Min-To-Multi-Time-Frame-Market': {
processFramework = TS.projects.foundations.botModules.fromOneMinToMultiTimeFrameMarket.newFoundationsBotModulesFromOneMinToMultiTimeFrameMarket(processIndex)
processFramework = TS.projects.foundations.botModules.fromOneMinToMultiTimeFrameMarket.newDataMiningBotModulesFromOneMinToMultiTimeFrameMarket(processIndex)
intitializeProcessFramework()
break;
}
case 'From-One-Min-To-Multi-Time-Frame-Daily': {
processFramework = TS.projects.foundations.botModules.fromOneMinToMultiTimeFrameDaily.newFoundationsBotModulesFromOneMinToMultiTimeFrameDaily(processIndex)
processFramework = TS.projects.foundations.botModules.fromOneMinToMultiTimeFrameDaily.newDataMiningBotModulesFromOneMinToMultiTimeFrameDaily(processIndex)
intitializeProcessFramework()
break;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesHistoricOHLCVs = function (processIndex) {
exports.newDataMiningBotModulesHistoricOHLCVs = function (processIndex) {

const MODULE_NAME = "Historic OHLCVs";
const CANDLES_FOLDER_NAME = "Candles/One-Min";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exports.newFoundationsBotModulesSingleMarketSensorBot = function (processIndex) {
exports.newDataMiningBotModulesSingleMarketSensorBot = function (processIndex) {

const MODULE_NAME = "Single Market Sensor Bot";

Expand Down Expand Up @@ -41,7 +41,8 @@
let botModuleDefinition = TS.projects.foundations.functionLibraries.taskFunctions.getBotModuleByName(
TS.projects.foundations.globals.taskConstants.TASK_NODE.bot.processes[processIndex].referenceParent.config.botModule
)
let project = TS.projects[TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName.toLowerCase()]
let projectCodeName = TS.projects.foundations.globals.taskConstants.PROJECT_DEFINITION_NODE.config.codeName
let project = TS.projects[PROJECTS_SCHEMA_MAP.get(projectCodeName).propertyName]
let botModule = project.botModules[botModuleDefinition.propertyName]
let moduleFunction = botModule[botModuleDefinition.functionName]
botModuleObject = moduleFunction(processIndex)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

exports.newFoundationsBotModulesCheckWebhook = function (processIndex) {
exports.newDataMiningBotModulesCheckWebhook = function (processIndex) {

const MODULE_NAME = "Check Webhooks";
const FOLDER_NAME = "External-Signals";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
},
{
"style": "Json",
"text": "\"botModules\": [\n {\n \"name\": \"Candles Volumes Multi Time Frame Market\",\n \"propertyName\": \"candlesVolumesMultiTimeFrameMarket\",\n \"functionName\": \"newFoundationsBotModulesCandlesVolumesMultiTimeFrameMarket\",\n \"fileName\": \"CandlesVolumesMultiTimeFrameMarket.js\",\n \"folderName\": \"Indicator-Bot/Candles-Volumes\"\n },",
"text": "\"botModules\": [\n {\n \"name\": \"Candles Volumes Multi Time Frame Market\",\n \"propertyName\": \"candlesVolumesMultiTimeFrameMarket\",\n \"functionName\": \"newDataMiningBotModulesCandlesVolumesMultiTimeFrameMarket\",\n \"fileName\": \"CandlesVolumesMultiTimeFrameMarket.js\",\n \"folderName\": \"Indicator-Bot/Candles-Volumes\"\n },",
"updated": 1621703869144
},
{
Expand Down
Loading

0 comments on commit cb010fb

Please sign in to comment.