0.0.8 • Published 1 year ago

contortionist v0.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

Contortionist

alt text

Control what LLMs can, and can't, say.

Install

npm install contortionist

Usage

import Contortionist from 'contortionist';
const grammar = 'root ::= "foo"';
const contortionist = new Contortionist({
  grammar,
  model: {
    protocol: 'llama.cpp',
    endpoint: 'http://localhost:4445',
  },
});

const result = await contortionist.execute(prompt, {
  n: 40,
  stream: true,
  callback: ({ partial }) => {
    output.textContent = partial;
  }
});
0.0.8

1 year ago

0.0.7

1 year ago

0.0.5

1 year ago

0.0.6

1 year ago

0.0.3

1 year ago

0.0.2

1 year ago

0.0.4

1 year ago

0.0.1

1 year ago