Class: ClaudeMemory::Ingest::ContentSanitizer
- Inherits:
-
Object
- Object
- ClaudeMemory::Ingest::ContentSanitizer
- Defined in:
- lib/claude_memory/ingest/content_sanitizer.rb
Overview
Strips privacy tags from transcript content before ingestion.
Note: No tag count limit is enforced. The regex pattern /<tag>.*?</tag>/m is provably safe from ReDoS (non-greedy matching with clear delimiters). Performance is O(n) and excellent even with 1000+ tags (~0.6ms). Long Claude sessions legitimately accumulate many tags (100-200+).
Defined Under Namespace
Modules: Pure
Constant Summary collapse
- SYSTEM_TAGS =
[ "claude-memory-context", "system-reminder", "local-command-caveat", "command-message", "command-name", "command-args" ].freeze
- USER_TAGS =
["private", "no-memory", "secret"].freeze