Lattice FPGA - declare pin
The *.lpf file does indeed describe the pinout of the FPGA, however before explaining the lines, you should know that there is an easier way to assign them using the Lattice Diamond design software and there are some great tutorials out there showing how to do this, I've just found this one: https://youtu.be/SmdEP_ZsBgM

He starts assigning pins at about 17:15 but it's worth watching the whole thing so you can see the process from start to finish.

To give you an idea of what the lines in the lpf file mean here are a few examples:

IOBUF ALLPORTS IO_TYPE=LVCMOS33 ; = Set all ports to use the 3V3 Low Voltage CMOS logic standard.

LOCATE COMP "seg_1" SITE "V6" ; = Assign the port named "seg_1" to pin V6.

Hope this helps,

Gipsy