Sorcerer
An open-source macOS multi-agent social simulator built with SwiftUI. It drives AI characters to conduct community discussions and evolve their positions by invoking locally logged-in CLI tools such as Claude Code, Codex and Ollama.
Timeline (last 90 days)
Sorcerer is a macOS app written purely in SwiftUI and open-sourced under the MIT license.
Sorcerer does not bundle any model and does not require users to enter an API key; instead, it calls command-line tools already installed and logged in on the user's computer, such as claude (Claude Code), codex (ChatGPT), or a local Ollama.
Sorcerer obtains and caches the user's PATH by launching an interactive login shell (zsh -ilc), with a 5-second timeout to prevent the shell from hanging.
The Claude backend runs with no tools, no session persistence, and no user configuration, and uses the stream-json output format, which carries the subscription's 5-hour and weekly usage windows.
The Codex backend is invoked via the command `codex exec --ephemeral -s read-only`.
The Ollama backend is invoked by sending streaming POST requests to localhost:11434.
A character in Sorcerer is represented by the Codable struct Persona, containing fields such as handle, role, bio, traits, interests, goals, mood, memories, ties, and an insider flag.
The apply function in Engine.swift is a pure function that validates the JSON returned by the model, discards unknown authors, clamps emotion values, restricts actions to an allowed list, and limits invitations to at most one per round.
Sorcerer supports generating a brief by pointing to a GitHub repository, folder, website, or file through the user's own gh login, in which each fact is marked as public, insider, or hidden.
When reading source files, only documents are read; .env and secret files are never opened, and the characters see the brief rather than the user's code.
4 more timeline events
All Facts (14)
Sorcerer is a macOS app written purely in SwiftUI and open-sourced under the MIT license.
50%UnverifiedSorcerer does not bundle any model and does not require users to enter an API key; instead, it calls command-line tools already installed and logged in on the user's computer, such as claude (Claude Code), codex (ChatGPT), or a local Ollama.
50%UnverifiedSorcerer obtains and caches the user's PATH by launching an interactive login shell (zsh -ilc), with a 5-second timeout to prevent the shell from hanging.
50%UnverifiedThe Claude backend runs with no tools, no session persistence, and no user configuration, and uses the stream-json output format, which carries the subscription's 5-hour and weekly usage windows.
50%UnverifiedThe Codex backend is invoked via the command `codex exec --ephemeral -s read-only`.
50%UnverifiedThe Ollama backend is invoked by sending streaming POST requests to localhost:11434.
50%UnverifiedA character in Sorcerer is represented by the Codable struct Persona, containing fields such as handle, role, bio, traits, interests, goals, mood, memories, ties, and an insider flag.
50%UnverifiedThe apply function in Engine.swift is a pure function that validates the JSON returned by the model, discards unknown authors, clamps emotion values, restricts actions to an allowed list, and limits invitations to at most one per round.
50%UnverifiedSorcerer supports generating a brief by pointing to a GitHub repository, folder, website, or file through the user's own gh login, in which each fact is marked as public, insider, or hidden.
50%UnverifiedWhen reading source files, only documents are read; .env and secret files are never opened, and the characters see the brief rather than the user's code.
50%UnverifiedSorcerer's partialRound function performs incremental parsing during JSON streaming, locating the posts field, tracking brace depth and string escapes, decoding closed post objects, and extracting the author and partial text from the currently unclosed object.
50%UnverifiedSorcerer's fork() method copies the current branch and assigns a new letter name and lineage marker; the rewind() method can return to a past round's fork, filtering posts, events, actions, and votes, removing characters who joined later, removing subsequent memories, and rebuilding emotions from the posts.
50%UnverifiedSorcerer's reporting system distinguishes model judgments from world counts: vote results come from true answers, action statistics count only each person's latest action, and an escalation followed by a cancellation counts only as one cancellation.
50%UnverifiedThe Sorcerer app has zero third-party dependencies on the app side, uses Swift Package, and can be run via swift run and tested via swift test; the landing page uses a Bun + Turbo monorepo (React, TanStack Router, Tailwind, Hono, tRPC) and is deployed on Cloudflare Pages.
50%