Skip to main content

Prompt Learner

Documentation Web App Discord

What is Prompt Learner?

A Modular Approach To Prompting

Prompt Learner is designed to make prompts modular.
This enables easy tuning, quick experimentation, and frictionless maintenance.
A prompt is composed of distinct modules where each module can be optimized & modified both on its own, and as a part of the complete system. Some modules are -

  1. The task type
  2. The task description
  3. A few examples
  4. Custom Prompt Technique specific Instructions
  5. Instructions for output format

See the documentation on "Why Prompt Learner?" to learn more.

Getting started

Watch our quick start guide

You can pip install Prompt Learner:

pip install prompt-learner

How it works

Architecture Prompt-learner runs on the above architecture. Starting from the left, the user has to decide on 4 aspects -

  1. The Task
  2. A Template format for your prompt
  3. A set of Examples
  4. An LLM model to use

A task and examples feed into the template of choice (Claude, Open AI..). The task and examples also interact with selectors which can pick the best n examples for the task using statistical and machine learning techniques. These selected examples slot into the template, along with any custom instructions from any prompting technique( such as adding 'think step by step' for chain of thought prompting) comprise the final prompt. The prompt invokes the LLM through the adapter with any given inference sample to produce the final output.

Metadata

Release files for prompt-learner 0.3.3

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

Source distribution (sdist)

Source distribution for prompt-learner 0.3.3
File Size Uploaded
prompt_learner-0.3.3.tar.gz 11.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for prompt-learner 0.3.3
File Interpreter ABI Platform
prompt_learner-0.3.3-py3-none-any.whl Python 3 none any Details

Total release size: 31.3 kB

Release files / prompt_learner-0.3.3.tar.gz

Download URL prompt_learner-0.3.3.tar.gz
Size 11.3 kB
Tags Source
SHA-256 checksum
How to use checksums
9b5b660f6aaaf01af926fd7c71c52c6795adc6f7fb71c3cda064b2fcd83699f2
BLAKE2b-256 checksum
How to use checksums
28b2ceed9be7aa23f036599daf65b65361c0c4b0bbbee0e50b821b59a06778ea
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.4 Darwin/23.5.0

Release files / prompt_learner-0.3.3-py3-none-any.whl

Download URL prompt_learner-0.3.3-py3-none-any.whl
Size 20.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5ac992f4d5e6750873da0926044691ab633039bb9e29071095250118b3e41229
BLAKE2b-256 checksum
How to use checksums
78ff6323fd9514dcef6fb67d970501ee3113ea87a4082b78cd9a346f17ead556
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.4 Darwin/23.5.0

Release history Release notifications | RSS feed

This release

0.3.3 This release

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.9

2 release files

0.2.8

2 release files

0.2.7

2 release files

0.2.6

2 release files

0.2.5

2 release files

0.2.4

2 release files

0.2.3

2 release files

0.2.2

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.9

2 release files

0.1.8

2 release files

0.1.7

2 release files

0.1.6

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