New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

pipeline-handler

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pipeline-handler

an idependant handler for pipelines (like in perfidy or epitelete)

  • 2.2.2
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
9
decreased by-73.53%
Maintainers
1
Weekly downloads
 
Created
Source

pipelineHandler

Getting started

$ npm i pipeline-handler

You can find working examples under test folder

API of the pipelineHandler class :

  • pipelines : your custom pipelines
  • transforms : your custom transforms to use
  • proskomma : a proskomma instance (if needed)
  • verbose : true|false

Using official pipelines

This package contains many pipelines already. You can use them as shown in the examples.

List of official pipelines

  • stripAlignmentPipeline :
    • description : strip alignment from a perf document
    • imputs :
      • perf : your aligned perf document
  • mergeAlignmentPipeline :
    • description : merge alignment of a perf document
    • imputs :
      • perf : your previously stripped perf document
      • strippedAlignment : the report of stripAlignmentPipeline
  • perf2usfmPipeline :
    • description : PERF => USFM
    • imputs :
      • perf : your perf document
  • usfm2perfPipeline :
    • description : USFM => PERF
    • imputs :
      • usfm : your usfm document
      • selectors : the selectors (eg: {"lang": "fra","abbr": "fraLSG"} )
const PipelineHandler = require("pipeline-handler");
const { Proskomma } = require("proskomma");

const pipelineH = new PipelineHandler({proskomma : new Proskomma()});

async function test() {
    let output = await pipelineH.runPipeline("YOUR_PIPELINE_NAME", {
        ...YOUR_INPUTS
    });
    
    // do some stuff with the output ...
}

test();

Development

$ npm i
$ npm run build
$ npm run test

This will create a perf file output.json.

example

See the test/test_usfm2perf_pipeline.js file for an example of a running code.

Keywords

FAQs

Package last updated on 05 Dec 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc