← 全部工具

apfel

热度 85 更新于 开发与构建

Apple Intelligence from the command-line, with OpenAi-compatible API server

homebrewauto-collected

安装

Homebrew
brew install apfel

通过 Homebrew 安装。

apfel

The free AI already on your Mac.

Apple Silicon Macs ship a built-in LLM via Apple FoundationModels. apfel exposes it as a UNIX tool and a local OpenAI-compatible server. 100% on-device. No API keys, no cloud.

| Mode | Command | What you get | |------|---------|--------------| | UNIX tool | apfel "prompt" / echo "text" \| apfel | Pipe-friendly answers, file attachments, JSON output, exit codes | | OpenAI-compatible server | apfel --serve | Drop-in local http://localhost:11434/v1 backend for OpenAI SDKs |

apfel --chat - interactive REPL.

Tool calling works in all contexts. On-device context window: 4096 tokens on macOS 26, 8192 on macOS 27 - read at runtime, see Limitations.

Requirements & Install

macOS 26 Tahoe+, Apple Silicon (M1+), Apple Intelligence enabled.

brew install apfel

Update:

brew upgrade apfel

Build from source (Command Line Tools with macOS 26.4 SDK / Swift 6.3, no Xcode):

git clone https://github.com/Arthur-Ficial/apfel.git && cd apfel && make install

Nix, same-day tap, Mint, mise, troubleshooting: docs/install.md.

Quick Start

UNIX tool

Quote prompts with ! in single quotes (zsh/bash history expansion): apfel 'Hello, Mac!'.

# Single prompt
apfel "What is the capital of Austria?"

# Permissive mode - reduces guardrail false positives for creative/long prompts
apfel --permissive "Write a dramatic opening for a thriller novel"

# Stream output
apfel --stream "Write a haiku about code"

# Pipe input
echo "Summarize: $(cat README.md)" | apfel