# Proof Generation

## Create a task

To generate a proof, you need to create a task. The input for this task should be in JSON format. You can provide this either as a JSON string using `--json` or as a path to a JSON file using `--file`.

In your project's root directory, execute the following command:

```bash
snarkify task create --json {input_of_your_proof}
```

After successfully executing this command, it will display `snarkify task info {task_id}`, which you can use to check the status of your task and retrieve the proof later.

## Query a task

To check the status of your task and access the proof once it's successfully completed, use the `snarkify task info` command. Here's an example of the output:

```
┌──────────────┬───────────────────────────────────────────────────────────────────────────────────────────────┐
│ service name │ poseidon_test                                                                                 │
├──────────────┼───────────────────────────────────────────────────────────────────────────────────────────────┤
│ task id      │ e5ec45e4682b424b9204a116ba009fc9                                                              │
├──────────────┼───────────────────────────────────────────────────────────────────────────────────────────────┤
│ state        │ SUCCESS                                                                                       │
├──────────────┼───────────────────────────────────────────────────────────────────────────────────────────────┤
│ result url   │ https://snarkify-task-result-test.s3.us-west-2.amazonaws.com/e5ec45e4682b424b9204a116ba009fc9 │
└──────────────┴───────────────────────────────────────────────────────────────────────────────────────────────┘
```

For more detailed information about the task, including the proof in the result field, use the `-d` flag.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.snarkify.io/serverless-gpu-proving/snakrify-cli/proof-generation.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
