Expected type is `"CortextDB"` and you should fill the tables to search in.
```json
"reldbs":{
"CortextDB":{
"file":"$$relpath/to/some.db",
"qtable":"$$tableNameToSearchIn",
"template":"cortext_with_link"
}
}
```
###### => for twitter queries
Expected type is `"twitter"` and no additional conf is needed (POSS for the future: add twitter query context, ex: "Présidentielles 2017 AND (query)").
```json
"reldbs":{
"twitter":{}
}
```
###### Real life examples
```json
```json
"data/gargistex":{
"data/gargistex":{
"first":"shale_and_ice.gexf",
"graphs":{
"graphs":{
"model_calibration.gexf":{
"shale_and_ice.gexf":{
"node0":{
"node0":{
"name":"terms",
"name":"terms",
"reldbs":{
"reldbtype":"csv",
"csv":{
"reldbfile":"shale_and_ice.csv",
"file":"model_calibration.csv",
"reldbqcols":["title","abstract"]
"qcols":["title"],
"template":"bib_details"
},
"twitter":{}
}
}
}
}
},
"data/test":{
"first":"mini_for_csv.gexf",
"graphs":{
"mini_for_csv.gexf":{
"node0":{
"name":"terms",
"reldbs":{
"csv":{
"file":"mini_for_csv.csv",
"qcols":["title","keywords","text"],
"template":"bib_details"
},
"twitter":{}
}
}
},
},
"model_calibration.gexf":{
"node1":{
"node0":{
"name":"authors",
"name":"terms",
"reldbs":{
"reldbtype":"csv",
"csv":{
"reldbfile":"model_calibration.csv",
"file":"mini_for_csv.csv",
"reldbqcols":["title","abstract"]
"qcols":["author"],
"template":"bib_details"
}
}
}
}
}
}
}
}
}
}
```
```
###### => for CortextDB SQL tables
In the last exemple, we have two nodetypes:
Expected type is `"CortextDB"` and you should fill the table to search in.
- node0 allows both CSV and twitter relatedDocs tabs.
This is a stub for a future documentation for developers.
This is a stub for a future documentation for developers.
#### About settings
- system-wide settings are in `settings_explorerjs.js`
- source-by-source settings (nodetypes, relatedDocs APIs) are in `db.json`
## Graph input choices
## Graph input choices
...
@@ -13,7 +16,7 @@ Tina allows 3 main ways of input :
...
@@ -13,7 +16,7 @@ Tina allows 3 main ways of input :
The `sourcemode` value is by default the one in settings_explorerjs.js (`TW.conf.sourcemode`), unless an url argument of the same name is present.
The `sourcemode` value is by default the one in settings_explorerjs.js (`TW.conf.sourcemode`), unless an url argument of the same name is present.
The `serverfile` option has an extended version called `servermenu`. It opens a list of files called`db.json` on the server, providing a menu to choose from it.
The `serverfile` option has an extended version called `servermenu`. It opens the list of files from`db.json` on the server, providing a menu to choose from it.
The detailed implementation of these choices can be found in the function `syncRemoteGraphData()` in main.js.
The detailed implementation of these choices can be found in the function `syncRemoteGraphData()` in main.js.
...
@@ -32,7 +35,8 @@ This will still evolve but the main steps for any graph initialization messily u
...
@@ -32,7 +35,8 @@ This will still evolve but the main steps for any graph initialization messily u
4.[`main.js`] mainStartGraph() function runs all the rest
4.[`main.js`] mainStartGraph() function runs all the rest
2. calls [`sigmaUtils`] where the function `FillGraph()` was a central point for filtering and preparing properties but now with 2 and 3 it just creates a filtered copy of the nodes and edges of the current active types to a new structure that groups them together (POSSIBLE remove this extra step)
2. calls [`sigmaUtils`] where the function `FillGraph()` was a central point for filtering and preparing properties but now with 2 and 3 it just creates a filtered copy of the nodes and edges of the current active types to a new structure that groups them together (POSSIBLE remove this extra step)
3. back in [`main.js`], finally all sigma settings (user + defaults) are merged and we initialize the sigma instance (`new sigma` etc.)
3. back in [`main.js`], finally all sigma settings (user + defaults) are merged and we initialize the sigma instance (`new sigma` etc.)
at this point, any additional conf located in db.json is used for nodeTypes and relatedDocsTypes
4. finally a call to [`TinawebJS`] initializes the action listeners and this phase should crucially initialize items that need the sigma instance (because they may depend the displayed categories, the number of displayed nodes, etc)
4. finally a call to [`TinawebJS`] initializes the action listeners and this phase should crucially initialize items that need the sigma instance (because they may depend the displayed categories, the number of displayed nodes, etc)