gitlab-cloud-connector 1.12.0 → 1.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5ad05b8bdbe28bb01760e2778f4fd95949d4ab927ee76a78b0177aafea43d912
4
- data.tar.gz: b2405278b9f29f0c3d696c44f2aeb0d3f06578e8c3af28189a33e3d998e5a626
3
+ metadata.gz: 077de053a3fe1fce666a22074c0b6b8e4eaff5acf93055d3fffbe80ee11edcd2
4
+ data.tar.gz: 45161c6c8d5d4a44141845caf4c3a766d3f7521216a6c2fdfc50b6f1f9a9997a
5
5
  SHA512:
6
- metadata.gz: 36c31411737f12736f99cc95bda8e3eae88eec3dc13f27727b5654b2cdd4df79d40aa86abcb1c4f2a6b7f5d500f2508a64bb610cbece045fbd479f29ffbb68de
7
- data.tar.gz: f0b345b64f19ffed81dd9a28ea67ea66d63759a762b353cb49762d3b947804eb940ffd60eb13559869b1169de0ee74c4fff0b8ee1aebad353f2cfad3f752841b
6
+ metadata.gz: f45035bc44bd61356cb4de0566ddedb3322dc37535437eb1d7552f29dfe2a4c169e73373432eae44877c96885709c2153e1f43f3430404a14e8755951a95253c
7
+ data.tar.gz: 5dc5d7321a6b93f30cba742f3fff4b19440109f88836f0c29da8e940e036aa50ed2441bccc33bf3dea7715e221bc0ec89a2cf9f6094dbfc73f14b5e173fbf2ac
@@ -0,0 +1,17 @@
1
+ ---
2
+ name: generate_embeddings_codebase
3
+ description: >
4
+ Generates embeddings for Chat with Codebase feature.
5
+ This unit primitive serves two purposes:
6
+ 1. System requests (majority): Used to populate a vector store for search functionality. These requests do not have an associated user.
7
+ 2. User requests (minority): Generated when Chat with Codebase feature is used. These requests include user.
8
+ group: group::code suggestions
9
+ feature_category: code_suggestions
10
+ unit_primitive_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/538567
11
+ introduced_by_url: https://gitlab.com/gitlab-org/cloud-connector/gitlab-cloud-connector/-/merge_requests/146
12
+ cut_off_date: 2024-02-15T00:00:00+00:00
13
+ backend_services:
14
+ - ai_gateway
15
+ add_ons:
16
+ - duo_pro
17
+ - duo_enterprise
@@ -1,6 +1,10 @@
1
1
  ---
2
2
  name: semantic_search_issue
3
- description: Perform semantic search on gitlab issues for a given query.
3
+ description: >
4
+ Performs semantic search on GitLab work items for a given query.
5
+ This unit primitive serves two purposes:
6
+ 1. System requests (majority): Used to populate a vector store for search functionality. These requests do not have an associated user or namespace IDs.
7
+ 2. User requests (minority): Generated when a work item search is performed using the Global Search feature for enabled projects. These requests include user and namespace IDs.
4
8
  group: group::global search
5
9
  feature_category: global_search
6
10
  backend_services:
@@ -11,7 +11,7 @@ module Gitlab
11
11
  InvalidConfigError = Class.new(StandardError)
12
12
 
13
13
  class << self
14
- attr_writer :config_dir, :memoize_data
14
+ attr_writer :config_dir
15
15
  attr_reader :override_config
16
16
 
17
17
  def config_dir
@@ -32,12 +32,6 @@ module Gitlab
32
32
  @override_config = value
33
33
  end
34
34
 
35
- def memoize_data?
36
- return @memoize_data unless @memoize_data.nil?
37
-
38
- data_loader_class == DEFAULT_DATA_LOADER_CLASS
39
- end
40
-
41
35
  def configure
42
36
  yield self if block_given?
43
37
  end
@@ -23,17 +23,13 @@ module Gitlab
23
23
  end
24
24
 
25
25
  def all
26
- if Configuration.memoize_data?
27
- @all ||= data_loader.load!
28
- else
29
- data_loader.load!
30
- end
26
+ data_loader.load!
31
27
  end
32
28
 
33
29
  private
34
30
 
35
31
  def data_loader
36
- Configuration.data_loader_class.new(self)
32
+ @data_loader ||= Configuration.data_loader_class.new(self)
37
33
  end
38
34
  end
39
35
 
@@ -11,11 +11,15 @@ module Gitlab
11
11
  include Overridable
12
12
 
13
13
  def load!
14
- Dir.glob(data_files_path).map { |file| load_model_from_file(file) }
14
+ load_data_from_files
15
15
  end
16
16
 
17
17
  private
18
18
 
19
+ def load_data_from_files
20
+ @load_data_from_files ||= Dir.glob(data_files_path).map { |file| load_model_from_file(file) }
21
+ end
22
+
19
23
  def data_files_path
20
24
  File.join(CloudConnector::Configuration.config_dir, model_class.model_name.tableize, '*.yml')
21
25
  end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Gitlab
4
4
  module CloudConnector
5
- VERSION = '1.12.0'
5
+ VERSION = '1.13.0'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gitlab-cloud-connector
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.12.0
4
+ version: 1.13.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nikola Milojevic
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-05-09 00:00:00.000000000 Z
11
+ date: 2025-05-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -139,6 +139,7 @@ files:
139
139
  - config/unit_primitives/generate_code.yml
140
140
  - config/unit_primitives/generate_commit_message.yml
141
141
  - config/unit_primitives/generate_cube_query.yml
142
+ - config/unit_primitives/generate_embeddings_codebase.yml
142
143
  - config/unit_primitives/generate_issue_description.yml
143
144
  - config/unit_primitives/glab_ask_git_command.yml
144
145
  - config/unit_primitives/include_dependency_context.yml