graphdb-workbench-tests 2.7.6 → 2.8.0-RC1
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.
- package/cypress.config.js +3 -0
- package/fixtures/cluster/2-nodes-cluster-group-status-deleted.json +30 -0
- package/fixtures/cluster/2-nodes-cluster-group-status.json +30 -0
- package/fixtures/cluster/3-nodes-cluster-group-status-after-replace.json +44 -0
- package/fixtures/cluster/3-nodes-cluster-group-status-building-snapshot.json +4 -1
- package/fixtures/cluster/3-nodes-cluster-group-status-receiving-snapshot.json +4 -1
- package/fixtures/cluster/3-nodes-cluster-group-status-sending-snapshot.json +4 -1
- package/fixtures/cluster/3-nodes-cluster-group-status-waiting-for-snapshot.json +4 -1
- package/fixtures/cluster/3-nodes-cluster-group-status.json +12 -3
- package/fixtures/cluster/4-nodes-cluster-group-status.json +58 -0
- package/fixtures/cluster/cluster-config.json +1 -0
- package/fixtures/cluster/cluster-node-status.json +4 -1
- package/fixtures/connectors/get-connectors.json +8 -0
- package/fixtures/connectors/get-retrieval-connector-0.json +1 -0
- package/fixtures/connectors/get-retrieval-connector.json +29 -0
- package/fixtures/connectors/get-ttyg-chatgpt-connectors.json +188 -0
- package/fixtures/locale-en.json +630 -61
- package/fixtures/namespaces/get-repository-starwars-namespaces.json +252 -0
- package/fixtures/remote-location/get-0-remote-locations.json +1 -2
- package/fixtures/remote-location/get-1-remote-locations.json +2 -4
- package/fixtures/remote-location/get-2-remote-locations.json +3 -6
- package/fixtures/remote-location/get-3-remote-locations.json +4 -8
- package/fixtures/remote-location/get-4-remote-locations.json +54 -0
- package/fixtures/remote-location/remote-location-status-in-cluster.json +1 -2
- package/fixtures/remote-location/remote-location-status-not-in-cluster.json +1 -2
- package/fixtures/remote-location/remote-locations-filter.json +1 -2
- package/fixtures/repositories/get-locations.json +67 -0
- package/fixtures/repositories/get-repositories.json +106 -0
- package/fixtures/repositories/get-repository-config-starwars-disabled-fts.json +201 -0
- package/fixtures/repositories/get-repository-config-starwars-enabled-fts.json +201 -0
- package/fixtures/repositories/get-ttyg-repositories.json +74 -0
- package/fixtures/similarity/get-similarity-indexes-0.json +1 -0
- package/fixtures/similarity/get-similarity-indexes.json +15 -0
- package/fixtures/similarity/get-ttyg-similarity-connectors.json +46 -0
- package/fixtures/ttyg/agent/create-agent.json +20 -0
- package/fixtures/ttyg/agent/get-agent-defaults.json +42 -0
- package/fixtures/ttyg/agent/get-agent-list-0.json +1 -0
- package/fixtures/ttyg/agent/get-agent-list-after-deleted.json +56 -0
- package/fixtures/ttyg/agent/get-agent-list-new-agent.json +22 -0
- package/fixtures/ttyg/agent/get-agent-list.json +77 -0
- package/fixtures/ttyg/agent/get-agent.json +25 -0
- package/fixtures/ttyg/chats/ask-question.json +25 -0
- package/fixtures/ttyg/chats/create/create-chat-response.json +16 -0
- package/fixtures/ttyg/chats/create/get-chats-after-create.json +12 -0
- package/fixtures/ttyg/chats/create/get-chats-before-create.json +7 -0
- package/fixtures/ttyg/chats/deleted-chat.json +3 -0
- package/fixtures/ttyg/chats/explain-response-1.json +59 -0
- package/fixtures/ttyg/chats/explain-response-2.json +59 -0
- package/fixtures/ttyg/chats/export-chat.json +34 -0
- package/fixtures/ttyg/chats/get-chat-list-0.json +1 -0
- package/fixtures/ttyg/chats/get-chat-list-with-deleted-chat.json +17 -0
- package/fixtures/ttyg/chats/get-chat-list-with-renamed-chat.json +22 -0
- package/fixtures/ttyg/chats/get-chat-list.json +22 -0
- package/fixtures/ttyg/chats/get-chat.json +199 -0
- package/fixtures/ttyg/chats/renamed-chat.json +4 -0
- package/integration/cluster/cluster-management.spec.js +0 -170
- package/integration/cluster/edit-cluster-nodes-modal.spec.js +425 -0
- package/integration/explore/graphs.overview.spec.js +4 -0
- package/integration/home/cookie-policy.spec.js +65 -0
- package/integration/home/create-repository.spec.js +35 -0
- package/integration/home/documentation-link.spec.js +60 -0
- package/integration/home/google-analytics.spec.js +60 -0
- package/integration/home/language-selector.spec.js +19 -0
- package/integration/home/rdf-resource-search.spec.js +192 -0
- package/integration/home/view-resource-autocomplete.spec.js +52 -0
- package/integration/home/workbench.home.spec.js +1 -277
- package/integration/import/import-user-data-file-upload.spec.js +13 -0
- package/integration/import/import-user-data.spec.js +8 -2
- package/integration/import/import-view.spec.js +6 -1
- package/integration/repository/attach-remote-location.spec.js +203 -0
- package/integration/repository/ontop-repository.spec.js +87 -1
- package/integration/repository/repositories.spec.js +4 -19
- package/integration/setup/my-settings.spec.js +2 -0
- package/integration/ttyg/agent-list.spec.js +76 -0
- package/integration/ttyg/agent-select-menu.spec.js +141 -0
- package/integration/ttyg/chat-list.spec.js +286 -0
- package/integration/ttyg/chat-panel.spec.js +175 -0
- package/integration/ttyg/clone-agent.spec.js +75 -0
- package/integration/ttyg/create-agent.spec.js +560 -0
- package/integration/ttyg/create-chat.spec.js +69 -0
- package/integration/ttyg/delete-agent.spec.js +51 -0
- package/integration/ttyg/edit-agent.spec.js +54 -0
- package/integration/ttyg/ttyg-permission.spec.js +66 -0
- package/integration/ttyg/ttyg-view.spec.js +75 -0
- package/npm-shrinkwrap.json +215 -220
- package/package.json +5 -6
- package/steps/alert-dialog-steps.js +25 -0
- package/steps/cluster/cluster-page-steps.js +8 -0
- package/steps/cluster/custer-nodes-configuration-steps.js +107 -0
- package/steps/home-steps.js +48 -5
- package/steps/import/import-steps.js +11 -11
- package/steps/modal-dialog-steps.js +8 -0
- package/steps/ontop-repository-steps.js +26 -0
- package/steps/repositories/attach-repository-steps.js +118 -0
- package/steps/repository-steps.js +53 -5
- package/steps/setup/settings-steps.js +17 -0
- package/steps/ttyg/chat-panel-steps.js +62 -0
- package/steps/ttyg/ttyg-agent-settings-modal.steps.js +462 -0
- package/steps/ttyg/ttyg-view-steps.js +333 -0
- package/steps/window-steps.js +5 -0
- package/stubs/cluster/cluster-stubs.js +127 -7
- package/stubs/cluster/remote-location-stubs.js +46 -0
- package/stubs/connector-stubs.js +39 -0
- package/stubs/environment-stubs.js +27 -0
- package/stubs/license-stubs.js +101 -0
- package/stubs/repositories/repositories-stubs.js +133 -0
- package/stubs/repositories-stub.js +15 -0
- package/stubs/security-stubs.js +7 -0
- package/stubs/similarity-index-stubs.js +32 -0
- package/stubs/stubs.js +4 -0
- package/stubs/ttyg/ttyg-stubs.js +166 -0
- package/support/commands.js +2 -0
- package/support/index.js +17 -0
- package/support/security-command.js +25 -0
- package/support/settings-commands.js +4 -5
- package/support/user-commands.js +31 -0
- package/steps/cluster/add-remote-location-dialog-steps.js +0 -11
- package/steps/cluster/create-cluster-dialog-steps.js +0 -39
- package/steps/cluster/replace-nodes-dialog-steps.js +0 -39
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
export class ChatPanelSteps {
|
|
2
|
+
|
|
3
|
+
static getChatPanel() {
|
|
4
|
+
return cy.get('.chat-panel');
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
static getChatDetailsElements() {
|
|
8
|
+
return ChatPanelSteps.getChatPanel().find('.chat-detail');
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
static getChatDetailElement(index = 0) {
|
|
12
|
+
return ChatPanelSteps.getChatDetailsElements().eq(index).scrollIntoView();
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
static getChatDetailActions(chatDetailIndex = 0, answerIndex = 0) {
|
|
16
|
+
return ChatPanelSteps.getChatDetailElement(chatDetailIndex).find('.actions').eq(answerIndex);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
static getQuestionInputElement() {
|
|
20
|
+
return ChatPanelSteps.getChatPanel().find('.question-input');
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
static getAskButtonElement() {
|
|
24
|
+
return ChatPanelSteps.getChatPanel().find('.ask-button');
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
static getChatDetailQuestionElement(index = 0) {
|
|
28
|
+
return ChatPanelSteps.getChatDetailElement(index).find('.question');
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
static regenerateQuestion(index, answerIndex = 0) {
|
|
32
|
+
ChatPanelSteps.getChatDetailActions(index, answerIndex).find('.regenerate-question-btn').scrollIntoView().click();
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
static copyAnswer(index, answerIndex = 0) {
|
|
36
|
+
ChatPanelSteps.getChatDetailActions(index, answerIndex).find('.copy-answer-btn').click({force: true});
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
static getAgentInfoMessages() {
|
|
40
|
+
return ChatPanelSteps.getChatPanel().find('.agent-changed-info');
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
static getAgentInfoMessage(index = 0) {
|
|
44
|
+
return ChatPanelSteps.getAgentInfoMessages().eq(index);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
static getOpenInSparqlEditorElements() {
|
|
48
|
+
return ChatPanelSteps.getChatPanel().find('open-in-sparql-editor');
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
static getOpenInSparqlEditorElement(index = 0) {
|
|
52
|
+
return ChatPanelSteps.getOpenInSparqlEditorElements().eq(index);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
static getCopyToClipboardElements() {
|
|
56
|
+
return ChatPanelSteps.getChatPanel().find('copy-to-clipboard');
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
static getCopyToClipboardElement(index = 0) {
|
|
60
|
+
return ChatPanelSteps.getCopyToClipboardElements().eq(index);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
@@ -0,0 +1,462 @@
|
|
|
1
|
+
import {ModalDialogSteps} from "../modal-dialog-steps";
|
|
2
|
+
|
|
3
|
+
export class TtygAgentSettingsModalSteps extends ModalDialogSteps {
|
|
4
|
+
|
|
5
|
+
static getSaveAgentButton() {
|
|
6
|
+
return this.getDialog().find('.save-agent-settings-btn');
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
static saveAgent() {
|
|
10
|
+
this.getSaveAgentButton().click();
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
// =========================
|
|
14
|
+
// Form fields
|
|
15
|
+
// =========================
|
|
16
|
+
|
|
17
|
+
// Agent name
|
|
18
|
+
|
|
19
|
+
static getAgentNameFormGroup() {
|
|
20
|
+
return this.getDialog().find('.agent-name-label');
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
static getAgentNameField() {
|
|
24
|
+
return this.getAgentNameFormGroup().find('input');
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
static typeAgentName(name) {
|
|
28
|
+
this.getAgentNameField().type(name);
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
static clearAgentName() {
|
|
32
|
+
this.getAgentNameField().clear();
|
|
33
|
+
cy.realPress('Tab');
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
static getAgentNameError() {
|
|
37
|
+
return this.getAgentNameFormGroup().find('.alert-danger');
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
// Repository ID
|
|
41
|
+
|
|
42
|
+
static getRepositoryIdFromGroup() {
|
|
43
|
+
return this.getDialog().find('.repository-id');
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
static getRepositorySelect() {
|
|
47
|
+
return this.getRepositoryIdFromGroup().find('select');
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
static selectRepository(repositoryId) {
|
|
51
|
+
this.getRepositorySelect().select(repositoryId);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
static getRepositoryIdError() {
|
|
55
|
+
return this.getRepositoryIdFromGroup().find('.alert-danger');
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
static verifyRepositorySelected(repositoryId) {
|
|
59
|
+
this.getRepositorySelect().find('option:selected').should('have.text', repositoryId);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
static verifyRepositoryOptionNotExist(repositoryId) {
|
|
63
|
+
this.getRepositorySelect().each(($select) => {
|
|
64
|
+
cy.wrap($select).find('option').should('not.contain.text', repositoryId);
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
// Extraction methods
|
|
69
|
+
|
|
70
|
+
static getExtractionMethodError() {
|
|
71
|
+
return this.getDialog().find('.extraction-methods-group .extraction-method-required-error');
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
static getExtractionMethod(method) {
|
|
75
|
+
return this.getDialog().find(`#${method}_method_heading`);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
static getSelectedExtractionMethods() {
|
|
79
|
+
return this.getDialog().find('.extraction-method-heading.selected');
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
static getSelectedExtractionMethod(index) {
|
|
83
|
+
return this.getSelectedExtractionMethods().eq(index);
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
static getExtractionMethodPanel(method) {
|
|
87
|
+
return this.getDialog().find(`#${method}_method_content`).find('.extraction-method-options');
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
// SPARQL extraction method
|
|
91
|
+
|
|
92
|
+
static enableSparqlExtractionMethod() {
|
|
93
|
+
this.getExtractionMethod('sparql_search').find('.extraction-method-toggle label').click();
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
static disableSparqlExtractionMethod() {
|
|
97
|
+
this.getExtractionMethod('sparql_search').find('.extraction-method-toggle label').click();
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
static toggleSparqlExtractionMethodPanel() {
|
|
101
|
+
this.getExtractionMethod('sparql_search').find('.panel-toggle-link').click();
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
static getSparqlExtractionMethodPanel() {
|
|
105
|
+
return this.getExtractionMethodPanel('sparql_search');
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
static getSparqlExtractionMethodError() {
|
|
109
|
+
return this.getSparqlExtractionMethodPanel().find('.sparql-method-option-required-error.alert-danger');
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
static selectSparqlMethodOntologyGraph() {
|
|
113
|
+
this.getSparqlExtractionMethodPanel().find('.ontology-graph-option input[type=radio]').click();
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
static getSparqlMethodOntologyGraphField() {
|
|
117
|
+
return this.getSparqlExtractionMethodPanel().find('#ontologyGraph');
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
static clearSparqlMethodOntologyGraphField() {
|
|
121
|
+
return this.getSparqlMethodOntologyGraphField().clear();
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
static typeSparqlMethodOntologyGraphField(value) {
|
|
125
|
+
return this.getSparqlMethodOntologyGraphField().type(value);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
static selectSparqlMethodSparqlQuery() {
|
|
129
|
+
this.getSparqlExtractionMethodPanel().find('.sparql-query-option input[type=radio]').click();
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
static getSparqlMethodSparqlQueryField() {
|
|
133
|
+
return this.getSparqlExtractionMethodPanel().find('#sparqlQuery');
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
static clearSparqlMethodSparqlQueryField() {
|
|
137
|
+
return this.getSparqlMethodSparqlQueryField().clear();
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
static typeSparqlMethodSparqlQueryField(value) {
|
|
141
|
+
// disabled the parsing of special character sequences because the value is a SPARQL query and may contain special characters
|
|
142
|
+
return this.getSparqlMethodSparqlQueryField().type(value, {parseSpecialCharSequences: false});
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
static getAddMissingNamespacesCheckbox() {
|
|
146
|
+
return cy.get('#addMissingNamespaces');
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
static toggleAddMissingNamespacesCheckbox() {
|
|
150
|
+
this.getAddMissingNamespacesCheckbox().click();
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
// FTS extraction method
|
|
154
|
+
|
|
155
|
+
static enableFtsExtractionMethod() {
|
|
156
|
+
this.getExtractionMethod('fts_search').find('.extraction-method-toggle label').click();
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
static disableFtsExtractionMethod() {
|
|
160
|
+
this.getExtractionMethod('fts_search').find('.extraction-method-toggle label').click();
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
static toggleFTSExtractionMethodPanel() {
|
|
164
|
+
this.getExtractionMethod('fts_search').find('.panel-toggle-link').click();
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
static getMissingRepositoryIdErrorInFtsSearchPanel() {
|
|
168
|
+
return this.getExtractionMethodPanel('fts_search').find('.missing-repositoryid-error');
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
static getFtsDisabledHelp() {
|
|
172
|
+
return this.getExtractionMethodPanel('fts_search').find('.fts-disabled-message');
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
static getFtsSearchMaxTriplesFormGroup() {
|
|
176
|
+
return this.getExtractionMethodPanel('fts_search').find('.max-triples');
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
// Similarity search method
|
|
180
|
+
|
|
181
|
+
static enableSimilaritySearchMethodPanel() {
|
|
182
|
+
this.getExtractionMethod('similarity_search')
|
|
183
|
+
.find('.extraction-method-toggle input[type="checkbox"]')
|
|
184
|
+
.should('not.be.checked')
|
|
185
|
+
.siblings('label')
|
|
186
|
+
.click();
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
static disableSimilaritySearchMethodPanel() {
|
|
190
|
+
this.getExtractionMethod('similarity_search')
|
|
191
|
+
.find('.extraction-method-toggle input[type="checkbox"]')
|
|
192
|
+
.should('be.checked') // Ensure the checkbox is checked
|
|
193
|
+
.siblings('label')
|
|
194
|
+
.click();
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
static toggleSimilaritySearchMethodPanel() {
|
|
198
|
+
this.getExtractionMethod('similarity_search').find('.panel-toggle-link').click();
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
static getSimilaritySearchIndexMissingHelp() {
|
|
202
|
+
return this.getExtractionMethodPanel('similarity_search').find('.no-similarity-index-message');
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
static clickOnSimilaritySearchIndexMissingHelp() {
|
|
206
|
+
this.getSimilaritySearchIndexMissingHelp().find('a').click();
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
static getSimilarityIndexFormGroup() {
|
|
210
|
+
return this.getExtractionMethodPanel('similarity_search').find('.similarity-index');
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
static getSimilarityIndexField() {
|
|
214
|
+
return this.getSimilarityIndexFormGroup().find('select');
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
static selectSimilarityIndex(index) {
|
|
218
|
+
this.getSimilarityIndexField().select(index);
|
|
219
|
+
}
|
|
220
|
+
|
|
221
|
+
static verifySimilarityIndexSelected(similarityIndex) {
|
|
222
|
+
this.getSimilarityIndexField().find('option:selected').should('have.text', similarityIndex);
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
static getSimilarityIndexThresholdFormGroup() {
|
|
226
|
+
return this.getExtractionMethodPanel('similarity_search').find('.similarity-index-threshold');
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
static getSimilarityIndexThresholdField() {
|
|
230
|
+
return this.getSimilarityIndexThresholdFormGroup().find('#similarityIndexThreshold');
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
static setSimilarityIndexThreshold(value) {
|
|
234
|
+
this.getSimilarityIndexThresholdField().invoke('val', value).trigger('input');
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
static getSimilarityIndexMaxTriplesFormGroup() {
|
|
238
|
+
return this.getExtractionMethodPanel('similarity_search').find('.similarity-max-triples');
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
static getSimilarityIndexMaxTriplesField() {
|
|
242
|
+
return this.getSimilarityIndexMaxTriplesFormGroup().find('input');
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
static setSimilarityIndexMaxTriples(value) {
|
|
246
|
+
this.getSimilarityIndexMaxTriplesField().invoke('val', value).trigger('input');
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
// Retrieval method
|
|
250
|
+
|
|
251
|
+
static enableRetrievalMethodPanel() {
|
|
252
|
+
this.getExtractionMethod('retrieval_search')
|
|
253
|
+
.find('.extraction-method-toggle input[type="checkbox"]')
|
|
254
|
+
.should('not.be.checked')
|
|
255
|
+
.siblings('label')
|
|
256
|
+
.click();
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
static disableRetrievalMethodPanel() {
|
|
260
|
+
this.getExtractionMethod('retrieval_search')
|
|
261
|
+
.find('.extraction-method-toggle input[type="checkbox"]')
|
|
262
|
+
.should('be.checked')
|
|
263
|
+
.siblings('label')
|
|
264
|
+
.click();
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
static toggleRetrievalMethodPanel() {
|
|
268
|
+
this.getExtractionMethod('retrieval_search').find('.panel-toggle-link').click();
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
static getMissingRetrievalConnectorHelp() {
|
|
272
|
+
return this.getExtractionMethodPanel('retrieval_search').find('.no-retrieval-connector-message');
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
static clickOnMissingRetrievalConnectorHelp() {
|
|
276
|
+
this.getMissingRetrievalConnectorHelp().find('a').click();
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
static getRetrievalConnectorFormGroup() {
|
|
280
|
+
return this.getExtractionMethodPanel('retrieval_search').find('.retrieval-connector');
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
static getRetrievalConnectorField() {
|
|
284
|
+
return this.getRetrievalConnectorFormGroup().find('select');
|
|
285
|
+
}
|
|
286
|
+
|
|
287
|
+
static selectRetrievalConnector(connector) {
|
|
288
|
+
this.getRetrievalConnectorField().select(connector);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
static getQueryTemplateFormGroup() {
|
|
292
|
+
return this.getExtractionMethodPanel('retrieval_search').find('.query-template');
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
static getQueryTemplateField() {
|
|
296
|
+
return this.getQueryTemplateFormGroup().find('textarea');
|
|
297
|
+
}
|
|
298
|
+
|
|
299
|
+
static clearQueryTemplate() {
|
|
300
|
+
this.getQueryTemplateField().clear();
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
static typeQueryTemplate(value) {
|
|
304
|
+
// disabled the parsing of special character sequences because the value is a SPARQL query and may contain special characters
|
|
305
|
+
return this.getQueryTemplateField().type(value, {parseSpecialCharSequences: false});
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
static getRetrievalMaxTriplesFormGroup() {
|
|
309
|
+
return this.getExtractionMethodPanel('retrieval_search').find('.retrieval-connector-max-triples');
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
static getRetrievalMaxTriplesField() {
|
|
313
|
+
return this.getRetrievalMaxTriplesFormGroup().find('input');
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
static setRetrievalMaxTriples(value) {
|
|
317
|
+
this.getRetrievalMaxTriplesField().invoke('val', value).trigger('input');
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
static verifyRetrievalConnectorSelected(connectorName) {
|
|
321
|
+
this.getRetrievalConnectorField().find('option:selected').should('have.text', connectorName);
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
// GPT model
|
|
325
|
+
|
|
326
|
+
static getGptModelFormGroup() {
|
|
327
|
+
return this.getDialog().find('.gpt-model');
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
static getGptModelField() {
|
|
331
|
+
return this.getGptModelFormGroup().find('input');
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
static clearGptModel() {
|
|
335
|
+
this.getGptModelField().clear();
|
|
336
|
+
cy.realPress('Tab');
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
static getGptModelError() {
|
|
340
|
+
return this.getGptModelFormGroup().find('.alert-danger');
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
static typeGptModel(value) {
|
|
344
|
+
return this.getGptModelField().type(value);
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
// temperature
|
|
348
|
+
|
|
349
|
+
static getTemperatureFormGroup() {
|
|
350
|
+
return this.getDialog().find('.temperature');
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
static getTemperatureField() {
|
|
354
|
+
return this.getTemperatureFormGroup().find('#temperature');
|
|
355
|
+
}
|
|
356
|
+
|
|
357
|
+
static getTemperatureSliderField() {
|
|
358
|
+
return this.getTemperatureFormGroup().find('#temperatureSlider');
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
static setTemperature(value) {
|
|
362
|
+
this.getTemperatureSliderField().invoke('val', value).trigger('input');
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
static getTemperatureWarning() {
|
|
366
|
+
return this.getTemperatureFormGroup().find('.high-temperature-warning');
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
// Top P
|
|
370
|
+
|
|
371
|
+
static getTopPFormGroup() {
|
|
372
|
+
return this.getDialog().find('.top-p');
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
static getTopPField() {
|
|
376
|
+
return this.getTopPFormGroup().find('#topP');
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
static setTopP(value) {
|
|
380
|
+
this.getTopPField().invoke('val', value).trigger('input');
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
// Seed
|
|
384
|
+
|
|
385
|
+
static getSeedFormGroup() {
|
|
386
|
+
return this.getDialog().find('.seed');
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
static getSeedField() {
|
|
390
|
+
return this.getSeedFormGroup().find('#seed');
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
static clearSeed() {
|
|
394
|
+
this.getSeedField().clear();
|
|
395
|
+
cy.realPress('Tab');
|
|
396
|
+
}
|
|
397
|
+
|
|
398
|
+
static typeSeed(value) {
|
|
399
|
+
return this.getSeedField().type(value);
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
// Additional query methods
|
|
403
|
+
static getIriDiscoverySearchCheckbox() {
|
|
404
|
+
return cy.get('#iri_discovery_search_checkbox');
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
static checkIriDiscoverySearchCheckbox() {
|
|
408
|
+
this.getIriDiscoverySearchCheckbox().check({force: true});
|
|
409
|
+
}
|
|
410
|
+
|
|
411
|
+
static uncheckIriDiscoverySearchCheckbox() {
|
|
412
|
+
this.getIriDiscoverySearchCheckbox().uncheck({force: true});
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
// System instructions
|
|
416
|
+
|
|
417
|
+
static getSystemInstructionsFormGroup() {
|
|
418
|
+
return this.getDialog().find('.system-instructions');
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
static getSystemInstructionsField() {
|
|
422
|
+
return this.getSystemInstructionsFormGroup().find('#systemInstruction');
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
static getSystemInstructionsWarning() {
|
|
426
|
+
return this.getSystemInstructionsFormGroup().find('.overriding-system-instructions-warning');
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
static clearSystemInstructions() {
|
|
430
|
+
this.getSystemInstructionsField().clear();
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
static typeSystemInstructions(value) {
|
|
434
|
+
return this.getSystemInstructionsField().type(value);
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
// User instructions
|
|
438
|
+
|
|
439
|
+
static getUserInstructionsFormGroup() {
|
|
440
|
+
return this.getDialog().find('.user-instructions');
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
static getUserInstructionsField() {
|
|
444
|
+
return this.getUserInstructionsFormGroup().find('#userInstruction');
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
static clearUserInstructions() {
|
|
448
|
+
this.getUserInstructionsField().clear();
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
static typeUserInstructions(value) {
|
|
452
|
+
return this.getUserInstructionsField().type(value);
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
static toggleAdvancedSettings() {
|
|
456
|
+
this.getDialog().find('.toggle-advanced-settings').click();
|
|
457
|
+
}
|
|
458
|
+
|
|
459
|
+
static getCreatingAgentLoader() {
|
|
460
|
+
return this.getDialog().find('.saving-agent-loader');
|
|
461
|
+
}
|
|
462
|
+
}
|