#pragma once
#include <util/stream/output.h>
#include <util/generic/maybe.h>

namespace NRTYServer {

    class THnswSearchSizeChooser {
    private:
        class TImpl;
        THolder<TImpl> Impl;
    public:
        THnswSearchSizeChooser();
        ~THnswSearchSizeChooser();

        size_t GetRecommendedSearchSize(size_t requestedTopSize) const;
        void ParseFromConfigStr(TStringBuf in);
        void DoToString(IOutputStream& so) const;
        TMaybe<TString> GetParseErrorString() const;
    };

}
