TLDR

Griptape is a modular Python framework for building AI-powered applications that securely connect to your enterprise data and APIs. It offers developers the ability to maintain control and flexibility at every step.

Company Fluff

🛠️ Core Components

🏗️ Structures

  • 🤖 Agents consist of a single Task.
  • 🔄 Pipelines organize a sequence of Tasks so that the output from one Task may flow into the next.
  • 🌐 Workflows configure Tasks to operate in parallel.

📝 Tasks

Tasks are the core building blocks within Structures, enabling interaction with Engines, Tools, and other Griptape components.

🔧 Tools

Tools provide capabilities for LLMs to interact with data and services. Griptape includes a variety of built-in Tools, and makes it easy to create custom Tools.

🧠 Memory

  • 💬 Conversation Memory enables LLMs to retain and retrieve information across interactions.
  • 🗃️ Task Memory keeps large or sensitive Task outputs off the prompt that is sent to the LLM.
  • 📊 Meta Memory enables passing in additional metadata to the LLM, enhancing the context and relevance of the interaction.

🚗 Drivers

Drivers facilitate interactions with external resources and services:

  • 🗣️ Prompt Drivers manage textual and image interactions with LLMs.
  • 🔢 Embedding Drivers generate vector embeddings from textual inputs.
  • 💾 Vector Store Drivers manage the storage and retrieval of embeddings.
  • 🎨 Image Generation Drivers create images from text descriptions.
  • 💼 SQL Drivers interact with SQL databases.
  • 🌐 Web Scraper Drivers extract information from web pages.
  • 🧠 Conversation Memory Drivers manage the storage and retrieval of conversational data.
  • 📡 Event Listener Drivers forward framework events to external services.
  • 🏗️ Structure Run Drivers execute structures both locally and in the cloud.
  • 🤖 Assistant Drivers enable interactions with various “assistant” services.
  • 🗣️ Text to Speech Drivers convert text to speech.
  • 🎙️ Audio Transcription Drivers convert audio to text.
  • 🔍 Web Search Drivers search the web for information.
  • 📈 Observability Drivers send trace and event data to observability platforms.
  • 📜 Ruleset Drivers load and apply rulesets from external sources.
  • 🗂️ File Manager Drivers handle file operations on local and remote storage.

🚂 Engines

Engines wrap Drivers and provide use-case-specific functionality:

  • 📊 RAG Engine is an abstraction for implementing modular Retrieval Augmented Generation (RAG) pipelines.
  • 🛠️ Extraction Engine extracts JSON or CSV data from unstructured text.
  • 📝 Summary Engine generates summaries from textual content.

📦 Additional Components

  • 📐 Rulesets steer LLM behavior with minimal prompt engineering.
  • 🔄 Loaders load data from various sources.
  • 🏺 Artifacts allow for passing data of different types between Griptape components.
  • ✂️ Chunkers segment texts into manageable pieces for diverse text types.
  • 🔢 Tokenizers count the number of tokens in a text to not exceed LLM token limits.

Documentation

Please refer to Griptape Docs for:

  • Getting started guides.
  • Core concepts and design overviews.
  • Examples.
  • Contribution guidelines.

Please check out Griptape Trade School for free online courses.

Quick Start


First, install griptape:

pip install "griptape[all]" -U  

Second, configure an OpenAI client by getting an API key and adding it to your environment as OPENAI_API_KEY. By default, Griptape uses OpenAI Chat Completions API to execute LLM prompts.

Griptape Extensions


Griptape’s extensibility allows anyone to develop and distribute functionality independently. All new integrations, including Tools, Drivers, Tasks, etc., should initially be developed as extensions and then can be upstreamed into Griptape core if discussed and approved.

The Griptape Extension Template provides the recommended structure, step-by-step instructions, basic automation, and usage examples for new integrations.

License

Griptape is available under the Apache 2.0 License.