Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejavascript
titleScoring parameters - time proximity
{
	"score": {
		// See preceding sections for other parameters
		"timeProx":{
			"time": string,
			"decay": string
		},
		// See following sections for other parameters
	}
}
  • "time" is the center point around which to decay.It has the same format as the "min" and "max" fields of the "time" query term (TBD link), ie "now", Unix time in ms, or one of a standard set of date/time formats (ISO, SMTP, etc).
  • "decay" specifies a duration is the "half life" of the decay (ie the duration from "time" at which the score is halved). It is in the format "N[dmwy]" where N is an integer and d,m,w,y denote "day", "month", "week" or "year" (eg "1w", "1m"; note currently if "m" is used, then the duration is always 1 month).
Code Block
languagejavascript
titleScoring parameters - geospatial proximity
{
	"score": {
		// See preceding sections for other parameters
		"geoProx":{
			"ll": string,
			"decay": string
		},
		// See following sections for other parameters
	}
}
  • "ll" is the lat/long of the center point around which to decay. It has the same format as theĀ 

...

  • the "centerll"/"minll"/"maxll" fields of the geospatial query term (TBD link), ie "lat,long" or "(lat,long)".
  • "decay" is the "half life" of the decay (ie the distance from "ll" at which the score is halved). It is in the same format as the "dist" field of the "geo" query term (TBD link), ie in the format "<distance><unit>" where <distance> is an integer or floating point number, and unit is one of "m" (miles), "km" (kilometers), "nm" (nautical miles).
    Code Block
    languagejavascript
    titleExample "score" object
    {
    	"score":{
    		"numAnalyze": 1000,
    		"sigWeight": 0.67,
    		"relWeight": 0.33,
    		"timeProx": {
    			"time": "now",
    			"duration": "1m"
    		}
    	}
    }