-
Notifications
You must be signed in to change notification settings - Fork 2
/
bigquery.go
26 lines (24 loc) · 1.07 KB
/
bigquery.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package labeler
import "time"
// BqIssue represents a GitHub issue in BigQuery.
// The schema is defined here:
// https://console.cloud.google.com/bigquery?authuser=1&folder=297399687849&organizationId=867596835188&orgonly=true&project=coder-labeler&supportedpurview=organizationId&ws=!1m5!1m4!4m3!1scoder-labeler!2sghindex!3sissues.
//
// CREATE VECTOR INDEX my_index ON my_dataset.my_table(embedding)
// OPTIONS(index_type = 'IVF', distance_type = 'COSINE',
// ivf_options = '{"num_lists": 2500}')
type BqIssue struct {
ID int64 `bigquery:"id"`
InstallID int64 `bigquery:"install_id"`
User string `bigquery:"user"`
Repo string `bigquery:"repo"`
Number int `bigquery:"number"`
Title string `bigquery:"title"`
State string `bigquery:"state"`
Body string `bigquery:"body"`
CreatedAt time.Time `bigquery:"created_at"`
UpdatedAt time.Time `bigquery:"updated_at"`
InsertedAt time.Time `bigquery:"inserted_at"`
Embedding []float64 `bigquery:"embedding"`
PullRequest bool `bigquery:"pull_request"`
}