Content Protection â
Claudux provides robust mechanisms to protect sensitive, manually curated, or work-in-progress content from AI modification.
Protection Philosophy â
Principle: AI should enhance documentation, not overwrite human expertise.
Approach: Multiple layers of protection ensure critical content remains untouched while allowing beneficial updates elsewhere.
Skip Markers â
Inline Protection â
Protect specific sections within files using language-appropriate skip markers:
Markdown files:
<!-- skip -->
## Sensitive Configuration Details
This section contains confidential setup instructions
that should not be automatically modified.
### Internal API Keys
- Production key: [manual setup required]
- Staging key: [contact devops]
<!-- /skip -->
JavaScript/TypeScript:
// skip
const INTERNAL_CONFIG = {
// This configuration is manually maintained
// and should not be auto-updated
secretEndpoint: "internal.company.com"
};
// /skip
Python:
# skip
# This function handles legacy authentication
# Keep unchanged for backward compatibility
def legacy_auth_handler():
pass
# /skip
Swift:
// skip
// Core authentication logic - manually maintained
class AuthManager {
// Implementation details preserved
}
// /skip
Supported Languages â
Language | Start Marker | End Marker |
---|---|---|
Markdown | <!-- skip --> | <!-- /skip --> |
JavaScript/TypeScript | // skip | // /skip --> |
Python | # skip | # /skip |
Swift | // skip | // /skip --> |
Go | // skip | // /skip --> |
Rust | // skip | // /skip --> |
Java/C++ | // skip | // /skip --> |
Path-Based Protection â
Automatically Protected Directories â
Claudux never modifies content in these directories:
đ Protected Paths:
âââ notes/ # Personal notes and drafts
âââ private/ # Confidential documentation
âââ .git/ # Version control data
âââ node_modules/ # Dependencies
âââ vendor/ # Third-party code
âââ target/build/dist/ # Build artifacts
Protected File Patterns â
Files matching these patterns are never modified:
đ Protected Files:
*.env # Environment configuration
*.key, *.pem # Cryptographic keys
*.p12 # Certificates
*.keystore # Java keystores
Custom Path Protection â
Configure additional protected paths in your project's content protection settings.
Work-in-Progress Protection â
Draft Documentation â
Protect documentation that's actively being written:
<!-- skip -->
# đ§ Work in Progress: New Feature Documentation
This section is actively being written and should not
be modified until complete.
## Authentication Flow v2
[Draft content being written by Sarah]
<!-- /skip -->
Collaborative Workflows â
Protect content being edited by team members:
<!-- skip -->
<!--
ASSIGNED TO: John Doe
DUE DATE: 2025-09-15
STATUS: In Review
This API documentation is being updated as part
of the v3.0 release cycle.
-->
## Enterprise API Documentation
[Content under active development]
<!-- /skip -->
Configuration-Based Protection â
Project-Level Settings â
Configure protection in claudux.json
:
{
"project": {
"name": "My Project",
"type": "nodejs"
},
"protection": {
"directories": ["internal/", "drafts/"],
"files": ["*.private.md", "team-notes.md"],
"patterns": ["*-wip-*"]
}
}
Git Integration â
Leverage git patterns for protection:
# .gitignore patterns extend to documentation protection
echo "internal-docs/" >> .gitignore
echo "*.secret.md" >> .gitignore
Protection Verification â
Skip Marker Detection â
Claudux validates protection markers during generation:
đĄī¸ Protection Analysis:
â
Found 3 skip sections in docs/api/internal.md
â
Protected directory: notes/ (12 files)
â
Protected files: 4 files matching *.env pattern
âšī¸ Total protected content: 156 lines across 8 files
Protection Reporting â
After generation, claudux reports what was protected:
đ Protection Summary:
đĄī¸ Protected content preserved:
âĸ docs/internal/secrets.md (skip markers)
âĸ notes/ directory (5 files)
âĸ config.env (file pattern)
đ Content updated:
âĸ docs/guide/setup.md (outside protected sections)
âĸ docs/api/public.md (no protection markers)
Best Practices â
1. Granular Protection â
Protect only what needs protection:
## Public API Documentation
This section documents our public API endpoints.
<!-- skip -->
### Internal Debugging Endpoints
These are for development use only...
<!-- /skip -->
## Authentication Flow
Standard OAuth 2.0 implementation...
2. Clear Boundaries â
Use descriptive comments explaining why content is protected:
<!-- skip -->
<!--
PROTECTED: Contains production credentials and internal URLs
Last updated: 2025-08-15 by Security Team
Next review: 2025-09-15
-->
## Production Deployment Checklist
<!-- /skip -->
3. Version Control Integration â
Commit protection markers to ensure team-wide consistency:
git add docs/internal.md # Commit skip markers
git commit -m "Add protection markers for sensitive documentation"
4. Periodic Review â
Regularly review protected content:
# Find all skip markers across documentation
grep -r "skip" docs/ --include="*.md"
# Review if protection is still needed
claudux update -m "Review and update content protection markers"
Protection Override â
Emergency Updates â
When protected content needs updating:
# Temporarily remove skip markers, update, then re-add
claudux update -m "Update protected section X after removing skip markers"
Selective Protection Removal â
Remove protection from specific sections:
<!-- Previously protected section now ready for AI updates -->
## Configuration Guide
This section is now stable and can be automatically maintained.
Protection Implementation â
Claudux implements protection through:
- Pre-processing scan: Identifies all protection markers before AI analysis
- Content isolation: Protected sections are excluded from AI context
- Post-processing merge: Protected content is merged back after generation
- Validation: Ensures protection markers remain intact
This multi-layer approach guarantees that protected content remains completely untouched during the documentation generation process.