Since RediSearch also uses RESP protocol, you can try redis-plus-plus'
generic command interface. Take FT.SEARCH for an example:
```
// variant<size, doc id, attributes<key, value>>
using Item = variant<long long, string, unordered_map<string, string>>;
auto result = r.command<vector<Item>>("FT.SEARCH", "myIdx", "hello", "LIMIT", "0", "10");
auto size = std::get<long long>(result.front());
for (auto iter = result.begin() + 1; iter != result.end(); ) {
auto &doc_id = std::get<string>(*iter++);
auto &attrs = std::get<unordered_map<string, string>>(*iter++);
}
```
Disclaimer: I'm the author of redis-plus-plus. If you have any problem on it, feel free to let me know.
Also
redis-plus-plus-modules has built-in support for some popular Redis modules, which is based on redis-plus-plus. However, it does not support RediSearch yet. You can open an issue for it. I think @
wingunder will be happy to add it to a TODO list.
Regards