@tilde-nlp/ngx-services 6.0.8 → 6.0.10
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/esm2022/lib/anonymisation/anonymisation.service.mjs +8 -5
- package/esm2022/lib/anonymisation/models/class-categories.model.mjs +2 -0
- package/esm2022/lib/anonymisation/models/class-category.model.mjs +1 -1
- package/fesm2022/tilde-nlp-ngx-services.mjs +7 -4
- package/fesm2022/tilde-nlp-ngx-services.mjs.map +1 -1
- package/lib/anonymisation/anonymisation.service.d.ts +7 -4
- package/lib/anonymisation/models/class-categories.model.d.ts +4 -0
- package/lib/anonymisation/models/class-category.model.d.ts +1 -1
- package/package.json +1 -1
|
@@ -11,7 +11,10 @@ export class AnonymisationService extends BaseService {
|
|
|
11
11
|
return this.#http.get(`${this.configuration.url}/anonymisation/settings`);
|
|
12
12
|
}
|
|
13
13
|
setSettings(settings) {
|
|
14
|
-
return this.#http.put(`${this.configuration.url}/anonymisation/settings`, settings);
|
|
14
|
+
return this.#http.put(`${this.configuration.url}/anonymisation/settings`, { classCategories: settings });
|
|
15
|
+
}
|
|
16
|
+
getDocumentJson(id) {
|
|
17
|
+
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/json`);
|
|
15
18
|
}
|
|
16
19
|
getDocumentById(id) {
|
|
17
20
|
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}`);
|
|
@@ -20,7 +23,7 @@ export class AnonymisationService extends BaseService {
|
|
|
20
23
|
return this.#http.get(`${this.configuration.url}/anonymisation/document/list`);
|
|
21
24
|
}
|
|
22
25
|
downloadDocument(id, extension) {
|
|
23
|
-
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: '
|
|
26
|
+
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: 'blob' });
|
|
24
27
|
}
|
|
25
28
|
deleteDocument(id) {
|
|
26
29
|
return this.#http.delete(`${this.configuration.url}/anonymisation/document/${id}`);
|
|
@@ -29,9 +32,9 @@ export class AnonymisationService extends BaseService {
|
|
|
29
32
|
const formData = new FormData;
|
|
30
33
|
formData.append('Title', body.title);
|
|
31
34
|
formData.append('Language', body.language);
|
|
32
|
-
formData.append('ClassCategories', JSON.stringify(body.classCategories));
|
|
33
35
|
formData.append('File', body.file);
|
|
34
|
-
|
|
36
|
+
const classCategories = JSON.stringify(body.classCategories);
|
|
37
|
+
return this.#http.post(`${this.configuration.url}/anonymisation/document?ClassCategories=${encodeURIComponent(classCategories)}`, formData, { reportProgress: true, observe: "events" });
|
|
35
38
|
}
|
|
36
39
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.7", ngImport: i0, type: AnonymisationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
37
40
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.7", ngImport: i0, type: AnonymisationService, providedIn: 'root' }); }
|
|
@@ -42,4 +45,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.7", ngImpor
|
|
|
42
45
|
providedIn: 'root'
|
|
43
46
|
}]
|
|
44
47
|
}], ctorParameters: () => [] });
|
|
45
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
48
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYW5vbnltaXNhdGlvbi5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmd4LXNlcnZpY2VzL3NyYy9saWIvYW5vbnltaXNhdGlvbi9hbm9ueW1pc2F0aW9uLnNlcnZpY2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFVBQVUsRUFBYSxNQUFNLHNCQUFzQixDQUFDO0FBQzdELE9BQU8sRUFBRSxNQUFNLEVBQUUsVU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fQ==
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export {};
|
|
2
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
2
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2xhc3MtY2F0ZWdvcnkubW9kZWwuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9uZ3gtc2VydmljZXMvc3JjL2xpYi9hbm9ueW1pc2F0aW9uL21vZGVscy9jbGFzcy1jYXRlZ29yeS5tb2RlbC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIiwic291cmNlc0NvbnRlbnQiOlsiZXhwb3J0IGludGVyZmFjZSBDbGFzc0NhdGVnb3J5IHtcclxuICBpZD86IG51bWJlcjtcclxuICBuYW1lOiBzdHJpbmc7XHJcbiAgbWV0aG9kOiBzdHJpbmc7XHJcbiAgZW5hYmxlZDogYm9vbGVhbjtcclxufVxyXG4iXX0=
|
|
@@ -119,7 +119,10 @@ class AnonymisationService extends BaseService {
|
|
|
119
119
|
return this.#http.get(`${this.configuration.url}/anonymisation/settings`);
|
|
120
120
|
}
|
|
121
121
|
setSettings(settings) {
|
|
122
|
-
return this.#http.put(`${this.configuration.url}/anonymisation/settings`, settings);
|
|
122
|
+
return this.#http.put(`${this.configuration.url}/anonymisation/settings`, { classCategories: settings });
|
|
123
|
+
}
|
|
124
|
+
getDocumentJson(id) {
|
|
125
|
+
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/json`);
|
|
123
126
|
}
|
|
124
127
|
getDocumentById(id) {
|
|
125
128
|
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}`);
|
|
@@ -128,7 +131,7 @@ class AnonymisationService extends BaseService {
|
|
|
128
131
|
return this.#http.get(`${this.configuration.url}/anonymisation/document/list`);
|
|
129
132
|
}
|
|
130
133
|
downloadDocument(id, extension) {
|
|
131
|
-
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: '
|
|
134
|
+
return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: 'blob' });
|
|
132
135
|
}
|
|
133
136
|
deleteDocument(id) {
|
|
134
137
|
return this.#http.delete(`${this.configuration.url}/anonymisation/document/${id}`);
|
|
@@ -137,9 +140,9 @@ class AnonymisationService extends BaseService {
|
|
|
137
140
|
const formData = new FormData;
|
|
138
141
|
formData.append('Title', body.title);
|
|
139
142
|
formData.append('Language', body.language);
|
|
140
|
-
formData.append('ClassCategories', JSON.stringify(body.classCategories));
|
|
141
143
|
formData.append('File', body.file);
|
|
142
|
-
|
|
144
|
+
const classCategories = JSON.stringify(body.classCategories);
|
|
145
|
+
return this.#http.post(`${this.configuration.url}/anonymisation/document?ClassCategories=${encodeURIComponent(classCategories)}`, formData, { reportProgress: true, observe: "events" });
|
|
143
146
|
}
|
|
144
147
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.7", ngImport: i0, type: AnonymisationService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
145
148
|
static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.7", ngImport: i0, type: AnonymisationService, providedIn: 'root' }); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tilde-nlp-ngx-services.mjs","sources":["../../../projects/ngx-services/src/lib/tokens/service-configuration.token.ts","../../../projects/ngx-services/src/lib/base-service/base.service.ts","../../../projects/ngx-services/src/lib/mt-proxy/mt-proxy.service.ts","../../../projects/ngx-services/src/lib/llm-service/models/llm-writing-style.enum.ts","../../../projects/ngx-services/src/lib/helpers/custom-headers.helper.ts","../../../projects/ngx-services/src/lib/llm-service/llm.service.ts","../../../projects/ngx-services/src/lib/quota-service/models/quota-type.enum.ts","../../../projects/ngx-services/src/lib/quota-service/quota.service.ts","../../../projects/ngx-services/src/lib/anonymisation/anonymisation.service.ts","../../../projects/ngx-services/src/public-api.ts","../../../projects/ngx-services/src/tilde-nlp-ngx-services.ts"],"sourcesContent":["import { InjectionToken } from \"@angular/core\";\r\nimport { ServiceConfiguration } from \"../configuration/service-configuration.model\";\r\n\r\nexport const serviceConfigurationToken = new InjectionToken<ServiceConfiguration>(\"ngx-tld-services Api service configuration.\");\r\n","import { inject } from \"@angular/core\";\r\nimport { serviceConfigurationToken } from \"../tokens/service-configuration.token\";\r\nimport { ServiceConfiguration } from \"../configuration/service-configuration.model\";\r\nimport { HttpClient } from \"@angular/common/http\";\r\nimport { SharedServiceConfiguration } from \"../configuration/shared-service-configuration.model\";\r\n\r\nexport abstract class BaseService<ConfigType> {\r\n readonly configuration: ConfigType;\r\n readonly sharedServiceConfiguration: SharedServiceConfiguration;\r\n\r\n readonly http: HttpClient = inject(HttpClient);\r\n\r\n readonly #allServiceConfiguration = inject(serviceConfigurationToken);\r\n\r\n constructor(getConfig: (allServiceConfiguration: ServiceConfiguration) => ConfigType | undefined) {\r\n const serviceConfig = getConfig(this.#allServiceConfiguration);\r\n\r\n if (!serviceConfig) {\r\n throw new Error(`${Object.getPrototypeOf(this).constructor.name} is created, but no service configuration defined in 'serviceConfigurationToken'. Config: ${JSON.stringify(this.#allServiceConfiguration)}`);\r\n }\r\n this.configuration = serviceConfig;\r\n this.sharedServiceConfiguration = this.#allServiceConfiguration.sharedConfiguration;\r\n }\r\n\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable, inject } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { LanguageDirectionResponse } from './models/language-direction-response.model';\r\nimport { MtProxyConfiguration } from './models/mt-proxy-configuration.model';\r\nimport { TextTranslationRequest } from './models/text-translation-request.model';\r\nimport { TextTranslationResponse } from './models/text-translation-response.model';\r\nimport { BaseService } from '../base-service/base.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MtProxyService extends BaseService<MtProxyConfiguration> {\r\n\r\n readonly #httpClient = inject(HttpClient);\r\n\r\n get #baseUrl() {\r\n return `${this.configuration.url}/translate`\r\n }\r\n\r\n constructor() {\r\n super(config => config.mtProxyService);\r\n }\r\n\r\n /**\r\n *\r\n * @returns available language directions.\r\n */\r\n getLanguageDirections(): Observable<LanguageDirectionResponse> {\r\n return this.#httpClient.get<LanguageDirectionResponse>(`${this.#baseUrl}/language-directions`);\r\n }\r\n\r\n translateText(request: TextTranslationRequest): Observable<TextTranslationResponse> {\r\n return this.#httpClient.post<TextTranslationResponse>(`${this.#baseUrl}/text`, request);\r\n }\r\n}\r\n","export enum LLMWritingStyle {\r\n GENERAL = 'General',\r\n PROFESSIONAL = 'Professional',\r\n ACADEMIC = 'Academic'\r\n}","export class CustomHeadersHelper {\r\n static xAppIdHeader(appId: string) {\r\n return { \"X-App-Id\": appId };\r\n }\r\n}\r\n","import { HttpClient } from \"@angular/common/http\";\r\nimport { inject, Injectable } from \"@angular/core\";\r\nimport { Observable } from \"rxjs\";\r\nimport { BaseService } from \"../base-service/base.service\";\r\nimport { CustomHeadersHelper } from \"../helpers/custom-headers.helper\";\r\nimport { LLMRephraseRequest } from \"./models/llm-rephrase-request.model\";\r\nimport { LLMServiceConfiguration } from \"./models/llm-service-configuration.model\";\r\nimport { LLMSummarizeRequest } from \"./models/llm-summarize-request.model\";\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LLMService extends BaseService<LLMServiceConfiguration> {\r\n readonly #http = inject(HttpClient);\r\n\r\n constructor() {\r\n super(config => config.llmService);\r\n }\r\n\r\n summarize(request: LLMSummarizeRequest): Observable<string> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.#http.post(`${this.configuration.url}/summarize`, request, { responseType: \"text\", headers })\r\n }\r\n\r\n rephrase(request: LLMRephraseRequest): Observable<string> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.#http.post(`${this.configuration.url}/rewrite`, request, { responseType: \"text\", headers })\r\n }\r\n}\r\n","export enum QuotaType {\r\n\tTRANSLATION_DOCUMENTS = 'TranslationDocuments',\r\n\tLLM_CHARACTER_COUNT = 'LlmCharacterCount',\r\n\tLLM_REQUESTS = 'LlmRequests',\r\n LEGACY_TRANSLATION_DOCUMENTS= 5,\r\n LEGACY_LLM_CHARACTER_COUNT = 6,\r\n\tLEGACY_LLM_REQUESTS = 7,\r\n}\r\n","import { Injectable } from \"@angular/core\";\r\nimport { QuotaServiceConfiguration } from \"./models/quota-service-configuration.model\";\r\nimport { BaseService } from \"../base-service/base.service\";\r\nimport { Observable } from \"rxjs\";\r\nimport { QuotaUsage } from \"./models/quota-usage.model\";\r\nimport { CustomHeadersHelper } from \"../helpers/custom-headers.helper\";\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class QuotaService extends BaseService<QuotaServiceConfiguration> {\r\n\r\n constructor() {\r\n super(config => config.quotaService);\r\n }\r\n\r\n getQuotaUsage(): Observable<{ usage: QuotaUsage[] }> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.http.get<{ usage: QuotaUsage[] }>(this.configuration.url, { headers });\r\n }\r\n}\r\n","import { HttpClient, HttpEvent } from '@angular/common/http';\r\nimport { inject, Injectable } from '@angular/core';\r\nimport { BaseService } from '../base-service/base.service';\r\nimport { AnonymisationServiceConfiguration } from './models/anonymisation-configuration.model';\r\nimport { Observable } from 'rxjs';\r\nimport { Document } from './models/document.model';\r\nimport { ClassCategory, UploadDocument } from './models';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class AnonymisationService extends BaseService<AnonymisationServiceConfiguration> {\r\n readonly #http = inject(HttpClient);\r\n\r\n constructor() {\r\n super(config => config.anonymisationsService);\r\n }\r\n\r\n getSettings(): Observable<ClassCategory[]> {\r\n return this.#http.get<ClassCategory[]>(`${this.configuration.url}/anonymisation/settings`);\r\n }\r\n\r\n setSettings(settings: ClassCategory[]): Observable<ClassCategory[]> {\r\n return this.#http.put<ClassCategory[]>(`${this.configuration.url}/anonymisation/settings`, settings);\r\n }\r\n\r\n getDocumentById(id: string): Observable<Document> {\r\n return this.#http.get<Document>(`${this.configuration.url}/anonymisation/document/${id}`);\r\n }\r\n\r\n getDocumentList(): Observable<Document[]> {\r\n return this.#http.get<Document[]>(`${this.configuration.url}/anonymisation/document/list`);\r\n }\r\n\r\n downloadDocument(id: string, extension: string): Observable<string> {\r\n return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: 'text' });\r\n }\r\n\r\n deleteDocument(id: string): Observable<void> {\r\n return this.#http.delete<void>(`${this.configuration.url}/anonymisation/document/${id}`);\r\n }\r\n\r\n uploadDocument(body: UploadDocument): Observable<HttpEvent<Document>> {\r\n const formData = new FormData;\r\n formData.append('Title', body.title);\r\n formData.append('Language', body.language);\r\n formData.append('ClassCategories', JSON.stringify(body.classCategories));\r\n formData.append('File', body.file);\r\n\r\n return this.#http.post<Document>(`${this.configuration.url}/anonymisation/document`, formData, { reportProgress: true, observe: \"events\" });\r\n }\r\n}\r\n","/*\r\n * Public API Surface of ngx-services\r\n */\r\n\r\nexport * from './lib';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAGa,yBAAyB,GAAG,IAAI,cAAc,CAAuB,6CAA6C;;MCGzG,WAAW,CAAA;AAMtB,IAAA,wBAAwB,CAAqC;AAEtE,IAAA,WAAA,CAAY,SAAoF,EAAA;AAJvF,QAAA,IAAA,CAAA,IAAI,GAAe,MAAM,CAAC,UAAU,CAAC,CAAC;AAEtC,QAAA,IAAA,CAAA,wBAAwB,GAAG,MAAM,CAAC,yBAAyB,CAAC,CAAC;QAGpE,MAAM,aAAa,GAAG,SAAS,CAAC,IAAI,CAAC,wBAAwB,CAAC,CAAC;QAE/D,IAAI,CAAC,aAAa,EAAE;YAClB,MAAM,IAAI,KAAK,CAAC,CAA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IAAI,CAAC,aAAa,CAAC,GAAG,CAAA,uBAAA,CAAyB,EAAE,QAAQ,EAAE,EAAE,cAAc,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,CAAC;KAC7I;8GAvCU,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAApB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,cAFnB,MAAM,EAAA,CAAA,CAAA,EAAA;;2FAEP,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAHhC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACVD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"tilde-nlp-ngx-services.mjs","sources":["../../../projects/ngx-services/src/lib/tokens/service-configuration.token.ts","../../../projects/ngx-services/src/lib/base-service/base.service.ts","../../../projects/ngx-services/src/lib/mt-proxy/mt-proxy.service.ts","../../../projects/ngx-services/src/lib/llm-service/models/llm-writing-style.enum.ts","../../../projects/ngx-services/src/lib/helpers/custom-headers.helper.ts","../../../projects/ngx-services/src/lib/llm-service/llm.service.ts","../../../projects/ngx-services/src/lib/quota-service/models/quota-type.enum.ts","../../../projects/ngx-services/src/lib/quota-service/quota.service.ts","../../../projects/ngx-services/src/lib/anonymisation/anonymisation.service.ts","../../../projects/ngx-services/src/public-api.ts","../../../projects/ngx-services/src/tilde-nlp-ngx-services.ts"],"sourcesContent":["import { InjectionToken } from \"@angular/core\";\r\nimport { ServiceConfiguration } from \"../configuration/service-configuration.model\";\r\n\r\nexport const serviceConfigurationToken = new InjectionToken<ServiceConfiguration>(\"ngx-tld-services Api service configuration.\");\r\n","import { inject } from \"@angular/core\";\r\nimport { serviceConfigurationToken } from \"../tokens/service-configuration.token\";\r\nimport { ServiceConfiguration } from \"../configuration/service-configuration.model\";\r\nimport { HttpClient } from \"@angular/common/http\";\r\nimport { SharedServiceConfiguration } from \"../configuration/shared-service-configuration.model\";\r\n\r\nexport abstract class BaseService<ConfigType> {\r\n readonly configuration: ConfigType;\r\n readonly sharedServiceConfiguration: SharedServiceConfiguration;\r\n\r\n readonly http: HttpClient = inject(HttpClient);\r\n\r\n readonly #allServiceConfiguration = inject(serviceConfigurationToken);\r\n\r\n constructor(getConfig: (allServiceConfiguration: ServiceConfiguration) => ConfigType | undefined) {\r\n const serviceConfig = getConfig(this.#allServiceConfiguration);\r\n\r\n if (!serviceConfig) {\r\n throw new Error(`${Object.getPrototypeOf(this).constructor.name} is created, but no service configuration defined in 'serviceConfigurationToken'. Config: ${JSON.stringify(this.#allServiceConfiguration)}`);\r\n }\r\n this.configuration = serviceConfig;\r\n this.sharedServiceConfiguration = this.#allServiceConfiguration.sharedConfiguration;\r\n }\r\n\r\n}\r\n","import { HttpClient } from '@angular/common/http';\r\nimport { Injectable, inject } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { LanguageDirectionResponse } from './models/language-direction-response.model';\r\nimport { MtProxyConfiguration } from './models/mt-proxy-configuration.model';\r\nimport { TextTranslationRequest } from './models/text-translation-request.model';\r\nimport { TextTranslationResponse } from './models/text-translation-response.model';\r\nimport { BaseService } from '../base-service/base.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MtProxyService extends BaseService<MtProxyConfiguration> {\r\n\r\n readonly #httpClient = inject(HttpClient);\r\n\r\n get #baseUrl() {\r\n return `${this.configuration.url}/translate`\r\n }\r\n\r\n constructor() {\r\n super(config => config.mtProxyService);\r\n }\r\n\r\n /**\r\n *\r\n * @returns available language directions.\r\n */\r\n getLanguageDirections(): Observable<LanguageDirectionResponse> {\r\n return this.#httpClient.get<LanguageDirectionResponse>(`${this.#baseUrl}/language-directions`);\r\n }\r\n\r\n translateText(request: TextTranslationRequest): Observable<TextTranslationResponse> {\r\n return this.#httpClient.post<TextTranslationResponse>(`${this.#baseUrl}/text`, request);\r\n }\r\n}\r\n","export enum LLMWritingStyle {\r\n GENERAL = 'General',\r\n PROFESSIONAL = 'Professional',\r\n ACADEMIC = 'Academic'\r\n}","export class CustomHeadersHelper {\r\n static xAppIdHeader(appId: string) {\r\n return { \"X-App-Id\": appId };\r\n }\r\n}\r\n","import { HttpClient } from \"@angular/common/http\";\r\nimport { inject, Injectable } from \"@angular/core\";\r\nimport { Observable } from \"rxjs\";\r\nimport { BaseService } from \"../base-service/base.service\";\r\nimport { CustomHeadersHelper } from \"../helpers/custom-headers.helper\";\r\nimport { LLMRephraseRequest } from \"./models/llm-rephrase-request.model\";\r\nimport { LLMServiceConfiguration } from \"./models/llm-service-configuration.model\";\r\nimport { LLMSummarizeRequest } from \"./models/llm-summarize-request.model\";\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LLMService extends BaseService<LLMServiceConfiguration> {\r\n readonly #http = inject(HttpClient);\r\n\r\n constructor() {\r\n super(config => config.llmService);\r\n }\r\n\r\n summarize(request: LLMSummarizeRequest): Observable<string> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.#http.post(`${this.configuration.url}/summarize`, request, { responseType: \"text\", headers })\r\n }\r\n\r\n rephrase(request: LLMRephraseRequest): Observable<string> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.#http.post(`${this.configuration.url}/rewrite`, request, { responseType: \"text\", headers })\r\n }\r\n}\r\n","export enum QuotaType {\r\n\tTRANSLATION_DOCUMENTS = 'TranslationDocuments',\r\n\tLLM_CHARACTER_COUNT = 'LlmCharacterCount',\r\n\tLLM_REQUESTS = 'LlmRequests',\r\n LEGACY_TRANSLATION_DOCUMENTS= 5,\r\n LEGACY_LLM_CHARACTER_COUNT = 6,\r\n\tLEGACY_LLM_REQUESTS = 7,\r\n}\r\n","import { Injectable } from \"@angular/core\";\r\nimport { QuotaServiceConfiguration } from \"./models/quota-service-configuration.model\";\r\nimport { BaseService } from \"../base-service/base.service\";\r\nimport { Observable } from \"rxjs\";\r\nimport { QuotaUsage } from \"./models/quota-usage.model\";\r\nimport { CustomHeadersHelper } from \"../helpers/custom-headers.helper\";\r\n\r\n\r\n@Injectable({\r\n providedIn: 'root',\r\n})\r\nexport class QuotaService extends BaseService<QuotaServiceConfiguration> {\r\n\r\n constructor() {\r\n super(config => config.quotaService);\r\n }\r\n\r\n getQuotaUsage(): Observable<{ usage: QuotaUsage[] }> {\r\n const headers = CustomHeadersHelper.xAppIdHeader(this.sharedServiceConfiguration.xAppId);\r\n return this.http.get<{ usage: QuotaUsage[] }>(this.configuration.url, { headers });\r\n }\r\n}\r\n","import { HttpClient, HttpEvent } from '@angular/common/http';\r\nimport { inject, Injectable } from '@angular/core';\r\nimport { BaseService } from '../base-service/base.service';\r\nimport { AnonymisationServiceConfiguration } from './models/anonymisation-configuration.model';\r\nimport { Observable } from 'rxjs';\r\nimport { Document } from './models/document.model';\r\nimport { UploadDocument } from './models';\r\nimport { ClassCategory } from './models/class-category.model';\r\nimport { ClassCategories } from './models/class-categories.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class AnonymisationService extends BaseService<AnonymisationServiceConfiguration> {\r\n readonly #http = inject(HttpClient);\r\n\r\n constructor() {\r\n super(config => config.anonymisationsService);\r\n }\r\n\r\n getSettings(): Observable<ClassCategories> {\r\n return this.#http.get<ClassCategories>(`${this.configuration.url}/anonymisation/settings`);\r\n }\r\n\r\n setSettings(settings: ClassCategory[]): Observable<ClassCategories> {\r\n return this.#http.put<ClassCategories>(`${this.configuration.url}/anonymisation/settings`, { classCategories: settings });\r\n }\r\n\r\n getDocumentJson(id: string): Observable<string> {\r\n return this.#http.get<string>(`${this.configuration.url}/anonymisation/document/${id}/json`);\r\n }\r\n\r\n getDocumentById(id: string): Observable<Document> {\r\n return this.#http.get<Document>(`${this.configuration.url}/anonymisation/document/${id}`);\r\n }\r\n\r\n getDocumentList(): Observable<Document[]> {\r\n return this.#http.get<Document[]>(`${this.configuration.url}/anonymisation/document/list`);\r\n }\r\n\r\n downloadDocument(id: string, extension: string): Observable<Blob> {\r\n return this.#http.get(`${this.configuration.url}/anonymisation/document/${id}/${extension}`, { responseType: 'blob' });\r\n }\r\n\r\n deleteDocument(id: string): Observable<void> {\r\n return this.#http.delete<void>(`${this.configuration.url}/anonymisation/document/${id}`);\r\n }\r\n\r\n uploadDocument(body: UploadDocument): Observable<HttpEvent<Document>> {\r\n const formData = new FormData;\r\n formData.append('Title', body.title);\r\n formData.append('Language', body.language);\r\n formData.append('File', body.file);\r\n\r\n const classCategories = JSON.stringify(body.classCategories);\r\n\r\n return this.#http.post<Document>(`${this.configuration.url}/anonymisation/document?ClassCategories=${encodeURIComponent(classCategories)}`, formData, { reportProgress: true, observe: \"events\" });\r\n }\r\n}\r\n","/*\r\n * Public API Surface of ngx-services\r\n */\r\n\r\nexport * from './lib';\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;MAGa,yBAAyB,GAAG,IAAI,cAAc,CAAuB,6CAA6C;;MCGzG,WAAW,CAAA;AAMtB,IAAA,wBAAwB,CAAqC;AAEtE,IAAA,WAAA,CAAY,SAAoF,EAAA;AAJvF,QAAA,IAAA,CAAA,IAAI,GAAe,MAAM,CAAC,UAAU,CAAC,CAAC;AAEtC,QAAA,IAAA,CAAA,wBAAwB,GAAG,MAAM,CAAC,yBAAyB,CAAC,CAAC;QAGpE,MAAM,aAAa,GAAG,SAAS,CAAC,IAAI,CAAC,wBAAwB,CAAC,CAAC;QAE/D,IAAI,CAAC,aAAa,EAAE;YAClB,MAAM,IAAI,KAAK,CAAC,CAAG,EAAA,MAAM,CAAC,cAAc,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I,CAAC,CAAC;QAEnC,MAAM,eAAe,GAAG,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;AAE7D,QAAA,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,CAAW,CAAG,EAAA,IAAI,CAAC,aAAa,CAAC,GAAG,2CAA2C,kBAAkB,CAAC,eAAe,CAAC,CAAE,CAAA,EAAE,QAAQ,EAAE,EAAE,cAAc,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,CAAC,CAAC;KACpM;8GA5CU,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA,EAAA;AAApB,IAAA,SAAA,IAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,cAFnB,MAAM,EAAA,CAAA,CAAA,EAAA;;2FAEP,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAHhC,UAAU;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,UAAU,EAAE,MAAM;AACnB,iBAAA,CAAA;;;ACZD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -3,16 +3,19 @@ import { BaseService } from '../base-service/base.service';
|
|
|
3
3
|
import { AnonymisationServiceConfiguration } from './models/anonymisation-configuration.model';
|
|
4
4
|
import { Observable } from 'rxjs';
|
|
5
5
|
import { Document } from './models/document.model';
|
|
6
|
-
import {
|
|
6
|
+
import { UploadDocument } from './models';
|
|
7
|
+
import { ClassCategory } from './models/class-category.model';
|
|
8
|
+
import { ClassCategories } from './models/class-categories.model';
|
|
7
9
|
import * as i0 from "@angular/core";
|
|
8
10
|
export declare class AnonymisationService extends BaseService<AnonymisationServiceConfiguration> {
|
|
9
11
|
#private;
|
|
10
12
|
constructor();
|
|
11
|
-
getSettings(): Observable<
|
|
12
|
-
setSettings(settings: ClassCategory[]): Observable<
|
|
13
|
+
getSettings(): Observable<ClassCategories>;
|
|
14
|
+
setSettings(settings: ClassCategory[]): Observable<ClassCategories>;
|
|
15
|
+
getDocumentJson(id: string): Observable<string>;
|
|
13
16
|
getDocumentById(id: string): Observable<Document>;
|
|
14
17
|
getDocumentList(): Observable<Document[]>;
|
|
15
|
-
downloadDocument(id: string, extension: string): Observable<
|
|
18
|
+
downloadDocument(id: string, extension: string): Observable<Blob>;
|
|
16
19
|
deleteDocument(id: string): Observable<void>;
|
|
17
20
|
uploadDocument(body: UploadDocument): Observable<HttpEvent<Document>>;
|
|
18
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<AnonymisationService, never>;
|