PSL Format Overview
A PSL file is a valid INI file. INI (short for "initialization") is a configuration file format known for its simplicity and readability.
Structure of an INI File
An INI file is organized into sections, each containing keys with values. Here's a basic structure:
Each section starts with the section name enclosed in square brackets []
. Under a section, there are pairs of keys and values separated by an equals sign =
.
Advantages of Using INI for PSL Files:
Comments Using `;`:
Comments can be introduced anywhere in the INI file by using a semicolon (
;
).Example:
No Need for Quotes:
Strings don't require surrounding quotation marks.
Example:
Support for Multiline and Multi-paragraph Inputs:
Values spanning multiple lines or even paragraphs are supported with straightforward indentation.
Example:
Preserved Indentation:
Our INI parser varies slightly from standard parsers. When indentation is used (either with tabs or 4 spaces) inside a key, such as when embedding Python code, this indentation is preserved.
Example:
Code Within a Key:
You can encapsulate entire code within a key.
Example:
No Escaping of Control Characters:
Characters that often require escaping in other formats can be used directly.
Example:
The INI format, combined with our unique parser features, makes it an excellent choice for PSL. It offers creators an intuitive way to define both the configuration and workflow of their GenAI applications.
Last updated