Skip to main content

DotPrompt

DotPrompt is a revolutionary approach to programming that explores the idea of code being 100% produced by AI, with humans only editing the prompts used to generate the code. This project, authored by Dmitry Degtyarev, introduces a new paradigm in software development where the source code is generated from ".prompt" files.

Overview

In traditional programming, code is built through a series of iterations, either by humans or AI. The resulting code doesn't reveal which prompts were used to build it, making it difficult to alter these prompts later. DotPrompt addresses this limitation by introducing a system where:

  1. Code is entirely produced by AI.
  2. Humans focus on editing the prompts used by AI to generate the code.
  3. ".prompt" files contain the prompts used to produce actual code files.
  4. A simple script executes these .prompt files to build the code.

Key Features

  • Self-generation: The builder script itself can be generated from a .prompt file, allowing the generator to generate itself.
  • Multi-level abstraction: .prompt files can be built from other .prompt files, enabling higher-level idea representation.
  • Reverse engineering: Potential for reverse engineering prompt files from existing source code.

Future Enhancements

  • Ability to produce multiple files from a single prompt (e.g., code and unit tests).
  • Automated error correction based on unit test results and error messages.

Installation

To install DotPrompt, use the following pip command:

pip3 install dotprompt-cli

Usage

The DotPrompt CLI supports the following parameters:

Usage: dotprompt [OPTIONS] INPUT_FILE

  CLI application to process prompt files and generate code.

  This application takes a prompt file stored in the local filesystem and produces a raw code file,
  stored along with the prompt. The prompt files have a ".prompt" suffix.

Options:
  --recursive      Process included files recursively
  --from-scratch   Generate code from scratch, ignoring existing output file
  --provider TEXT  LLM provider (bedrock or anthropic)
  --model TEXT     LLM model to use
  --help           Show this message and exit.

Parameters

  • INPUT_FILE: Path to the input .prompt file (required)
  • --recursive: Flag to recursively process included files
  • --from-scratch: Flag to generate code from scratch, ignoring existing output file
  • --provider: LLM provider (bedrock or anthropic, default is 'bedrock')
  • --model: LLM model to use (default is 'anthropic.claude-3-5-sonnet-20240620-v1:0')

License

This project is licensed under the MIT License.

Contact

For more information or to get in touch with the author, visit https://twitter.com/Mitek99.

Metadata

Release files for dotprompt-cli 0.0.4

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

Source distribution (sdist)

Source distribution for dotprompt-cli 0.0.4
File Size Uploaded
dotprompt_cli-0.0.4.tar.gz 6.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for dotprompt-cli 0.0.4
File Interpreter ABI Platform
dotprompt_cli-0.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 14.3 kB

Release files / dotprompt_cli-0.0.4.tar.gz

Download URL dotprompt_cli-0.0.4.tar.gz
Size 6.0 kB
Tags Source
SHA-256 checksum
How to use checksums
8a6bcf00da7ae022ffdd745c2d788716a7ee5b619cec6d12c427aedd0da0c46a
BLAKE2b-256 checksum
How to use checksums
2c6a6a9f75346d10623653cebf2eb265565c6838054079832d3ebb4c7184e23f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.3

Release files / dotprompt_cli-0.0.4-py3-none-any.whl

Download URL dotprompt_cli-0.0.4-py3-none-any.whl
Size 8.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8ebd54ed4920cd49dfe69f630357a90bd22537d417731b2467e53698ad54065e
BLAKE2b-256 checksum
How to use checksums
2a4eff2eeee0fdf6a7f726810e9e077e7abcd729babe5bde3c087ec966cac711
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.1.1 CPython/3.12.3

Release history Release notifications | RSS feed

This release

0.0.4 This release

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.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