Skip to main content

Turbo Text Transformer Prompts

Note this is automatically installed when you do pip install turbo-text-transformer. This repo is just for storing the templates.

Designed for use with turbo-text-transformer.

You pipe some text in, the template is applied, then you pipe it into ttt (from pip install turbo-text-transformer) which will process it with eg. OpenAI.

cat pyproject.toml tttp/__main__.py | tttp -t readme | ttt > README.md

Turbo Text Transformer Prompts is a command-line tool that allows users to generate text files from pre-configured templates using user input prompts. The tool uses Jinja2 templating engine to render text files from templates.

How to Run

pip install turbo-text-transformer-prompts

You will also need to clone the repository containing the templates you want to use. For example:

mkdir -p ~/.config/ttt/
git clone https://github.com/fergusfettes/turbo-text-transformer-prompts ~/.config/ttt

Template Structure

A template is a text file written in Jinja2 syntax. The file should have the .j2 extension and be placed inside the templates directory. They will be installed in the ~/.config/ttt/templates directory.

This is a smiple example of a template:

Context: Provide only code as output.
Prompt: {{prompt}}
Code:

It will just output a code snippet based on the query.

You can also pass a list of flags to the prompt to fine tune the control, such as this:

This is an example of minimally altering some given code to achieve a specific task.

I received the following code:

`{{language}}
{{prompt}}
`

My task was to make minimal alterations to this code to: "{{task}}".

The altered code is below.

`{{language}}

For this one, you can pass the 'task' and 'language' arguments to make it more specific.

Contributing

PULL REQUESTS WITH MORE TEMPLATES VERY WELCOME!

If you find a bug or would like to contribute to Turbo Text Transformer Prompts, please create a new GitHub issue or pull request.

License

Turbo Text Transformer Prompts is licensed under the MIT License. See the LICENSE file for details.

Metadata

Release files for turbo-text-transformer-prompts 0.1.10

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for turbo-text-transformer-prompts 0.1.10
File Size Uploaded
turbo_text_transformer_prompts-0.1.10.tar.gz 12.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for turbo-text-transformer-prompts 0.1.10
File Interpreter ABI Platform
turbo_text_transformer_prompts-0.1.10-py3-none-any.whl Python 3 none any Details

Total release size: 31.0 kB

Release files / turbo_text_transformer_prompts-0.1.10.tar.gz

Download URL turbo_text_transformer_prompts-0.1.10.tar.gz
Size 12.7 kB
Tags Source
SHA-256 checksum
How to use checksums
825cd560d743d54f4d8ea0f87015d58f79c14fb80b55918a463eb4b358375010
BLAKE2b-256 checksum
How to use checksums
9ad4c45105c3b77927347cb84435fda8901ed5353f02f6edb289b38a4175a825
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.2 CPython/3.10.6 Linux/5.19.0-38-generic

Release files / turbo_text_transformer_prompts-0.1.10-py3-none-any.whl

Download URL turbo_text_transformer_prompts-0.1.10-py3-none-any.whl
Size 18.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
222814c5d36182071cb59ed0cff6c42805c86a0442e64fc09d9002620ced8a30
BLAKE2b-256 checksum
How to use checksums
df7bcf5bd3b7911606bd718fc441bdf1be9c47fa7e123d8dbf2b76429a37e4b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.2 CPython/3.10.6 Linux/5.19.0-38-generic

Release history Release notifications | RSS feed

This release

0.1.10 This release

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page