<commit_before><?php
/**
 * ZnZend
 *
 * @author <NAME> <<EMAIL>>
 * @link   http://github.com/zionsg/ZnZend for canonical source repository
 */

namespace ZnZend\Captcha\Service;

/**
 * Interface for services providing question/answer for ZnZend\Captcha\Question adapter
 */
interface QuestionServiceInterface
{
    /**
     * Generate new set of question and answer
     *
     * @return QuestionServiceInterface
     */
    public function generate();

    /**
     * Get current question
     *
     * @return string
     */
    public function getQuestion();

    /**
     * Verify user input with current answer
     *
     * This is preferred over a getAnswer() method as the developer would not
     * need to know the implementation details in order to compare the answers.
     *
     * @param  mixed $value
     * @return bool
     */
    public function verify($value);<commit_msg>Use getAnswer() instead of verify() as service does not cache answers<commit_after><?php
/**
 * ZnZend
 *
 * @author <NAME> <<EMAIL>>
 * @link   http://github.com/zionsg/ZnZend for canonical source repository
 */

namespace ZnZend\Captcha\Service;

/**
 * Interface for services providing question/answer for ZnZend\Captcha\Question adapter
 */
interface QuestionServiceInterface
{
    /**
     * Generate new set of question and answer
     *
     * @return QuestionServiceInterface
     */
    public function generate();

    /**
     * Get current question
     *
     * @return string
     */
    public function getQuestion();

    /**
     * Get answer to current question
     *
     * @return string
     */
    public function getAnswer();
{'fraction_non_alphanumeric': 0.10225197808886184, 'fraction_numerical': 0.0, 'mean_word_length': 2.629139072847682, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5447754', 'n_tokens_mistral': 452, 'n_tokens_neox': 437, 'n_words': 143}