FireKit AI
  • Welcome to FireKit AI
  • Guide
    • Introduction
    • Core Concepts
      • AI Chains
      • Blocks
      • Edges
    • Rules
    • Debugging
  • Blocks
    • Agent
    • Skill
    • VectorStore Reader
    • Text
    • Chat Memory
Powered by GitBook
On this page
  • Token Limits
  • Cycle Detection
  • Skill Chains
  1. Guide

Rules

PreviousEdgesNextDebugging

Last updated 1 year ago

There are certain rules to consider when designing chains.

Token Limits

A token is a unit of text processable by language models. You can think of tokens as pieces of words each around 4 English characters in length. Language models have limits on how many tokens they are able to process and generate on each run. The limits are as follows:

GPT-4: 8192

GPT-3.5: 4096

Cycle Detection

A valid chain is one without any cycles along the path of any set of connected flow edges. A cycle, if allowed, would cause an infinite execution loop. FireKit detects cycles at runtime and will raise an error if detected.

Skill Chains

Skill chains follow the rules of regular chains with these exceptions:

  • A flow edge from a block outside a skill to a block within a skill is a valid connection. In other words, the output of a block outside of a skill can be used as input for a block inside a skill

  • The output of a block inside a skill cannot be used as input for a block outside a skill

With regards to cycle detection, all blocks within a skill, along with the agent block, can be viewed as a single entity.

A valid connection
This is considered a cycle