1.0.1 • Published 7 months ago

@graphai/token_bound_string_agent v1.0.1

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

@graphai/token_bound_string_agent for GraphAI

This agent generate a reference string from a sorted array of strings, adding one by one until the token count exceeds the specified limit.

Install

yarn add @graphai/token_bound_string_agent

Usage

import { GraphAI } from "graphai";
import { tokenBoundStringsAgent } from "@graphai/token_bound_string_agent";

const agents = { tokenBoundStringsAgent };

const graph = new GraphAI(graph_data, agents);
const result = await graph.run();

Agents description

  • tokenBoundStringsAgent - token bound Agent

Input/Output/Params Schema & samples

Input/Params example

  • tokenBoundStringsAgent
{
  "inputs": {
    "chunks": [
      "Here's to the crazy ones. The misfits. The rebels. The troublemakers.",
      "The round pegs in the square holes. The ones who see things differently.",
      "They're not fond of rules. And they have no respect for the status quo.",
      "You can quote them, disagree with them, glorify or vilify them.",
      "About the only thing you can't do is ignore them.",
      "Because they change things.",
      "They push the human race forward.",
      "And while some may see them as the crazy ones, we see genius.",
      "Because the people who are crazy enough to think they can change the world, are the ones who do."
    ]
  },
  "params": {
    "limit": 80
  }
}
1.0.1

7 months ago

1.0.0

8 months ago

0.0.2

9 months ago

0.0.1

10 months ago