Skills
Skill files for specialized workflows: legal, finance
Claude Code skills are YAML-based files that embed domain knowledge, terminology, and formatting conventions to tailor Claude's behavior for specialized workflows like legal discovery, financial modeling, or academic research. They trade narrow focus for precision but require maintenance as domains evolve.
Claude Code skills are YAML-based files that embed domain knowledge, terminology rules, and output conventions to tailor Claude’s behavior for specialized tasks. Rather than relying on general-purpose instruction in each prompt, a legal team can store a skill file that encodes litigation vocabulary, citation conventions, and privilege-logging templates; a research group can version a skill that enforces academic citation standards and LaTeX formatting; a financial services team can standardize model risk assessment templates and regulatory citation formats. This post surveys what such skills typically contain, how they are structured, and the practical trade-offs of vertical specialization versus general-purpose tooling.
What a skill file packages
A Claude Code skill for a specialized domain typically consists of four elements: domain vocabulary, rule sets, output templates, and metadata. The metadata layer includes fields like name, description, version, and triggers that tell Claude Code when and how to activate the skill. The vocabulary section defines jargon specific to the domain (legal: “chain of custody,” “work product doctrine”; finance: “value-at-risk,” “liquidity premium”; research: “pre-registration,” “replication study”) and clarifies abbreviations or acronyms that may be ambiguous outside the field. The rule sets encode operational constraints, such as citation formats, document classification hierarchies, or data handling conventions. Templates provide starting structures for common outputs: a litigation hold notice, a financial risk summary, a research methodology appendix.
A minimal legal discovery skill might look like this:
name: Legal Discovery Assistant
description: >
Handles document review, privilege identification, and
litigation hold notices with Bluebook citation and
privilege log formatting.
version: "1.2.0"
triggers:
- keywords: ["discovery", "privilege", "litigation hold"]
- context_type: "legal_document"
vocabulary:
terms:
- term: work_product_doctrine
definition: >
Materials prepared in anticipation of litigation by or
at the direction of counsel
abbrev: WPD
- term: attorney_client_privilege
definition: >
Communications between attorney and client for purpose
of obtaining legal advice
abbrev: ACP
citation_format: bluebook
output_templates:
privilege_log:
- field: document_id
- field: date_range
- field: privilege_type
options: [ACP, WPD, joint_defense]
- field: brief_description
- field: withheld_pages
format: "pp. 3-5, 12"
rules:
- redact_unrelated_content: true
- require_chain_of_custody: true
- validate_bluebook_format: true
A finance-focused skill would substitute citation_format: regulatory (referencing SEC rules, Basel III, Dodd-Frank sections), define vocabulary around liquidity, counterparty risk, and stress-test scenarios, and provide templates for risk reports and model validation sign-offs. A research skill would specify citation format as bibtex or apa, define controlled vocabularies for methodology (randomized controlled trial, observational study, meta-analysis), and provide templates for methods sections, conflict-of-interest disclosures, and data availability statements.
Domain specialization and consistency
The primary advantage of vertical skills is consistency. A legal team using a shared discovery skill ensures that every document review follows the same privilege identification rules, every privilege log uses the same field order and formatting, and every citation conforms to the same style. This is particularly valuable in regulated domains where compliance audits verify that processes are documented and repeatable. A finance team using a standardized risk assessment skill ensures that value-at-risk calculations are consistent across models, that regulatory citations point to the correct statute sections, and that sign-off procedures are encoded and auditable.
Vertical skills also reduce cognitive load. A researcher using a methodology skill does not need to recall whether the team’s convention is “sample size (n)” or “N=” or “N = ”; the skill encodes it. A lawyer using a litigation hold skill does not need to debate whether a particular email chain is privileged; the skill provides a decision tree based on domain rules and past practice. This consistency is especially valuable in knowledge-intensive domains where error rates are high and correction is expensive.
Storage and activation
Skills are stored in project-local or user-local directories. The standard user-local path is ~/.claude/skills/ (Unix-like systems) or .claude/skills/ (project-relative). A project may also define skills in a dedicated directory and reference them in a .claude/config.yaml or similar project manifest. Claude Code activation happens via:
- Explicit skill loading in the UI or API (e.g., “Activate legal-discovery skill”)
- Context-based triggers embedded in the skill’s
triggerssection (keyword matching, document type detection) - Project-scoped auto-activation if a
.claude/config.yamlspecifies default skills
Once activated, the skill’s vocabulary, rules, and templates are available in Claude’s context window for the session. Deactivation is explicit or implicit (closing the session or switching projects).
Skills vs alternatives: a comparison
| Dimension | Vertical Skill | System Prompt + General Model | Fine-Tuned Model | External Tool Chain |
|---|---|---|---|---|
| Setup time | Hours (define vocabulary, rules, templates) | Minutes (write prompt) | Days to weeks (data collection, training) | Days to weeks (API integration) |
| Consistency | High (rules are versioned and auditable) | Medium (depends on prompt quality, drift over time) | High (learned distribution) | Varies (tool-dependent) |
| Flexibility | Low (narrow focus, hard to adapt) | High (can rephrase on the fly) | Low (requires retraining for new tasks) | Medium (tools have fixed APIs) |
| Maintenance | Medium (update vocabulary, rules as domain evolves) | High (every session requires re-prompting) | High (retraining on new data) | High (API changes, deprecations) |
| Transparency | High (YAML rules are human-readable) | Medium (prompt logic is implicit) | Low (learned weights are opaque) | Varies (tool documentation) |
| Compliance audit trail | Excellent (skill versions in git, rules documented) | Poor (prompts are ephemeral) | Medium (training data is static) | Good (tool logs, but external dependency) |
The comparison reveals a central trade-off: vertical skills excel at consistency, transparency, and auditability but sacrifice flexibility and require careful maintenance. A general-purpose system prompt is fast to iterate but drifts over time and is hard to audit. Fine-tuned models offer learned consistency but are opaque and costly to retrain. External tool chains (regulatory databases, legal research APIs, financial data feeds) provide domain authority but introduce operational complexity and licensing costs.
In practice, many teams use a hybrid: a vertical skill to standardize core workflows and output formats, a general-purpose base model to handle out-of-domain questions flexibly, and lightweight external integrations (APIs, webhooks) to pull in real-time data or validate results.
Practical challenges and limitations
Vertical skills are not panacea. A legal discovery skill is only as good as the privilege rules it encodes; if those rules change (a new court ruling narrows work product protection, for example), the skill must be updated, tested, and re-deployed. A finance skill that encodes Basel III liquidity calculations becomes stale if regulatory bodies update the rules. A research skill that assumes a specific citation format (APA 7th edition) must be revised when APA 8 arrives.
Additionally, narrow skills can become brittle when presented with edge cases or out-of-domain variation. A litigation hold skill trained on email discovery may struggle with encrypted communications, instant messages, or non-English documents. A financial risk skill built for equities may give poor results when applied to derivatives or commodities. Developers and domain experts must anticipate these failure modes and either expand the skill’s scope (at the cost of complexity) or document explicit boundaries.
Skills also require coordination within teams. If multiple lawyers use the legal discovery skill but each interprets the privilege rules differently, consistency is lost. Skills work best when backed by documented domain expertise, clear ownership (who maintains the skill?), and regular audits.
When to build a vertical skill
Build a vertical skill when:
- Your domain has well-defined, stable terminology and rules that change infrequently
- You have multiple team members who must follow the same conventions
- Your domain is regulated and you need auditable, versioned instructions
- Your workflows are repetitive and benefit from templated outputs
- You want to reduce manual prompt engineering and iteration
Do not build a vertical skill if:
- Your domain is novel or rapidly evolving (skill maintenance overhead is high)
- Your workflows are highly variable and require ad hoc creativity
- You have only one user or no consistency requirement
- General-purpose prompting or external tools already solve the problem
Takeaways
Vertical skills are a practical tool for teams that prioritize consistency and compliance over flexibility. A well-designed skill for legal discovery, financial risk assessment, or academic research can reduce error rates, improve auditability, and standardize team output. However, skills trade narrow focus for precision and require ongoing maintenance as domains evolve. For most use cases, a hybrid approach combining a vertical skill for core workflows, a general-purpose model for flexibility, and lightweight external integrations for real-time data offers the best balance. The key is to version skills in git, document ownership and update procedures, and regularly audit them against ground truth to catch rule drift.
Further reading
- Claude Code documentation - Anthropic’s official guide to skill structure and activation
- Anthropic skills repository - Open-source example skills for research, legal, and finance workflows
- Claude Sonnet 4 release notes - Context and capabilities for Claude Code skills in production
- Prompt engineering best practices - Supplementary guidance on structuring domain instructions for consistency
- YAML specification - Reference for skill file syntax and validation
Frequently asked
What exactly is a Claude Code skill file?
A skill file is a YAML document stored in ~/.claude/skills/ or .claude/skills/ that describes domain-specific instructions, vocabulary, citation rules, and output templates. It is loaded by Claude Code when activated and modifies Claude's behavior for a narrowly scoped task without requiring model fine-tuning.
What should a legal discovery skill include?
A legal skill typically packages legal vocabulary (privilege, discovery, chain of custody), citation conventions (case names, statutes, Bluebook format), document classification rules, and output templates for privilege logs or redaction reports. It may also encode workflow conventions like document metadata handling.
How do skill files differ from prompting instructions in a system message?
Skill files are persistent, versioned, and project-scoped; system messages are ephemeral per-conversation. Skills allow teams to share and iterate on domain rules without embedding them in every prompt, reducing redundancy and improving consistency across sessions.
What are the main trade-offs of vertical skills?
Narrow skills excel at consistency, recall of domain rules, and team standardization. Trade-offs include reduced flexibility for out-of-domain questions, higher maintenance overhead as domains evolve, and the risk of over-fitting to a single workflow rather than adapting to variation within a field.
Can multiple skills be active at once?
Claude Code supports skill composition, though interaction complexity grows with each additional skill. Conflicts between overlapping vocabularies or rules require explicit resolution in the skill hierarchy or project configuration. Most teams activate one primary vertical skill per session.