Documentation Writing Your First Formula

Writing Your First Formula

Inputs

With Melder you can write 'AI Formulas' the same way you write Excel formulas today. The simplest is =M.GEN which takes in a list of prompt arguments:

=M.GEN([prompt_segments]...)

This outputs a Melder Text record containing the AI reply.

Examples

Basic Usage

=M.GEN("tell me a joke")

Basic GEN example

Reference a Cell

=M.GEN("tell me a joke about", A2)

Cell reference example

Multiple Arguments

=M.GEN("tell me a joke about", A2, B2, "and make it funny")

Multiple arguments

Outputs

Melder Text Record

By default, =M.GEN outputs a Melder Text Record, which has special features:

  • Special icon in the cell
  • Hover to scroll through contents
  • Citation information in side panel

Melder Text Record

Plain Text Output

To get standard Excel text output, add .text to your formula:

=M.GEN("tell me a joke").text

Text output

You can also reference a Melder Text record directly:

=B2.text

Direct reference