From f9d993065fcd05e528957dce5459db7931c022e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Olaf=20Sch=C3=BCsler?= Date: Fri, 17 Jan 2025 18:50:08 +0100 Subject: [PATCH] [QI2-1338] Add documentation on usage --- README.md | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/README.md b/README.md index eb89f825..6bfd97ac 100644 --- a/README.md +++ b/README.md @@ -24,3 +24,37 @@ qi login ``` This will open a browser window that will allow you to login or create an account. By default this command will login to the production environment, but the command accepts an argument for a different host URL if needed (e.g. for beta testing purposes). + +## Upload files + +The CLI can be used to upload files to Quantum Inspire. These files can both be hybrid and quantum circuits. + +```bash +qi files upload +``` + +The CLI will assume that files with the extension `.cq` are quantum circuits, while files with a `.py` extension are python files. For the `backend_type` use any of the id's in the list below: + +* QX emulator, id = 1 +* Spin-2+, id = 2 +* Starmon-7, id = 3 + +## Get results + +The previous command outputs a job ID for the job that was just started. Use this job ID when querying for results. + +```bash +qi results get +``` + +**Note**: Mostly useful for quantum circuits. + +## Get final results + +A job also always contains a final result. This object can be queried with the following command. + +```bash +qi final_results get +``` + +**Note**: This object will always be generated. In the case of a quantum circuit, the result and final result will be the same. For hybrid algorithms, the final result is a free form datastructure that could for example be used for the aggregation of data. This is generated in the `finalize` step.