The easiest way to work with QPL programs is using the build.py script:
# Compile and execute a program
python3 build.py source.qpl
# Compile without running
python3 build.py source.qpl --no-run
# Show source and compiled code
python3 build.py source.qpl --show-code
# Save to custom output file and run with 500 shots
python3 build.py source.qpl -o output.qasm --shots 500See python3 build.py --help for full documentation.
# Run all examples
python3 run_examples.py
# Run specific example
python3 run_examples.py local_qbit.qpl
# Save compiled files to compiled_output/
python3 run_examples.py --save-compiled
# Clean up compiled files
python3 run_examples.py --clean
# List available examples
python3 run_examples.py --list# Compile QPL source to assembly
python3 compile.py source.qpl -o output.qasm
# Run compiled assembly
python3 runtime/run_from_file.py output.qasmpython3 run_tests.py
python3 run_tests.py -v # Verbose output.qpl- High-level QPL source files.qasm- Compiled assembly files