npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

shy-credit-test

v0.6.5-rc0

Published

[![npm version](https://img.shields.io/npm/v/shy-credit-test.svg?style=flat-square)](https://www.npmjs.org/package/shy-credit-test) [![npm downloads](https://img.shields.io/npm/dm/shy-credit-test.svg?style=flat-square)](http://npm-stat.com/charts.html?pac

Downloads

28

Readme

shy-credit

npm version npm downloads Node.js CI

Suite JSON handler module

  • LabelResultDef: Former project.label_interface
  • LabelResult: Former label.info.result

Documentation

Getting Started

Install

Using npm:

$ npm i shy-credit-test

Build your own project with shy-credit

create new project:

$ npm init
$ npm i shy-credit-test
$ node index.js

index.js:

const ShyCredit = require("shy-credit-test").default;

// Validate legacy label interface and generate summary
const legacyLabelInterface = {...};
// This will throw error if label interface is invalid
const labelResultDef = ShyCredit.Image.LabelResultDef.createFromLegacy(legacyLabelInterface);
const labelResultDefSummary = labelResultDef.summarizeToJSON();

// Validate legacy label result and generate tags
const legacyLabelResult = {...};
// This will throw error if label result is invalid
const labelResult = ShyCredit.Image.LabelResult.createFromLegacy(legacyLabelResult);
const labelResultTags = labelResult.generateTags();

// Build label interface from scratch
const newLabelResultDef = new ShyCredit.Image.LabelResultDef({
  type: 'legacyImage', // legacy type is supported only for now
  dataType: 'image',
  ... // Check documentations for detail
});
console.log(newLabelResultDef.toJSON());

How to use

LabelResultDef

  • What is it
    • Previously project.label_interface
    • Contains information about how to label (classes, properties)
  • When to use this module
    • Validate plain JSON label_interface value
    • Generate summary for overview
    • Create new label interface with constructor functions
    • Get informations like keypoint templates, AI engines and autolabel-able classes
  • TODO
    • Create new object with YAML settings
  • Further considerations
    • Add versioning
      • Currently there's no version and only legacy image type is supported
    • Legacy image still follows "any" in typescript. It'd be better to define types.

LabelResult

  • What is it
    • Previously label.info.result
    • Contains labeled result
  • When to use this module
    • Validate plain JSON label result
    • Generate "tags" from result
  • TODO
    • More detailed validation

Running the tests

Run test codes

$ git clone https://github.com/Superb-AI-Suite/shy-credit.git
$ cd shy-credit
$ npm i
$ npm run test

Build & Publish Project

Publish in NPM

$ git clone https://github.com/Superb-AI-Suite/shy-credit.git
$ cd shy-credit
$ npm i
$ # Do the job
$ # Don't forget to run test and change version in package.json before publish
$ # also index.ts
$ npm run build
$ npm publish

Build Docs

$ npm i typedoc --global
$ typedoc docs src/

TODO

  • Add Documentations for each Classes

Semver

Until shy-credit reaches a 1.0 release, breaking changes will be released with a new minor version.

Authors

Contact [email protected]

License

MIT