Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stone Prover Examples Documentation #46

Closed

Conversation

Benjtalkshow
Copy link

closes #32

PR: Add Documentation Page for Reference Test Files and Examples

This PR adds a new documentation page under docs/pages/examples.md, which provides a comprehensive list of reference test files related to the Stone Prover and Cairo programs. The documentation includes details about the following:

  • Cairo sources
  • Execution artifacts (trace, memory, input, output)
  • Prover parameters & config
  • Proof

Each example includes a brief description of the program, its execution process, and the corresponding artifacts that are essential for generating and verifying proofs of Cairo programs.

Changes

  • New Documentation Page: Added docs/pages/examples.md
  • Reference Files: Provided links to essential test files (Cairo sources, traces, memory, prover parameters, config, and proof) from the repository and the official documentation.
  • Usage Instructions: Steps to create a proof and descriptions of all input files used in the process, ensuring clear understanding of how the Stone Prover operates.

Test Files Included:

  1. Cairo Sources
  2. Execution Artifacts (Trace, Memory, Input, Output)
  3. Prover Parameters & Config
  4. Generated Proof

References

Copy link
Member

@dmirgaleev dmirgaleev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's split the page into two parts:

  1. Section describing which files each test case contains

    • Note that there will be more than one test scenario
    • Note that cpu air prover config is the same for all tests -- make sure to note that in the docs
    • do not use chatgpt (it's obvious) it doesn't give useful info; you need to go through the available stone materials to come up with meaningful descriptions
  2. Section containing a list of test cases

    • Use a table that contains name of the program and short description what it is about
    • Add column "layout" and "builtins" that will contain respective parameters for the particular case

Additionally, can you please put files from test_files folder to a subfolder test_files/fibonacci - that would set up a basis for the new test cases.

@Benjtalkshow
Copy link
Author

Benjtalkshow commented Sep 30, 2024

Let's split the page into two parts:

  1. Section describing which files each test case contains

    • Note that there will be more than one test scenario
    • Note that cpu air prover config is the same for all tests -- make sure to note that in the docs
    • do not use chatgpt (it's obvious) it doesn't give useful info; you need to go through the available stone materials to come up with meaningful descriptions
  2. Section containing a list of test cases

    • Use a table that contains name of the program and short description what it is about
    • Add column "layout" and "builtins" that will contain respective parameters for the particular case

Additionally, can you please put files from test_files folder to a subfolder test_files/fibonacci - that would set up a basis for the new test cases.

Alright @dmirgaleev . I carefully went through the files and read about them. I just used chatgpt to correct my wrong grammar. But i have taken your corrections by the way.

@dmirgaleev
Copy link
Member

Thanks! Please, let me know if you need any assistance

@Benjtalkshow
Copy link
Author

Thanks! Please, let me know if you need any assistance

Hi, @dmirgaleev
I just made the changes requested. Thanks

Execution artifacts include the trace and memory files generated when running the Cairo programs.

- **Trace**: [`fibonacci_trace.json`](https://github.com/dipdup-io/stone-packaging/tree/master/test_files/fibonacci/fibonacci_trace.json)
- **Description**: A detailed step-by-step execution log of the Fibonacci program. This file provides insight into the program’s execution, making it a key tool for debugging and verification.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Сan you please provide a link to the website where you get this information from?

- **Description**: A detailed step-by-step execution log of the Fibonacci program. This file provides insight into the program’s execution, making it a key tool for debugging and verification.

- **Memory**: [`fibonacci_memory.json`](https://github.com/dipdup-io/stone-packaging/tree/master/test_files/fibonacci/fibonacci_memory.json)
- **Description**: Shows the memory state during execution, including how `felt252` values are stored and manipulated.It records how variables are stored and changed throughout the run, helping developers ensure proper memory handling.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Сan you please provide a link to the website where you get this information from?


- **Input Files**:
- **Private Input**: [`fibonacci_private_input.json`](https://github.com/dipdup-io/stone-packaging/tree/master/test_files/fibonacci/fibonacci_private_input.json)
- **Description**: Contains cryptographic inputs like Pedersen hashes and range checks and other sensitive data used during the proof generation process.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Сan you please provide a link to the website where you get this information from?

```

- **Public Input**: [`fibonacci_public_input.json`](https://github.com/dipdup-io/stone-packaging/tree/master/test_files/fibonacci/fibonacci_public_input.json)
- **Description**: Lays out the public input values required for running the Fibonacci program. This file ensures the correct parameters, such as the number of steps and memory segments, are applied.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Сan you please provide a link to the website where you get this information from?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Сan you please provide a link to the website where you get this information from?
@dmirgaleev
i used the referenced files provided in the task description.
Please can you give me a detailed overview of what you want to see?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just trying to understand if the docs you provided are correct. For instance, where can I find, that fibonacci_trace.json contains "A detailed step-by-step execution log of the Fibonacci program. This file provides insight into the program’s execution, making it a key tool for debugging and verification."?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just trying to understand if the docs you provided are correct. For instance, where can I find, that fibonacci_trace.json contains "A detailed step-by-step execution log of the Fibonacci program. This file provides insight into the program’s execution, making it a key tool for debugging and verification."?

Yea. i am gonna correct that. Maybe i will provided technical details of what the files does instead of making the an abstract explanation.

@Benjtalkshow
Copy link
Author

Hello @dmirgaleev
I have made the requested changes. Thanks

@dmirgaleev
Copy link
Member

Close because of a lot of things irrelevant. But your efforts will be counted.

@dmirgaleev dmirgaleev closed this Oct 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Book] Examples
2 participants