Google App Indexing is not working on description field but working on title field
Asked Answered
F

1

7

I have gone through this https://mcmap.net/q/1627837/-android-app-indexing-api-description-field. It discusses the use of description field in the App Indexing api. While calling this api I am setting both title and description fields. Below is the sample code

  Thing object = new Thing.Builder()
    .setName(title)
    .setUrl(uri)
    .setDescription(description)
    .build();

return new Action.Builder(Action.TYPE_VIEW)
    .setObject(object)
    .setActionStatus(Action.STATUS_TYPE_COMPLETED)
    .build();

But when I use the google app search and type in a keyword which was there in the title, I am able to see the autocomplete results. But if I type a keyword which was present in description field, I am not able to get the auto complete results. So what should I do to get the content of description field to app index?

And since this is a news reading application. So I am setting description to the first paragraph of the news content. The first paragraph can be as long as 500 characters. Is there any recommendation on the content length which we pass to the description field?

Fiche answered 24/5, 2016 at 9:3 Comment(1)
@Shruti: I have clearly mentioned in my question, that I have gone through this post. Please read out the question carefully. There the user is asking the use of that field. In my case, I am fully aware of its usage. But it is not working as expected. Please remove the duplicate tag from question.Fiche
G
2

I tried an experiment in an attempt to see if the terms in the description make a difference:

1-I put everything, including the description, in the title:

Thing object = new Thing.Builder()
.setName(title + " " + description)
.setUrl(uri)
.build();

I could search for everything in the title and/or description.

2-I did everything per documentation but left the description out:

Thing object = new Thing.Builder()
.setName(title)
.setUrl(uri)
.build();

I could search for everything in the title but terms that were only in the description could not be found in the search results.

3-I did everything per documentation, this time also added the description:

Thing object = new Thing.Builder()
.setName(title)
.setDescription(description)
.setUrl(uri)
.build();

The result was identical to case 2; couldn't find any term that were in the description but not in the title.

4-I did everything per documentation, this time added a dummy but unique description:

Thing object = new Thing.Builder()
.setName(title)
.setDescription("askdf asdfm askdfssdf")
.setUrl(uri)
.build();

Searching for that unique description didn't find the app.

Based on this experiment, I don't think the description is part of the search (or maybe used only in a minor way). My suggestion is, until there is a change, to add the description to the title for app indexing (like case 1 above), if you need the description terms to be indexed too. Now, in fairness, in many cases that might result in an overly broad hit rate. I suspect that might have something to do with the current implementation.

Goodrum answered 6/6, 2016 at 23:33 Comment(1)
Thanks for the detailed explanation.Fiche

© 2022 - 2024 — McMap. All rights reserved.