<commit_before>--- refer from openresty redis lib

local sub = string.sub
local byte = string.byte
local tcp = ngx.socket.tcp
local concat = table.concat
local null = ngx.null
local pairs = pairs
local unpack = unpack
local setmetatable = setmetatable
local tonumber = tonumber
local error = error


local ok, new_tab = pcall(require, "table.new")
if not ok then
    new_tab = function (narr, nrec) return {} end
end


local _M = new_tab(0, 155)
_M._VERSION = '0.01'


local commands = {
    --[[kv]]
    "decr",
    "decrby",
    "del",
    "exists",
    "get",
    "getset",
    "incr",
    "incrby",
    "mget",
    "mset",
    "set",
    "setnx",
    "ttl",
    "expire",
    "expireat",
    "persist",

    --[[hash]]
    "hdel", 
    "hexists", 
    "hget", 
    "hgetall", 
    "hincrby", 
    "hkeys", 
    "hlen", 
    "hmget", 
    --[["hmset",]] 
    "hset", 
    "hvals",
    --[[ledisdb special commands]] 
    "hclear", 
    "hmclear",
    "hexpire",
    "hexpireat",
    "httl",
    "hpersist",

    --[[list]]
    "lindex", 
    "llen", 
    "lpop", 
    "lpush", 
    "lrange", 
    "rpop", 
    "rpush", 
    --[[ledisdb special commands]]
    "lclear", 
    "lmclear",
    "lexpire",
    "lexpireat",
    "lttl",
    "lpersist",

    --[[zset]]
    "zadd", 
    "zcard", 
    "zcount", 
    "zincrby", 
    "zrange", 
    "zrangebyscore", 
    "zrank", 
    "zrem", 
    "zremrangebyrank", 
    "zremrangebyscore", 
    "zrevrange", 
    "zrevrank", 
    "zrevrangebyscore", 
    "zscore", 
    --[[ledisdb special commands]]
    "zclear", 
    "zmclear",
    "zexpire",
    "zexpireat",
    "zttl",
    "zpersist",

    --[[bit]]
    "bget",
    "bdelete",
    "bsetbit",
    "bgetbit",
    "bmsetbit",
    "bcount",
    "bopt",
    "bexpire",
    "bexpireat",
    "bttl",
    "bpersist",

    --[[server]]
    "ping",
    "echo",
    "select"
}


local mt = { __index = _M }

<commit_msg>add set commands for lua(openresty)<commit_after>--- refer from openresty redis lib

local sub = string.sub
local byte = string.byte
local tcp = ngx.socket.tcp
local concat = table.concat
local null = ngx.null
local pairs = pairs
local unpack = unpack
local setmetatable = setmetatable
local tonumber = tonumber
local error = error


local ok, new_tab = pcall(require, "table.new")
if not ok then
    new_tab = function (narr, nrec) return {} end
end


local _M = new_tab(0, 155)
_M._VERSION = '0.01'


local commands = {
    --[[kv]]
    "decr",
    "decrby",
    "del",
    "exists",
    "get",
    "getset",
    "incr",
    "incrby",
    "mget",
    "mset",
    "set",
    "setnx",
    "ttl",
    "expire",
    "expireat",
    "persist",

    --[[hash]]
    "hdel", 
    "hexists", 
    "hget", 
    "hgetall", 
    "hincrby", 
    "hkeys", 
    "hlen", 
    "hmget", 
    --[["hmset",]] 
    "hset", 
    "hvals",
    --[[ledisdb special commands]] 
    "hclear", 
    "hmclear",
    "hexpire",
    "hexpireat",
    "httl",
    "hpersist",

    --[[list]]
    "lindex", 
    "llen", 
    "lpop", 
    "lpush", 
    "lrange", 
    "rpop", 
    "rpush", 
    --[[ledisdb special commands]]
    "lclear", 
    "lmclear",
    "lexpire",
    "lexpireat",
    "lttl",
    "lpersist",

    --[[zset]]
    "zadd", 
    "zcard", 
    "zcount", 
    "zincrby", 
    "zrange", 
    "zrangebyscore", 
    "zrank", 
    "zrem", 
    "zremrangebyrank", 
    "zremrangebyscore", 
    "zrevrange", 
    "zrevrank", 
    "zrevrangebyscore", 
    "zscore", 
    --[[ledisdb special commands]]
    "zclear", 
    "zmclear",
    "zexpire",
    "zexpireat",
    "zttl",
    "zpersist",

    --[[bit]]
    "bget",
    "bdelete",
    "bsetbit",
    "bgetbit",
    "bmsetbit",
    "bcount",
    "bopt",
    "bexpire",
    "bexpireat",
    "bttl",
    "bpersist",

    --[[set]]
    "sadd",
    "scard",
    "sdiff",
    "sdiffstore",
    "sinter",
    "sinterstore",
    "sismember",
    "smembers",
    "srem",
    "sunion",
    "sunionstore",


    "sclear",
    "smclear",
    "sexpire",
    "sexpireat",
    "sttl",
    "spersist",

    --[[server]]
    "ping",
    "echo",
    "select"
}


local mt = { __index = _M }


{'fraction_non_alphanumeric': 0.1850230974957452, 'fraction_numerical': 0.0034038414782397277, 'mean_word_length': 2.0564635958395243, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, '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': '3070384', 'n_tokens_mistral': 1761, 'n_tokens_neox': 1647, 'n_words': 340}