Skip to content
ZYShin edited this page Nov 5, 2017 · 4 revisions

Welcome to the ESLWriter wiki!

Menu

Update log

2017.11.05

Add all prepositions to MongoDB's common.thesaurus to make them synonymous with each other, using the following script:

var preps = [
"aboard",
"about",
"above",
"across",
"after",
"against",
"along",
"amid",
"among",
"anti",
"around",
"as",
"at",
"before",
"behind",
"below",
"beneath",
"beside",
"besides",
"between",
"beyond",
"but",
"by",
"concerning",
"considering",
"despite",
"down",
"during",
"except",
"excepting",
"excluding",
"following",
"for",
"from",
"in",
"inside",
"into",
"like",
"near",
"of",
"off",
"on",
"onto",
"opposite",
"outside",
"over",
"past",
"per",
"plus",
"regarding",
"round",
"save",
"since",
"than",
"through",
"to",
"toward",
"towards",
"under",
"underneath",
"unlike",
"until",
"up",
"upon",
"versus",
"via",
"with",
"within",
"without"
]

var commonPreps = [
"aboard",
"about",
"above",
"across",
"after",
"against",
"along",
"amid",
"among",
// "anti",
"around",
"as",
"at",
"before",
"behind",
"below",
"beneath",
"beside",
"besides",
"between",
"beyond",
"but",
"by",
// "concerning",
// "considering",
"despite",
"down",
"during",
"except",
"excepting",
"excluding",
// "following",
"for",
"from",
"in",
"inside",
"into",
"like",
"near",
"of",
"off",
"on",
"onto",
// "opposite",
"outside",
"over",
// "past",
"per",
// "plus",
// "regarding",
// "round",
// "save",
"since",
"than",
"through",
"to",
"toward",
"towards",
"under",
"underneath",
"unlike",
"until",
"up",
"upon",
"versus",
"via",
"with",
"within",
"without"
]

var generateDocument = function(value) {
    document = document.concat([{"s" : NumberInt(5), "w" : value}])
}

var addSync = function(value) {
    var token = db.thesaurus.findOne({"_id" : value})
//     var token = db.thesaurus_backup.findOne({"_id" : value})
    var updateMeaning = [syncDoc]
    if (token != null) {
//         var meaning = token.meaning
//         var updateMeaning = meaning.concat(syncDoc)
        db.thesaurus.updateOne({"_id" : value}, {$set:{'meaning' : updateMeaning}}, true)
    }
    else {
        db.thesaurus.insertOne({"_id" : value, 'meaning' : updateMeaning})
    }
}

var document = []
preps.forEach(generateDocument)
var syncDoc = {"ant" : [], "pos" : "prep", "exp" : "preposition", "syn" : document}
commonPreps.forEach(addSync)

2017.10.11

We used to use Azure storage which requires the following packages. They are no longer needed.

  • pyodbc-3.0.7-cp27-none-win32.whl or pyodbc-3.0.7-cp27-none-win_amd64.whl
  • django-pyodbc-azure
  • azure
  • pythonnet-2.0.0.dev1-cp27-none-win32.whl or pythonnet-2.0.0.dev1-cp27-none-win_amd64.whl

Clone this wiki locally