Skip to main content

Modular Python framework for LLM workflows, tools, memory, and data.

Project description

griptape

PyPI Version Tests Docs Griptape Discord

Griptape offers developers the ability to build AI systems that operate across two dimensions: predictability and creativity.

For predictability, software structures like sequential pipelines and directed acyclic graphs (DAGs) are enforced. Creativity, on the other hand, is facilitated by safely prompting LLMs with tools that connect to external APIs and data sources. Developers can move between these two dimensions according to their use case.

Documentation

Please refer to Griptape Docs for:

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

Quick Start

First, install griptape and griptape-tools:

pip install griptape griptape-tools -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 Completions API to execute LLM prompts.

With Griptape, you can create structures, such as Agents, Pipelines, and Workflows, that are composed of different types of tasks. Let's build a simple creative agent that dynamically uses two tools with shared short-term memory.

from griptape.structures import Agent
from griptape.tools import WebScraper, ToolOutputProcessor

agent = Agent(
    tools=[WebScraper(), ToolOutputProcessor()]
)

agent.run(
    "based on https://www.griptape.ai/, tell me what Griptape is"
)

And here is the output:

Q: based on https://www.griptape.ai/, tell me what Griptape is
A: Griptape is an opinionated Python framework that enables developers to fully harness the potential of LLMs while enforcing strict trust boundaries, schema validation, and activity-level permissions. It offers developers the ability to build AI systems that operate across two dimensions: predictability and creativity. Griptape can be used to create conversational and autonomous agents.

During the run, the Griptape agent loaded a webpage, stored its full content in the short-term memory, and queried it to answer the original question.

Versioning

Griptape is in early development and its APIs and documentation are subject to change. Until we stabilize the API and release version 1.0.0, we will use minor versions (i.e., x.Y.z) to introduce features and breaking features, and patch versions (i.e., x.y.Z) for bug fixes.

Contributing

Contributions in the form of bug reports, feature ideas, or pull requests are super welcome! Take a look at the current issues and if you'd like to help please submit a pull request with some tests.

License

Griptape is available under the Apache 2.0 License.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

griptape-0.14.5.tar.gz (51.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

griptape-0.14.5-py3-none-any.whl (96.3 kB view details)

Uploaded Python 3

File details

Details for the file griptape-0.14.5.tar.gz.

File metadata

  • Download URL: griptape-0.14.5.tar.gz
  • Upload date:
  • Size: 51.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/21.6.0

File hashes

Hashes for griptape-0.14.5.tar.gz
Algorithm Hash digest
SHA256 f5caba50e434901da6f79fcd3cfcd1c5e8e68cf347ee9f80a9dd0be0ad27db49
MD5 09b8c9276c11578504dcaebe24977c55
BLAKE2b-256 e856a7c6363bfe9d106d4fa58000df4496040ececd24fd2836c9db383277dc66

See more details on using hashes here.

File details

Details for the file griptape-0.14.5-py3-none-any.whl.

File metadata

  • Download URL: griptape-0.14.5-py3-none-any.whl
  • Upload date:
  • Size: 96.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/21.6.0

File hashes

Hashes for griptape-0.14.5-py3-none-any.whl
Algorithm Hash digest
SHA256 2ecfdca7cb5e595a5175cdda1086f0f1c98e9a0676a5d8ee31bf1ff37f4f8e03
MD5 1e2ed35a4e885812e5560c4101c43a6f
BLAKE2b-256 7cc8c6f5180d6b12f858b381f4bfc34c9b84adae1a63a30cea981c0902095783

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page