Skip to content

Commit

Permalink
Clean up docs
Browse files Browse the repository at this point in the history
  • Loading branch information
collindutter committed Oct 25, 2024
1 parent d72af55 commit 1e80649
Show file tree
Hide file tree
Showing 16 changed files with 22 additions and 37 deletions.
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,8 @@ Drivers facilitate interactions with external resources and services:
Engines wrap Drivers and provide use-case-specific functionality:

- 📊 **RAG Engine** is an abstraction for implementing modular Retrieval Augmented Generation (RAG) pipelines.
- 🛠️ **Extraction Engines** extract JSON or CSV data from unstructured text.
- 📝 **Summary Engines** generate summaries from textual content.
- 🖼️ **Image Generation Engines** generate images from textual descriptions.
- 🔎 **Image Query Engines** query images based on textual prompts.
- 🛠️ **Extraction Engine** extracts JSON or CSV data from unstructured text.
- 📝 **Summary Engine** generates summaries from textual content.

### 📦 Additional Components

Expand Down
8 changes: 1 addition & 7 deletions docs/griptape-framework/data/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,12 @@ Griptape provides several abstractions for working with data.

**Tokenizers** are used to tokenize and detokenize text in order to track LLM token limits.

[Audio Engines](../engines/audio-engines.md) are used for working with audio.
[RAG Engines](../engines/rag-engines.md) are used for implementing modular RAG pipelines.

[Extraction Engines](../engines/extraction-engines.md) are used for extracting structured content.

[Image Query Engines](../engines/image-query-engines.md) are used for querying images with text.

[Image Generation Engines](../engines/image-generation-engines.md) are used for generating images.

[Summary Engines](../engines/summary-engines.md) are used for summarizing text content.

[RAG Engines](../engines/rag-engines.md) are used for implementing modular RAG pipelines.

[Vector Store Drivers](../drivers/vector-store-drivers.md) are used to store and query vector databases.

[Prompt Drivers](../drivers/prompt-drivers.md) are used to call LLM APIs.
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,6 @@ search:

[Audio Transcription Drivers](../../reference/griptape/drivers/audio_transcription/index.md) extract text from spoken audio.

This driver acts as a critical bridge between audio transcription Engines and the underlying models, facilitating the construction and execution of API calls that transform speech into editable and searchable text. Utilized predominantly in applications that support the input of verbal communications, the Audio Transcription Driver effectively extracts and interprets speech, rendering it into a textual format that can be easily integrated into data systems and Workflows.

This capability is essential for enhancing accessibility, improving content discoverability, and automating tasks that traditionally relied on manual transcription, thereby streamlining operations and enhancing efficiency across various industries.

## Audio Transcription Drivers

### OpenAI
Expand Down
10 changes: 5 additions & 5 deletions docs/griptape-framework/drivers/image-generation-drivers.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ search:

## Overview

[Image Generation Drivers](../../reference/griptape/drivers/image_generation/index.md) are used by [image generation Engines](../engines/image-generation-engines.md) to build and execute API calls to image generation models.
[Image Generation Drivers](../../reference/griptape/drivers/image_generation/index.md) build and execute API calls to image generation models.

Provide a Driver when building an [Engine](../engines/image-generation-engines.md), then pass it to a [Tool](../tools/index.md) for use by an [Agent](../structures/agents.md):
Provide a Driver to a [Tool](../tools/index.md) for use by an [Agent](../structures/agents.md):

```python
--8<-- "docs/griptape-framework/drivers/src/image_generation_drivers_1.py"
Expand All @@ -23,7 +23,7 @@ The [Amazon Bedrock Image Generation Driver](../../reference/griptape/drivers/im

The [Bedrock Stable Diffusion Model Driver](../../reference/griptape/drivers/image_generation_model/bedrock_stable_diffusion_image_generation_model_driver.md) provides support for Stable Diffusion models hosted by Amazon Bedrock. This Model Driver supports configurations specific to Stable Diffusion, like style presets, clip guidance presets, and sampler.

This Model Driver supports negative prompts. When provided (for example, when used with an [image generation Engine](../engines/image-generation-engines.md) configured with [Negative Rulesets](../engines/image-generation-engines.md#image-generation-engine-rulesets)), the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.
This Model Driver supports negative prompts. When provided, the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.

```python
--8<-- "docs/griptape-framework/drivers/src/image_generation_drivers_2.py"
Expand All @@ -33,7 +33,7 @@ This Model Driver supports negative prompts. When provided (for example, when us

The [Bedrock Titan Image Generator Model Driver](../../reference/griptape/drivers/image_generation_model/bedrock_titan_image_generation_model_driver.md) provides support for Titan Image Generator models hosted by Amazon Bedrock. This Model Driver supports configurations specific to Titan Image Generator, like quality, seed, and cfg_scale.

This Model Driver supports negative prompts. When provided (for example, when used with an [image generation engine](../engines/image-generation-engines.md) configured with [Negative Rulesets](../engines/image-generation-engines.md#image-generation-engine-rulesets)), the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.
This Model Driver supports negative prompts. When provided, the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.

```python
--8<-- "docs/griptape-framework/drivers/src/image_generation_drivers_3.py"
Expand All @@ -53,7 +53,7 @@ The [Leonardo Image Generation Driver](../../reference/griptape/drivers/image_ge

This Driver supports configurations like model selection, image size, specifying a generation seed, and generation steps. For details on supported configuration parameters, see [Leonardo.Ai's image generation documentation](https://docs.leonardo.ai/reference/creategeneration).

This Driver supports negative prompts. When provided (for example, when used with an [image generation engine](../engines/image-generation-engines.md) configured with [Negative Rulesets](../engines/image-generation-engines.md#image-generation-engine-rulesets)), the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.
This Driver supports negative prompts. When provided, the image generation request will include negatively-weighted prompts describing features or characteristics to avoid in the resulting generation.

```python
--8<-- "docs/griptape-framework/drivers/src/image_generation_drivers_5.py"
Expand Down
2 changes: 1 addition & 1 deletion docs/griptape-framework/drivers/image-query-drivers.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ search:

## Overview

Image Query Drivers are used by [Image Query Engines](../engines/image-query-engines.md) to execute natural language queries on the contents of images. You can specify the provider and model used to query the image by providing the Engine with a particular Image Query Driver.
Image Query Drivers execute natural language queries on the contents of images. You can specify the provider and model used to query the image by providing the Engine with a particular Image Query Driver.

!!! info
All Image Query Drivers default to a `max_tokens` of 256. It is recommended that you set this value to correspond to the desired response length.
Expand Down
2 changes: 1 addition & 1 deletion docs/griptape-framework/drivers/text-to-speech-drivers.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ search:

[Text to Speech Drivers](../../reference/griptape/drivers/text_to_speech/index.md) are used to build and execute API calls to audio generation models.

Provide a Driver when building an [Engine](../engines/audio-engines.md), then pass it to a [Tool](../tools/index.md) for use by an [Agent](../structures/agents.md):
Provide a Driver to a [Tool](../tools/index.md) for use by an [Agent](../structures/agents.md):

## Text to Speech Drivers

Expand Down
8 changes: 4 additions & 4 deletions docs/griptape-framework/structures/tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ This task takes a python function, and authors can elect to return a custom arti

## Image Generation Tasks

To generate an image, use one of the following [Image Generation Tasks](../../reference/griptape/tasks/index.md). All Image Generation Tasks accept an [Image Generation Engine](../engines/image-generation-engines.md) configured to use an [Image Generation Driver](../drivers/image-generation-drivers.md).
To generate an image, use one of the following [Image Generation Tasks](../../reference/griptape/tasks/index.md). All Image Generation Tasks accept an [Image Generation Driver](../drivers/image-generation-drivers.md).

All successful Image Generation Tasks will always output an [Image Artifact](../data/artifacts.md#image). Each task can be configured to additionally write the generated image to disk by providing either the `output_file` or `output_dir` field. The `output_file` field supports file names in the current directory (`my_image.png`), relative directory prefixes (`images/my_image.png`), or absolute paths (`/usr/var/my_image.png`). By setting `output_dir`, the task will generate a file name and place the image in the requested directory.

Expand Down Expand Up @@ -342,7 +342,7 @@ The [Outpainting Image Generation Task](../../reference/griptape/tasks/outpainti

## Image Query Task

The [Image Query Task](../../reference/griptape/tasks/image_query_task.md) performs a natural language query on one or more input images. This Task uses an [Image Query Engine](../engines/image-query-engines.md) configured with an [Image Query Driver](../drivers/image-query-drivers.md) to perform the query. The functionality provided by this Task depend on the capabilities of the model provided by the Driver.
The [Image Query Task](../../reference/griptape/tasks/image_query_task.md) performs a natural language query on one or more input images. This Task uses an [Image Query Driver](../drivers/image-query-drivers.md) to perform the query. The functionality provided by this Task depend on the capabilities of the model provided by the Driver.

This Task accepts two inputs: a query (represented by either a string or a [Text Artifact](../data/artifacts.md#text)) and a list of [Image Artifacts](../data/artifacts.md#image) or a Callable returning these two values.

Expand All @@ -361,15 +361,15 @@ This Task is useful for orchestrating multiple specialized Structures in a singl

## Text to Speech Task

This Task enables Structures to synthesize speech from text using [Text to Speech Engines](../../reference/griptape/engines/audio/text_to_speech_driver.md) and [Text to Speech Drivers](../../reference/griptape/drivers/text_to_speech/index.md).
This Task enables Structures to synthesize speech from text using [Text to Speech Drivers](../../reference/griptape/drivers/text_to_speech/index.md).

```python
--8<-- "docs/griptape-framework/structures/src/tasks_17.py"
```

## Audio Transcription Task

This Task enables Structures to transcribe speech from text using [Audio Transcription Engines](../../reference/griptape/engines/audio/audio_transcription_engine.md) and [Audio Transcription Drivers](../../reference/griptape/drivers/audio_transcription/index.md).
This Task enables Structures to transcribe speech from text using [Audio Transcription Drivers](../../reference/griptape/drivers/audio_transcription/index.md).

```python
--8<-- "docs/griptape-framework/structures/src/tasks_18.py"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Audio Transcription Tool

This Tool enables [Agents](../../griptape-framework/structures/agents.md) to transcribe speech from text using [Audio Transcription Engines](../../reference/griptape/engines/audio/audio_transcription_engine.md) and [Audio Transcription Drivers](../../reference/griptape/drivers/audio_transcription/index.md).
This Tool enables [Agents](../../griptape-framework/structures/agents.md) to transcribe speech from text using [Audio Transcription Drivers](../../reference/griptape/drivers/audio_transcription/base_audio_transcription_driver.md).

```python
--8<-- "docs/griptape-tools/official-tools/src/audio_transcription_tool_1.py"
Expand Down
2 changes: 1 addition & 1 deletion docs/griptape-tools/official-tools/text-to-speech-tool.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Text To Speech Tool

This Tool enables LLMs to synthesize speech from text using [Text to Speech Engines](../../reference/griptape/engines/audio/text_to_speech_driver.md) and [Text to Speech Drivers](../../reference/griptape/drivers/text_to_speech/index.md).
This Tool enables LLMs to synthesize speech from text using [Text to Speech Drivers](../../reference/griptape/drivers/text_to_speech/index.md).

```python
--8<-- "docs/griptape-tools/official-tools/src/text_to_speech_tool_1.py"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Variation Image Generation Engine Tool
# Variation Image Generation Tool

This Tool allows LLMs to generate variations of an input image from a text prompt. The input image can be provided either by its file path or by its [Task Memory](../../griptape-framework/structures/task-memory.md) reference.

Expand Down
2 changes: 1 addition & 1 deletion griptape/tools/inpainting_image_generation/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class InpaintingImageGenerationTool(BaseImageGenerationTool):
"""A tool that can be used to generate prompted inpaintings of an image.
Attributes:
engine: The inpainting image generation engine used to generate the image.
image_generation_driver: The image generation driver used to generate the image.
output_dir: If provided, the generated image will be written to disk in output_dir.
output_file: If provided, the generated image will be written to disk as output_file.
"""
Expand Down
2 changes: 1 addition & 1 deletion griptape/tools/outpainting_image_generation/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class OutpaintingImageGenerationTool(BaseImageGenerationTool):
"""A tool that can be used to generate prompted outpaintings of an image.
Attributes:
engine: The outpainting image generation engine used to generate the image.
image_generation_driver: The image generation driver used to generate the image.
output_dir: If provided, the generated image will be written to disk in output_dir.
output_file: If provided, the generated image will be written to disk as output_file.
"""
Expand Down
2 changes: 1 addition & 1 deletion griptape/tools/prompt_image_generation/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class PromptImageGenerationTool(BaseImageGenerationTool):
"""A tool that can be used to generate an image from a text prompt.
Attributes:
engine: The prompt image generation engine used to generate the image.
image_generation_driver: The image generation driver used to generate the image.
output_dir: If provided, the generated image will be written to disk in output_dir.
output_file: If provided, the generated image will be written to disk as output_file.
"""
Expand Down
2 changes: 1 addition & 1 deletion griptape/tools/text_to_speech/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class TextToSpeechTool(ArtifactFileOutputMixin, BaseTool):
"""A tool that can be used to generate speech from input text.
Attributes:
engine: The text to audio generation engine used to generate the speech audio.
text_to_speech_driver: The text to audio generation driver used to generate the speech audio.
output_dir: If provided, the generated audio will be written to disk in output_dir.
output_file: If provided, the generated audio will be written to disk as output_file.
"""
Expand Down
2 changes: 1 addition & 1 deletion griptape/tools/variation_image_generation/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class VariationImageGenerationTool(BaseImageGenerationTool):
"""A tool that can be used to generate prompted variations of an image.
Attributes:
engine: The variation image generation engine used to generate the image.
image_generation_driver: The image generation driver used to generate the image.
output_dir: If provided, the generated image will be written to disk in output_dir.
output_file: If provided, the generated image will be written to disk as output_file.
"""
Expand Down
3 changes: 0 additions & 3 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,8 @@ nav:
- Building Custom Tools: "griptape-tools/custom-tools/index.md"
- Engines:
- RAG Engines: "griptape-framework/engines/rag-engines.md"
- Image Query Engines: "griptape-framework/engines/image-query-engines.md"
- Extraction Engines: "griptape-framework/engines/extraction-engines.md"
- Summary Engines: "griptape-framework/engines/summary-engines.md"
- Image Generation Engines: "griptape-framework/engines/image-generation-engines.md"
- Audio Engines: "griptape-framework/engines/audio-engines.md"
- Drivers:
- Prompt Drivers: "griptape-framework/drivers/prompt-drivers.md"
- Embedding Drivers: "griptape-framework/drivers/embedding-drivers.md"
Expand Down

0 comments on commit 1e80649

Please sign in to comment.