Skip to content

Commit

Permalink
initial documentation for prompt format
Browse files Browse the repository at this point in the history
  • Loading branch information
Viehzeug committed Oct 26, 2023
1 parent 21f3c8a commit b9f2e57
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
2 changes: 2 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ Next to the `test.json` file, the `instances/` directory contains the recorded i

Each instance is generated using [`lve record`](#recording-an-lve). To create an LVE instance, `lve record` instantiates the prompt template using concrete placeholder values as provided by the user. It then runs the prompt against the model using a provided inference configuration (e.g. `temperature`) and finally applies the LVE's checking logic to determine whether the model's response passes or fails the LVE.

The prompt here can be a list of messages in JSON format (with `content` and `role`) or point to a `promptfile` congaing the prompt. For more details and prompts with multiple variables see [Prompt Formats](./prompt/format).

After running the model and checking the resulting output, `lve record` stores information on the recorded instance in the `instances/` directory, which includes JSON lines of the following format:

```json
Expand Down
8 changes: 8 additions & 0 deletions docs/prompt/format.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Prompt Format

## Prompt File
A prompt file can contain either plain text, a single message as a single JSON object or a sequence of messages with one JSON object per line (JSONL).


## Multi-Variable Prompts
TBD.

0 comments on commit b9f2e57

Please sign in to comment.