You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by lukai <lu...@gmail.com> on 2012/03/19 07:42:15 UTC

How to extend "TermInfo" ?

Hi, guys:
  I have needs to add a new data filed in "TermInfo".  refer to here:
http://lucene.apache.org/core/old_versioned_docs/versions/3_5_0/fileformats.html#TermDictionary

  Do i need to change the term FST build process? Anybody had done this
kind of modification before?

Thanks,

Re: How to extend "TermInfo" ?

Posted by lukai <lu...@gmail.com>.
Thx, i will try to move to 4.x version.


On Mon, Mar 19, 2012 at 2:24 PM, Michael McCandless <
lucene@mikemccandless.com> wrote:

> On Mon, Mar 19, 2012 at 5:13 PM, lukai <lu...@gmail.com> wrote:
>
> > Thanks for the information.
>
> You're welcome!
>
> > I'd like to store like one float value per item. To implement another
> query
> > evaluation algo which needs to store information per term.
>
> OK, sounds neat.
>
> > BTW, i might also
> > want to store information per document for each item. It seems currently
> the
> > payload information are stored in each position the term occurs. Any
> plans
> > to store add an mechanism to store information per doc?
>
> In trunk, you can use doc values for this?
>
> > It might be also
> > possible to merge all payload info for one document, but it's a bit
> > computing waste in runtime.
>
> In 3.x, you can make a field for each document, that has only one term
> occurrence and stores the payload on it?
>

Smart solution... :)


>
> Mike McCandless
>
> http://blog.mikemccandless.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: dev-help@lucene.apache.org
>
>

Re: How to extend "TermInfo" ?

Posted by Michael McCandless <lu...@mikemccandless.com>.
On Mon, Mar 19, 2012 at 5:13 PM, lukai <lu...@gmail.com> wrote:

> Thanks for the information.

You're welcome!

> I'd like to store like one float value per item. To implement another query
> evaluation algo which needs to store information per term.

OK, sounds neat.

> BTW, i might also
> want to store information per document for each item. It seems currently the
> payload information are stored in each position the term occurs. Any plans
> to store add an mechanism to store information per doc?

In trunk, you can use doc values for this?

> It might be also
> possible to merge all payload info for one document, but it's a bit
> computing waste in runtime.

In 3.x, you can make a field for each document, that has only one term
occurrence and stores the payload on it?

Mike McCandless

http://blog.mikemccandless.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Re: How to extend "TermInfo" ?

Posted by lukai <lu...@gmail.com>.
Thanks for the information.

I'd like to store like one float value per item. To implement another query
evaluation algo which needs to store information per term. BTW, i might
also want to store information per document for each item. It seems
currently the payload information are stored in each position the term
occurs. Any plans to store add an mechanism to store information per doc?
It might be also possible to merge all payload info for one document, but
it's a bit computing waste in runtime.


On Mon, Mar 19, 2012 at 3:07 AM, Michael McCandless <
lucene@mikemccandless.com> wrote:

> It is not easy to add new per-term metadata in 3.x.
>
> But in trunk (to eventually be 4.0)... you can make your own codec and
> store additional per-term metadata.
>
> What kind of metadata are you wanting to store...?
>
> Mike McCandless
>
> http://blog.mikemccandless.com
>
> On Mon, Mar 19, 2012 at 2:42 AM, lukai <lu...@gmail.com> wrote:
> > Hi, guys:
> >   I have needs to add a new data filed in "TermInfo".  refer to
> > here:
> http://lucene.apache.org/core/old_versioned_docs/versions/3_5_0/fileformats.html#Term
> > Dictionary
> >
> >   Do i need to change the term FST build process? Anybody had done this
> kind
> > of modification before?
> >
> > Thanks,
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
> For additional commands, e-mail: dev-help@lucene.apache.org
>
>

Re: How to extend "TermInfo" ?

Posted by Michael McCandless <lu...@mikemccandless.com>.
It is not easy to add new per-term metadata in 3.x.

But in trunk (to eventually be 4.0)... you can make your own codec and
store additional per-term metadata.

What kind of metadata are you wanting to store...?

Mike McCandless

http://blog.mikemccandless.com

On Mon, Mar 19, 2012 at 2:42 AM, lukai <lu...@gmail.com> wrote:
> Hi, guys:
>   I have needs to add a new data filed in "TermInfo".  refer to
> here:http://lucene.apache.org/core/old_versioned_docs/versions/3_5_0/fileformats.html#Term
> Dictionary
>
>   Do i need to change the term FST build process? Anybody had done this kind
> of modification before?
>
> Thanks,

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org