# Is it possible to get the forward index table?

**URL:** <https://discuss.elastic.co/t/is-it-possible-to-get-the-forward-index-table/16672>\
**Category:** Elasticsearch\
**Created:** [March 28, 2014, 8:40am UTC](https://discuss.elastic.co/t/is-it-possible-to-get-the-forward-index-table/16672 "2014-03-28T08:40:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eric\_Lu](https://avatars.discourse-cdn.com/v4/letter/e/919ad9/32.png) [@Eric\_Lu](https://discuss.elastic.co/u/Eric_Lu)\
**Post date:** [March 28, 2014, 8:40am UTC](https://discuss.elastic.co/t/is-it-possible-to-get-the-forward-index-table/16672/1 "2014-03-28T08:40:47Z")

</div>

hi,

Our system needs to calculate the TFs(term frequency) of the result of  
search. i.e, we get a set of documents by a "query\_string" search, and we  
want to get the TF of every document.  
As we know, elasticseach provides the inverted index(term----\>documents),  
but it do produce forward index table(document---\>terms) when index a  
document. is it possible to get it?

If it is not possible, we have to manually process the search result to get  
the documents' TF. It actually is what elasticsearch has done before.

Or any suggestions? thank you.

eric

--  
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](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![spinscale](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/spinscale/32/25011_2.png) [@spinscale](https://discuss.elastic.co/u/spinscale)\
**Post date:** [March 31, 2014, 7:56am UTC](https://discuss.elastic.co/t/is-it-possible-to-get-the-forward-index-table/16672/2 "2014-03-31T07:56:37Z")

</div>

Hey,

have you seen the term vectors API, see

> **[Elasticsearch Platform — Find real-time answers at scale](https://www.elastic.co)**
>
> Power insights and outcomes with the Elasticsearch Platform and AI. See into your data and find answers that matter with enterprise solutions designed to help you build, observe, and protect. Try Elasticsearch free today.

However, executing this after every search request might be really slow,  
but better gather your own numbers... also it requires mapping and will  
increase your index size.

--Alex

On Fri, Mar 28, 2014 at 9:40 AM, Eric Lu [lzy3906@gmail.com](mailto:lzy3906@gmail.com) wrote:

> hi,
> 
> Our system needs to calculate the TFs(term frequency) of the result of  
> search. i.e, we get a set of documents by a "query\_string" search, and we  
> want to get the TF of every document.  
> As we know, elasticseach provides the inverted index(term----\>documents),  
> but it do produce forward index table(document---\>terms) when index a  
> document. is it possible to get it?
> 
> If it is not possible, we have to manually process the search result to  
> get the documents' TF. It actually is what elasticsearch has done before.
> 
> Or any suggestions? thank you.
> 
> eric
> 
> --  
> 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](mailto:elasticsearch+unsubscribe@googlegroups.com).  
> To view this discussion on the web visit  
> [https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com)[https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com?utm\_medium=email&utm\_source=footer](https://groups.google.com/d/msgid/elasticsearch/96fac536-22de-4448-a00b-5c0b7660a743%40googlegroups.com?utm_medium=email&utm_source=footer)  
> .  
> For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

--  
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](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/CAGCwEM-RgbdebNjDi5z%2BuoF2zM2De9RK7YDzz%3Dqja2aAc4WFjA%40mail.gmail.com](https://groups.google.com/d/msgid/elasticsearch/CAGCwEM-RgbdebNjDi5z%2BuoF2zM2De9RK7YDzz%3Dqja2aAc4WFjA%40mail.gmail.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 1:39am UTC](https://discuss.elastic.co/t/is-it-possible-to-get-the-forward-index-table/16672/3 "2017-07-06T01:39:29Z")

</div>


