Socket
Socket
Sign inDemoInstall

sap-leonardo

Package Overview
Dependencies
48
Maintainers
1
Versions
19
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.5.6 to 0.5.7

dist/image_classification.d.ts

32

CHANGELOG.md

@@ -5,3 +5,20 @@ # CHANGELOG

## next
- rename image_classification
- more examples
- using a better product for product image classification test and example
- add log4js
- update translate service to [1810B](https://help.sap.com/viewer/2e6173bf645243bb9a88f0269250f3a2/1.0/en-US)
- adjust detection_boxes for four people at human detection test
- add topic detection test: topics should not exceed the number of documents
- more topic detection tests
- upgrade dev dependencies
- error code: (product) image classification
- adjust timeouts human detection (15sec) and result vulues
- turn off timeout at multi-instance image segmentation (normal 10sec)
- adjust language detection service
## 0.5.6
- wrong API: Product Image Classification API

@@ -11,2 +28,3 @@ - separate src and test

## 0.5.5
- Inference Service for Customizable Object Detection

@@ -16,2 +34,3 @@ - adjust timeout for ocr test

## 0.5.4
- typo in Inference Service for Topic Detection

@@ -22,2 +41,3 @@ - examples:

## 0.5.3
- Inference Service for Topic Detection

@@ -30,8 +50,8 @@ - examples:

<a name="v0.5.2"></a>
## 0.5.2
- Inference Service For Customizable Image Feature Extraction
- ImageFeatureExtraction:customizable
- test similarity scoring with algorithm test cases
- examples:
- examples:
- face feature extraction with similarity

@@ -41,7 +61,7 @@ - face detection

<a name="v0.5.1"></a>
## 0.5.1
- Inference Service for Face Feature Extraction service
- tslint and eslint
- examples:
- examples:
- mulit_instance_image_segmentation

@@ -51,8 +71,8 @@ - similarity_scoring

<a name="v0.5.0"></a>
## 0.5.0
- Inference Service For Customizable Image Feature Extraction
<a name="v0.1.9"></a>
## < 0.5.0
- Inference Service for Customizable Image Classification

@@ -59,0 +79,0 @@ - Inference Service for Optical Character Recognition (OCR)

2

dist/index.d.ts

@@ -1,2 +0,2 @@

export * from "./imageclassification";
export * from "./image_classification";
export * from "./ocr";

@@ -3,0 +3,0 @@ export * from "./translation";

@@ -6,3 +6,3 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
__export(require("./imageclassification"));
__export(require("./image_classification"));
__export(require("./ocr"));

@@ -9,0 +9,0 @@ __export(require("./translation"));

@@ -19,3 +19,3 @@ "use strict";

};
const url = this.baseUrl + "/ml/languagedetection/language";
const url = this.baseUrl + "/ml/languagedetection/lang-detect/";
const data = JSON.stringify({ message });

@@ -37,3 +37,3 @@ request.post({ url, body: data, headers }, (err, response, body) => {

};
const url = this.baseUrl + "/ml/languagedetection/version";
const url = this.baseUrl + "/ml/languagedetection/lang-detect/version";
request.get({ url, headers }, (err, response, body) => {

@@ -40,0 +40,0 @@ if (err) {

@@ -10,3 +10,22 @@ import { Promise } from "es6-promise";

key: string;
inlineElements?: ITextTranslationRequestMarkup;
}
export interface ITextTranslationRequestMarkup {
ranges?: ITextTranslationRequestMarkupRange[];
markers?: ITextTranslationRequestMarkupMarker[];
}
export interface ITextTranslationRequestMarkupRange {
id: number;
begin: number;
end: number;
}
export interface ITextTranslationRequestMarkupMarker {
id: number;
position: number;
align: Align;
}
export declare enum Align {
Left = "left",
Right = "right"
}
export declare class Translation {

@@ -13,0 +32,0 @@ private apiKey;

@@ -6,2 +6,7 @@ "use strict";

const request = require("request");
var Align;
(function (Align) {
Align["Left"] = "left";
Align["Right"] = "right";
})(Align = exports.Align || (exports.Align = {}));
class Translation {

@@ -8,0 +13,0 @@ constructor(apiKey, baseUrl = "https://sandbox.api.sap.com") {

{
"name": "sap-leonardo",
"version": "0.5.6",
"version": "0.5.7",
"description": "NPM module for SAP Leonardo Machine Learning Foundation - Functional Services https://api.sap.com/package/SAPLeonardoMLFunctionalServices",

@@ -49,14 +49,15 @@ "main": "dist/index.js",

"devDependencies": {
"@types/chai": "^4.1.6",
"@types/chai": "^4.1.7",
"@types/mocha": "^5.2.5",
"@types/request": "^2.47.1",
"@types/request": "^2.48.1",
"chai": "^4.2.0",
"coveralls": "^3.0.2",
"eslint": "^5.8.0",
"eslint": "^5.9.0",
"istanbul": "^1.1.0-alpha.1",
"log4js": "^3.0.6",
"mocha": "^5.2.0",
"ts-node": "^7.0.1",
"tslint": "^5.11.0",
"typescript": "^3.1.3"
"typescript": "^3.1.6"
}
}

@@ -7,3 +7,3 @@ # SAP Leonardo Machine Learning Foundation - Functional Services

"SAP Leonardo Machine Learning foundation provides readily consumable pre-trained models, as well as customizable models." ---- https://api.sap.com/package/SAPLeonardoMLFunctionalServices
"SAP Leonardo Machine Learning foundation provides readily consumable pre-trained models, as well as customizable models." ---- [SAP Leonardo Machine Learning Foundation - Functional Services](https://api.sap.com/package/SAPLeonardoMLFunctionalServices)

@@ -17,6 +17,6 @@ [![Build Status](https://api.travis-ci.org/choas/sap-leonardo.svg?branch=master)](https://travis-ci.org/choas/sap-leonardo)

## Usage
Install the npm package:
```sh

@@ -29,2 +29,3 @@ npm install sap-leonardo

Use e.g. the image classification service with your API key:
```javascript

@@ -42,8 +43,8 @@ const leonardo = require("sap-leonardo");

```
More examples can be found in the examples and src/test folder.
## Implemented Services
### Following services are implemented:
### Following services are implemented

@@ -69,2 +70,3 @@ - [Inference Service For Customizable Image Feature Extraction](https://api.sap.com/api/img_feature_extraction_api/resource)

### Following services require a training instance (not implemented)
- ~~Training Service for Customizable Object Detection~~

@@ -77,3 +79,2 @@ - ~~Training Service for Customizable Similarity Search~~

## Build

@@ -85,3 +86,2 @@

## Test

@@ -96,2 +96,3 @@

install all dependencies:
```sh

@@ -102,2 +103,3 @@ npm install

run the tests:
```sh

@@ -108,5 +110,5 @@ npm test

## Blog Posts
- [NPM Module for SAP Leonardo Machine Learning](https://blogs.sap.com/2018/10/04/npm-module-for-sap-leonardo-machine-learning/)
## Testdata Sources

@@ -123,9 +125,9 @@

- [converse-2069209_640.jpg](https://pixabay.com/en/converse-shoes-grass-outdoors-2069209/)
- [keyboard-70506_640.jpg](https://pixabay.com/en/keyboard-computer-hardware-keys-70506/)
- ~[keyboard-70506_640.jpg](https://pixabay.com/en/keyboard-computer-hardware-keys-70506/)~
- [data-transfer-3199547_640.jpg](https://pixabay.com/en/data-transfer-connection-data-3199547/)
- topic_detection.zip:
- https://en.wikipedia.org/wiki/Apple_pie
- https://en.wikipedia.org/wiki/Computer_science
- https://en.wikipedia.org/wiki/Computational_complexity_theory
- [Wikipedia apple pie](https://en.wikipedia.org/wiki/Apple_pie)
- [Wikipedia computer science](https://en.wikipedia.org/wiki/Computer_science)
- [Wikipedio computational complexity theory](https://en.wikipedia.org/wiki/Computational_complexity_theory)
## License

@@ -137,4 +139,5 @@

http://www.apache.org/licenses/LICENSE-2.0
[http://www.apache.org/licenses/LICENSE-2.0
](http://www.apache.org/licenses/LICENSE-2.0)
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc