[KongchangAI]
Productresksecure

reskSecure

A Python package that intercepts at the logits level during LLM generation, using a 64-bit permission bitmask to define the operations a user or process may perform, implementing a bitmask-based LLM firewall to prevent jailbreak attacks and unauthorized tool calls.

Timeline (last 90 days)

Oct 14

reskSecure enforces the allowlist at the boundary, at a point earlier than when tool definitions are handed to the model, rejecting everything outside that set, so the model cannot see tools it has no right to call.

Unverified50%
Oct 14

Having only an allowlist without seeing denial records is like being blind; having only logs without enforcement is nothing but a diary—neither alone is enough.

Unverified50%
Oct 13

reskSecure uses a policy.yaml file to define policies, mapping capability bitmasks to phrase rules and tool permissions, and supports hard mode and bias mode.

Unverified50%
Oct 13

reskSecure provides the BitmaskLogitsProcessor class, used to instantiate within the generation pipeline, passing in the user mask, model name, tokenizer, policy set, and device, intercepting each token prediction and applying policy rules.

Unverified50%
Oct 13

In hard mode, the token logit matching a violating phrase is set to -inf, so the model cannot generate any part of that phrase at all, and if part has already been generated, it is forcibly ended with EOS.

Unverified50%
Oct 13

In bias mode, reskSecure applies a negative penalty value (such as -5.0) to tokens matching violating phrases, reducing but not eliminating the probability of the violating phrase appearing.

Unverified50%
Oct 13

reskSecure is a Python package that intercepts during the token prediction stage, blocking or penalizing violating phrases before they appear, and uses a 64-bit permission bitmask to define what a user or process may do.

Unverified50%
Oct 13

Hugging Face's generate interface supports intervening on logits through the logits_processor parameter, and reskSecure uses this mechanism to block or suppress violating phrases before token sampling.

Unverified50%
Oct 13

In the example policy of reskSecure, the mask 7 (binary 111) indicates possession of three capabilities, bits 0, 1, and 2, corresponding to the read_email, send_email, and read_sql tool permissions respectively.

Unverified50%
Oct 13

reskSecure intercepts in the middle of the generation process, so violating content never appears in the output stream at all, making it more timely and more thorough than post-hoc scanning.

Unverified50%

3 more timeline events

All Facts (13)

Unverified

reskSecure enforces the allowlist at the boundary, at a point earlier than when tool definitions are handed to the model, rejecting everything outside that set, so the model cannot see tools it has no right to call.

50%
Unverified

Having only an allowlist without seeing denial records is like being blind; having only logs without enforcement is nothing but a diary—neither alone is enough.

50%
Unverified

reskSecure uses a policy.yaml file to define policies, mapping capability bitmasks to phrase rules and tool permissions, and supports hard mode and bias mode.

50%
Unverified

reskSecure provides the BitmaskLogitsProcessor class, used to instantiate within the generation pipeline, passing in the user mask, model name, tokenizer, policy set, and device, intercepting each token prediction and applying policy rules.

50%
Unverified

In hard mode, the token logit matching a violating phrase is set to -inf, so the model cannot generate any part of that phrase at all, and if part has already been generated, it is forcibly ended with EOS.

50%
Unverified

In bias mode, reskSecure applies a negative penalty value (such as -5.0) to tokens matching violating phrases, reducing but not eliminating the probability of the violating phrase appearing.

50%
Unverified

reskSecure is a Python package that intercepts during the token prediction stage, blocking or penalizing violating phrases before they appear, and uses a 64-bit permission bitmask to define what a user or process may do.

50%
Unverified

Hugging Face's generate interface supports intervening on logits through the logits_processor parameter, and reskSecure uses this mechanism to block or suppress violating phrases before token sampling.

50%
Unverified

In the example policy of reskSecure, the mask 7 (binary 111) indicates possession of three capabilities, bits 0, 1, and 2, corresponding to the read_email, send_email, and read_sql tool permissions respectively.

50%
Unverified

reskSecure intercepts in the middle of the generation process, so violating content never appears in the output stream at all, making it more timely and more thorough than post-hoc scanning.

50%
Unverified

In strict mode, if a prohibited phrase is partially matched, reskSecure forces generation to terminate with EOS.

50%
Unverified

reskSecure's verify_tool_action function is used to validate tool calls after generation, checking against the bitmask whether the required bits are set in the user mask, and rejecting them if not.

50%
Unverified

reskSecure is installed via pip install resksecure, and it installs the dependency resklogits for GPU-accelerated pattern matching.

50%

Source Articles