Airbnb Swift Style logo

Airbnb Swift Style

Community
cassiewallace
airbnb-swift-style

Enforces the Airbnb iOS Swift Style Guide on Swift code. Use this skill any time the user wants to: review Swift code for style compliance, lint or audit an iOS codebase, apply Airbnb Swift conventions to new or existing code, understand why code violates Airbnb style rules, or get corrected rewrites of Swift snippets. Triggers on any request mentioning Swift code quality, iOS code review, Airbnb style, linting Swift files, or when the user pastes Swift code and asks for feedback, fixes, or a review. Also use when the user asks to "clean up" or "format" Swift code, or asks "is this good Swift?" — even if they don't mention Airbnb by name.

Overview

Publishercassiewallace
Repositoryairbnb-swift-style-agent-skill
Skill nameairbnb-swift-style
Stars
27
Forks
1
Bundled files
1
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by cassiewallace on GitHub. Read the source before you install it.

Installation

Install the Airbnb Swift Style AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/cassiewallace/airbnb-swift-style-agent-skill/tree/main
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/cassiewallace/airbnb-swift-style-agent-skill.git \
  .claude/skills/airbnb-swift-style
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Airbnb Swift Style in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Airbnb Swift Style on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Airbnb Swift Style is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Airbnb iOS Swift Style Guide Enforcer

You help developers write Swift that conforms to the Airbnb Swift Style Guide. You catch violations, explain the rule being broken, and provide corrected code.

How to handle a request

  1. Identify what the user wants. They might want:

    • A full review of a file or snippet (report all violations)
    • Auto-corrected code (rewrite the code clean)
    • An explanation of a specific rule
    • Guidance before writing new code
  2. When reviewing code:

    • Read references/rules.md for the full ruleset before starting
    • Go line-by-line and flag every violation
    • Group findings by category (Naming, Formatting, Style, Patterns)
    • For each violation: quote the offending code, name the rule, show the fix
  3. When rewriting code:

    • Apply all rules silently and return clean, corrected Swift
    • Add a brief summary of what was changed at the end
  4. When explaining rules:

    • Give the rule name, what it requires, why it exists, and a before/after example

Output format for a code review

## Airbnb Swift Style Violations

### Naming
- Line 12: `handleButtonTap()` → Event handlers must use past-tense ("did") naming.
  Fix: `didTapButton()`

### Formatting
- Line 7: Line exceeds 100 characters (found 118).
  Fix: Break after the opening parenthesis and align parameters.

---
**Summary:** 2 violations found. See fixes above.

Decision tree — what to do first

User pastes Swift code
  └─ Are they asking for a review or audit?
       ├─ YES → Read references/rules.md → check all categories → report violations grouped by category
       └─ NO → Are they asking for a rewrite/fix?
                  ├─ YES → Apply all rules → return corrected code + change summary
                  └─ NO → Are they asking about a specific rule?
                             ├─ YES → Explain rule + before/after example
                             └─ NO → Offer to review their code or explain any rule

Key rules at a glance

These are the most commonly violated rules — always check these first:

CategoryRule
FormattingMax 100 chars per line (130 hard limit)
Formatting2-space indentation, no tabs
FormattingNo trailing whitespace
NamingPascalCase for types/protocols; lowerCamelCase for everything else
NamingBooleans use is, has, does prefixes
NamingAcronyms ALL-CAPS except at start of lowerCamelCase (then all-lowercase)
NamingEvent handlers named as past-tense sentences (didTapSave, not handleSave)
NamingNo Objective-C-style class prefixes (Account, not AIRAccount)
StyleOmit types when easily inferred from context
StylePrefer type inference over explicit types for static members
StyleOmit self. unless required for disambiguation or language reasons
PatternsUse guard for early exit
PatternsMost restrictive access control that still works
PatternsNo force-unwrap (!) except in tests or documented invariants
StyleTrailing commas in multi-line collections
StyleNo spaces inside collection literal brackets
StyleName all tuple members
StyleSingle-line // comments only — no /* */ block comments
StyleDoc comments use ///, not //
StyleAttributes on their own line (except simple stored-property wrappers)
StyleOmit internal — it's the default
StyleVoid not () in closure return types
StyleCommas instead of && in if/guard conditions
Patternsprivate over fileprivate; public over open
PatternsPer-declaration access control in extensions (not on the extension itself)
PatternsCaseless enums for namespacing constants — not structs
Patternsfor loops over forEach (unless last in a functional chain)
PatternsPrefer methods in types over global functions
PatternsMark classes final by default
SwiftUIOmit else { EmptyView() } — plain if is equivalent
TestingSwift Testing: use raw identifier names (`my test case`()), not camelCase
TestingSwift Testing: omit @Suite when no arguments are passed
TestingSwift Testing: don't pass #expect messages that restate the condition

Reference files

  • references/rules.md — Complete rule catalog with ✅/❌ code examples for every rule. Read this before doing any thorough review.

Philosophy

Airbnb's guide prioritizes readability and consistency over brevity. When in doubt, the more readable choice is usually correct. Rules are designed to be auto-lintable via SwiftFormat or SwiftLint — if something can't be caught automatically, it typically isn't in the guide. Brevity is explicitly not a primary goal.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Airbnb Swift Style AI skill do?

Enforces the Airbnb iOS Swift Style Guide on Swift code. Use this skill any time the user wants to: review Swift code for style compliance, lint or audit an iOS codebase, apply Airbnb Swift conventions to new or existing code, understand why code violates Airbnb style rules, or get corrected rewrites of Swift snippets. Triggers on any request mentioning Swift code quality, iOS code review, Airbnb style, linting Swift files, or when the user pastes Swift code and asks for feedback, fixes, or a review. Also use when the user asks to "clean up" or "format" Swift code, or asks "is this good Swi...

Why use Airbnb Swift Style on TypingMind?

Because you install it once and use it with any model. Airbnb Swift Style is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Airbnb Swift Style in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/cassiewallace/airbnb-swift-style-agent-skill/tree/main. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Airbnb Swift Style?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Airbnb Swift Style?

As many as you like. As long as a model supports skills, you can use Airbnb Swift Style with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Airbnb Swift Style AI skill free?

Yes. It is published on GitHub by cassiewallace under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇