Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

feat: Added a new KeywordMatchMode field to support more keyword matching options feat: Added more DiversificationLevel configuration options #365

Merged
merged 2 commits into from
Sep 15, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/common.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/company.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/company_service.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/completion_service.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/event.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/event_service.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/filters.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/histogram.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/job.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
80 changes: 73 additions & 7 deletions protos/google/cloud/talent/v4/job_service.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -383,7 +383,7 @@ message SearchJobsRequest {
// integer/double value or an expression that can be evaluated to a number.
//
// Parenthesis are supported to adjust calculation precedence. The
// expression must be < 100 characters in length.
// expression must be < 200 characters in length.
//
// The expression is considered invalid for a job if the expression
// references custom attributes that are not populated on the job or if the
Expand Down Expand Up @@ -420,6 +420,11 @@ message SearchJobsRequest {
// clustered so that only one representative job of the cluster is
// displayed to the job seeker higher up in the results, with the other jobs
// being displayed lower down in the results.
//
// If you are using pageToken to page through the result set,
// latency might be lower but we can't guarantee that all results are
// returned. If you are using page offset, latency might be higher but all
// results are returned.
enum DiversificationLevel {
// The diversification level isn't specified.
DIVERSIFICATION_LEVEL_UNSPECIFIED = 0;
Expand All @@ -431,11 +436,57 @@ message SearchJobsRequest {

// Default diversifying behavior. The result list is ordered so that
// highly similar results are pushed to the end of the last page of search
// results. If you are using pageToken to page through the result set,
// latency might be lower but we can't guarantee that all results are
// returned. If you are using page offset, latency might be higher but all
// results are returned.
// results.
SIMPLE = 2;

// Only one job from the same company will be shown at once, other jobs
// under same company are pushed to the end of the last page of search
// result.
ONE_PER_COMPANY = 3;

// Similar to ONE_PER_COMPANY, but it allows at most two jobs in the
// same company to be shown at once, the other jobs under same company are
// pushed to the end of the last page of search result.
TWO_PER_COMPANY = 4;

// The result list is ordered such that somewhat similar results are pushed
// to the end of the last page of the search results. This option is
// recommended if SIMPLE diversification does not diversify enough.
DIVERSIFY_BY_LOOSER_SIMILARITY = 5;
}

// Controls what keyword matching behavior the search has. When keyword
// matching is enabled, a keyword match returns jobs that may not match given
// category filters when there are matching keywords. For example, for the
// query "program manager" with KeywordMatchMode set to KEYWORD_MATCH_ALL, a
// job posting with the title "software developer," which doesn't fall into
// "program manager" ontology, and "program manager" appearing in its
// description will be surfaced.
//
// For queries like "cloud" that don't contain title or
// location specific ontology, jobs with "cloud" keyword matches are returned
// regardless of this enum's value.
//
// Use [Company.keyword_searchable_job_custom_attributes][google.cloud.talent.v4.Company.keyword_searchable_job_custom_attributes] if
// company-specific globally matched custom field/attribute string values are
// needed. Enabling keyword match improves recall of subsequent search
// requests.
enum KeywordMatchMode {
// The keyword match option isn't specified. Defaults to
// [KeywordMatchMode.KEYWORD_MATCH_ALL][google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode.KEYWORD_MATCH_ALL] behavior.
KEYWORD_MATCH_MODE_UNSPECIFIED = 0;

// Disables keyword matching.
KEYWORD_MATCH_DISABLED = 1;

// Enable keyword matching over [Job.title][google.cloud.talent.v4.Job.title],
// [Job.description][google.cloud.talent.v4.Job.description], [Job.company_display_name][google.cloud.talent.v4.Job.company_display_name], [Job.addresses][google.cloud.talent.v4.Job.addresses],
// [Job.qualifications][google.cloud.talent.v4.Job.qualifications], and keyword searchable [Job.custom_attributes][google.cloud.talent.v4.Job.custom_attributes]
// fields.
KEYWORD_MATCH_ALL = 2;

// Only enable keyword matching over [Job.title][google.cloud.talent.v4.Job.title].
KEYWORD_MATCH_TITLE_ONLY = 3;
}

// Required. The resource name of the tenant to search within.
Expand Down Expand Up @@ -658,6 +709,14 @@ message SearchJobsRequest {
// score (determined by API algorithm).
CustomRankingInfo custom_ranking_info = 14;

// This field is deprecated. Please use
// [SearchJobsRequest.keyword_match_mode][google.cloud.talent.v4.SearchJobsRequest.keyword_match_mode] going forward.
//
// To migrate, disable_keyword_match set to false maps to
// [KeywordMatchMode.KEYWORD_MATCH_ALL][google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode.KEYWORD_MATCH_ALL], and disable_keyword_match set to
// true maps to [KeywordMatchMode.KEYWORD_MATCH_DISABLED][google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode.KEYWORD_MATCH_DISABLED]. If
// [SearchJobsRequest.keyword_match_mode][google.cloud.talent.v4.SearchJobsRequest.keyword_match_mode] is set, this field is ignored.
//
// Controls whether to disable exact keyword match on [Job.title][google.cloud.talent.v4.Job.title],
// [Job.description][google.cloud.talent.v4.Job.description], [Job.company_display_name][google.cloud.talent.v4.Job.company_display_name], [Job.addresses][google.cloud.talent.v4.Job.addresses],
// [Job.qualifications][google.cloud.talent.v4.Job.qualifications]. When disable keyword match is turned off, a
Expand All @@ -677,7 +736,14 @@ message SearchJobsRequest {
// requests.
//
// Defaults to false.
bool disable_keyword_match = 16;
bool disable_keyword_match = 16 [deprecated = true];

// Controls what keyword match options to use. If both keyword_match_mode and
// disable_keyword_match are set, keyword_match_mode will take precedence.
//
// Defaults to [KeywordMatchMode.KEYWORD_MATCH_ALL][google.cloud.talent.v4.SearchJobsRequest.KeywordMatchMode.KEYWORD_MATCH_ALL] if no value
// is specified.
KeywordMatchMode keyword_match_mode = 18;
}

// Response for SearchJob method.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/tenant.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion protos/google/cloud/talent/v4/tenant_service.proto
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2020 Google LLC
// Copyright 2021 Google LLC
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down
19 changes: 18 additions & 1 deletion protos/protos.d.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading