How to use a custom scoring script that has a lot of dependencies?

I have a java file that creates a custom scoring in:

"similarity.default.type": "com.engine.scoring.elasticsearch.TweakedSimilarity"

and there are other files also that define filters and analyzers which are similar kind of package structure.

Almost all of those files have a lot dependencies like lucene, elasticsearch, java.io etc.

Even if I place the java file in the config/scripts directory I always get error that the file wasn't found.

I am not sure whether or not should I class files or java files? Both are not running.

1 Like