Python support for custom score

I'm trying to use a python script to create a custom score. I installed the
plugin doing this:

bin/plugin -install elasticsearch/elasticsearch-lang-python/1.1.0

It seemed to work fine. When the server starts up, I get this:

2012-03-14 18:18:33,103][INFO ][node ] [Grey King]
{0.18.7}[1062]: initializing ...
[2012-03-14 18:18:33,115][INFO ][plugins ] [Grey King]
loaded [lang-python], sites []
[2012-03-14 18:18:34,294][WARN ][script ] [Grey King] no
script engine found for [py]
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: initialized
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: starting ...

Result of query trying to use it is:

nested: ElasticSearchIllegalArgumentException[script_lang not supported
[python]]; }]","status":500}

What else do I need to do to support a Python script?

Thanks,
Brandon

Just to add some clarification, here is the query:

curl -X GET "http://localhost:9200/employers/employer/_search?pretty=true"
-d
'{"query":{"custom_score":{"params":{"param1":3},"script":"weight(param1)","lang":"python","query":{"query_string":{"query":"fa*"}}}}}'

On Wednesday, March 14, 2012 6:22:21 PM UTC-4, Brandon Hilkert wrote:

I'm trying to use a python script to create a custom score. I installed
the plugin doing this:

bin/plugin -install elasticsearch/elasticsearch-lang-python/1.1.0

It seemed to work fine. When the server starts up, I get this:

2012-03-14 18:18:33,103][INFO ][node ] [Grey King]
{0.18.7}[1062]: initializing ...
[2012-03-14 18:18:33,115][INFO ][plugins ] [Grey King]
loaded [lang-python], sites
[2012-03-14 18:18:34,294][WARN ][script ] [Grey King] no
script engine found for [py]
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: initialized
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: starting ...

Result of query trying to use it is:

nested: ElasticSearchIllegalArgumentException[script_lang not supported
[python]]; }]","status":500}

What else do I need to do to support a Python script?

Thanks,
Brandon

Check the readme: GitHub - elastic/elasticsearch-lang-python: Python language Plugin for elasticsearch,
1.1.0 only supports 0.19.0, not 0.18 version.

On Thu, Mar 15, 2012 at 1:53 AM, Brandon Hilkert brandon@meeteor.comwrote:

Just to add some clarification, here is the query:

curl -X GET "http://localhost:9200/employers/employer/_search?pretty=true"
-d
'{"query":{"custom_score":{"params":{"param1":3},"script":"weight(param1)","lang":"python","query":{"query_string":{"query":"fa*"}}}}}'

On Wednesday, March 14, 2012 6:22:21 PM UTC-4, Brandon Hilkert wrote:

I'm trying to use a python script to create a custom score. I installed
the plugin doing this:

bin/plugin -install elasticsearch/elasticsearch-**lang-python/1.1.0

It seemed to work fine. When the server starts up, I get this:

2012-03-14 18:18:33,103][INFO ][node ] [Grey King]
{0.18.7}[1062]: initializing ...
[2012-03-14 18:18:33,115][INFO ][plugins ] [Grey King]
loaded [lang-python], sites
[2012-03-14 18:18:34,294][WARN ][script ] [Grey King]
no script engine found for [py]
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: initialized
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: starting ...

Result of query trying to use it is:

nested: ElasticSearchIllegalArgumentEx**ception[script_lang not
supported [python]]; }]","status":500}

What else do I need to do to support a Python script?

Thanks,
Brandon

Oops! Didn't realize homebrew still had an older version....Thanks!

On Friday, March 16, 2012 1:07:12 PM UTC-4, kimchy wrote:

Check the readme:
GitHub - elastic/elasticsearch-lang-python: Python language Plugin for elasticsearch, 1.1.0 only
supports 0.19.0, not 0.18 version.

Just to add some clarification, here is the query:

curl -X GET "http://localhost:9200/employers/employer/_search?pretty=true"
-d
'{"query":{"custom_score":{"params":{"param1":3},"script":"weight(param1)","lang":"python","query":{"query_string":{"query":"fa*"}}}}}'

On Wednesday, March 14, 2012 6:22:21 PM UTC-4, Brandon Hilkert wrote:

I'm trying to use a python script to create a custom score. I installed
the plugin doing this:

bin/plugin -install elasticsearch/elasticsearch-**lang-python/1.1.0

It seemed to work fine. When the server starts up, I get this:

2012-03-14 18:18:33,103][INFO ][node ] [Grey King]
{0.18.7}[1062]: initializing ...
[2012-03-14 18:18:33,115][INFO ][plugins ] [Grey King]
loaded [lang-python], sites
[2012-03-14 18:18:34,294][WARN ][script ] [Grey King]
no script engine found for [py]
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: initialized
[2012-03-14 18:18:34,529][INFO ][node ] [Grey King]
{0.18.7}[1062]: starting ...

Result of query trying to use it is:

nested: ElasticSearchIllegalArgumentEx**ception[script_lang not
supported [python]]; }]","status":500}

What else do I need to do to support a Python script?

Thanks,
Brandon

Excusse the newbie question, but...
Where exactly should this bin/plugin -install elasticsearch/elasticsearch-lang-python/1.2.0. be run?
do I need to git clone the repository? there is no "bin" folder there.

you should run
bin/plugin -install elasticsearch/elasticsearch-lang-python/1.2.0
in the bin/ directory of you elasticsearch installation. if there is no bin
folder there is something wrong. Make sure you get a copy from
Elasticsearch Platform — Find real-time answers at scale | Elastic and unzip / tar it in order to
install the plugin. you don't need to clone the plugin git repo.

simon

On Sunday, March 3, 2013 9:30:21 AM UTC+1, Eran wrote:

Excusse the newbie question, but...
Where exactly should this bin/plugin -install
elasticsearch/elasticsearch-lang-python/1.2.0. be run?
do I need to git clone the repository? there is no "bin" folder there.

--
View this message in context:
http://elasticsearch-users.115913.n3.nabble.com/Python-support-for-custom-score-tp3827038p4030871.html
Sent from the Elasticsearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Thanks alot!

On Sun, Mar 3, 2013 at 11:54 AM, simonw-2 [via Elasticsearch Users] <
ml-node+s115913n4030874h70@n3.nabble.com> wrote:

you should run
bin/plugin -install elasticsearch/elasticsearch-lang-python/1.2.0
in the bin/ directory of you elasticsearch installation. if there is no
bin folder there is something wrong. Make sure you get a copy from
Elasticsearch Platform — Find real-time answers at scale | Elastic and unzip / tar it in order to
install the plugin. you don't need to clone the plugin git repo.

simon

On Sunday, March 3, 2013 9:30:21 AM UTC+1, Eran wrote:

Excusse the newbie question, but...
Where exactly should this bin/plugin -install
elasticsearch/elasticsearch-**lang-python/1.2.0. be run?
do I need to git clone the repository? there is no "bin" folder there.

--
View this message in context: http://elasticsearch-users.**
115913.n3.nabble.com/Python-support-for-custom-score-
tp3827038p4030871.htmlhttp://elasticsearch-users.115913.n3.nabble.com/Python-support-for-custom-score-tp3827038p4030871.html
Sent from the Elasticsearch Users mailing list archive at Nabble.com.

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [hidden email]http://user/SendEmail.jtp?type=node&node=4030874&i=0
.
For more options, visit https://groups.google.com/groups/opt_out.


If you reply to this email, your message will be added to the discussion
below:

http://elasticsearch-users.115913.n3.nabble.com/Python-support-for-custom-score-tp3827038p4030874.html
To unsubscribe from Python support for custom score, click herehttp://elasticsearch-users.115913.n3.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=3827038&code=ZXJhbmlkQGdtYWlsLmNvbXwzODI3MDM4fDY0MzA1NjE1MA==
.
NAMLhttp://elasticsearch-users.115913.n3.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html!nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers!nabble%3Aemail.naml-instant_emails!nabble%3Aemail.naml-send_instant_email!nabble%3Aemail.naml