About the permanentid field
About the permanentid field
|
|
Note
Use the |
The permanentid field contains a value that permanently identifies each item within an organization.
The field value remains the same, even for an item that’s indexed more than once with different sources.
This field allows Coveo Machine Learning (Coveo ML) models to learn user behavior on stable item IDs.
permanentid field value
The method to get the permanentid field value may be different depending on the repository type:
-
For other repository types, such as Google Drive and YouTube, where one item can have more than one URI, the
permanentidfield is typically a hash of a string containing:(repository type identification) + (unique separator) + (source dependent unique item identifier) -
For Salesforce sources, the
permanentidis automatically set by the Salesforce connector.
Taking advantage of the permanentid field
The permanentid field usage should be mostly transparent, but you may need to perform some tasks to fully take advantage of the custom aspects benefits.
-
Standard source types
The introduction and usage of the
permanentidfield is meant to be mostly transparent for standard source types:-
All standard sources automatically include the
permanentidmetadata and field mapping. -
Since April 2017, a JavaScript Search Framework search page automatically detects the existence of the
permanentidfield for each clicked item. It sends this field and its value with each Coveo Analytics event, in thecontentIdKeyandcontentIdValuemetadata fields respectively. The page always sends theurihashfield and its value. -
The Coveo ML models take the
contentIdKeyfield and thecontentIdValuemetadata passed in Coveo Analytics events to identify each item to learn from, using theurihashas a fallback. The transition from theurihashto thepermanentidfield is therefore automatic. Within an index or even a source, items may be identified using either field.The models can map older events, which contain only the
urihashfield, to newer ones with both theurihashandpermanentidfields. This allows each item's click history to be preserved through the transition.NoteFollowing the transition from the
urihashto thepermanentidfield, your users may experience a minor and temporary degradation of Coveo ML Automatic Relevance Tuning (ART) and Content Recommendation (CR) model performance, but only if you push custom Coveo Analytics click events that don’t include both theurihashandpermanentid.
-
-
Custom sources (Push API)
For custom sources populated through the Push API, when the URI isn’t a unique identifier and you want to allow Coveo ML models to learn usage of pushed items, you can:
-
Push metadata that uniquely and permanently identifies each pushed item.
The content of the metadata can be anything such as a URI or a GUID, as long as it’s unique and never changes.
NoteUsing an alphanumeric string of at most 60 characters (without spaces) optimizes index performance. However, you can use any value you want. Using a value that isn’t hashed can help with troubleshooting.
-
About the urihash field
The value of the urihash field for a given item is based on the item's URI value.
The item's URI is hashed to create a standardized urihash value.