dataqna

package
v0.0.0-...-6edceaf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 14, 2021 License: Apache-2.0 Imports: 14 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	AnnotatedString_SemanticMarkupType_name = map[int32]string{
		0: "MARKUP_TYPE_UNSPECIFIED",
		1: "METRIC",
		2: "DIMENSION",
		3: "FILTER",
		4: "UNUSED",
		5: "BLOCKED",
		6: "ROW",
	}
	AnnotatedString_SemanticMarkupType_value = map[string]int32{
		"MARKUP_TYPE_UNSPECIFIED": 0,
		"METRIC":                  1,
		"DIMENSION":               2,
		"FILTER":                  3,
		"UNUSED":                  4,
		"BLOCKED":                 5,
		"ROW":                     6,
	}
)

Enum value maps for AnnotatedString_SemanticMarkupType.

View Source
var (
	SuggestionType_name = map[int32]string{
		0: "SUGGESTION_TYPE_UNSPECIFIED",
		1: "ENTITY",
		2: "TEMPLATE",
	}
	SuggestionType_value = map[string]int32{
		"SUGGESTION_TYPE_UNSPECIFIED": 0,
		"ENTITY":                      1,
		"TEMPLATE":                    2,
	}
)

Enum value maps for SuggestionType.

View Source
var (
	InterpretEntity_name = map[int32]string{
		0: "INTERPRET_ENTITY_UNSPECIFIED",
		1: "DIMENSION",
		2: "METRIC",
	}
	InterpretEntity_value = map[string]int32{
		"INTERPRET_ENTITY_UNSPECIFIED": 0,
		"DIMENSION":                    1,
		"METRIC":                       2,
	}
)

Enum value maps for InterpretEntity.

View Source
var (
	InterpretError_InterpretErrorCode_name = map[int32]string{
		0: "INTERPRET_ERROR_CODE_UNSPECIFIED",
		1: "INVALID_QUERY",
		2: "FAILED_TO_UNDERSTAND",
		3: "FAILED_TO_ANSWER",
	}
	InterpretError_InterpretErrorCode_value = map[string]int32{
		"INTERPRET_ERROR_CODE_UNSPECIFIED": 0,
		"INVALID_QUERY":                    1,
		"FAILED_TO_UNDERSTAND":             2,
		"FAILED_TO_ANSWER":                 3,
	}
)

Enum value maps for InterpretError_InterpretErrorCode.

View Source
var (
	ExecutionInfo_JobExecutionState_name = map[int32]string{
		0: "JOB_EXECUTION_STATE_UNSPECIFIED",
		1: "NOT_EXECUTED",
		2: "RUNNING",
		3: "SUCCEEDED",
		4: "FAILED",
	}
	ExecutionInfo_JobExecutionState_value = map[string]int32{
		"JOB_EXECUTION_STATE_UNSPECIFIED": 0,
		"NOT_EXECUTED":                    1,
		"RUNNING":                         2,
		"SUCCEEDED":                       3,
		"FAILED":                          4,
	}
)

Enum value maps for ExecutionInfo_JobExecutionState.

View Source
var (
	InterpretationStructure_VisualizationType_name = map[int32]string{
		0:  "VISUALIZATION_TYPE_UNSPECIFIED",
		1:  "TABLE",
		2:  "BAR_CHART",
		3:  "COLUMN_CHART",
		4:  "TIMELINE",
		5:  "SCATTER_PLOT",
		6:  "PIE_CHART",
		7:  "LINE_CHART",
		8:  "AREA_CHART",
		9:  "COMBO_CHART",
		10: "HISTOGRAM",
		11: "GENERIC_CHART",
		12: "CHART_NOT_UNDERSTOOD",
	}
	InterpretationStructure_VisualizationType_value = map[string]int32{
		"VISUALIZATION_TYPE_UNSPECIFIED": 0,
		"TABLE":                          1,
		"BAR_CHART":                      2,
		"COLUMN_CHART":                   3,
		"TIMELINE":                       4,
		"SCATTER_PLOT":                   5,
		"PIE_CHART":                      6,
		"LINE_CHART":                     7,
		"AREA_CHART":                     8,
		"COMBO_CHART":                    9,
		"HISTOGRAM":                      10,
		"GENERIC_CHART":                  11,
		"CHART_NOT_UNDERSTOOD":           12,
	}
)

Enum value maps for InterpretationStructure_VisualizationType.

View Source
var (
	UserFeedback_UserFeedbackRating_name = map[int32]string{
		0: "USER_FEEDBACK_RATING_UNSPECIFIED",
		1: "POSITIVE",
		2: "NEGATIVE",
	}
	UserFeedback_UserFeedbackRating_value = map[string]int32{
		"USER_FEEDBACK_RATING_UNSPECIFIED": 0,
		"POSITIVE":                         1,
		"NEGATIVE":                         2,
	}
)

Enum value maps for UserFeedback_UserFeedbackRating.

View Source
var File_google_cloud_dataqna_v1alpha_annotated_string_proto protoreflect.FileDescriptor
View Source
var File_google_cloud_dataqna_v1alpha_auto_suggestion_service_proto protoreflect.FileDescriptor
View Source
var File_google_cloud_dataqna_v1alpha_question_proto protoreflect.FileDescriptor
View Source
var File_google_cloud_dataqna_v1alpha_question_service_proto protoreflect.FileDescriptor
View Source
var File_google_cloud_dataqna_v1alpha_user_feedback_proto protoreflect.FileDescriptor

Functions

func RegisterAutoSuggestionServiceServer

func RegisterAutoSuggestionServiceServer(s *grpc.Server, srv AutoSuggestionServiceServer)

func RegisterQuestionServiceServer

func RegisterQuestionServiceServer(s *grpc.Server, srv QuestionServiceServer)

Types

type AnnotatedString

type AnnotatedString struct {

	// Text version of the string.
	TextFormatted string `protobuf:"bytes,1,opt,name=text_formatted,json=textFormatted,proto3" json:"text_formatted,omitempty"`
	// HTML version of the string annotation.
	HtmlFormatted string `protobuf:"bytes,2,opt,name=html_formatted,json=htmlFormatted,proto3" json:"html_formatted,omitempty"`
	// Semantic version of the string annotation.
	Markups []*AnnotatedString_SemanticMarkup `protobuf:"bytes,3,rep,name=markups,proto3" json:"markups,omitempty"`
	// contains filtered or unexported fields
}

Describes string annotation from both semantic and formatting perspectives. Example:

User Query:

top countries by population in Africa

0   4         14 17         28 31    37

Table Data:

+ "country" - dimension + "population" - metric + "Africa" - value in the "continent" column

text_formatted = `"top countries by population in Africa"`

html_formatted =

`"top <b>countries</b> by <b>population</b> in <i>Africa</i>"`

``` markups = [

{DIMENSION, 4, 12}, // 'countries'
{METRIC, 17, 26}, // 'population'
{FILTER, 31, 36}  // 'Africa'

] ```

Note that html formattings for 'DIMENSION' and 'METRIC' are the same, while semantic markups are different.

func (*AnnotatedString) Descriptor deprecated

func (*AnnotatedString) Descriptor() ([]byte, []int)

Deprecated: Use AnnotatedString.ProtoReflect.Descriptor instead.

func (*AnnotatedString) GetHtmlFormatted

func (x *AnnotatedString) GetHtmlFormatted() string

func (*AnnotatedString) GetMarkups

func (*AnnotatedString) GetTextFormatted

func (x *AnnotatedString) GetTextFormatted() string

func (*AnnotatedString) ProtoMessage

func (*AnnotatedString) ProtoMessage()

func (*AnnotatedString) ProtoReflect

func (x *AnnotatedString) ProtoReflect() protoreflect.Message

func (*AnnotatedString) Reset

func (x *AnnotatedString) Reset()

func (*AnnotatedString) String

func (x *AnnotatedString) String() string

type AnnotatedString_SemanticMarkup

type AnnotatedString_SemanticMarkup struct {

	// The semantic type of the markup substring.
	Type AnnotatedString_SemanticMarkupType `` /* 131-byte string literal not displayed */
	// Unicode character index of the query.
	StartCharIndex int32 `protobuf:"varint,2,opt,name=start_char_index,json=startCharIndex,proto3" json:"start_char_index,omitempty"`
	// The length (number of unicode characters) of the markup substring.
	Length int32 `protobuf:"varint,3,opt,name=length,proto3" json:"length,omitempty"`
	// contains filtered or unexported fields
}

Semantic markup denotes a substring (by index and length) with markup information.

func (*AnnotatedString_SemanticMarkup) Descriptor deprecated

func (*AnnotatedString_SemanticMarkup) Descriptor() ([]byte, []int)

Deprecated: Use AnnotatedString_SemanticMarkup.ProtoReflect.Descriptor instead.

func (*AnnotatedString_SemanticMarkup) GetLength

func (x *AnnotatedString_SemanticMarkup) GetLength() int32

func (*AnnotatedString_SemanticMarkup) GetStartCharIndex

func (x *AnnotatedString_SemanticMarkup) GetStartCharIndex() int32

func (*AnnotatedString_SemanticMarkup) GetType

func (*AnnotatedString_SemanticMarkup) ProtoMessage

func (*AnnotatedString_SemanticMarkup) ProtoMessage()

func (*AnnotatedString_SemanticMarkup) ProtoReflect

func (*AnnotatedString_SemanticMarkup) Reset

func (x *AnnotatedString_SemanticMarkup) Reset()

func (*AnnotatedString_SemanticMarkup) String

type AnnotatedString_SemanticMarkupType

type AnnotatedString_SemanticMarkupType int32

Semantic markup types.

const (
	// No markup type was specified.
	AnnotatedString_MARKUP_TYPE_UNSPECIFIED AnnotatedString_SemanticMarkupType = 0
	// Markup for a substring denoting a metric.
	AnnotatedString_METRIC AnnotatedString_SemanticMarkupType = 1
	// Markup for a substring denoting a dimension.
	AnnotatedString_DIMENSION AnnotatedString_SemanticMarkupType = 2
	// Markup for a substring denoting a filter.
	AnnotatedString_FILTER AnnotatedString_SemanticMarkupType = 3
	// Markup for an unused substring.
	AnnotatedString_UNUSED AnnotatedString_SemanticMarkupType = 4
	// Markup for a substring containing blocked phrases.
	AnnotatedString_BLOCKED AnnotatedString_SemanticMarkupType = 5
	// Markup for a substring that contains terms for row.
	AnnotatedString_ROW AnnotatedString_SemanticMarkupType = 6
)

func (AnnotatedString_SemanticMarkupType) Descriptor

func (AnnotatedString_SemanticMarkupType) Enum

func (AnnotatedString_SemanticMarkupType) EnumDescriptor deprecated

func (AnnotatedString_SemanticMarkupType) EnumDescriptor() ([]byte, []int)

Deprecated: Use AnnotatedString_SemanticMarkupType.Descriptor instead.

func (AnnotatedString_SemanticMarkupType) Number

func (AnnotatedString_SemanticMarkupType) String

func (AnnotatedString_SemanticMarkupType) Type

type AutoSuggestionServiceClient

type AutoSuggestionServiceClient interface {
	// Gets a list of suggestions based on a prefix string.
	// AutoSuggestion tolerance should be less than 1 second.
	SuggestQueries(ctx context.Context, in *SuggestQueriesRequest, opts ...grpc.CallOption) (*SuggestQueriesResponse, error)
}

AutoSuggestionServiceClient is the client API for AutoSuggestionService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

type AutoSuggestionServiceServer

type AutoSuggestionServiceServer interface {
	// Gets a list of suggestions based on a prefix string.
	// AutoSuggestion tolerance should be less than 1 second.
	SuggestQueries(context.Context, *SuggestQueriesRequest) (*SuggestQueriesResponse, error)
}

AutoSuggestionServiceServer is the server API for AutoSuggestionService service.

type BigQueryJob

type BigQueryJob struct {

	// The job ID.
	JobId string `protobuf:"bytes,1,opt,name=job_id,json=jobId,proto3" json:"job_id,omitempty"`
	// The project ID of the job.
	ProjectId string `protobuf:"bytes,2,opt,name=project_id,json=projectId,proto3" json:"project_id,omitempty"`
	// The location where the job is running.
	Location string `protobuf:"bytes,3,opt,name=location,proto3" json:"location,omitempty"`
	// contains filtered or unexported fields
}

BigQuery job information. This can be used to query the BigQuery API and retrieve the current job's status (using [jobs.get](https://cloud.google.com/bigquery/docs/reference/rest/v2/jobs/get)).

func (*BigQueryJob) Descriptor deprecated

func (*BigQueryJob) Descriptor() ([]byte, []int)

Deprecated: Use BigQueryJob.ProtoReflect.Descriptor instead.

func (*BigQueryJob) GetJobId

func (x *BigQueryJob) GetJobId() string

func (*BigQueryJob) GetLocation

func (x *BigQueryJob) GetLocation() string

func (*BigQueryJob) GetProjectId

func (x *BigQueryJob) GetProjectId() string

func (*BigQueryJob) ProtoMessage

func (*BigQueryJob) ProtoMessage()

func (*BigQueryJob) ProtoReflect

func (x *BigQueryJob) ProtoReflect() protoreflect.Message

func (*BigQueryJob) Reset

func (x *BigQueryJob) Reset()

func (*BigQueryJob) String

func (x *BigQueryJob) String() string

type CreateQuestionRequest

type CreateQuestionRequest struct {

	// Required. The name of the project this data source reference belongs to.
	// Example: `projects/foo/locations/bar`
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// Required. The question to create.
	Question *Question `protobuf:"bytes,2,opt,name=question,proto3" json:"question,omitempty"`
	// contains filtered or unexported fields
}

Request to create a question resource.

func (*CreateQuestionRequest) Descriptor deprecated

func (*CreateQuestionRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateQuestionRequest.ProtoReflect.Descriptor instead.

func (*CreateQuestionRequest) GetParent

func (x *CreateQuestionRequest) GetParent() string

func (*CreateQuestionRequest) GetQuestion

func (x *CreateQuestionRequest) GetQuestion() *Question

func (*CreateQuestionRequest) ProtoMessage

func (*CreateQuestionRequest) ProtoMessage()

func (*CreateQuestionRequest) ProtoReflect

func (x *CreateQuestionRequest) ProtoReflect() protoreflect.Message

func (*CreateQuestionRequest) Reset

func (x *CreateQuestionRequest) Reset()

func (*CreateQuestionRequest) String

func (x *CreateQuestionRequest) String() string

type DataQuery

type DataQuery struct {

	// The generated SQL query to be sent to the backend.
	Sql string `protobuf:"bytes,1,opt,name=sql,proto3" json:"sql,omitempty"`
	// contains filtered or unexported fields
}

Representation of the data query for the backend. This is provided for informational purposes only. Clients should not use it to send it to the backend directly, but rather use the `execute` RPC to trigger the execution. Using the `execute` RPC is needed in order to track the state of a question and report on it correctly to the data administrators.

func (*DataQuery) Descriptor deprecated

func (*DataQuery) Descriptor() ([]byte, []int)

Deprecated: Use DataQuery.ProtoReflect.Descriptor instead.

func (*DataQuery) GetSql

func (x *DataQuery) GetSql() string

func (*DataQuery) ProtoMessage

func (*DataQuery) ProtoMessage()

func (*DataQuery) ProtoReflect

func (x *DataQuery) ProtoReflect() protoreflect.Message

func (*DataQuery) Reset

func (x *DataQuery) Reset()

func (*DataQuery) String

func (x *DataQuery) String() string

type DebugFlags

type DebugFlags struct {

	// Whether to include the original VAQuery.
	IncludeVaQuery bool `protobuf:"varint,1,opt,name=include_va_query,json=includeVaQuery,proto3" json:"include_va_query,omitempty"`
	// Whether to include the original nested VAQuery.
	IncludeNestedVaQuery bool `` /* 126-byte string literal not displayed */
	// Whether to include the original human interpretation strings generated
	// by Analyza.
	IncludeHumanInterpretation bool `` /* 142-byte string literal not displayed */
	// Whether to include the Aqua debug response.
	IncludeAquaDebugResponse bool `` /* 138-byte string literal not displayed */
	// The time in milliseconds from Unix epoch to be used
	// to process the query. This is useful for testing
	// the queries at different time period.
	// If not set or time_override <= 0, then the current
	// time is used.
	TimeOverride int64 `protobuf:"varint,5,opt,name=time_override,json=timeOverride,proto3" json:"time_override,omitempty"`
	// Set to true if request is initiated by an internal Google user.
	IsInternalGoogleUser bool `` /* 126-byte string literal not displayed */
	// Determines whether cache needs to be ignored. If set to
	// true, cache won't be queried and updated.
	IgnoreCache bool `protobuf:"varint,7,opt,name=ignore_cache,json=ignoreCache,proto3" json:"ignore_cache,omitempty"`
	// Whether to include the request/response pair from the call to the
	// EntityIndex for SearchEntities.
	IncludeSearchEntitiesRpc bool `` /* 138-byte string literal not displayed */
	// Whether to include the request/response pair from the call to the
	// Annotations service for ListColumnAnnotations.
	IncludeListColumnAnnotationsRpc bool `` /* 161-byte string literal not displayed */
	// Whether to include the entity list passed to Analyza.
	IncludeVirtualAnalystEntities bool `` /* 154-byte string literal not displayed */
	// Whether to include the table list.
	IncludeTableList bool `protobuf:"varint,11,opt,name=include_table_list,json=includeTableList,proto3" json:"include_table_list,omitempty"`
	// Whether to include the domain list.
	IncludeDomainList bool `protobuf:"varint,12,opt,name=include_domain_list,json=includeDomainList,proto3" json:"include_domain_list,omitempty"`
	// contains filtered or unexported fields
}

Configuriation of debug flags.

func (*DebugFlags) Descriptor deprecated

func (*DebugFlags) Descriptor() ([]byte, []int)

Deprecated: Use DebugFlags.ProtoReflect.Descriptor instead.

func (*DebugFlags) GetIgnoreCache

func (x *DebugFlags) GetIgnoreCache() bool

func (*DebugFlags) GetIncludeAquaDebugResponse

func (x *DebugFlags) GetIncludeAquaDebugResponse() bool

func (*DebugFlags) GetIncludeDomainList

func (x *DebugFlags) GetIncludeDomainList() bool

func (*DebugFlags) GetIncludeHumanInterpretation

func (x *DebugFlags) GetIncludeHumanInterpretation() bool

func (*DebugFlags) GetIncludeListColumnAnnotationsRpc

func (x *DebugFlags) GetIncludeListColumnAnnotationsRpc() bool

func (*DebugFlags) GetIncludeNestedVaQuery

func (x *DebugFlags) GetIncludeNestedVaQuery() bool

func (*DebugFlags) GetIncludeSearchEntitiesRpc

func (x *DebugFlags) GetIncludeSearchEntitiesRpc() bool

func (*DebugFlags) GetIncludeTableList

func (x *DebugFlags) GetIncludeTableList() bool

func (*DebugFlags) GetIncludeVaQuery

func (x *DebugFlags) GetIncludeVaQuery() bool

func (*DebugFlags) GetIncludeVirtualAnalystEntities

func (x *DebugFlags) GetIncludeVirtualAnalystEntities() bool

func (*DebugFlags) GetIsInternalGoogleUser

func (x *DebugFlags) GetIsInternalGoogleUser() bool

func (*DebugFlags) GetTimeOverride

func (x *DebugFlags) GetTimeOverride() int64

func (*DebugFlags) ProtoMessage

func (*DebugFlags) ProtoMessage()

func (*DebugFlags) ProtoReflect

func (x *DebugFlags) ProtoReflect() protoreflect.Message

func (*DebugFlags) Reset

func (x *DebugFlags) Reset()

func (*DebugFlags) String

func (x *DebugFlags) String() string

type ExecuteQuestionRequest

type ExecuteQuestionRequest struct {

	// Required. The unique identifier for the question.
	// Example: `projects/foo/locations/bar/questions/1234`
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Required. Index of the interpretation to execute.
	InterpretationIndex int32 `protobuf:"varint,2,opt,name=interpretation_index,json=interpretationIndex,proto3" json:"interpretation_index,omitempty"`
	// contains filtered or unexported fields
}

Request to execute an interpretation.

func (*ExecuteQuestionRequest) Descriptor deprecated

func (*ExecuteQuestionRequest) Descriptor() ([]byte, []int)

Deprecated: Use ExecuteQuestionRequest.ProtoReflect.Descriptor instead.

func (*ExecuteQuestionRequest) GetInterpretationIndex

func (x *ExecuteQuestionRequest) GetInterpretationIndex() int32

func (*ExecuteQuestionRequest) GetName

func (x *ExecuteQuestionRequest) GetName() string

func (*ExecuteQuestionRequest) ProtoMessage

func (*ExecuteQuestionRequest) ProtoMessage()

func (*ExecuteQuestionRequest) ProtoReflect

func (x *ExecuteQuestionRequest) ProtoReflect() protoreflect.Message

func (*ExecuteQuestionRequest) Reset

func (x *ExecuteQuestionRequest) Reset()

func (*ExecuteQuestionRequest) String

func (x *ExecuteQuestionRequest) String() string

type ExecutionInfo

type ExecutionInfo struct {

	// Status returned by the backend when the job was created.
	JobCreationStatus *status.Status `protobuf:"bytes,1,opt,name=job_creation_status,json=jobCreationStatus,proto3" json:"job_creation_status,omitempty"`
	// Status of the job execution.
	JobExecutionState ExecutionInfo_JobExecutionState `` /* 181-byte string literal not displayed */
	// Time when the execution was triggered.
	CreateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
	// BigQuery job information.
	// Future versions will have different backends. Hence, clients must make sure
	// they can handle it when this field is not populated.
	BigqueryJob *BigQueryJob `protobuf:"bytes,4,opt,name=bigquery_job,json=bigqueryJob,proto3" json:"bigquery_job,omitempty"`
	// contains filtered or unexported fields
}

Information about the backend status (such as BigQuery) of the execution.

func (*ExecutionInfo) Descriptor deprecated

func (*ExecutionInfo) Descriptor() ([]byte, []int)

Deprecated: Use ExecutionInfo.ProtoReflect.Descriptor instead.

func (*ExecutionInfo) GetBigqueryJob

func (x *ExecutionInfo) GetBigqueryJob() *BigQueryJob

func (*ExecutionInfo) GetCreateTime

func (x *ExecutionInfo) GetCreateTime() *timestamppb.Timestamp

func (*ExecutionInfo) GetJobCreationStatus

func (x *ExecutionInfo) GetJobCreationStatus() *status.Status

func (*ExecutionInfo) GetJobExecutionState

func (x *ExecutionInfo) GetJobExecutionState() ExecutionInfo_JobExecutionState

func (*ExecutionInfo) ProtoMessage

func (*ExecutionInfo) ProtoMessage()

func (*ExecutionInfo) ProtoReflect

func (x *ExecutionInfo) ProtoReflect() protoreflect.Message

func (*ExecutionInfo) Reset

func (x *ExecutionInfo) Reset()

func (*ExecutionInfo) String

func (x *ExecutionInfo) String() string

type ExecutionInfo_JobExecutionState

type ExecutionInfo_JobExecutionState int32

Enum of possible job execution statuses.

const (
	// No job execution was specified.
	ExecutionInfo_JOB_EXECUTION_STATE_UNSPECIFIED ExecutionInfo_JobExecutionState = 0
	// No job execution was requested, yet.
	ExecutionInfo_NOT_EXECUTED ExecutionInfo_JobExecutionState = 1
	// The job is running.
	ExecutionInfo_RUNNING ExecutionInfo_JobExecutionState = 2
	// The job completed successfully.
	ExecutionInfo_SUCCEEDED ExecutionInfo_JobExecutionState = 3
	// The job completed unsuccessfully.
	ExecutionInfo_FAILED ExecutionInfo_JobExecutionState = 4
)

func (ExecutionInfo_JobExecutionState) Descriptor

func (ExecutionInfo_JobExecutionState) Enum

func (ExecutionInfo_JobExecutionState) EnumDescriptor deprecated

func (ExecutionInfo_JobExecutionState) EnumDescriptor() ([]byte, []int)

Deprecated: Use ExecutionInfo_JobExecutionState.Descriptor instead.

func (ExecutionInfo_JobExecutionState) Number

func (ExecutionInfo_JobExecutionState) String

func (ExecutionInfo_JobExecutionState) Type

type GetQuestionRequest

type GetQuestionRequest struct {

	// Required. The unique identifier for the question.
	// Example: `projects/foo/locations/bar/questions/1234`
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// The list of fields to be retrieved.
	ReadMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=read_mask,json=readMask,proto3" json:"read_mask,omitempty"`
	// contains filtered or unexported fields
}

A request to get a previously created question.

func (*GetQuestionRequest) Descriptor deprecated

func (*GetQuestionRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetQuestionRequest.ProtoReflect.Descriptor instead.

func (*GetQuestionRequest) GetName

func (x *GetQuestionRequest) GetName() string

func (*GetQuestionRequest) GetReadMask

func (x *GetQuestionRequest) GetReadMask() *fieldmaskpb.FieldMask

func (*GetQuestionRequest) ProtoMessage

func (*GetQuestionRequest) ProtoMessage()

func (*GetQuestionRequest) ProtoReflect

func (x *GetQuestionRequest) ProtoReflect() protoreflect.Message

func (*GetQuestionRequest) Reset

func (x *GetQuestionRequest) Reset()

func (*GetQuestionRequest) String

func (x *GetQuestionRequest) String() string

type GetUserFeedbackRequest

type GetUserFeedbackRequest struct {

	// Required. The unique identifier for the user feedback.
	// User feedback is a singleton resource on a Question.
	// Example: `projects/foo/locations/bar/questions/1234/userFeedback`
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

Request to get user feedback.

func (*GetUserFeedbackRequest) Descriptor deprecated

func (*GetUserFeedbackRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetUserFeedbackRequest.ProtoReflect.Descriptor instead.

func (*GetUserFeedbackRequest) GetName

func (x *GetUserFeedbackRequest) GetName() string

func (*GetUserFeedbackRequest) ProtoMessage

func (*GetUserFeedbackRequest) ProtoMessage()

func (*GetUserFeedbackRequest) ProtoReflect

func (x *GetUserFeedbackRequest) ProtoReflect() protoreflect.Message

func (*GetUserFeedbackRequest) Reset

func (x *GetUserFeedbackRequest) Reset()

func (*GetUserFeedbackRequest) String

func (x *GetUserFeedbackRequest) String() string

type HumanReadable

type HumanReadable struct {

	// Generated query explaining the interpretation.
	GeneratedInterpretation *AnnotatedString `` /* 130-byte string literal not displayed */
	// Annotations on the original query.
	OriginalQuestion *AnnotatedString `protobuf:"bytes,2,opt,name=original_question,json=originalQuestion,proto3" json:"original_question,omitempty"`
	// contains filtered or unexported fields
}

Human readable interpretation.

func (*HumanReadable) Descriptor deprecated

func (*HumanReadable) Descriptor() ([]byte, []int)

Deprecated: Use HumanReadable.ProtoReflect.Descriptor instead.

func (*HumanReadable) GetGeneratedInterpretation

func (x *HumanReadable) GetGeneratedInterpretation() *AnnotatedString

func (*HumanReadable) GetOriginalQuestion

func (x *HumanReadable) GetOriginalQuestion() *AnnotatedString

func (*HumanReadable) ProtoMessage

func (*HumanReadable) ProtoMessage()

func (*HumanReadable) ProtoReflect

func (x *HumanReadable) ProtoReflect() protoreflect.Message

func (*HumanReadable) Reset

func (x *HumanReadable) Reset()

func (*HumanReadable) String

func (x *HumanReadable) String() string

type InterpretEntity

type InterpretEntity int32

Query entities of an interpretation.

const (
	// No interpret entity was specified.
	InterpretEntity_INTERPRET_ENTITY_UNSPECIFIED InterpretEntity = 0
	// A dimenstion entity.
	InterpretEntity_DIMENSION InterpretEntity = 1
	// A metric entity.
	InterpretEntity_METRIC InterpretEntity = 2
)

func (InterpretEntity) Descriptor

func (InterpretEntity) Enum

func (x InterpretEntity) Enum() *InterpretEntity

func (InterpretEntity) EnumDescriptor deprecated

func (InterpretEntity) EnumDescriptor() ([]byte, []int)

Deprecated: Use InterpretEntity.Descriptor instead.

func (InterpretEntity) Number

func (InterpretEntity) String

func (x InterpretEntity) String() string

func (InterpretEntity) Type

type InterpretError

type InterpretError struct {

	// Error message explaining why this question could not be interpreted.
	Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	// The code for the error category why the interpretation failed.
	Code InterpretError_InterpretErrorCode `` /* 130-byte string literal not displayed */
	// Details on interpretation failure.
	Details *InterpretError_InterpretErrorDetails `protobuf:"bytes,3,opt,name=details,proto3" json:"details,omitempty"`
	// contains filtered or unexported fields
}

Details on the failure to interpret the question.

func (*InterpretError) Descriptor deprecated

func (*InterpretError) Descriptor() ([]byte, []int)

Deprecated: Use InterpretError.ProtoReflect.Descriptor instead.

func (*InterpretError) GetCode

func (*InterpretError) GetDetails

func (*InterpretError) GetMessage

func (x *InterpretError) GetMessage() string

func (*InterpretError) ProtoMessage

func (*InterpretError) ProtoMessage()

func (*InterpretError) ProtoReflect

func (x *InterpretError) ProtoReflect() protoreflect.Message

func (*InterpretError) Reset

func (x *InterpretError) Reset()

func (*InterpretError) String

func (x *InterpretError) String() string

type InterpretError_InterpretAmbiguityDetails

type InterpretError_InterpretAmbiguityDetails struct {
	// contains filtered or unexported fields
}

Details about a query that was too ambiguous. Currently, the message has no fields and its presence signals that there was ambiguity.

func (*InterpretError_InterpretAmbiguityDetails) Descriptor deprecated

func (*InterpretError_InterpretAmbiguityDetails) Descriptor() ([]byte, []int)

Deprecated: Use InterpretError_InterpretAmbiguityDetails.ProtoReflect.Descriptor instead.

func (*InterpretError_InterpretAmbiguityDetails) ProtoMessage

func (*InterpretError_InterpretAmbiguityDetails) ProtoReflect

func (*InterpretError_InterpretAmbiguityDetails) Reset

func (*InterpretError_InterpretAmbiguityDetails) String

type InterpretError_InterpretErrorCode

type InterpretError_InterpretErrorCode int32

The interpret error code provides an error category why the interpretation failed.

const (
	// No interpret error code was specified.
	InterpretError_INTERPRET_ERROR_CODE_UNSPECIFIED InterpretError_InterpretErrorCode = 0
	// The query is not valid.
	InterpretError_INVALID_QUERY InterpretError_InterpretErrorCode = 1
	// The interpreter failed to understand the question. For example, because
	// it was too ambiguous.
	InterpretError_FAILED_TO_UNDERSTAND InterpretError_InterpretErrorCode = 2
	// The interpreter could understand the question, but was not able to arrive
	// at an answer. For example, because a requested operation is not
	// supported.
	InterpretError_FAILED_TO_ANSWER InterpretError_InterpretErrorCode = 3
)

func (InterpretError_InterpretErrorCode) Descriptor

func (InterpretError_InterpretErrorCode) Enum

func (InterpretError_InterpretErrorCode) EnumDescriptor deprecated

func (InterpretError_InterpretErrorCode) EnumDescriptor() ([]byte, []int)

Deprecated: Use InterpretError_InterpretErrorCode.Descriptor instead.

func (InterpretError_InterpretErrorCode) Number

func (InterpretError_InterpretErrorCode) String

func (InterpretError_InterpretErrorCode) Type

type InterpretError_InterpretErrorDetails

type InterpretError_InterpretErrorDetails struct {

	// Populated if parts of the query are unsupported.
	UnsupportedDetails *InterpretError_InterpretUnsupportedDetails `protobuf:"bytes,1,opt,name=unsupported_details,json=unsupportedDetails,proto3" json:"unsupported_details,omitempty"`
	// Populated if the query is incomplete.
	IncompleteQueryDetails *InterpretError_InterpretIncompleteQueryDetails `` /* 129-byte string literal not displayed */
	// Populated if the query was too ambiguous.
	AmbiguityDetails *InterpretError_InterpretAmbiguityDetails `protobuf:"bytes,3,opt,name=ambiguity_details,json=ambiguityDetails,proto3" json:"ambiguity_details,omitempty"`
	// contains filtered or unexported fields
}

Details on interpretation failure.

func (*InterpretError_InterpretErrorDetails) Descriptor deprecated

func (*InterpretError_InterpretErrorDetails) Descriptor() ([]byte, []int)

Deprecated: Use InterpretError_InterpretErrorDetails.ProtoReflect.Descriptor instead.

func (*InterpretError_InterpretErrorDetails) GetAmbiguityDetails

func (*InterpretError_InterpretErrorDetails) GetIncompleteQueryDetails

func (*InterpretError_InterpretErrorDetails) GetUnsupportedDetails

func (*InterpretError_InterpretErrorDetails) ProtoMessage

func (*InterpretError_InterpretErrorDetails) ProtoMessage()

func (*InterpretError_InterpretErrorDetails) ProtoReflect

func (*InterpretError_InterpretErrorDetails) Reset

func (*InterpretError_InterpretErrorDetails) String

type InterpretError_InterpretIncompleteQueryDetails

type InterpretError_InterpretIncompleteQueryDetails struct {

	// List of missing interpret entities.
	Entities []InterpretEntity `` /* 127-byte string literal not displayed */
	// contains filtered or unexported fields
}

Details about an incomplete query.

func (*InterpretError_InterpretIncompleteQueryDetails) Descriptor deprecated

Deprecated: Use InterpretError_InterpretIncompleteQueryDetails.ProtoReflect.Descriptor instead.

func (*InterpretError_InterpretIncompleteQueryDetails) GetEntities

func (*InterpretError_InterpretIncompleteQueryDetails) ProtoMessage

func (*InterpretError_InterpretIncompleteQueryDetails) ProtoReflect

func (*InterpretError_InterpretIncompleteQueryDetails) Reset

func (*InterpretError_InterpretIncompleteQueryDetails) String

type InterpretError_InterpretUnsupportedDetails

type InterpretError_InterpretUnsupportedDetails struct {

	// Unsupported operators. For example: median.
	Operators []string `protobuf:"bytes,1,rep,name=operators,proto3" json:"operators,omitempty"`
	// Unsupported intents.
	Intent []string `protobuf:"bytes,2,rep,name=intent,proto3" json:"intent,omitempty"`
	// contains filtered or unexported fields
}

Details about unsupported parts in a query.

func (*InterpretError_InterpretUnsupportedDetails) Descriptor deprecated

Deprecated: Use InterpretError_InterpretUnsupportedDetails.ProtoReflect.Descriptor instead.

func (*InterpretError_InterpretUnsupportedDetails) GetIntent

func (*InterpretError_InterpretUnsupportedDetails) GetOperators

func (*InterpretError_InterpretUnsupportedDetails) ProtoMessage

func (*InterpretError_InterpretUnsupportedDetails) ProtoReflect

func (*InterpretError_InterpretUnsupportedDetails) Reset

func (*InterpretError_InterpretUnsupportedDetails) String

type Interpretation

type Interpretation struct {

	// List of data sources used in the current understanding.
	DataSources []string `protobuf:"bytes,1,rep,name=data_sources,json=dataSources,proto3" json:"data_sources,omitempty"`
	// The level of confidence that one of the interpretations is correct. This is
	// a value in the range [0, 1] where a value of 0.5 or below is to be
	// considered a low confidence.
	Confidence float64 `protobuf:"fixed64,2,opt,name=confidence,proto3" json:"confidence,omitempty"`
	// A list of unused phrases. Clients should display a Did You Mean (DYM)
	//  dialog if this is non-empty, even if this is the only interpretation.
	UnusedPhrases []string `protobuf:"bytes,3,rep,name=unused_phrases,json=unusedPhrases,proto3" json:"unused_phrases,omitempty"`
	// Human readable representation of the query.
	HumanReadable *HumanReadable `protobuf:"bytes,4,opt,name=human_readable,json=humanReadable,proto3" json:"human_readable,omitempty"`
	// Information about the interpretation structure that helps to understand and
	// visualize the response.
	InterpretationStructure *InterpretationStructure `` /* 130-byte string literal not displayed */
	// Representation of the data query to be sent to the backend.
	DataQuery *DataQuery `protobuf:"bytes,6,opt,name=data_query,json=dataQuery,proto3" json:"data_query,omitempty"`
	// Information about the backend response. This is populated only if execution
	// of an interpretation was requested.
	ExecutionInfo *ExecutionInfo `protobuf:"bytes,7,opt,name=execution_info,json=executionInfo,proto3" json:"execution_info,omitempty"`
	// contains filtered or unexported fields
}

An interpretation of a natural language query.

func (*Interpretation) Descriptor deprecated

func (*Interpretation) Descriptor() ([]byte, []int)

Deprecated: Use Interpretation.ProtoReflect.Descriptor instead.

func (*Interpretation) GetConfidence

func (x *Interpretation) GetConfidence() float64

func (*Interpretation) GetDataQuery

func (x *Interpretation) GetDataQuery() *DataQuery

func (*Interpretation) GetDataSources

func (x *Interpretation) GetDataSources() []string

func (*Interpretation) GetExecutionInfo

func (x *Interpretation) GetExecutionInfo() *ExecutionInfo

func (*Interpretation) GetHumanReadable

func (x *Interpretation) GetHumanReadable() *HumanReadable

func (*Interpretation) GetInterpretationStructure

func (x *Interpretation) GetInterpretationStructure() *InterpretationStructure

func (*Interpretation) GetUnusedPhrases

func (x *Interpretation) GetUnusedPhrases() []string

func (*Interpretation) ProtoMessage

func (*Interpretation) ProtoMessage()

func (*Interpretation) ProtoReflect

func (x *Interpretation) ProtoReflect() protoreflect.Message

func (*Interpretation) Reset

func (x *Interpretation) Reset()

func (*Interpretation) String

func (x *Interpretation) String() string

type InterpretationStructure

type InterpretationStructure struct {

	// List of possible visualization types to apply for this interpretation. The
	// order has no relevance.
	VisualizationTypes []InterpretationStructure_VisualizationType `` /* 199-byte string literal not displayed */
	// Information about the output columns, that is, the columns that will be
	// returned by the backend.
	ColumnInfo []*InterpretationStructure_ColumnInfo `protobuf:"bytes,2,rep,name=column_info,json=columnInfo,proto3" json:"column_info,omitempty"`
	// contains filtered or unexported fields
}

Information about the interpretation structure that helps to understand and visualize the response.

func (*InterpretationStructure) Descriptor deprecated

func (*InterpretationStructure) Descriptor() ([]byte, []int)

Deprecated: Use InterpretationStructure.ProtoReflect.Descriptor instead.

func (*InterpretationStructure) GetColumnInfo

func (*InterpretationStructure) GetVisualizationTypes

func (*InterpretationStructure) ProtoMessage

func (*InterpretationStructure) ProtoMessage()

func (*InterpretationStructure) ProtoReflect

func (x *InterpretationStructure) ProtoReflect() protoreflect.Message

func (*InterpretationStructure) Reset

func (x *InterpretationStructure) Reset()

func (*InterpretationStructure) String

func (x *InterpretationStructure) String() string

type InterpretationStructure_ColumnInfo

type InterpretationStructure_ColumnInfo struct {

	// The alias of the output column as used by the backend. For example, the
	// field name in the schema provided in the query response in BigQuery.
	OutputAlias string `protobuf:"bytes,1,opt,name=output_alias,json=outputAlias,proto3" json:"output_alias,omitempty"`
	// Human readable name of the output column.
	DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
	// contains filtered or unexported fields
}

Information about a column.

func (*InterpretationStructure_ColumnInfo) Descriptor deprecated

func (*InterpretationStructure_ColumnInfo) Descriptor() ([]byte, []int)

Deprecated: Use InterpretationStructure_ColumnInfo.ProtoReflect.Descriptor instead.

func (*InterpretationStructure_ColumnInfo) GetDisplayName

func (x *InterpretationStructure_ColumnInfo) GetDisplayName() string

func (*InterpretationStructure_ColumnInfo) GetOutputAlias

func (x *InterpretationStructure_ColumnInfo) GetOutputAlias() string

func (*InterpretationStructure_ColumnInfo) ProtoMessage

func (*InterpretationStructure_ColumnInfo) ProtoMessage()

func (*InterpretationStructure_ColumnInfo) ProtoReflect

func (*InterpretationStructure_ColumnInfo) Reset

func (*InterpretationStructure_ColumnInfo) String

type InterpretationStructure_VisualizationType

type InterpretationStructure_VisualizationType int32

Enumeration of visualzation types to use for query response data.

const (
	// No visualization type was specified.
	InterpretationStructure_VISUALIZATION_TYPE_UNSPECIFIED InterpretationStructure_VisualizationType = 0
	// Show a table.
	InterpretationStructure_TABLE InterpretationStructure_VisualizationType = 1
	// Show a [bar
	// chart](https://developers.google.com/chart/interactive/docs/gallery/barchart).
	InterpretationStructure_BAR_CHART InterpretationStructure_VisualizationType = 2
	// Show a [column
	// chart](https://developers.google.com/chart/interactive/docs/gallery/columnchart).
	InterpretationStructure_COLUMN_CHART InterpretationStructure_VisualizationType = 3
	// Show a
	// [timeline](https://developers.google.com/chart/interactive/docs/gallery/timeline).
	InterpretationStructure_TIMELINE InterpretationStructure_VisualizationType = 4
	// Show a [scatter
	// plot](https://developers.google.com/chart/interactive/docs/gallery/scatterchart).
	InterpretationStructure_SCATTER_PLOT InterpretationStructure_VisualizationType = 5
	// Show a [pie
	// chart](https://developers.google.com/chart/interactive/docs/gallery/piechart).
	InterpretationStructure_PIE_CHART InterpretationStructure_VisualizationType = 6
	// Show a [line
	// chart](https://developers.google.com/chart/interactive/docs/gallery/linechart).
	InterpretationStructure_LINE_CHART InterpretationStructure_VisualizationType = 7
	// Show an [area
	// chart](https://developers.google.com/chart/interactive/docs/gallery/areachart).
	InterpretationStructure_AREA_CHART InterpretationStructure_VisualizationType = 8
	// Show a [combo
	// chart](https://developers.google.com/chart/interactive/docs/gallery/combochart).
	InterpretationStructure_COMBO_CHART InterpretationStructure_VisualizationType = 9
	// Show a
	// [histogram](https://developers.google.com/chart/interactive/docs/gallery/histogram).
	InterpretationStructure_HISTOGRAM InterpretationStructure_VisualizationType = 10
	// This denotes queries when the user has not specified the particular type
	// of chart and has mentioned only a generic chart name such as "Chart",
	// "Plot", "Graph", etc. This will differentiate it from specific charting
	// terms such as "Bar chart", "Pie chart", etc.
	InterpretationStructure_GENERIC_CHART InterpretationStructure_VisualizationType = 11
	// The user tried to specify a chart type, but the interpreter could not
	// understand the type. The client should display a generic chart and may
	// give a hint to the user that the requested type was not understood.
	InterpretationStructure_CHART_NOT_UNDERSTOOD InterpretationStructure_VisualizationType = 12
)

func (InterpretationStructure_VisualizationType) Descriptor

func (InterpretationStructure_VisualizationType) Enum

func (InterpretationStructure_VisualizationType) EnumDescriptor deprecated

func (InterpretationStructure_VisualizationType) EnumDescriptor() ([]byte, []int)

Deprecated: Use InterpretationStructure_VisualizationType.Descriptor instead.

func (InterpretationStructure_VisualizationType) Number

func (InterpretationStructure_VisualizationType) String

func (InterpretationStructure_VisualizationType) Type

type Question

type Question struct {

	// Output only. Immutable. The unique identifier for the Question. The ID is server-generated.
	// Example: `projects/foo/locations/bar/questions/123`
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Required. Immutable. Scopes to be used for the question. A scope defines the relevant data set
	// scope. It can be a reference to a specific data source or a collection of
	// data sources. Currently, support is limited to a single BigQuery table.
	// There must be exactly one `scopes` element.
	//
	// Example:
	// `//bigquery.googleapis.com/projects/test-project/datasets/foo/tables/bar`
	Scopes []string `protobuf:"bytes,2,rep,name=scopes,proto3" json:"scopes,omitempty"`
	// Required. Immutable. The query in natural language.
	Query string `protobuf:"bytes,3,opt,name=query,proto3" json:"query,omitempty"`
	// A list of annotations to use instead of the default annotation of a data
	// source (set in the data source reference resource). There must not be
	// more than one annotation with the same data source reference.
	DataSourceAnnotations []string `` /* 126-byte string literal not displayed */
	// An error field explaining why interpretation failed. This is only populated
	// if the interpretation failed.
	//
	// Note: This is different from getting a status error on the request itself.
	// This is not a client or server error and the Question resource is still
	// persisted, but the service could not interpret the question. Clients should
	// present the error to the user so the user can rephrase the question.
	InterpretError *InterpretError `protobuf:"bytes,5,opt,name=interpret_error,json=interpretError,proto3" json:"interpret_error,omitempty"`
	// A list of interpretations for this question.
	Interpretations []*Interpretation `protobuf:"bytes,6,rep,name=interpretations,proto3" json:"interpretations,omitempty"`
	// Time when the question was created.
	CreateTime *timestamppb.Timestamp `protobuf:"bytes,7,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
	// Output only. The e-mail address of the user that created this question.
	UserEmail string `protobuf:"bytes,8,opt,name=user_email,json=userEmail,proto3" json:"user_email,omitempty"`
	// Input only. Immutable. Flags to request additional information for debugging purposes.
	DebugFlags *DebugFlags `protobuf:"bytes,9,opt,name=debug_flags,json=debugFlags,proto3" json:"debug_flags,omitempty"`
	// Top level debug information.
	// This will be stored as the type DebugInformation.
	// Using Any so clients don't need to pull in anything
	// inside the debug message.
	DebugInfo *anypb.Any `protobuf:"bytes,10,opt,name=debug_info,json=debugInfo,proto3" json:"debug_info,omitempty"`
	// contains filtered or unexported fields
}

The question resource represents a natural language query, its settings, understanding generated by the system, and answer retrieval status. A question cannot be modified.

func (*Question) Descriptor deprecated

func (*Question) Descriptor() ([]byte, []int)

Deprecated: Use Question.ProtoReflect.Descriptor instead.

func (*Question) GetCreateTime

func (x *Question) GetCreateTime() *timestamppb.Timestamp

func (*Question) GetDataSourceAnnotations

func (x *Question) GetDataSourceAnnotations() []string

func (*Question) GetDebugFlags

func (x *Question) GetDebugFlags() *DebugFlags

func (*Question) GetDebugInfo

func (x *Question) GetDebugInfo() *anypb.Any

func (*Question) GetInterpretError

func (x *Question) GetInterpretError() *InterpretError

func (*Question) GetInterpretations

func (x *Question) GetInterpretations() []*Interpretation

func (*Question) GetName

func (x *Question) GetName() string

func (*Question) GetQuery

func (x *Question) GetQuery() string

func (*Question) GetScopes

func (x *Question) GetScopes() []string

func (*Question) GetUserEmail

func (x *Question) GetUserEmail() string

func (*Question) ProtoMessage

func (*Question) ProtoMessage()

func (*Question) ProtoReflect

func (x *Question) ProtoReflect() protoreflect.Message

func (*Question) Reset

func (x *Question) Reset()

func (*Question) String

func (x *Question) String() string

type QuestionServiceClient

type QuestionServiceClient interface {
	// Gets a previously created question.
	GetQuestion(ctx context.Context, in *GetQuestionRequest, opts ...grpc.CallOption) (*Question, error)
	// Creates a question.
	CreateQuestion(ctx context.Context, in *CreateQuestionRequest, opts ...grpc.CallOption) (*Question, error)
	// Executes an interpretation.
	ExecuteQuestion(ctx context.Context, in *ExecuteQuestionRequest, opts ...grpc.CallOption) (*Question, error)
	// Gets previously created user feedback.
	GetUserFeedback(ctx context.Context, in *GetUserFeedbackRequest, opts ...grpc.CallOption) (*UserFeedback, error)
	// Updates user feedback. This creates user feedback if there was none before
	// (upsert).
	UpdateUserFeedback(ctx context.Context, in *UpdateUserFeedbackRequest, opts ...grpc.CallOption) (*UserFeedback, error)
}

QuestionServiceClient is the client API for QuestionService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

type QuestionServiceServer

type QuestionServiceServer interface {
	// Gets a previously created question.
	GetQuestion(context.Context, *GetQuestionRequest) (*Question, error)
	// Creates a question.
	CreateQuestion(context.Context, *CreateQuestionRequest) (*Question, error)
	// Executes an interpretation.
	ExecuteQuestion(context.Context, *ExecuteQuestionRequest) (*Question, error)
	// Gets previously created user feedback.
	GetUserFeedback(context.Context, *GetUserFeedbackRequest) (*UserFeedback, error)
	// Updates user feedback. This creates user feedback if there was none before
	// (upsert).
	UpdateUserFeedback(context.Context, *UpdateUserFeedbackRequest) (*UserFeedback, error)
}

QuestionServiceServer is the server API for QuestionService service.

type SuggestQueriesRequest

type SuggestQueriesRequest struct {

	// Required. The parent of the suggestion query is the resource denoting the project and
	// location.
	Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"`
	// The scopes to which this search is restricted. The only supported scope
	// pattern is
	// `//bigquery.googleapis.com/projects/{GCP-PROJECT-ID}/datasets/{DATASET-ID}/tables/{TABLE-ID}`.
	Scopes []string `protobuf:"bytes,2,rep,name=scopes,proto3" json:"scopes,omitempty"`
	// User query for which to generate suggestions. If the query is empty, zero
	// state suggestions are returned. This allows UIs to display suggestions
	// right away, helping the user to get a sense of what a query might look
	// like.
	Query string `protobuf:"bytes,3,opt,name=query,proto3" json:"query,omitempty"`
	// The requested suggestion type. Multiple suggestion types can be
	// requested, but there is no guarantee that the service will return
	// suggestions for each type. Suggestions for a requested type might rank
	// lower than suggestions for other types and the service may decide to cut
	// these suggestions off.
	SuggestionTypes []SuggestionType `` /* 163-byte string literal not displayed */
	// contains filtered or unexported fields
}

Request for query suggestions.

func (*SuggestQueriesRequest) Descriptor deprecated

func (*SuggestQueriesRequest) Descriptor() ([]byte, []int)

Deprecated: Use SuggestQueriesRequest.ProtoReflect.Descriptor instead.

func (*SuggestQueriesRequest) GetParent

func (x *SuggestQueriesRequest) GetParent() string

func (*SuggestQueriesRequest) GetQuery

func (x *SuggestQueriesRequest) GetQuery() string

func (*SuggestQueriesRequest) GetScopes

func (x *SuggestQueriesRequest) GetScopes() []string

func (*SuggestQueriesRequest) GetSuggestionTypes

func (x *SuggestQueriesRequest) GetSuggestionTypes() []SuggestionType

func (*SuggestQueriesRequest) ProtoMessage

func (*SuggestQueriesRequest) ProtoMessage()

func (*SuggestQueriesRequest) ProtoReflect

func (x *SuggestQueriesRequest) ProtoReflect() protoreflect.Message

func (*SuggestQueriesRequest) Reset

func (x *SuggestQueriesRequest) Reset()

func (*SuggestQueriesRequest) String

func (x *SuggestQueriesRequest) String() string

type SuggestQueriesResponse

type SuggestQueriesResponse struct {

	// A list of suggestions.
	Suggestions []*Suggestion `protobuf:"bytes,1,rep,name=suggestions,proto3" json:"suggestions,omitempty"`
	// contains filtered or unexported fields
}

Response to SuggestQueries.

func (*SuggestQueriesResponse) Descriptor deprecated

func (*SuggestQueriesResponse) Descriptor() ([]byte, []int)

Deprecated: Use SuggestQueriesResponse.ProtoReflect.Descriptor instead.

func (*SuggestQueriesResponse) GetSuggestions

func (x *SuggestQueriesResponse) GetSuggestions() []*Suggestion

func (*SuggestQueriesResponse) ProtoMessage

func (*SuggestQueriesResponse) ProtoMessage()

func (*SuggestQueriesResponse) ProtoReflect

func (x *SuggestQueriesResponse) ProtoReflect() protoreflect.Message

func (*SuggestQueriesResponse) Reset

func (x *SuggestQueriesResponse) Reset()

func (*SuggestQueriesResponse) String

func (x *SuggestQueriesResponse) String() string

type Suggestion

type Suggestion struct {

	// Detailed information about the suggestion.
	SuggestionInfo *SuggestionInfo `protobuf:"bytes,1,opt,name=suggestion_info,json=suggestionInfo,proto3" json:"suggestion_info,omitempty"`
	// The score of the suggestion. This can be used to define ordering in UI.
	// The score represents confidence in the suggestion where higher is better.
	// All score values must be in the range [0, 1).
	RankingScore float64 `protobuf:"fixed64,2,opt,name=ranking_score,json=rankingScore,proto3" json:"ranking_score,omitempty"`
	// The type of the suggestion.
	SuggestionType SuggestionType `` /* 153-byte string literal not displayed */
	// contains filtered or unexported fields
}

A suggestion for a query with a ranking score.

func (*Suggestion) Descriptor deprecated

func (*Suggestion) Descriptor() ([]byte, []int)

Deprecated: Use Suggestion.ProtoReflect.Descriptor instead.

func (*Suggestion) GetRankingScore

func (x *Suggestion) GetRankingScore() float64

func (*Suggestion) GetSuggestionInfo

func (x *Suggestion) GetSuggestionInfo() *SuggestionInfo

func (*Suggestion) GetSuggestionType

func (x *Suggestion) GetSuggestionType() SuggestionType

func (*Suggestion) ProtoMessage

func (*Suggestion) ProtoMessage()

func (*Suggestion) ProtoReflect

func (x *Suggestion) ProtoReflect() protoreflect.Message

func (*Suggestion) Reset

func (x *Suggestion) Reset()

func (*Suggestion) String

func (x *Suggestion) String() string

type SuggestionInfo

type SuggestionInfo struct {

	// Annotations for the suggestion. This provides information about which part
	// of the suggestion corresponds to what semantic meaning (e.g. a metric).
	AnnotatedSuggestion *AnnotatedString `protobuf:"bytes,1,opt,name=annotated_suggestion,json=annotatedSuggestion,proto3" json:"annotated_suggestion,omitempty"`
	// Matches between user query and the annotated string.
	QueryMatches []*SuggestionInfo_MatchInfo `protobuf:"bytes,2,rep,name=query_matches,json=queryMatches,proto3" json:"query_matches,omitempty"`
	// contains filtered or unexported fields
}

Detailed information about the suggestion.

func (*SuggestionInfo) Descriptor deprecated

func (*SuggestionInfo) Descriptor() ([]byte, []int)

Deprecated: Use SuggestionInfo.ProtoReflect.Descriptor instead.

func (*SuggestionInfo) GetAnnotatedSuggestion

func (x *SuggestionInfo) GetAnnotatedSuggestion() *AnnotatedString

func (*SuggestionInfo) GetQueryMatches

func (x *SuggestionInfo) GetQueryMatches() []*SuggestionInfo_MatchInfo

func (*SuggestionInfo) ProtoMessage

func (*SuggestionInfo) ProtoMessage()

func (*SuggestionInfo) ProtoReflect

func (x *SuggestionInfo) ProtoReflect() protoreflect.Message

func (*SuggestionInfo) Reset

func (x *SuggestionInfo) Reset()

func (*SuggestionInfo) String

func (x *SuggestionInfo) String() string

type SuggestionInfo_MatchInfo

type SuggestionInfo_MatchInfo struct {

	// Unicode character index of the string annotation.
	StartCharIndex int32 `protobuf:"varint,1,opt,name=start_char_index,json=startCharIndex,proto3" json:"start_char_index,omitempty"`
	// Count of unicode characters of this substring.
	Length int32 `protobuf:"varint,2,opt,name=length,proto3" json:"length,omitempty"`
	// contains filtered or unexported fields
}

MatchInfo describes which part of suggestion matched with data in user typed query. This can be used to highlight matching parts in the UI. This is different from the annotations provided in annotated_suggestion. The annotated_suggestion provides information about the semantic meaning, while this provides information about how it relates to the input.

Example: user query: `top products`

```

annotated_suggestion {
 text_formatted = "top product_group"
 html_formatted = "top <b>product_group</b>"
 markups {
  {type: TEXT, start_char_index: 0, length: 3}
  {type: DIMENSION, start_char_index: 4, length: 13}
 }
}
query_matches {
 { start_char_index: 0, length: 3 }
 { start_char_index: 4, length: 7}
}

```

func (*SuggestionInfo_MatchInfo) Descriptor deprecated

func (*SuggestionInfo_MatchInfo) Descriptor() ([]byte, []int)

Deprecated: Use SuggestionInfo_MatchInfo.ProtoReflect.Descriptor instead.

func (*SuggestionInfo_MatchInfo) GetLength

func (x *SuggestionInfo_MatchInfo) GetLength() int32

func (*SuggestionInfo_MatchInfo) GetStartCharIndex

func (x *SuggestionInfo_MatchInfo) GetStartCharIndex() int32

func (*SuggestionInfo_MatchInfo) ProtoMessage

func (*SuggestionInfo_MatchInfo) ProtoMessage()

func (*SuggestionInfo_MatchInfo) ProtoReflect

func (x *SuggestionInfo_MatchInfo) ProtoReflect() protoreflect.Message

func (*SuggestionInfo_MatchInfo) Reset

func (x *SuggestionInfo_MatchInfo) Reset()

func (*SuggestionInfo_MatchInfo) String

func (x *SuggestionInfo_MatchInfo) String() string

type SuggestionType

type SuggestionType int32

The type of suggestion.

const (
	// No suggestiont type is specified.
	SuggestionType_SUGGESTION_TYPE_UNSPECIFIED SuggestionType = 0
	// Entity suggestion type. Suggestions are for single entities.
	SuggestionType_ENTITY SuggestionType = 1
	// Template suggestion type. Suggestions are for full sentences.
	SuggestionType_TEMPLATE SuggestionType = 2
)

func (SuggestionType) Descriptor

func (SuggestionType) Enum

func (x SuggestionType) Enum() *SuggestionType

func (SuggestionType) EnumDescriptor deprecated

func (SuggestionType) EnumDescriptor() ([]byte, []int)

Deprecated: Use SuggestionType.Descriptor instead.

func (SuggestionType) Number

func (SuggestionType) String

func (x SuggestionType) String() string

func (SuggestionType) Type

type UnimplementedAutoSuggestionServiceServer

type UnimplementedAutoSuggestionServiceServer struct {
}

UnimplementedAutoSuggestionServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedAutoSuggestionServiceServer) SuggestQueries

type UnimplementedQuestionServiceServer

type UnimplementedQuestionServiceServer struct {
}

UnimplementedQuestionServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedQuestionServiceServer) CreateQuestion

func (*UnimplementedQuestionServiceServer) ExecuteQuestion

func (*UnimplementedQuestionServiceServer) GetQuestion

func (*UnimplementedQuestionServiceServer) GetUserFeedback

func (*UnimplementedQuestionServiceServer) UpdateUserFeedback

type UpdateUserFeedbackRequest

type UpdateUserFeedbackRequest struct {

	// Required. The user feedback to update. This can be called even if there is no
	// user feedback so far.
	// The feedback's name field is used to identify the user feedback (and the
	// corresponding question) to update.
	UserFeedback *UserFeedback `protobuf:"bytes,1,opt,name=user_feedback,json=userFeedback,proto3" json:"user_feedback,omitempty"`
	// The list of fields to be updated.
	UpdateMask *fieldmaskpb.FieldMask `protobuf:"bytes,2,opt,name=update_mask,json=updateMask,proto3" json:"update_mask,omitempty"`
	// contains filtered or unexported fields
}

Request to updates user feedback.

func (*UpdateUserFeedbackRequest) Descriptor deprecated

func (*UpdateUserFeedbackRequest) Descriptor() ([]byte, []int)

Deprecated: Use UpdateUserFeedbackRequest.ProtoReflect.Descriptor instead.

func (*UpdateUserFeedbackRequest) GetUpdateMask

func (x *UpdateUserFeedbackRequest) GetUpdateMask() *fieldmaskpb.FieldMask

func (*UpdateUserFeedbackRequest) GetUserFeedback

func (x *UpdateUserFeedbackRequest) GetUserFeedback() *UserFeedback

func (*UpdateUserFeedbackRequest) ProtoMessage

func (*UpdateUserFeedbackRequest) ProtoMessage()

func (*UpdateUserFeedbackRequest) ProtoReflect

func (*UpdateUserFeedbackRequest) Reset

func (x *UpdateUserFeedbackRequest) Reset()

func (*UpdateUserFeedbackRequest) String

func (x *UpdateUserFeedbackRequest) String() string

type UserFeedback

type UserFeedback struct {

	// Required. The unique identifier for the user feedback.
	// User feedback is a singleton resource on a Question.
	// Example: `projects/foo/locations/bar/questions/1234/userFeedback`
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// Free form user feedback, such as a text box.
	FreeFormFeedback string `protobuf:"bytes,2,opt,name=free_form_feedback,json=freeFormFeedback,proto3" json:"free_form_feedback,omitempty"`
	// The user feedback rating
	Rating UserFeedback_UserFeedbackRating `` /* 132-byte string literal not displayed */
	// contains filtered or unexported fields
}

Feedback provided by a user.

func (*UserFeedback) Descriptor deprecated

func (*UserFeedback) Descriptor() ([]byte, []int)

Deprecated: Use UserFeedback.ProtoReflect.Descriptor instead.

func (*UserFeedback) GetFreeFormFeedback

func (x *UserFeedback) GetFreeFormFeedback() string

func (*UserFeedback) GetName

func (x *UserFeedback) GetName() string

func (*UserFeedback) GetRating

func (*UserFeedback) ProtoMessage

func (*UserFeedback) ProtoMessage()

func (*UserFeedback) ProtoReflect

func (x *UserFeedback) ProtoReflect() protoreflect.Message

func (*UserFeedback) Reset

func (x *UserFeedback) Reset()

func (*UserFeedback) String

func (x *UserFeedback) String() string

type UserFeedback_UserFeedbackRating

type UserFeedback_UserFeedbackRating int32

Enumeration of feedback ratings.

const (
	// No rating was specified.
	UserFeedback_USER_FEEDBACK_RATING_UNSPECIFIED UserFeedback_UserFeedbackRating = 0
	// The user provided positive feedback.
	UserFeedback_POSITIVE UserFeedback_UserFeedbackRating = 1
	// The user provided negative feedback.
	UserFeedback_NEGATIVE UserFeedback_UserFeedbackRating = 2
)

func (UserFeedback_UserFeedbackRating) Descriptor

func (UserFeedback_UserFeedbackRating) Enum

func (UserFeedback_UserFeedbackRating) EnumDescriptor deprecated

func (UserFeedback_UserFeedbackRating) EnumDescriptor() ([]byte, []int)

Deprecated: Use UserFeedback_UserFeedbackRating.Descriptor instead.

func (UserFeedback_UserFeedbackRating) Number

func (UserFeedback_UserFeedbackRating) String

func (UserFeedback_UserFeedbackRating) Type

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL