Skip to content

v0.2.0

Latest

Choose a tag to compare

@CreevekCZ CreevekCZ released this 15 Mar 23:39
a9915e1

πŸš€ Release v0.2.0

Release v0.2.0 of afm-cli, a Swift CLI for interacting with macOS Apple Intelligence foundation models.

✨ What's New

Structured JSON Output

  • --schema / --json-schema β€” Request structured output that conforms to a JSON Schema using Apple's DynamicGenerationSchema API
  • Accepts a file path (e.g. schema.json) or an inline JSON string
  • Output is pretty-printed JSON matching the requested shape
  • Supported schema types: string, integer, number, boolean, object, array

Context window overflow handling

  • When using --conversation, if the combined prompt exceeds the 4096-token context limit, the CLI automatically drops the oldest messages, rebuilds the prompt from recent history, and retries. A warning is printed to stderr.

Improvements

  • File input validation β€” Clear limits and validation for --file: max 1 MB, UTF-8, plain text only
  • --pre-prompt β€” Alias for --system-prompt for convenience

πŸ”— Links