RFC: dezi-for-wordpress

10 views
Skip to first unread message

Peter Karman

unread,
Oct 17, 2012, 11:58:41 PM10/17/12
to dezi-...@googlegroups.com
I have been working on a Dezi plugin for Wordpress and would appreciate feedback
from any Wordpress users out there:

https://github.com/APMG/dezi-for-wordpress


--
Peter Karman . http://peknet.com/ . pe...@peknet.com

Paul Stubbe

unread,
Oct 22, 2012, 2:32:42 PM10/22/12
to dezi-...@googlegroups.com, pe...@peknet.com
Peter,
 
I've installed your plugin today and got it "almost" running, I think.
 
I first tried to work without an explicit dezi user and password, but that did not seem to work in the wordpress interface.
 
I think I still have an issue with where or what to do with the dezi4w.js
 
I get results but the facets do not work yet. Could you publish a screen shot of what it should look like?
 
I also activated the
         ui_class  => 'Dezi::UI'
as explained in the Dezi::Tutorial to have two views of the results and there I could see some wordpress facets.
 
Now my first user remark:
 
 I tried to integrate the wordpress search with my existing Dezi migration plan.
The result in the Dezi:UI works just fine and I can link to the wordpress content and use the wordpress facets.
But from the wordpress interface I can not link back to content from outside of wordpress, they get changed to some wordpress link.
I would like to use "one and only one Dezi" for all my different searches: this would be really neat.
And use, like you proposed, for example the "origin" facet to limit my search to wordpress (as an option).
 
I have a second user issue:
I live in a multilingual environment: How to define the stemmer for multiple languages?
 
I hope this helps you.
 
Paul
 
 
 

Op donderdag 18 oktober 2012 06:03:41 UTC+2 schreef Peter Karman het volgende:

Peter Karman

unread,
Oct 22, 2012, 11:51:39 PM10/22/12
to dezi-...@googlegroups.com
Paul Stubbe wrote on 10/22/12 1:32 PM:
> Peter,
>
> I've installed your plugin today and got it "almost" running, I think.

Great, thanks for the feedback, Paul.


>
> I first tried to work without an explicit dezi user and password, but that did
> not seem to work in the wordpress interface.

Yes, you need to define a user/pass, though Dezi will just ignore them unless
they are also specified in your dezi config file.

I will try and figure out how to make that more clear in the Wordpress UI.


>
> I think I still have an issue with where or what to do with the dezi4w.js

That should just be for the admin view, not used in the search results afaik.


>
> I get results but the facets do not work yet. Could you publish a screen shot of
> what it should look like?


added to git here:
https://raw.github.com/APMG/dezi-for-wordpress/master/dezi-for-wordpress-screenshot.png

I've also installed the plugin on dezi.org so that site is now using dezi to
power its search:

http://dezi.org/2012/10/23/dezi-for-wordpress/

>
> I also activated the
> ui_class => 'Dezi::UI'
> as explained in the Dezi::Tutorial to have two views of the results and there I
> could see some wordpress facets.

Yes, I do that too while debugging/developing.


>
> Now my first user remark:
>
> I tried to integrate the wordpress search with my existing Dezi migration plan.
> The result in the Dezi:UI works just fine and I can link to the wordpress
> content and use the wordpress facets.
> But from the wordpress interface I can not link back to content from outside of
> wordpress, they get changed to some wordpress link.

You likely need to define a 'permalink' field in your non-wordpress index
schemas. That's what the Wordpress plugin indexes each post under, and what it
uses in the results.

See the schema here:
https://github.com/APMG/dezi-for-wordpress/blob/master/dezi-config.pl#L49

> I would like to use "one and only one Dezi" for all my different searches: this
> would be really neat.
> And use, like you proposed, for example the "origin" facet to limit my search to
> wordpress (as an option).


Yes, I am doing something similar now at $work. For it to work more seamlessly,
you must use the same index schema across all your indexes, and since the
Wordpress schema is the more rigid because the built-in UI relies on it, that
may (as it has for me) define the schema used by all my indexes. I leave some
fields undef in my non-Wordpress collections, but I have the fields defined in
my config nonetheless.


>
> I have a second user issue:
> I live in a multilingual environment: How to define the stemmer for multiple
> languages?
>

You'll want to provide one index-per-language. Dezi can serve multiple indexes
but assumes one QueryParser per server, so there's some limitations there. IME,
mixing languages in a single index is a recipe for disaster, unless you turn off
stemming (which is on by default in many of the example configs) or you
transliterate everything to pure 7-bit ASCII (see e.g.
Search::Tools::Transliterate).

Also, the LucyX::Suggester support for the Wordpress autocomplete feature
assumes one language per suggester, and one suggester per Dezi server. So that
might be a limitation given the current design.

I have an application at $work where I serve multiple indexes, each with its own
stemming (read: language) options, inside a single server. I use a custom Plack
application that mounts multiple Dezi servers, each at different URI points.
That's one of the reasons I made Dezi::Server a Plack-friendly app, because you
can embed it in a bigger Dezi app.

If your Wordpress app has multiple languages in it, and you had a multi-Dezi
server instance that you tried to make work in concert with Wordpress, there
would need to be some way of determining which Dezi server to target new content
changes at based on the language. I'm not sure offhand how to do that in
Wordpress, but if there's locale/language settings available, I'm sure we could
figure it out.

> I hope this helps you.

It does, thanks.
Reply all
Reply to author
Forward
0 new messages