SPB Git

Repository Public

README.md 3.4 KB

# Vendored ORIX Astra modules

Everything in this folder except this file and patches/ is a copy of files from ORIX Astra (https://git.spboucher.ai/orix-astra, local checkout ~/Desktop/Cluster/apple/ORIXAstra), the iPhone app by the same author. The copied revision is the commit hash in ASTRA_REVISION.

Here In the ORIX Astra repository
Packages/AstraCore/Sources, Packages/AstraProviders/Sources, Packages/AstraAgents/Sources, Packages/AstraLocal/Sources same paths
Tests/AstraCoreTests, Tests/AstraProvidersTests, Tests/AstraAgentsTests, Tests/AstraLocalTests same paths
Tests/AstraLocalFixtures same path (recorded Hugging Face responses and the build 2 catalogue, read by AstraLocalTests from the source tree)
docs/catalog same path (catalog.json, the model catalogue also served at https://www.orixlab.dev/astra/models/v1/catalog.json, and its baseline)
Packages/AstraUI/Sources/Resources/catalog.json same path: the catalogue file the Astra app bundles, read by one AstraLocalTests test. No other part of AstraUI is vendored.
LICENSE LICENSE

The paths are kept identical on purpose: the vendored tests locate their fixtures relative to their own file (Vendor/ plays the role of the Astra repository root).

# Rules

  1. Never edit a vendored file. ORIX Astra is the reference for provider behaviour. A fix belongs in ORIX Astra, then comes here through a sync.
  2. macOS or ORIX Docs adaptations go in our own targets (Sources/DocAI, Sources/DocLocalModels), which depend on the vendored modules: another Keychain service, another storage folder, an editor-aware memory policy, a router.
  3. If a vendored file genuinely cannot compile or behave correctly on macOS, the smallest possible change is recorded as patches/NNNN-what-and-why.patch (a diff -u with paths relative to this folder, -p1). Scripts/sync-astra.sh applies the patches after every copy and refuses to continue when one no longer applies. A silent edit is a defect. There is no patch at the moment: see docs/v2/AI_PROVIDERS.md for the test results of the unchanged modules on macOS.
  4. Sources/DocLocalModels/Resources/catalog.json is a byte-for-byte copy of docs/catalog/catalog.json, refreshed by the sync script and checked by a unit test.

# Refreshing

sh
Scripts/sync-astra.sh                      # ../ORIXAstra at its HEAD
Scripts/sync-astra.sh <checkout> <rev>     # any committed revision
Scripts/sync-astra.sh --check              # verify that Vendor/ is exactly ASTRA_REVISION + patches; writes nothing

The script reads the checkout with git archive (committed content only; work in progress there never leaks in, and the checkout is not modified), rewrites ASTRA_REVISION, and prints which files changed. Then run the tests (docs/v2/AI_PROVIDERS.md, section "Tests") and commit.

# Licence

ORIX Astra and ORIX Docs have the same author and rights holder (Simon-Pierre Boucher). LICENSE is ORIX Astra's licence file, copied with the code; it also lists the third-party components the modules link (MLX Swift, MLX Swift LM, swift-transformers, swift-jinja, each under its own licence). The vendored files keep their original ORIX Astra headers.

Files main
Menu

Theme