Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.trykode.xyz/llms.txt

Use this file to discover all available pages before exploring further.

Every time you send code to a third-party LLM — even in a prompt — you are sending your variable names, function names, class names, type names, and the business logic they encode. For a startup, that might be acceptable. For a financial services firm, a medical software company, or any team with genuinely proprietary algorithms, handing identifier names to an external model is a real information security concern. Blindfold Mode solves this by making your code unreadable to the LLM while keeping Kode’s output perfectly usable.

How Blindfold Mode works

Blindfold Mode intercepts all code context before it is submitted to the LLM and replaces every identifier with a deterministic SHA-256-derived code. The mapping is kept entirely on your machine — the LLM never sees your real names.
1
Obfuscation before submission
2
When you run any Kode command with Blindfold Mode enabled, the Obfuscator scans every piece of code context using a regex that matches valid identifiers ([a-zA-Z_][a-zA-Z0-9_]{0,63}). Language keywords (package, import, func, var, const, type, struct, interface, and so on) are skipped — only your identifiers are replaced.
3
Each identifier is hashed using the formula:
4
ZK<4-digit-code> = SHA-256(salt + ":" + identifier)
5
The first two bytes of the SHA-256 digest are combined to produce a zero-padded 4-digit number, giving codes in the range ZK0000ZK9999. For example, your function calculateMonthlyInterest becomes something like ZK4821. Your class CustomerLedger becomes ZK0934. The LLM receives code that looks like:
6
func ZK4821(ZK0934 *ZK7712) float64 {
    return ZK0934.ZK1102 * ZK0934.ZK5523
}
7
The mapping stays local
8
The forward map (identifier → ZK-code) and reverse map (ZK-code → identifier) are held in memory by the Obfuscator struct and are never serialized or transmitted. The LLM has no way to reconstruct your original names from the codes it receives.
9
LLM generates obfuscated patches
10
The LLM sees the obfuscated code and generates patches using the same ZK-codes. Because the codes are consistently applied — the same identifier always maps to the same code within a session — the LLM can reason about the code’s structure even without knowing what the names mean.
11
Deobfuscation before verification and application
12
After the LLM returns a patch, the Obfuscator.Deobfuscate() method reverses every ZK-code back to its original identifier using the reverse map. The restored patch then flows through the normal six-gate verification pipeline with your real identifiers intact. If the patch passes all gates, it is written to disk with your actual, meaningful names.

Enable Blindfold Mode

Add blindfold_mode to the engine section of your .kode/kode.json:
{
  "engine": {
    "blindfold_mode": true
  }
}
Blindfold Mode is not currently available as a per-command flag. It is configured at the project level so that all Kode commands in that repository use it consistently.

Trade-offs

Understanding the trade-offs helps you decide when Blindfold Mode is worth activating.

Pros

Identifiers never leave your machine. The LLM has zero knowledge of your proprietary function names, class names, type names, or variable names. Even if a provider logs prompts, they contain only opaque ZK-codes.

Cons

Reduced contextual awareness. Semantic names help LLMs produce better suggestions. ZK4821 conveys nothing about purpose. The LLM may produce slightly more generic or less idiomatic code compared to unobfuscated mode.
The quality reduction is typically small for well-structured code, because the LLM can still reason from structure (types, function signatures, call graphs) even without semantic names. It is most noticeable for tasks that require understanding domain logic, such as adding validation rules to a complex business object.

Best for

Blindfold Mode is designed for codebases where the identifier names themselves carry material business value:
  • Financial services — proprietary risk models, pricing algorithms, trading strategies
  • Medical software — patient data models, clinical decision logic
  • Enterprise SaaS — billing logic, subscription management, data retention policies
  • Any team with a competitor concern — when you would not paste your code into a public forum
Comments and string literals are also obfuscated. Because the obfuscator processes your full file content — not just declarations — any identifier-like token inside a comment (e.g., // Apply the Basel III formula for capital adequacy) or a string literal is replaced with its ZK-code before LLM submission. This prevents inadvertent disclosure of proprietary methodologies through inline documentation.