0.1.2 • Published 8 months ago

janus-ai v0.1.2

Weekly downloads
-
License
MIT
Repository
github
Last release
8 months ago

janus-ai

A TypeScript / JavaScript library for tracking AI rate limits across multiple services.

Usage

import JanusAI from 'janus-ai';

export const janus = new JanusAI();

janus.connect();

const registerInput = async () => {
  const janusDataObject = await janus.registerChatInput({
    model: 'gpt-4', 
    data: { 
      messages: [
        {
          role: "user",
          content: "Hello, Janus!"
        }
      ] 
    }
  });

  console.log(janusDataObject.system.load);
};

const janusDataObject = await janus.registerChatInput({
  model: data.model, 
  data: { messages: data.messages, functions: data.functions }
})

Development and testing

Built in TypeScript, tested with Jest.

$ yarn install
$ yarn test
0.1.2

8 months ago

0.1.1

8 months ago

0.1.0

9 months ago