You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Mirko Görgen <mg...@ipylon.de> on 2004/10/11 11:42:45 UTC

Lucene Term Highlighting

Hi

Does anybody tried out to do a "term highlighting" using Lucene? I tried
to get the "Term Highlighter" found on the Lucene Sandbox area. But
unfortunatly it doesn´t work. For my understanding I have to add the jar
file and to extend to xsp lucene example. There is no comment to change
s.th. on the source of lucene.

So perhaps there is someone how has a small example or small how-to to
get this thing working.

Regards

Mirko


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


RE: Lucene Term Highlighting

Posted by Hugo Burm <hu...@xs4all.nl>.
>
> Hi Hugo
>
> First of all I dont wanted to be impolitely when I wrote "... outdated
> article ...". So I hope you don´t get it wrong :-)
>

No problem. You were right. It is outdated. Somebody has to buy me some
time...


> >"For my understanding I have to add the jar file and to extend to xsp
> >lucene
> >example. There is no comment to change s.th. on the source
> >of lucene."
> Which jar file and which xsp lucene example you are talking about?
>
> I was talking about the jar file from the lucene Sandbox area and the
> xsp example of cocoon block.
>
> But to sum up, problem is now solved for me. So result could
> be seen at
> www.learnkey.de
>

I wanted to ask you to submit your site to the livesites section of the
Cocoon site. But I just found out that it is already there. Thanks!

Hugo



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


AW: Lucene Term Highlighting

Posted by Mirko Görgen <mg...@ipylon.de>.
Hi Hugo

First of all I dont wanted to be impolitely when I wrote "... outdated
article ...". So I hope you don´t get it wrong :-)

>"For my understanding I have to add the jar file and to extend to xsp
>lucene
>example. There is no comment to change s.th. on the source of lucene."
>Which jar file and which xsp lucene example you are talking about?

I was talking about the jar file from the lucene Sandbox area and the
xsp example of cocoon block.

But to sum up, problem is now solved for me. So result could be seen at
www.learnkey.de

For the one how are interesting in.

I used another xslt which give me one node including whole text of each
page and modified same parts of cocoon.xconf to tell lucene to add this
node to the index. By searching I pulled out the field again and used
the classes of the jar file to get the "term highlighting". 

Regards
Mirko


-----Ursprüngliche Nachricht-----
Von: Hugo Burm [mailto:hugob@xs4all.nl] 
Gesendet: Mittwoch, 13. Oktober 2004 00:07
An: users@cocoon.apache.org
Betreff: RE: Lucene Term Highlighting

Hello Mirko,

I am the one who wrote the outdated article. Today, I looked into the
Lucene
sandbox code for the hit-highlighter. Not that many things did change.
But
the good news is that you don't have to modify the Lucene source code
(the
main reason we had to modify the Lucene source code was, that we needed
access to some private fields and methods. The interface did change, so
you
can get this info today without changing the code).

When you are using Cocoon, the only way to go is to build a transformer
from
this sandbox code (or ask somebody else to build it for you and make it
part
of the distribution). So, when a project needs hit-highlighting,  the
only
thing that has to be done is plugging in the transformer into the Cocoon
pipeline. I can think of other solutions, but none of them fits so
nicely
into the Cocoon pipeline concept. So some "volunteer" must update the
code
in the outdated article with the latest sandbox code (and, please, make
it
more configurable).

Quoting from your original question, I am not quite sure what you want
to
say with:
"For my understanding I have to add the jar file and to extend to xsp
lucene
example. There is no comment to change s.th. on the source of lucene."
Which jar file and which xsp lucene example you are talking about?


Hugo Burm





> -----Original Message-----
> From: Mirko Görgen [mailto:mgo@ipylon.de]
> Sent: Tuesday, October 12, 2004 7:10 PM
> To: users@cocoon.apache.org; 'mvaterlaus'
> Subject: AW: Lucene Term Highlighting
>
>
> Hi MV
>
> Yes I allready noticed this articel, but I guess this is a little bit
> out of date. On the other hand, using this method you have to
> modify the
> source of lucene, regarding lucene webpage especially the "term
> highlighting" you only have to add the jar. I think this is the better
> way of implementing it.
>
> Anyway, thanks for your response
>
> MG
>
> -----Ursprüngliche Nachricht-----
> Von: mvaterlaus [mailto:mvaterlaus@gmail.com]
> Gesendet: Dienstag, 12. Oktober 2004 09:21
> An: users@cocoon.apache.org
> Betreff: Re: Lucene Term Highlighting
>
> Hello Mirko,
>
> in case you haven't found a solution yet, on cocooncenter.org there
> was an article covering this topic quite a while ago. Anyhow, might
> still be worth a click
>
> <http://www.cocooncenter.org/articles/lucene.html>
>
> --mv
>
> On Mon, 11 Oct 2004 11:42:45 +0200, Mirko Görgen
> <mg...@ipylon.de> wrote:
> > Hi
> >
> > Does anybody tried out to do a "term highlighting" using Lucene? I
> tried
> > to get the "Term Highlighter" found on the Lucene Sandbox area. But
> > unfortunatly it doesn´t work. For my understanding I have to add the
> jar
> > file and to extend to xsp lucene example. There is no comment to
> change
> > s.th. on the source of lucene.
> >
> > So perhaps there is someone how has a small example or
> small how-to to
> > get this thing working.
> >
> > Regards
> >
> > Mirko
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> > For additional commands, e-mail: users-help@cocoon.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


RE: Lucene Term Highlighting

Posted by Hugo Burm <hu...@xs4all.nl>.
Hello Mirko,

I am the one who wrote the outdated article. Today, I looked into the Lucene
sandbox code for the hit-highlighter. Not that many things did change. But
the good news is that you don't have to modify the Lucene source code (the
main reason we had to modify the Lucene source code was, that we needed
access to some private fields and methods. The interface did change, so you
can get this info today without changing the code).

When you are using Cocoon, the only way to go is to build a transformer from
this sandbox code (or ask somebody else to build it for you and make it part
of the distribution). So, when a project needs hit-highlighting,  the only
thing that has to be done is plugging in the transformer into the Cocoon
pipeline. I can think of other solutions, but none of them fits so nicely
into the Cocoon pipeline concept. So some "volunteer" must update the code
in the outdated article with the latest sandbox code (and, please, make it
more configurable).

Quoting from your original question, I am not quite sure what you want to
say with:
"For my understanding I have to add the jar file and to extend to xsp lucene
example. There is no comment to change s.th. on the source of lucene."
Which jar file and which xsp lucene example you are talking about?


Hugo Burm





> -----Original Message-----
> From: Mirko Görgen [mailto:mgo@ipylon.de]
> Sent: Tuesday, October 12, 2004 7:10 PM
> To: users@cocoon.apache.org; 'mvaterlaus'
> Subject: AW: Lucene Term Highlighting
>
>
> Hi MV
>
> Yes I allready noticed this articel, but I guess this is a little bit
> out of date. On the other hand, using this method you have to
> modify the
> source of lucene, regarding lucene webpage especially the "term
> highlighting" you only have to add the jar. I think this is the better
> way of implementing it.
>
> Anyway, thanks for your response
>
> MG
>
> -----Ursprüngliche Nachricht-----
> Von: mvaterlaus [mailto:mvaterlaus@gmail.com]
> Gesendet: Dienstag, 12. Oktober 2004 09:21
> An: users@cocoon.apache.org
> Betreff: Re: Lucene Term Highlighting
>
> Hello Mirko,
>
> in case you haven't found a solution yet, on cocooncenter.org there
> was an article covering this topic quite a while ago. Anyhow, might
> still be worth a click
>
> <http://www.cocooncenter.org/articles/lucene.html>
>
> --mv
>
> On Mon, 11 Oct 2004 11:42:45 +0200, Mirko Görgen
> <mg...@ipylon.de> wrote:
> > Hi
> >
> > Does anybody tried out to do a "term highlighting" using Lucene? I
> tried
> > to get the "Term Highlighter" found on the Lucene Sandbox area. But
> > unfortunatly it doesn´t work. For my understanding I have to add the
> jar
> > file and to extend to xsp lucene example. There is no comment to
> change
> > s.th. on the source of lucene.
> >
> > So perhaps there is someone how has a small example or
> small how-to to
> > get this thing working.
> >
> > Regards
> >
> > Mirko
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> > For additional commands, e-mail: users-help@cocoon.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


AW: Lucene Term Highlighting

Posted by Mirko Görgen <mg...@ipylon.de>.
Hi MV

Yes I allready noticed this articel, but I guess this is a little bit
out of date. On the other hand, using this method you have to modify the
source of lucene, regarding lucene webpage especially the "term
highlighting" you only have to add the jar. I think this is the better
way of implementing it. 

Anyway, thanks for your response

MG  

-----Ursprüngliche Nachricht-----
Von: mvaterlaus [mailto:mvaterlaus@gmail.com] 
Gesendet: Dienstag, 12. Oktober 2004 09:21
An: users@cocoon.apache.org
Betreff: Re: Lucene Term Highlighting

Hello Mirko,

in case you haven't found a solution yet, on cocooncenter.org there
was an article covering this topic quite a while ago. Anyhow, might
still be worth a click

<http://www.cocooncenter.org/articles/lucene.html>

--mv

On Mon, 11 Oct 2004 11:42:45 +0200, Mirko Görgen <mg...@ipylon.de> wrote:
> Hi
> 
> Does anybody tried out to do a "term highlighting" using Lucene? I
tried
> to get the "Term Highlighter" found on the Lucene Sandbox area. But
> unfortunatly it doesn´t work. For my understanding I have to add the
jar
> file and to extend to xsp lucene example. There is no comment to
change
> s.th. on the source of lucene.
> 
> So perhaps there is someone how has a small example or small how-to to
> get this thing working.
> 
> Regards
> 
> Mirko
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Lucene Term Highlighting

Posted by mvaterlaus <mv...@gmail.com>.
Hello Mirko,

in case you haven't found a solution yet, on cocooncenter.org there
was an article covering this topic quite a while ago. Anyhow, might
still be worth a click

<http://www.cocooncenter.org/articles/lucene.html>

--mv

On Mon, 11 Oct 2004 11:42:45 +0200, Mirko Görgen <mg...@ipylon.de> wrote:
> Hi
> 
> Does anybody tried out to do a "term highlighting" using Lucene? I tried
> to get the "Term Highlighter" found on the Lucene Sandbox area. But
> unfortunatly it doesn´t work. For my understanding I have to add the jar
> file and to extend to xsp lucene example. There is no comment to change
> s.th. on the source of lucene.
> 
> So perhaps there is someone how has a small example or small how-to to
> get this thing working.
> 
> Regards
> 
> Mirko
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org