Index of every page on this site: llms.txt
All skills
jeremylongshore avatar

/clade-data-handling

@820dfc8
Run it yourself

Handle sensitive data with Claude — PII redaction, conversation management, Use when working with data-handling patterns. context window optimization, and data retention policies. Trigger with "anthropic data privacy", "claude pii", "anthropic context window", "manage claude conversations", "anthropic data retention".

Use this Skill: https://skilld.dev/gh/jeremylongshore/tons-of-skills-marketplace/clade-data-handling

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesone-pager.md

≈527 tokens on demand. Your agent reads this file only when SKILL.md points to it.

clade-data-handling — One-Pager

Manage the 200K context window, redact PII, and handle data retention for Claude integrations.

The Problem

Claude's 200K token context window is generous but not infinite. Long conversations overflow it and trigger invalid_request_error. Developers also need to handle sensitive data responsibly — sending raw PII (emails, phone numbers, SSNs, credit cards) to any external API is a compliance risk. And few teams understand Anthropic's default data retention policies or what they are responsible for on their end.

The Solution

This skill provides three production patterns: token counting with countTokens before every request to prevent overflow, a conversation trimming strategy that preserves the first message and recent turns while dropping the middle, and regex-based PII redaction for emails, phone numbers, SSNs, and credit card numbers. It also documents Anthropic's data retention defaults (no training on API data, zero retention on Enterprise).

Who / What / When

Aspect Details
Who Developers building Claude applications that handle user data or long conversations
What Context window management, conversation trimming, PII redaction, and data retention policy guidance
When When your application processes user-generated content, handles multi-turn conversations, or must comply with data privacy requirements

Key Features

  1. Token counting — Use client.messages.countTokens() to measure input before sending, calculate available budget as 200K - max_tokens
  2. Conversation trimming — Keep the first message (key context) and the last 3 turns, drop the middle to fit within budget
  3. PII redaction — Regex patterns to strip emails, phone numbers, SSNs, and credit card numbers before sending to the API
  4. Data retention awareness — Anthropic does not train on API data by default; zero retention available on Enterprise plans; your responsibility to manage stored responses

Quick Start

See SKILL.md for full instructions.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    The skill provides instructional documentation and code patterns for managing data privacy and context windows when using Claude integrations. It focuses on PII redaction and conversation optimization.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 820dfc8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 2 months ago
What it can do
Reads files Edits files
version
1.1.0
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
[
  "saas",
  "anthropic",
  "claude",
  "data",
  "privacy",
  "context"
]
All 3 allowed tools
ReadWriteEdit
Other metadata
compatibility
Designed for Claude Code

README badge

README badge for jeremylongshore/tons-of-skills-marketplace/clade-data-handling