Another Word For It Patrick Durusau on Topic Maps and Semantic Diversity

October 18, 2011

Basic interface to Apache Solr (Python recipe)

Filed under: Python,Solr,Teaching — Patrick Durusau @ 2:40 pm

Basic interface to Apache Solr (Python recipe) by Graham Poulter.

From the post:

A basic model class representing Apache Solr. Abstracts the select, delete, update, and commit operations.

Select operation returns Python object parsed from a JSON-formatted response.

(code omitted)

There are several full-fledged Python libraries for interfacing to Apache Solr.

But sometimes all you need is a little code to build an appropriate HTTP request and parse the response. In that case, using this class could save you some time.

I think recipes are a good thing. What I have found in cooking is that at first I follow them closely until I gain confidence with the techniques and the likely result. The longer I use them the more I am likely to depart from them. So I get, usually, an edible result and learn something in the bargain.

I think there is a lesson here for teaching people about semantic and data mining techniques in general and topic maps in particular.

No Comments

No comments yet.

RSS feed for comments on this post.

Sorry, the comment form is closed at this time.

Powered by WordPress