One-dimensional structured data hypothesis test evaluation method based on zero-knowledge proof
Through the integer reconstruction hypothesis testing method and zero-knowledge proof technology, the trust problem in synthetic data evaluation is solved, and a credible and verifiable evaluation of the distribution consistency between synthetic data and real data is achieved under the premise of protecting privacy. It is suitable for finance, medical care, government affairs and other fields.
Patent Information
- Application Number
- CN202510823619.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-19
- Publication Date
- 2025-09-19
AI Technical Summary
Existing technologies cannot effectively evaluate the distribution consistency of synthetic data and real data while protecting the privacy of real data, leading to trust issues between data owners and users.
Combining hypothesis testing methods with zero-knowledge proof technology, the test statistic calculation process is reconstructed through integerization, and an equivalent constraint circuit suitable for the zero-knowledge proof system is constructed, enabling data owners to generate credible and verifiable proof of consistency between synthetic data and real data distribution.
Without leaking real data information, the credibility and calculation accuracy of synthetic data evaluation results are ensured, solving the trust bottleneck in the data circulation process. It is suitable for highly sensitive fields such as finance, medical care, and government affairs.
Smart Images

Figure CN120675766A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of information security and trusted computing technology, and in particular relates to a one-dimensional structured data hypothesis testing and evaluation method based on zero-knowledge proof. Background Art
[0002] Against the backdrop of accelerating digital transformation, structured data, with its clear field definitions and relational characteristics, has become a core production factor driving business decisions, algorithm training, and business innovation. In high-value, data-intensive sectors such as finance, healthcare, and government affairs, data owners (such as banks, hospitals, and government agencies) have accumulated large amounts of structured business data containing user behavior trajectories, health records, and social relationships. Data users (such as third-party analysis agencies and scientific research teams) rely on this data for tasks such as model training, trend forecasting, and disease transmission pattern analysis. However, real business data often contains a large amount of sensitive and private information. To fully leverage the value of business data to meet business needs while maintaining security and compliance, various industries are gradually experimenting with using synthetic data to replace real data. This approach maintains the distribution characteristics of real data while avoiding the risk of privacy leakage in real data.
[0003] However, the utility of synthetic data is directly related to its value and reliability in real-world downstream tasks. Therefore, data owners often need to evaluate the utility of synthetic data when generating and distributing it. One method for evaluating the utility of structured data is hypothesis testing, which compares the observed frequency with the theoretical frequency and calculates a test statistic to assess the degree of fit between the observed data and the expected theoretical distribution. However, traditional hypothesis testing methods still fail to address the trust issue in the circulation of synthetic data. The core reason lies in the information asymmetry between data owners and data users: data owners can provide utility evaluation results for synthetic data, but due to privacy protection restrictions, they cannot disclose any real data or its statistical information. Data users, on the other hand, need to rely on real data for comparison when verifying the quality of synthetic data. This conflicting verification logic leads to an impasse between the two parties. How to ensure that data owners provide data users with a verifiable utility evaluation result for synthetic data while protecting the privacy of real data has become a key challenge in breaking the trust bottleneck in data circulation.
[0004] To address this issue, zero-knowledge proof technology can be introduced into the utility evaluation process of structured synthetic data to ensure that no specific information about the real data is leaked during the evaluation of the distribution fit between the synthetic data and the real sample data. However, in the process of introducing zero-knowledge proof technology, the limitations of zero-knowledge proof in its application must be overcome. First, zero-knowledge proof calculations are usually performed on finite fields. Since finite fields are discrete and cannot directly support floating-point operations, floating-point numbers need to be converted to fixed-point representation through scaling factors. However, this method may lead to loss of computational precision, especially when multiple operations are involved, as errors may be accumulated and amplified. Second, most existing zero-knowledge proof systems have difficulty handling traditional division operations and can only simulate them through multiplication inverse elements on finite fields. The calculation of inverse elements usually relies on the extended Euclidean algorithm, which is more complex than ordinary multiplication. The floating-point numbers generated during the calculation process can also lead to loss of precision and even computational overflow problems.
[0005] Therefore, there is an urgent need to propose a zero-knowledge proof implementation solution that supports statistical testing, has controllable computational accuracy, and is applicable to finite domain environments, so as to promote the compliant, secure, and trustworthy sharing of structured synthetic data on a larger scale. Summary of the Invention
[0006] The purpose of the present invention is to provide a hypothesis testing and evaluation method for one-dimensional structured data based on zero-knowledge proof, thereby completing a credible and verifiable evaluation of the distribution consistency between synthetic data and real data without leaking the real data or its sensitive statistical information. To this end, the present invention combines the hypothesis testing method with zero-knowledge proof technology, integer-reconstructs the calculation process of the statistics in traditional hypothesis testing, and then constructs an equivalent constraint circuit suitable for zero-knowledge proof systems. Through the above circuit design, the data owner, as the prover, can generate a zero-knowledge proof of the hypothesis test result without disclosing the real data; the data user, as the verifier, only needs to obtain synthetic data and a small amount of non-sensitive public input information to independently verify the correctness of the hypothesis testing process and conclusion. At the same time, even within the computational constraints of zero-knowledge proof, the reconstructed test statistic can still maintain a low loss of computational accuracy and effectively evaluate the distribution difference between synthetic data and real data.
[0007] The specific technical solution for achieving the purpose of the present invention is:
[0008] A zero-knowledge proof-based hypothesis testing and evaluation method for single-dimensional structured data evaluates the distribution consistency between real data and synthetic data while ensuring the privacy of real data. By adapting hypothesis testing in the statistical field to the zero-knowledge proof environment and integer-reconstructing the calculation process of the test statistic, the limitations of zero-knowledge proof in application, such as precision loss, difficulty in division operations, and high circuit complexity, are overcome.
[0009] The hypothesis test is a statistical inference method based on significance levels. It measures the distribution difference between synthetic data and real data on a single-dimensional variable by constructing a test statistic, and determines whether the null hypothesis is valid based on the relationship between the test statistic and the critical value. The zero-knowledge proof is a cryptographic protocol that allows the prover to prove to the verifier that they have correctly performed the distribution consistency test calculation for synthetic data and real data without revealing any additional information. The integer reconstruction is a reconstruction method that converts floating-point calculations into fixed-point integer operations, quantizing them through scaling factors and using generalization to convert division into multiplication, to adapt to the requirements of zero-knowledge proof for finite field integer operations.
[0010] This paper combines hypothesis testing methods with zero-knowledge proof technology to achieve a credible and verifiable evaluation of the distribution consistency of single-dimensional structured data, including the following steps:
[0011] Step A1: Synthetic data preprocessing: The prover reads the synthetic data and selects the single-dimensional structured attribute to be tested. Based on the two different attribute types, continuous variables and discrete variables, the frequency is counted using equal-width binning and category statistics respectively. The frequency of the synthetic data is used as the observation frequency.
[0012] Step A2: Circuit modeling: Use real data as the private input of the zero-knowledge proof circuit, and the observed frequency of the synthetic data and the preset chi-square distribution critical value as the public input, and pass them into the circuit. Within the circuit, calculate the frequency of the real data in each category or interval to obtain the expected frequency. Then, the formula for the chi-square goodness-of-fit test is integerized to adapt to the finite field operation of the zero-knowledge proof, and compared with the preset chi-square distribution critical value to determine the distribution consistency of the synthetic data and the real data at a predetermined significance level. The formula for the chi-square goodness-of-fit test is as follows:
[0013]
[0014] in Indicates the number of categories for discrete variables or the number of intervals for continuous variables. Indicates the synthetic data The frequency of the category, Indicates the real data The frequency of the category, and are the total capacity of synthetic data and real data, The significance level is The degrees of freedom are The critical value of the chi-square distribution, is the scaling factor that uniformly scales floating-point numbers to integers;
[0015] Step A3: Circuit compilation and proof generation: The prover compiles the structure of the circuit and each computational step into an R1CS constraint system; combines the private and public inputs of the circuit to construct a witness that satisfies the circuit constraints; then uses the witness, public input, and the proof key pk distributed by the trusted third party in the zero-knowledge proof protocol to generate the final zero-knowledge proof. ;
[0016] Step A4: Proof Verification: The verifier receives the synthetic data provided by the prover, the preset chi-square distribution critical value, and the zero-knowledge proof. , by using the public input and the verification key vk distributed by the trusted third party in the zero-knowledge proof protocol, the verifier is able to verify the zero-knowledge proof Whether it is effective, and then confirm the consistency of the distribution of synthetic data and real data without having to access real data;
[0017] Among them: the zero-knowledge proof is a cryptographic protocol that allows the prover to prove to the verifier that it has correctly performed the distribution consistency test calculation of synthetic data and real data without revealing any additional information; the R1CS constraint system is a formal representation method for expressing the logical constraints of a computational circuit. The constraint system consists of a number of triples and can express the integer addition and multiplication relationship in the optimized test statistic calculation; the Witness is a set of circuit private inputs and intermediate variable values that satisfy the R1CS constraint system, including the real data used by the prover in the process of executing the internal calculation of the circuit, the frequency of the real data in each category or interval, and the intermediate results of the statistical calculation, which are used to generate the final zero-knowledge proof, but are not disclosed to the verifier.
[0018] Furthermore, the step A1 includes the following steps:
[0019] Step A11: The prover obtains the synthetic dataset to be evaluated and selects one of the single-dimensional structured attributes as the object of hypothesis testing;
[0020] Step A12: Determine whether the selected attribute belongs to a continuous variable or a discrete variable;
[0021] Step A13: If the selected attribute is a continuous variable, the value range of the attribute is divided using the equal-width binning method, and the frequency of the synthetic data in each interval is counted;
[0022] Step A14: If the selected attribute is a discrete variable, directly count the frequency of the synthetic data in each category.
[0023] Furthermore, the step A2 includes the following steps:
[0024] Step A21: Using the real data corresponding to the attribute to be verified as the private input of the zero-knowledge proof circuit, and using the observed frequency of the synthetic data and the preset chi-square distribution critical value as the public input of the circuit;
[0025] Step A22: In the circuit, the real data is processed according to the type of the attribute to be tested. If it is a discrete variable, its frequency in each category is counted; if it is a continuous variable, its frequency in each interval is counted to obtain the expected frequency;
[0026] Step A23: Perform an equivalent transformation on the statistical formula of the chi-square goodness-of-fit test. Through mathematical processing such as common denominator and scaling, the expression containing floating-point numbers and division operations is reconstructed into a form containing only integer addition and multiplication, which is convenient for implementation in the circuit.
[0027] Step A24: Based on the transformed test statistic formula, the chi-square test statistic is calculated by combining the expected frequency and the observed frequency, and compared with the preset chi-square distribution critical value;
[0028] Step A25: If the test statistic is less than or equal to the preset chi-square distribution critical value, the hypothesis test conclusion is output as True, indicating that the distribution of the synthetic data is consistent with that of the real data at the predetermined significance level;
[0029] Step A26: If the test statistic is greater than the preset chi-square distribution critical value, the hypothesis test conclusion is output as False, indicating that the distribution of the synthetic data is inconsistent with that of the real data at the predetermined significance level.
[0030] Furthermore, the step A3 includes the following steps:
[0031] Step A31: The prover uses the zero-knowledge proof compiler to compile the circuit structure and computational logic in step A2 into an R1CS constraint system;
[0032] Step A32: The prover constructs a witness that satisfies the circuit constraints based on the private input and public input of the circuit.
[0033] Step A33: The prover generates a zero-knowledge proof using the generated Witness, public input, and the proof key pk distributed by the trusted third party. , which is used to prove the statistical distribution consistency between synthetic data and real data under a predetermined threshold.
[0034] Furthermore, the step A4 includes the following steps:
[0035] Step A41: The verifier receives the synthetic data from the prover, the agreed chi-square distribution critical value, and the zero-knowledge proof ;
[0036] Step A42: The verifier uses the zero-knowledge proof verification algorithm to verify the proof based on the verification key vk distributed by the trusted third party and the public input. Verify the effectiveness of
[0037] Step A43: If the verification passes, it indicates that the synthetic data and the real data are distributed consistently at the preset significance level, and the evaluation results are credible;
[0038] Step A44: If the verification fails, it indicates that the evaluation result is unacceptable. The verifier may refuse to accept the synthesized data and require the prover to regenerate the synthesized data and submit a new zero-knowledge proof.
[0039] The beneficial effects of the present invention include:
[0040] The present invention aims to break through the trust bottleneck of synthetic data in the circulation process, design a zero-knowledge proof method that can efficiently support statistical hypothesis testing tasks, and realize verifiable structured data synthesis utility evaluation. The present invention fully considers the technical limitations of zero-knowledge proof such as the lack of floating-point support and complex division processing. By integer-reconstructing the test statistic calculation process in the hypothesis test and constructing a corresponding zero-knowledge proof circuit, the controllability of the test accuracy and the credibility and verifiability of the calculation results are guaranteed. The prover can generate a zero-knowledge proof of the hypothesis test result without leaking any real data or its sensitive statistical information. The verifier only needs to obtain synthetic data and a small amount of non-sensitive public input to independently verify the logical integrity and computational correctness of the test process. The present invention not only solves the contradiction between the inability to leak real data and the need to verify the test process, but also improves the feasibility and trust basis of synthetic data evaluation in actual business scenarios. It is particularly suitable for highly sensitive fields such as finance, medical care, and government affairs that have strict compliance requirements for data privacy. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 This is a framework diagram of the one-dimensional structured data hypothesis testing and evaluation method based on zero-knowledge proof proposed by the present invention;
[0042] Figure 2 This is a flow chart of zero-knowledge proof generation and verification for the chi-square goodness-of-fit test problem proposed in the present invention. DETAILED DESCRIPTION
[0043] The present invention is further described in detail with reference to the following specific examples and accompanying drawings. The processes, conditions, experimental methods, etc. for implementing the present invention, except for those specifically mentioned below, are common knowledge and common common sense in the art and are not particularly limited by the present invention.
[0044] The present invention discloses a one-dimensional structured data hypothesis test evaluation method based on zero-knowledge proof, which aims to achieve a credible and verifiable evaluation of the distribution consistency of synthetic data and real data under the premise of protecting real data and its sensitive statistical information. This method reconstructs the statistical calculation process in traditional hypothesis testing into integers, and converts floating-point operations into fixed-point integer calculations executable in the zero-knowledge proof system by means of preset scaling factors and arithmetic substitution; further constructs an equivalent constraint circuit so that the data owner, as the prover, generates a zero-knowledge proof that conforms to the statistical test process, and the data user, as the verifier, only needs to access the synthetic data and a small amount of non-sensitive public input information to independently verify the correctness of the entire hypothesis testing process and the credibility of the conclusion. This method effectively takes into account both computational accuracy and proof efficiency, overcomes the problem that traditional statistical analysis methods are difficult to directly apply in privacy-restricted environments, and provides a feasible path for the credible implementation of synthetic data utility evaluation in highly sensitive data scenarios.
[0045] Figure 1 This figure shows the framework of the zero-knowledge proof hypothesis testing method for single-dimensional structured data proposed in this paper. The data owner, as the prover of the method, is responsible for generating synthetic data and proving its statistical distribution consistency with the real data. Specific tasks include:
[0046] (1) Preprocessing of real data: The data owner first preprocesses the real data and synthetic data, dividing them into discrete or continuous variables and performing frequency statistics based on the variable type. Discrete variables: Divide the data into multiple categories and calculate the expected frequency of each category. Continuous variables: Divide the data into multiple intervals and calculate the observed frequency of each interval.
[0047] (2) Chi-square goodness-of-fit test: The data owner uses the chi-square test method to calculate the goodness-of-fit statistic between the synthetic data and the real data, and quantify the degree of approximation of the synthetic data to the real distribution.
[0048] (3) Zero-knowledge proof generation: The data owner generates a zero-knowledge proof (ZKP) based on the results of the chi-square test to prove that the distribution of the synthetic data is consistent with the distribution of the real data without revealing any specific information of the real data.
[0049] (4) Result output: If the verification passes, the proof will return a "true" result, indicating that the hypothesis test is successful; if it fails, it will return "false".
[0050] Data users, acting as verifiers of the method, receive synthetic data and its corresponding zero-knowledge proof from the data owner and can independently verify that the distribution of the synthetic data is consistent with the distribution of the real data. This verification process does not rely on any real data, but is based solely on publicly available synthetic data and zero-knowledge proofs.
[0051] In the field of cryptography, circuit models, with their parallel topology and modular computing unit design, demonstrate significant advantages when processing highly parallelized and specific types of computing tasks (such as large-scale matrix operations). In zero-knowledge proofs, circuits are mathematical models used to describe the computational process. Through circuits, the prover can transform the computational task into a series of constraints that precisely define the relationship between input and output. Each computational step in the circuit is converted into a constraint, ensuring that the computational process can be confirmed as correct by the verifier without leaking the input data. The present invention uses the gnark library to design and compile zero-knowledge proof circuits. gnark is a high-performance zk-SNARK library that provides a high-level API interface for circuit design and implementation.
[0052] Figure 2 The flowchart of the zero-knowledge proof generation and verification for the chi-square goodness-of-fit test problem proposed by the present invention is shown. It is mainly divided into the following steps:
[0053] (1) Circuit writing: The data owner (prover) uses the API provided by gnark to convert the calculation steps of the chi-square goodness-of-fit test, including data reading, frequency statistics, test statistic calculation, distribution comparison, etc., into basic calculation units in the zero-knowledge proof circuit. These calculation units construct the logical structure of the circuit through gates and connections. Specifically:
[0054] Private Input: Private input is core information that the prover wishes to keep confidential. It is not exposed to the verifier and remains confidential throughout the zero-knowledge proof process. In the synthetic data utility evaluation scenario, private input is real data accumulated by the data owner.
[0055] Public Input: Public input is data that needs to be made public during the proof process and is usually shared by the verifier and the prover. Public input is non-sensitive data and can be used directly by the verifier for verification. In the synthetic data utility evaluation scenario, public input includes: the observation frequency of synthetic data in each category or interval, the total capacity of real data, and the number of observations in each category or interval. , the total capacity of the synthetic data , the predetermined significance level The corresponding chi-square distribution critical value .
[0056] Data reading: Loading private and public inputs into the circuit. This process is achieved through input gates to ensure the correct delivery and initialization of data.
[0057] Frequency statistics: Calculate the frequency of real data in each category or interval. This step is completed through the addition gate, selection gate, and comparison gate in the circuit to ensure the accuracy and efficiency of frequency calculation.
[0058] Test statistic calculation: The circuit calculates the test statistic according to the optimized test statistic formula based on the frequency statistics of the input synthetic data and the intermediate results generated in the previous step. This calculation process is completed through mathematical operation gates such as addition gates and multiplication gates to ensure the correctness of the statistical calculation. The formula is:
[0059]
[0060] in Indicates the number of categories for discrete variables or the number of intervals for continuous variables. Indicates the synthetic data The frequency of the category, Indicates the real data The frequency of the category, and are the total capacity of synthetic data and real data, The significance level is The degrees of freedom are The critical value of the chi-square distribution, is the scaling factor that uniformly scales floating point numbers to integers.
[0061] Distribution comparison: The circuit uses the calculated test statistic and the input chi-square distribution critical value to determine whether the distribution of the synthetic data and the real data are consistent at a predetermined significance level through a comparison gate.
[0062] (2) Circuit Compilation: The data owner (prover) uses the gnark compiler to convert the structure of the circuit and each computational step into an R1CS (Rank-1 Constraint System). By converting each operation in the circuit into a corresponding mathematical constraint, the computational rules defined by the circuit are ensured to be followed during the subsequent proof generation process.
[0063] (3) Protocol Initialization: During the protocol initialization phase, a trusted third party generates a public reference string consisting of a Proving Key (pk) and a Verification Key (vk). pk is used by the data owner (prover) to generate valid proofs, while vk is used by the data user (verifier) to check the validity of proofs during the verification phase. This step provides the necessary security foundation for subsequent proof generation and verification.
[0064] (4) Proof Generation: The proof generation phase includes two processes: witness generation and proof calculation. First, the data owner (prover) constructs a witness that satisfies the circuit constraints based on the private input and public input of the circuit. Then, the generated witness, public input and proof key pk are used to generate the final zero-knowledge proof. , which is used to prove the statistical distribution consistency between synthetic data and real data under a predetermined threshold.
[0065] (5) Proof Verification: In the verification phase, the data user (verifier) receives the zero-knowledge proof of the synthetic data and its utility evaluation results provided by the data owner. By using the public input and verification key vk, data users can verify the zero-knowledge proof The effectiveness of the algorithm is then verified to confirm the consistency of the distribution of the synthetic data with the real data. This process does not require access to the real data, ensuring the privacy and security of the real data.
[0066] Through the above process, zero-knowledge proof technology achieves the dual goals of privacy protection and verifiability in hypothesis testing between synthetic and real data. Data owners can generate verifiable hypothesis test results, proving the distributional consistency of synthetic and real data without disclosing real data. Data users can then independently verify these results, ensuring the statistical reliability of the synthetic data.
[0067] The protection content of the present invention is not limited to the above embodiments. Without departing from the spirit and scope of the inventive concept, changes and advantages that can be thought of by those skilled in the art are included in the present invention and are protected by the appended claims.
Claims
1. A one-dimensional structured data hypothesis testing and evaluation method based on zero-knowledge proof, characterized in that: Combining zero-knowledge proof and chi-square goodness-of-fit test method, we can achieve a credible and verifiable evaluation of the distribution consistency between synthetic data and real data while protecting the privacy of real data. The specific steps include the following: Step A1: Synthetic data preprocessing: The prover reads the synthetic data and selects the single-dimensional structured attribute to be tested. Based on the two different attribute types, continuous variables and discrete variables, the frequency is counted using equal-width binning and category statistics respectively. The frequency of the synthetic data is used as the observation frequency. Step A2: Circuit modeling: Use real data as the private input of the zero-knowledge proof circuit, and pass the observed frequency of the synthetic data and the preset chi-square distribution critical value as the public input to the circuit; Inside the circuit, the frequency of real data in each category or interval is calculated to obtain the expected frequency; The formula for the chi-square goodness-of-fit test is then integerified to accommodate the finite field operations of the zero-knowledge proof and compared with a preset chi-square distribution critical value to determine the distribution consistency between the synthetic data and the real data at a predetermined significance level. The formula for the chi-square goodness-of-fit test is as follows: ; in Indicates the number of categories for discrete variables or the number of intervals for continuous variables. Indicates the synthetic data The frequency of the category, Indicates the real data The frequency of the category, and are the total capacity of synthetic data and real data, The significance level is The degrees of freedom are The critical value of the chi-square distribution, is the scaling factor that uniformly scales floating-point numbers to integers; Step A3: Circuit compilation and proof generation: the prover compiles the structure of the circuit and each computational step into an R1CS constraint system. Combine the private and public inputs of the circuit to construct a Witness that satisfies the circuit constraints. The final zero-knowledge proof is then generated using the Witness, public input, and the proof key pk distributed by the trusted third party in the zero-knowledge proof protocol. ; Step A4: Proof Verification: The verifier receives the synthetic data provided by the prover, the preset chi-square distribution critical value, and the zero-knowledge proof. , by using the public input and the verification key vk distributed by the trusted third party in the zero-knowledge proof protocol, the verifier is able to verify the zero-knowledge proof Whether it is effective, and then confirm the consistency of the distribution of synthetic data and real data without having to access real data; The zero-knowledge proof is a cryptographic protocol that allows the prover to prove to the verifier that they have correctly performed the distribution consistency check calculation of synthetic data and real data without revealing any additional information; The R1CS constraint system is a formal representation method for expressing logical constraints of computational circuits. The constraint system consists of several triples and can express the integer addition and multiplication relationship in the optimized test statistic calculation. The Witness is a set of circuit private inputs and intermediate variable values that satisfy the R1CS constraint system. It contains the real data used by the prover in the process of executing the internal calculation of the circuit, the frequency of the real data in each category or interval, and the intermediate results of the statistical calculation. It is used to generate the final zero-knowledge proof but is not disclosed to the verifier.
2. The one-dimensional structured data hypothesis testing and evaluation method according to claim 1, wherein: The step A1 comprises the following steps: Step A11: The prover obtains the synthetic dataset to be evaluated and selects one of the single-dimensional structured attributes as the object of hypothesis testing; Step A12: Determine whether the selected attribute belongs to a continuous variable or a discrete variable; Step A13: If the selected attribute is a continuous variable, the value range of the attribute is divided using the equal-width binning method, and the frequency of the synthetic data in each interval is counted; Step A14: If the selected attribute is a discrete variable, directly count the frequency of the synthetic data in each category.
3. The one-dimensional structured data hypothesis testing and evaluation method according to claim 1, wherein: Step A2 includes the following steps: Step A21: Using the real data corresponding to the attribute to be verified as the private input of the zero-knowledge proof circuit, and using the observed frequency of the synthetic data and the preset chi-square distribution critical value as the public input of the circuit; Step A22: In the circuit, the real data is processed according to the type of the attribute to be tested. If it is a discrete variable, its frequency in each category is counted; if it is a continuous variable, its frequency in each interval is counted to obtain the expected frequency; Step A23: Perform an equivalent transformation on the statistical formula of the chi-square goodness-of-fit test. Through mathematical processing such as common denominator and scaling, the expression containing floating-point numbers and division operations is reconstructed into a form containing only integer addition and multiplication, which is convenient for implementation in the circuit. Step A24: Based on the transformed test statistic formula, the chi-square test statistic is calculated by combining the expected frequency and the observed frequency, and compared with the preset chi-square distribution critical value; Step A25: If the test statistic is less than or equal to the preset chi-square distribution critical value, the hypothesis test conclusion is output as True, indicating that the distribution of the synthetic data is consistent with that of the real data at the predetermined significance level; Step A26: If the test statistic is greater than the preset chi-square distribution critical value, the hypothesis test conclusion is output as False, indicating that the distribution of the synthetic data is inconsistent with that of the real data at the predetermined significance level.
4. The one-dimensional structured data hypothesis testing and evaluation method according to claim 1, wherein: The step A3 comprises the following steps: Step A31: The prover uses the zero-knowledge proof compiler to compile the circuit structure and computational logic in step A2 into an R1CS constraint system; Step A32: The prover constructs a witness that satisfies the circuit constraints based on the private input and public input of the circuit. Step A33: The prover generates a zero-knowledge proof using the generated Witness, public input, and the proof key pk distributed by the trusted third party. , which is used to prove the statistical distribution consistency between synthetic data and real data under a predetermined threshold.
5. The one-dimensional structured data hypothesis testing and evaluation method according to claim 1, wherein: Step A4 includes the following steps: Step A41: The verifier receives the synthetic data from the prover, the agreed chi-square distribution critical value, and the zero-knowledge proof ; Step A42: The verifier uses the zero-knowledge proof algorithm to verify the proof based on the verification key vk distributed by the trusted third party and the public input. Verify the effectiveness of Step A43: If the verification passes, it indicates that the synthetic data and the real data are distributed consistently at the preset significance level, and the evaluation results are credible; Step A44: If the verification fails, it indicates that the evaluation result is unacceptable. The verifier may refuse to accept the synthesized data and require the prover to regenerate the synthesized data and submit a new zero-knowledge proof.