Research

Uncensored on request: one switch serves DeepSeek V4.1 Flash Unfiltered beside the normal model

dealignai's public uncensored build of DeepSeek V4.1 Flash differs from the original by 54 rank-1 edits, about 1 MB of numbers. We apply them per request, to flagged rows only, on the same server as the normal model. 450,198 checks found 0 normal rows changed, and the server lost 4 to 8 percent of its throughput.

8 min read

Unfiltered, per request: DeepSeek V4.1 Flash, an uncensored switch on the same server. 450,198 checks with 0 rows changed, about 1 MB of rank-1 edits, 4 to 8% throughput cost. Perch and DeepSeek logos.

DeepSeek V4.1 Flash Unfiltered is the same model with most refusals removed, for approved accounts on the Unlimited pass. It does not run on a separate copy of the model. It runs on the same server as the normal DeepSeek V4.1 Flash 1017, and each request says whether it wants the uncensored version.

This is how that switch works, how we checked that it never touches anyone else's request, and what it costs.

Key findings

  • The uncensored build is the original plus 54 rank-1 edits. We extracted them from dealignai's public uncensored build of the same model into a pairs file of about 1 MB.
  • The edit applies to flagged rows only. Over 450,198 checks on the server, 0 normal rows changed.
  • Flagged and normal requests never share prompt cache. Each strength gets its own cache namespace too.
  • The speed cost is 4 to 8 percent of server throughput in our load test. The first version cost 60 percent.
  • We chose half strength. It removed every refusal on our hardest prompt set and scored 94 and 93 on our MMLU sample, against 96 with the switch off and 92 at full strength.
  • Greedy decoding is not deterministic on this kernel stack, so "the output is identical" can never be the test. Exact row checks are.

Where the edits come from

The source is dealignai's public uncensored build of the same model, DeepSeek-V4.1-Flash-1017-UNCENSORED-FP8. The edits are their work: we found their shape and apply them per request instead of shipping a second model. Comparing its weights with the original's showed that only two matrices change per layer, in layers 10 to 36: the attention output projection and the shared expert's down projection. That is 54 matrices.

Each change has the same shape. The edited matrix is the original minus a rank-1 piece:

W' = W − λ u uᵀ W

Here u is one unit vector of 5,120 numbers and λ is a per-layer strength. So the whole difference between the two builds fits in 54 vectors and 54 strengths.

We extracted them on CPU, with HTTP range reads of just the two tensors per layer, about 2.9 GB in all, without downloading either model. The build is stored in FP8, and that took one extra step. A plain least-squares fit put the strengths 1 to 32 percent too low, because small changes fall inside FP8's rounding cells and vanish. So we refined each vector and strength until the requantized result landed in the same FP8 cells as the uncensored build. The fit reproduces 91 to 99 percent of the build's FP8 bytes exactly, and what remains matches FP8's own re-rounding noise.

The result is a pairs file of 1,107,120 bytes, checked by hash every time the server loads it.

One model, edited per request

A rank-1 edit to the weights is the same as a rank-1 edit to the matrix's output:

o' = o − λ u (uᵀ o)

That means there is no second copy of the weights. The switch is a vLLM plugin that adds a hook on each of the 54 matrices. When a batch runs, the hook applies that correction to the rows that belong to flagged requests and leaves every other row as it was. A request turns the switch on with one field in vLLM's extra arguments, so the API server needed no changes.

Two details make it safe to share a batch:

  • Unflagged rows are never written. On the fast path, a row with no correction comes back bit for bit.
  • The cache is split. A flagged request's cache key starts with a prefix that includes the pairs file's hash and the strength. It shares no prompt cache with normal requests, or with requests at another strength.

We checked the split with one prompt of about 29,700 tokens:

Request, in orderCached tokens
Normal, first0
Normal, second29,568
Flagged, first0
Flagged, second29,568
Flagged at another strength, first0
Normal, third29,568

A flagged request never reuses the normal cache, and the normal cache is untouched by flagged traffic.

Proving normal requests do not change

The obvious test is to send the same prompt with and without the plugin and compare the text. On this server that test is useless, and finding out why was one of the more useful results.

Greedy decoding is not deterministic here, even with no plugin installed. We sent 8 fixed prompts, 5 coding and 3 essays, at temperature 0. Two runs of plain vLLM matched on 0 of 8. Teacher-forced log probabilities differed by about 0.06 nats per token from run to run. The cause is the expert-layer kernel, which adds partial sums in no fixed order. Any other user's traffic moves the numbers by that much.

So we tested where the answer can be exact:

  • Rows. Debug checks compared every corrected activation's unflagged rows bit for bit, across all our test prompts, the MMLU runs and the mixed-batch runs: 450,198 checks, 0 changed.
  • The switch turned off. With the plugin installed and no flags, the server ran the same kernels and applied 0 corrections. Its log-probability noise was 0.070 within runs and 0.066 against plain vLLM, next to 0.059 within plain vLLM itself. Speed was the same.
  • Mixed batches. A normal request running beside a flagged one drifted from its solo run at the same point in the text as two plain runs drift from each other.

The first version was exact, and slow

Our first build ran any decoding step that held a flagged row without vLLM's precompiled decode graphs. That step ran about 13 times slower, and every request sharing it waited. In our load test, 32 simultaneous users with 8 flagged dropped everyone from 112.6 to 48.6 tokens per second, and server output fell 60 percent.

The second build captures a second set of decode graphs at startup, with the correction inside, in about 9 seconds. A pure decoding step with a flagged row replays those instead.

32 simultaneous usersTokens/s per userServer output
No flags112.6baseline
First build, 8 flagged48.6-60%
Second build, 8 flagged105.1-8%
Second build, all 32 flagged110.6-4%

The correction itself costs almost nothing. Running the flagged path with the correction set to nothing is as slow as running it at full strength. The cost is the path, not the math.

One gap is left. The model has a fused, single-kernel decode path that only covers small batches, and flagged steps cannot use it. At 32 users the server already runs without it, so flagged requests cost only the correction. With one user, a flagged request streamed at 468 tokens per second against 802 for a normal one, and normal requests that share a step with a flagged one lose the fused path while that step lasts. Prefill and mixed steps with a flagged row still run without graphs; median time to first token stayed at 0.45 to 0.52 seconds. Putting the correction inside the fused kernel is planned, not built.

Choosing the strength

dealignai's own strength is the obvious default. We tested lower settings to see what the refusals actually needed. These are the results with the switch off, at half strength and at full strength:

StrengthHardest prompt set, 10 prompts the normal model refusesMMLU sample, 100 questionsMoral-scenario questions, 8
Off0 complied968
Half10 complied; rerun: 9, and 1 with no answer94; rerun: 936
Full9, and 1 with no answer; rerun: 10924

"No answer" means the model thought until it hit the 8,000-token budget. It shows up at every strength, and on the normal model too. It is a thinking loop at temperature 0, not a refusal.

With 100 questions, one question is one point and the standard error is about 2.4 points, so the MMLU gaps are within noise. The drop on moral-scenario questions, from 8 right to 4 at full strength, is the one pattern that held. Half strength lost fewer of them.

We chose half strength. It is the weakest setting we tested that removed every refusal on the hardest set, in two runs, and it hurt moral judgment less than full strength. Some requests to Unfiltered are still screened anyway, so pushing harder than "no refusals" buys nothing.

If the switch cannot load

The plugin is tied to one vLLM build. If its hooks cannot be installed, for example because a new build renames a module, it logs an error and turns the switch off. Flagged requests are then served by the normal model, still in their own cache namespace. It never serves a half-installed switch. Every image update has to pass its 20 CPU tests again, plus an on-server check of every module it patches. The tests cover the masked correction touching only flagged rows, the correction matching the weight edit, flag parsing and cache keys, and every vLLM wrapper it patches.

What we would tell anyone doing the same

  • Check whether the edit is low rank. If it is, it can be a switch on one copy of the model instead of a second deployment.
  • Split the prompt cache by flag and by strength. Otherwise a normal request could reuse cache computed with the edit, or the other way round.
  • Test exactness where it can be exact. Generated text drifts on its own. Activation rows do not.
  • Measure the path, not the math. Our correction was cheap. Losing the precompiled decode graphs was not.
  • Use the weakest strength that removes the refusals. More push cost moral judgment and bought nothing we needed.

DeepSeek V4.1 Flash Unfiltered is for approved accounts on the Unlimited pass. How to apply has the rules. For how we tuned the same model's serving, see how we made DeepSeek V4.1 Flash faster.

Frequently asked questions

How can one server serve an uncensored model and the normal model at the same time?
In our case the uncensored build differs from the original by 54 rank-1 edits. A rank-1 edit to a weight matrix can be applied to that matrix's output instead, so we keep one copy of the weights and apply the edits only to the rows of requests that carry a flag. Every other row in the same batch is left alone, and flagged requests get their own prompt cache.
Does an uncensored switch change the answers normal users get?
Not in our tests. On the server, debug checks compared every corrected activation's unflagged rows bit for bit: 450,198 checks, 0 changed. Comparing generated text does not work for this, because greedy decoding on that kernel stack is not deterministic: the same request twice at temperature 0 gives different text even with no switch installed.
How much speed does a per-request uncensored switch cost?
In our load test with 32 simultaneous users, server output fell 8 percent with 8 of them flagged and 4 percent with all of them flagged. The first version, which ran flagged steps without precompiled decode graphs, cost 60 percent. A lone flagged request is still slower than a normal one, because flagged steps cannot use the model's fused single-kernel decode path.
Why run the uncensored edit at half strength?
Half strength was the weakest setting we tested that removed every refusal on our hardest prompt set, in two runs. It scored 94 and 93 of 100 on our MMLU sample, against 96 with the switch off and 92 at dealignai's full strength, and it lost fewer moral-judgment questions than full strength. With 100 questions, those MMLU gaps are within noise.

Explore Perch