@elizaos/app-core 2.0.3-beta.2 → 2.0.3-beta.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/agent-bridge.d.ts +5 -5
- package/api/auth/audit.d.ts +1 -1
- package/api/auth/auth-context.d.ts +1 -1
- package/api/auth/bootstrap-token.d.ts +1 -1
- package/api/auth/sessions.d.ts +1 -1
- package/api/auth-bootstrap-routes.d.ts +1 -1
- package/api/auth-pairing-routes.d.ts +1 -1
- package/api/auth-pairing-routes.d.ts.map +1 -1
- package/api/auth-pairing-routes.js +2 -3
- package/api/auth-session-routes.d.ts +2 -2
- package/api/auth.d.ts +1 -1
- package/api/automations-compat-routes.d.ts +1 -1
- package/api/background-tasks-routes.d.ts +1 -1
- package/api/catalog-routes.d.ts +1 -1
- package/api/cloud-voice-routes.d.ts +1 -1
- package/api/compat-route-shared.d.ts +12 -5
- package/api/compat-route-shared.d.ts.map +1 -1
- package/api/compat-route-shared.js +22 -187
- package/api/database-rows-compat-routes.d.ts +1 -1
- package/api/dev-compat-routes.d.ts +1 -1
- package/api/dev-route-catalog.d.ts.map +1 -1
- package/api/dev-route-catalog.js +20 -0
- package/api/drop-status-compat-route.d.ts +3 -0
- package/api/drop-status-compat-route.d.ts.map +1 -0
- package/api/drop-status-compat-route.js +12 -0
- package/api/first-run-routes.d.ts +1 -1
- package/api/internal-routes.d.ts +1 -1
- package/api/runtime-mode-routes.d.ts +1 -1
- package/api/secrets-manager-routes.d.ts.map +1 -1
- package/api/sensitive-request-routes.d.ts +2 -2
- package/api/server-config-filter.d.ts.map +1 -1
- package/api/server-config-filter.js +0 -1
- package/api/server-first-run-helpers.d.ts.map +1 -1
- package/api/server-first-run-helpers.js +0 -3
- package/api/server.d.ts +8 -8
- package/api/server.d.ts.map +1 -1
- package/api/server.js +13 -59
- package/api/training-benchmarks.d.ts +1 -1
- package/api/training-benchmarks.d.ts.map +1 -1
- package/api/training-benchmarks.js +31 -9
- package/api/workbench-compat-routes.d.ts +1 -1
- package/benchmark/server-utils.d.ts +2 -2
- package/browser.d.ts +4 -4
- package/cli/plugins-cli.d.ts.map +1 -1
- package/cli/plugins-cli.js +5 -0
- package/cli/program/register.auth.d.ts +27 -1
- package/cli/program/register.auth.d.ts.map +1 -1
- package/cli/program/register.auth.js +187 -0
- package/cli/program/register.dashboard.d.ts.map +1 -1
- package/cli/program/register.dashboard.js +11 -1
- package/cli/program.d.ts +1 -1
- package/first-run/first-run-config.d.ts +1 -1
- package/index.d.ts +46 -47
- package/index.d.ts.map +1 -1
- package/index.js +3 -7
- package/package.json +42 -36
- package/packaging/PUBLISHING_GUIDE.md +20 -20
- package/platform/elizaos-agent-browser-stub.d.ts +0 -1
- package/platform/elizaos-agent-browser-stub.d.ts.map +1 -1
- package/platform/elizaos-agent-browser-stub.js +0 -1
- package/platform/ios-runtime-bridge.d.ts.map +1 -1
- package/platform/ios-runtime-bridge.js +0 -1
- package/platform/native-plugin-entrypoints.d.ts +2 -2
- package/platforms/android/app/build.gradle +30 -7
- package/platforms/android/app/src/main/elizavoice-jni/elizavoice-jni.cpp +179 -35
- package/platforms/android/app/src/main/java/ai/elizaos/app/ElizaAgentService.java +60 -32
- package/platforms/android/app/src/main/java/ai/elizaos/app/ElizaBionicInferenceServer.java +405 -65
- package/platforms/android/app/src/main/java/ai/elizaos/app/ElizaVoiceNative.java +35 -0
- package/platforms/android/app/src/main/java/ai/elizaos/app/ElizaVoicePlugin.java +13 -6
- package/platforms/android/app/src/main/res/drawable/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-land-hdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-land-mdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-land-xhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-land-xxhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-land-xxxhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-port-hdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-port-mdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-port-xhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-port-xxhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/drawable-port-xxxhdpi/splash.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-hdpi/ic_launcher.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-hdpi/ic_launcher_monochrome.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-mdpi/ic_launcher.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-mdpi/ic_launcher_monochrome.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xhdpi/ic_launcher_foreground.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xhdpi/ic_launcher_monochrome.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_foreground.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_monochrome.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_foreground.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_monochrome.png +0 -0
- package/platforms/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png +0 -0
- package/platforms/android/app/src/main/res/values/colors.xml +5 -1
- package/platforms/android/app/src/main/res/values/ic_launcher_background.xml +1 -1
- package/platforms/android/app/src/main/res/values/styles.xml +4 -1
- package/platforms/electrobun/electrobun.config.ts +0 -1
- package/platforms/electrobun/native/macos/window-effects.mm +4 -0
- package/platforms/electrobun/package.json +11 -9
- package/platforms/electrobun/remotes/local-model/src/bun/eliza1-catalog.ts +1 -1
- package/platforms/electrobun/remotes/runtime/src/dev/phase2-smoke.ts +10 -5
- package/platforms/electrobun/remotes/runtime/src/dev/phase3-smoke.ts +11 -15
- package/platforms/electrobun/src/application-menu.ts +0 -7
- package/platforms/electrobun/src/desktop-http-request.test.ts +30 -1
- package/platforms/electrobun/src/desktop-http-request.ts +14 -2
- package/platforms/electrobun/src/desktop-test-bridge-server.ts +28 -0
- package/platforms/electrobun/src/fatal-shutdown.test.ts +3 -7
- package/platforms/electrobun/src/index.ts +64 -13
- package/platforms/electrobun/src/lifecycle/api-base-owner.test.ts +83 -0
- package/platforms/electrobun/src/lifecycle/api-base-owner.ts +37 -16
- package/platforms/electrobun/src/native/agent.ts +28 -17
- package/platforms/electrobun/src/native/credentials.ts +6 -1
- package/platforms/electrobun/src/native/desktop-window.test.ts +142 -26
- package/platforms/electrobun/src/native/desktop.ts +8 -4
- package/platforms/electrobun/src/native/index.ts +6 -0
- package/platforms/electrobun/src/native/remote-plugin-host.ts +18 -8
- package/platforms/electrobun/src/preload.js +1 -1
- package/platforms/electrobun/src/voice/voice-live-validation.test.ts +10 -5
- package/platforms/electrobun/src/voice/voice-runtime-adapter.ts +3 -2
- package/platforms/electrobun/src/voice/voice-service.test.ts +26 -0
- package/platforms/electrobun/src/voice/voice-service.ts +57 -17
- package/platforms/electrobun/tsconfig.json +17 -1
- package/platforms/ios/App/App/Base.lproj/LaunchScreen.storyboard +4 -6
- package/registry/index.d.ts +1 -6
- package/registry/index.d.ts.map +1 -1
- package/registry/index.js +9 -101
- package/runtime/android-avf-microdroid-bridge.d.ts +1 -1
- package/runtime/bundled-fused-lib.d.ts +36 -0
- package/runtime/bundled-fused-lib.d.ts.map +1 -0
- package/runtime/bundled-fused-lib.js +77 -0
- package/runtime/channel-plugin-map.d.ts +1 -5
- package/runtime/channel-plugin-map.d.ts.map +1 -1
- package/runtime/channel-plugin-map.js +11 -31
- package/runtime/desktop/index.d.ts +5 -5
- package/runtime/dev-server.js +11 -2
- package/runtime/eliza.d.ts.map +1 -1
- package/runtime/eliza.js +18 -8
- package/runtime/mode/route-mode-guard.d.ts +1 -1
- package/runtime/mode/route-mode-matrix.d.ts +1 -1
- package/runtime/voice-warmup.d.ts +4 -19
- package/runtime/voice-warmup.d.ts.map +1 -1
- package/runtime/voice-warmup.js +4 -14
- package/scripts/aosp/README.md +10 -1
- package/scripts/aosp/compile-libllama-paths.mjs +110 -0
- package/scripts/aosp/compile-libllama-zig-pin.test.mjs +147 -0
- package/scripts/aosp/compile-libllama.mjs +377 -81
- package/scripts/aosp/compile-libllama.test.mjs +133 -0
- package/scripts/aosp/compile-shim.mjs +21 -1
- package/scripts/aosp/deploy-pixel.mjs +1 -1
- package/scripts/aosp/stage-default-models.mjs +24 -31
- package/scripts/aosp/stage-default-models.test.mjs +23 -0
- package/scripts/assert-required-bundled-packages.test.ts +22 -1
- package/scripts/build-helpers/verify-fused-symbols.mjs +33 -0
- package/scripts/build-helpers/verify-fused-symbols.test.mjs +0 -0
- package/scripts/build-image.sh +1 -3
- package/scripts/build-llama-cpp-mtp.mjs +17 -16
- package/scripts/check-i18n.mjs +0 -1
- package/scripts/copy-runtime-node-modules.ts +147 -0
- package/scripts/desktop-build.mjs +317 -4
- package/scripts/docker-ci-smoke.sh +33 -8
- package/scripts/ensure-type-package-aliases.mjs +1 -1
- package/scripts/ios-xcframework/run-physical-device-smoke.mjs +1 -1
- package/scripts/lib/agent-source-watcher.mjs +0 -1
- package/scripts/lib/artifact-staleness.d.mts +33 -0
- package/scripts/lib/artifact-staleness.mjs +122 -0
- package/scripts/lib/artifact-staleness.test.mts +98 -0
- package/scripts/lib/duet-bridge.mjs +1 -1
- package/scripts/lib/ios-plist-url-scheme.mjs +80 -0
- package/scripts/lib/mobile-build-decisions.mjs +97 -0
- package/scripts/lib/renderer-build-manifest.d.mts +65 -0
- package/scripts/lib/renderer-build-manifest.mjs +257 -0
- package/scripts/lib/renderer-build-manifest.test.mts +277 -0
- package/scripts/lib/stage-android-agent.mjs +13 -4
- package/scripts/lib/verify-ondevice-artifact.d.mts +16 -0
- package/scripts/lib/verify-ondevice-artifact.mjs +61 -0
- package/scripts/lib/verify-ondevice-artifact.test.mts +98 -0
- package/scripts/lib/websocket-pending-queue.ts +92 -0
- package/scripts/link-docker-local-app-packages.mjs +6 -0
- package/scripts/playwright-ui-live-stack.ts +430 -144
- package/scripts/playwright-ui-smoke-api-stub.mjs +160 -168
- package/scripts/run-local-plugin-live-smoke.mjs +1 -6
- package/scripts/run-mobile-build-brand-separation.test.mts +33 -0
- package/scripts/run-mobile-build-ios-engine-gate.test.mjs +85 -0
- package/scripts/run-mobile-build-mtp-staleness.test.mts +198 -0
- package/scripts/run-mobile-build.mjs +408 -86
- package/scripts/serve-real-local-agent.ts +72 -0
- package/scripts/stage-desktop-fused-lib.mjs +43 -14
- package/scripts/verify-ondevice-artifact.mjs +111 -0
- package/scripts/voice-attribution-smoke.ts +144 -38
- package/scripts/voice-duet.mjs +6 -6
- package/scripts/voice-e2e-hardware.ts +22 -16
- package/scripts/voice-interactive.mjs +16 -45
- package/security/agent-vault-id.d.ts +1 -1
- package/security/platform-secure-store-node.d.ts +1 -1
- package/services/ambient-audio/consent.d.ts +1 -1
- package/services/ambient-audio/index.d.ts +6 -6
- package/services/ambient-audio/replay-buffer.d.ts +1 -1
- package/services/ambient-audio/response-gate.d.ts +1 -1
- package/services/ambient-audio/service.d.ts +3 -3
- package/services/connector-target-catalog.d.ts +1 -1
- package/services/sensitive-requests/index.d.ts +6 -6
- package/services/steward-sidecar/wallet-setup.d.ts +1 -1
- package/services/steward-sidecar.d.ts +3 -3
- package/services/tunnel-to-mobile/index.d.ts +1 -1
- package/services/vault-bootstrap.d.ts.map +1 -1
- package/services/vault-bootstrap.js +14 -10
- package/services/voice-profiles/diarization-pipeline.d.ts +1 -1
- package/services/voice-profiles/index.d.ts +11 -11
- package/services/voice-profiles/owner-confidence.d.ts +1 -1
- package/services/voice-profiles/private-challenge.d.ts +1 -1
- package/services/voice-profiles/store.d.ts +1 -1
- package/test/helpers/live-provider.test.ts +91 -1
- package/test/helpers/live-provider.ts +195 -51
- package/test/scripts/websocket-pending-queue.test.ts +119 -0
- package/test-support/test-helpers.d.ts +0 -33
- package/test-support/test-helpers.d.ts.map +1 -1
- package/test-support/test-helpers.js +81 -189
- package/ui-compat.d.ts +1 -0
- package/ui-compat.d.ts.map +1 -1
- package/ui-compat.js +4 -0
- package/platforms/electrobun/docs/convergence-audit.json +0 -3505
- package/platforms/electrobun/docs/convergence-audit.md +0 -694
- package/platforms/electrobun/scripts/ensure-whisper-gguf.sh +0 -55
- package/platforms/electrobun/scripts/ensure-whisper-model.sh +0 -35
- package/platforms/electrobun/scripts/generate-convergence-audit.ts +0 -1203
- package/platforms/electrobun/src/native/whisper-env.test.ts +0 -71
- package/platforms/electrobun/src/native/whisper-env.ts +0 -68
- package/registry/app-registry.d.ts +0 -14
- package/registry/app-registry.d.ts.map +0 -1
- package/registry/app-registry.js +0 -29
- package/registry/entries/apps/app-polymarket.json +0 -31
- package/registry/entries/apps/clawville.json +0 -27
- package/registry/entries/apps/companion.json +0 -28
- package/registry/entries/apps/database-viewer.json +0 -27
- package/registry/entries/apps/defense-of-the-agents.json +0 -27
- package/registry/entries/apps/documents.json +0 -30
- package/registry/entries/apps/feed.json +0 -27
- package/registry/entries/apps/hyperliquid.json +0 -31
- package/registry/entries/apps/log-viewer.json +0 -27
- package/registry/entries/apps/memory-viewer.json +0 -27
- package/registry/entries/apps/model-tester.json +0 -31
- package/registry/entries/apps/plugin-viewer.json +0 -27
- package/registry/entries/apps/relationship-viewer.json +0 -27
- package/registry/entries/apps/runtime-debugger.json +0 -27
- package/registry/entries/apps/shopify.json +0 -31
- package/registry/entries/apps/skills-viewer.json +0 -27
- package/registry/entries/apps/steward.json +0 -31
- package/registry/entries/apps/training.json +0 -54
- package/registry/entries/apps/trajectory-viewer.json +0 -27
- package/registry/entries/apps/vincent.json +0 -31
- package/registry/entries/connectors/bluebubbles.json +0 -99
- package/registry/entries/connectors/bluesky.json +0 -173
- package/registry/entries/connectors/discord.json +0 -119
- package/registry/entries/connectors/farcaster.json +0 -174
- package/registry/entries/connectors/feishu.json +0 -79
- package/registry/entries/connectors/google-chat.json +0 -120
- package/registry/entries/connectors/google.json +0 -82
- package/registry/entries/connectors/imessage.json +0 -96
- package/registry/entries/connectors/instagram.json +0 -64
- package/registry/entries/connectors/line.json +0 -86
- package/registry/entries/connectors/matrix.json +0 -94
- package/registry/entries/connectors/mattermost.json +0 -110
- package/registry/entries/connectors/msteams.json +0 -104
- package/registry/entries/connectors/nextcloud-talk.json +0 -104
- package/registry/entries/connectors/nostr.json +0 -70
- package/registry/entries/connectors/signal.json +0 -81
- package/registry/entries/connectors/slack.json +0 -102
- package/registry/entries/connectors/telegram.json +0 -71
- package/registry/entries/connectors/tlon.json +0 -94
- package/registry/entries/connectors/twitch.json +0 -110
- package/registry/entries/connectors/whatsapp.json +0 -113
- package/registry/entries/connectors/x.json +0 -231
- package/registry/entries/connectors/zalo.json +0 -112
- package/registry/entries/connectors/zalouser.json +0 -122
- package/registry/entries/plugins/agent-orchestrator.json +0 -33
- package/registry/entries/plugins/agent-skills.json +0 -72
- package/registry/entries/plugins/anthropic.json +0 -73
- package/registry/entries/plugins/app-control.json +0 -23
- package/registry/entries/plugins/auto-trader.json +0 -203
- package/registry/entries/plugins/background-runner.json +0 -26
- package/registry/entries/plugins/blooio.json +0 -102
- package/registry/entries/plugins/browser.json +0 -75
- package/registry/entries/plugins/cli.json +0 -40
- package/registry/entries/plugins/clipboard.json +0 -44
- package/registry/entries/plugins/coding-tools.json +0 -71
- package/registry/entries/plugins/commands.json +0 -63
- package/registry/entries/plugins/computeruse.json +0 -74
- package/registry/entries/plugins/copilot-proxy.json +0 -93
- package/registry/entries/plugins/directives.json +0 -63
- package/registry/entries/plugins/edge-tts.json +0 -97
- package/registry/entries/plugins/elevenlabs.json +0 -169
- package/registry/entries/plugins/elizacloud.json +0 -208
- package/registry/entries/plugins/evm.json +0 -134
- package/registry/entries/plugins/experience.json +0 -34
- package/registry/entries/plugins/facewear.json +0 -131
- package/registry/entries/plugins/form.json +0 -26
- package/registry/entries/plugins/github.json +0 -93
- package/registry/entries/plugins/gmail-watch.json +0 -25
- package/registry/entries/plugins/goals.json +0 -77
- package/registry/entries/plugins/google-genai.json +0 -106
- package/registry/entries/plugins/groq.json +0 -93
- package/registry/entries/plugins/hedera.json +0 -48
- package/registry/entries/plugins/inmemorydb.json +0 -25
- package/registry/entries/plugins/linear.json +0 -51
- package/registry/entries/plugins/local-inference.json +0 -137
- package/registry/entries/plugins/local-storage.json +0 -36
- package/registry/entries/plugins/localdb.json +0 -25
- package/registry/entries/plugins/mcp.json +0 -44
- package/registry/entries/plugins/memory.json +0 -124
- package/registry/entries/plugins/minecraft.json +0 -79
- package/registry/entries/plugins/moltbook.json +0 -83
- package/registry/entries/plugins/music.json +0 -155
- package/registry/entries/plugins/mysticism.json +0 -48
- package/registry/entries/plugins/nearai.json +0 -82
- package/registry/entries/plugins/ngrok.json +0 -69
- package/registry/entries/plugins/ollama.json +0 -96
- package/registry/entries/plugins/openai.json +0 -189
- package/registry/entries/plugins/openrouter.json +0 -188
- package/registry/entries/plugins/pdf.json +0 -26
- package/registry/entries/plugins/plugin-manager.json +0 -23
- package/registry/entries/plugins/prose.json +0 -48
- package/registry/entries/plugins/rlm.json +0 -26
- package/registry/entries/plugins/roblox.json +0 -88
- package/registry/entries/plugins/rss.json +0 -64
- package/registry/entries/plugins/s3-storage.json +0 -91
- package/registry/entries/plugins/scheduling.json +0 -35
- package/registry/entries/plugins/shell.json +0 -94
- package/registry/entries/plugins/social-alpha.json +0 -72
- package/registry/entries/plugins/tailscale.json +0 -81
- package/registry/entries/plugins/tee.json +0 -53
- package/registry/entries/plugins/todos.json +0 -26
- package/registry/entries/plugins/trajectory-logger.json +0 -33
- package/registry/entries/plugins/trust.json +0 -39
- package/registry/entries/plugins/tts.json +0 -71
- package/registry/entries/plugins/tunnel.json +0 -45
- package/registry/entries/plugins/twilio.json +0 -168
- package/registry/entries/plugins/vercel-ai-gateway.json +0 -128
- package/registry/entries/plugins/video.json +0 -23
- package/registry/entries/plugins/vision.json +0 -43
- package/registry/entries/plugins/webhooks.json +0 -23
- package/registry/entries/plugins/workflow.json +0 -25
- package/registry/entries/plugins/xai.json +0 -75
- package/registry/loader.d.ts +0 -28
- package/registry/loader.d.ts.map +0 -1
- package/registry/loader.js +0 -158
- package/registry/schema.d.ts +0 -1199
- package/registry/schema.d.ts.map +0 -1
- package/registry/schema.js +0 -300
- package/scripts/patches/llama-mobile-kokoro-tts.patch +0 -480
- package/scripts/release-workflow-drift.test.ts +0 -57
- package/test/helpers/i18n.ts +0 -5
- package/test/helpers/loopback.ts +0 -33
- package/test/helpers/react-test.ts +0 -40
- package/test/helpers/skip-without.ts +0 -53
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import fs from "node:fs";
|
|
2
|
+
import os from "node:os";
|
|
3
|
+
import path from "node:path";
|
|
4
|
+
import { afterEach, describe, expect, test } from "vitest";
|
|
5
|
+
import {
|
|
6
|
+
resolveAndroidNdkHostDir,
|
|
7
|
+
resolveDefaultAndroidAssetsDir,
|
|
8
|
+
resolveHomebrewFormulaIncludeDirs,
|
|
9
|
+
} from "./compile-libllama-paths.mjs";
|
|
10
|
+
|
|
11
|
+
const tmpDirs = [];
|
|
12
|
+
|
|
13
|
+
function makeTmpDir() {
|
|
14
|
+
const dir = fs.mkdtempSync(path.join(os.tmpdir(), "compile-libllama-test-"));
|
|
15
|
+
tmpDirs.push(dir);
|
|
16
|
+
return dir;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
afterEach(() => {
|
|
20
|
+
while (tmpDirs.length > 0) {
|
|
21
|
+
fs.rmSync(tmpDirs.pop(), { recursive: true, force: true });
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
describe("compile-libllama Android Vulkan host resolution", () => {
|
|
26
|
+
test("uses the current OS host prebuilt instead of hardcoded linux", () => {
|
|
27
|
+
const prebuiltRoot = makeTmpDir();
|
|
28
|
+
fs.mkdirSync(path.join(prebuiltRoot, "darwin-x86_64"));
|
|
29
|
+
fs.mkdirSync(path.join(prebuiltRoot, "linux-x86_64"));
|
|
30
|
+
|
|
31
|
+
expect(
|
|
32
|
+
resolveAndroidNdkHostDir(prebuiltRoot, {
|
|
33
|
+
platform: "darwin",
|
|
34
|
+
arch: "arm64",
|
|
35
|
+
}),
|
|
36
|
+
).toBe("darwin-x86_64");
|
|
37
|
+
});
|
|
38
|
+
|
|
39
|
+
test("does not select a prebuilt for the wrong host OS", () => {
|
|
40
|
+
const prebuiltRoot = makeTmpDir();
|
|
41
|
+
fs.mkdirSync(path.join(prebuiltRoot, "linux-x86_64"));
|
|
42
|
+
|
|
43
|
+
expect(
|
|
44
|
+
resolveAndroidNdkHostDir(prebuiltRoot, {
|
|
45
|
+
platform: "darwin",
|
|
46
|
+
arch: "arm64",
|
|
47
|
+
}),
|
|
48
|
+
).toBeNull();
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
test("expands Homebrew opt and versioned Cellar include roots", () => {
|
|
52
|
+
const prefix = makeTmpDir();
|
|
53
|
+
fs.mkdirSync(path.join(prefix, "Cellar", "vulkan-headers", "1.3.290"), {
|
|
54
|
+
recursive: true,
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
expect(
|
|
58
|
+
resolveHomebrewFormulaIncludeDirs("vulkan-headers", [prefix]),
|
|
59
|
+
).toEqual([
|
|
60
|
+
path.join(prefix, "opt", "vulkan-headers", "include"),
|
|
61
|
+
path.join(prefix, "Cellar", "vulkan-headers", "1.3.290", "include"),
|
|
62
|
+
]);
|
|
63
|
+
});
|
|
64
|
+
});
|
|
65
|
+
|
|
66
|
+
describe("compile-libllama Android assets dir resolution", () => {
|
|
67
|
+
test("prefers the flat elizaOS packages/app shell when present", () => {
|
|
68
|
+
const root = makeTmpDir();
|
|
69
|
+
fs.mkdirSync(path.join(root, "packages", "app", "android"), {
|
|
70
|
+
recursive: true,
|
|
71
|
+
});
|
|
72
|
+
fs.mkdirSync(path.join(root, "apps", "app", "android"), {
|
|
73
|
+
recursive: true,
|
|
74
|
+
});
|
|
75
|
+
|
|
76
|
+
expect(resolveDefaultAndroidAssetsDir({ root })).toBe(
|
|
77
|
+
path.join(
|
|
78
|
+
root,
|
|
79
|
+
"packages",
|
|
80
|
+
"app",
|
|
81
|
+
"android",
|
|
82
|
+
"app",
|
|
83
|
+
"src",
|
|
84
|
+
"main",
|
|
85
|
+
"assets",
|
|
86
|
+
"agent",
|
|
87
|
+
),
|
|
88
|
+
);
|
|
89
|
+
});
|
|
90
|
+
|
|
91
|
+
test("uses host apps/app shell when packages/app is absent", () => {
|
|
92
|
+
const root = makeTmpDir();
|
|
93
|
+
fs.mkdirSync(path.join(root, "apps", "app", "android"), {
|
|
94
|
+
recursive: true,
|
|
95
|
+
});
|
|
96
|
+
|
|
97
|
+
expect(resolveDefaultAndroidAssetsDir({ root })).toBe(
|
|
98
|
+
path.join(
|
|
99
|
+
root,
|
|
100
|
+
"apps",
|
|
101
|
+
"app",
|
|
102
|
+
"android",
|
|
103
|
+
"app",
|
|
104
|
+
"src",
|
|
105
|
+
"main",
|
|
106
|
+
"assets",
|
|
107
|
+
"agent",
|
|
108
|
+
),
|
|
109
|
+
);
|
|
110
|
+
});
|
|
111
|
+
|
|
112
|
+
test("falls back to nested eliza/packages/app shell", () => {
|
|
113
|
+
const root = makeTmpDir();
|
|
114
|
+
fs.mkdirSync(path.join(root, "eliza", "packages", "app", "android"), {
|
|
115
|
+
recursive: true,
|
|
116
|
+
});
|
|
117
|
+
|
|
118
|
+
expect(resolveDefaultAndroidAssetsDir({ root })).toBe(
|
|
119
|
+
path.join(
|
|
120
|
+
root,
|
|
121
|
+
"eliza",
|
|
122
|
+
"packages",
|
|
123
|
+
"app",
|
|
124
|
+
"android",
|
|
125
|
+
"app",
|
|
126
|
+
"src",
|
|
127
|
+
"main",
|
|
128
|
+
"assets",
|
|
129
|
+
"agent",
|
|
130
|
+
),
|
|
131
|
+
);
|
|
132
|
+
});
|
|
133
|
+
});
|
|
@@ -62,7 +62,11 @@ import os from "node:os";
|
|
|
62
62
|
import path from "node:path";
|
|
63
63
|
import process from "node:process";
|
|
64
64
|
import { fileURLToPath } from "node:url";
|
|
65
|
-
import {
|
|
65
|
+
import {
|
|
66
|
+
assertZigPinForTargets,
|
|
67
|
+
ensureZigDrivers,
|
|
68
|
+
probeZig,
|
|
69
|
+
} from "./compile-libllama.mjs";
|
|
66
70
|
|
|
67
71
|
const here = path.dirname(fileURLToPath(import.meta.url));
|
|
68
72
|
|
|
@@ -329,6 +333,22 @@ export async function main(argv = process.argv.slice(2)) {
|
|
|
329
333
|
const args = parseArgs(argv);
|
|
330
334
|
const zigVersion = probeZig();
|
|
331
335
|
console.log(`[compile-shim] Found zig ${zigVersion}`);
|
|
336
|
+
// Same aarch64/x86_64 `*-linux-musl` lld link as compile-libllama — pin the
|
|
337
|
+
// zig 0.13.x series so a 0.16 toolchain's lld doesn't SIGSEGV the link.
|
|
338
|
+
assertZigPinForTargets({
|
|
339
|
+
version: zigVersion,
|
|
340
|
+
zigTriples: args.abis.map((abi) => {
|
|
341
|
+
const target = SHIM_ABI_TARGETS.find((t) => t.androidAbi === abi);
|
|
342
|
+
if (!target) {
|
|
343
|
+
throw new Error(
|
|
344
|
+
`[compile-shim] unknown ABI ${abi}; expected one of ${SHIM_ABI_TARGETS.map(
|
|
345
|
+
(t) => t.androidAbi,
|
|
346
|
+
).join(", ")}.`,
|
|
347
|
+
);
|
|
348
|
+
}
|
|
349
|
+
return target.zigTarget;
|
|
350
|
+
}),
|
|
351
|
+
});
|
|
332
352
|
|
|
333
353
|
for (const abi of args.abis) {
|
|
334
354
|
if (args.skipIfPresent) {
|
|
@@ -326,7 +326,7 @@ async function main(argv = process.argv.slice(2)) {
|
|
|
326
326
|
if (args.voice) {
|
|
327
327
|
console.log(
|
|
328
328
|
"[deploy-pixel] (dry-run) would run the on-device voice round-trip check " +
|
|
329
|
-
"(mic→VAD→
|
|
329
|
+
"(mic→VAD→local ASR→MTP text→OmniVoice TTS) via the local-inference voice endpoint, " +
|
|
330
330
|
"reporting TTFT-from-utterance-end.",
|
|
331
331
|
);
|
|
332
332
|
}
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
// once at APK build time, then every install is offline-capable.
|
|
13
13
|
//
|
|
14
14
|
// Output (per ABI is unnecessary — GGUF files are arch-independent):
|
|
15
|
-
//
|
|
16
|
-
//
|
|
15
|
+
// packages/app-core/platforms/android/app/src/main/assets/agent/models/<file>.gguf
|
|
16
|
+
// packages/app-core/platforms/android/app/src/main/assets/agent/models/manifest.json
|
|
17
17
|
//
|
|
18
18
|
// On-device: ElizaAgentService (or any white-label fork's equivalent)
|
|
19
19
|
// extracts assets/agent/models/* into the per-user state dir's
|
|
@@ -25,9 +25,9 @@
|
|
|
25
25
|
//
|
|
26
26
|
// APK size impact (Q4_K_M quants):
|
|
27
27
|
// eliza-1-2B ~1.2 GB
|
|
28
|
-
//
|
|
28
|
+
// kokoro voice + preset ~0.2 GB
|
|
29
29
|
// --------------------------------------
|
|
30
|
-
// total ~1.
|
|
30
|
+
// total ~1.4 GB
|
|
31
31
|
//
|
|
32
32
|
// Opt out for builders who want to download at runtime instead:
|
|
33
33
|
// --skip-bundled-models (passed by build-aosp.mjs)
|
|
@@ -56,8 +56,8 @@ const repoRoot = resolveRepoRootFromImportMeta(import.meta.url);
|
|
|
56
56
|
* eliza/packages/app-core/src/services/local-inference/catalog.ts so the
|
|
57
57
|
* runtime registry treats them as known catalog models, not orphans.
|
|
58
58
|
*
|
|
59
|
-
* The Android image bundles the
|
|
60
|
-
*
|
|
59
|
+
* The Android image bundles the 2B chat tier — the smallest/entry tier and the
|
|
60
|
+
* small-phone floor — so first boot has a local chat model on tight RAM.
|
|
61
61
|
*
|
|
62
62
|
* Sizes are sanity-checked at download time. If HuggingFace serves
|
|
63
63
|
* a smaller file (e.g. partial download, repo deleted, replaced) the
|
|
@@ -74,17 +74,6 @@ const CHAT_MODEL_ELIZA_1_MOBILE = {
|
|
|
74
74
|
role: "chat",
|
|
75
75
|
};
|
|
76
76
|
|
|
77
|
-
const CHAT_MODEL_ELIZA_1_LITE = {
|
|
78
|
-
id: "eliza-1-0_8b",
|
|
79
|
-
displayName: "eliza-1-0.8B",
|
|
80
|
-
hfRepo: "elizaos/eliza-1",
|
|
81
|
-
hfPath: "bundles/0_8b/text/eliza-1-0_8b-128k.gguf",
|
|
82
|
-
ggufFile: "text/eliza-1-0_8b-128k.gguf",
|
|
83
|
-
expectedMinBytes: 300 * 1024 * 1024,
|
|
84
|
-
expectedMaxBytes: 800 * 1024 * 1024,
|
|
85
|
-
role: "chat",
|
|
86
|
-
};
|
|
87
|
-
|
|
88
77
|
// Kokoro-82M voice — the on-device TTS voice. Without it the bundle has no
|
|
89
78
|
// tts/ model, so the runtime can't synthesize and the app falls back to the
|
|
90
79
|
// platform TextToSpeech (the "android voice"). Kokoro is the small/fast voice
|
|
@@ -96,7 +85,7 @@ const VOICE_MODEL_KOKORO = {
|
|
|
96
85
|
id: "eliza-1-kokoro",
|
|
97
86
|
displayName: "Eliza-1 Voice (Kokoro)",
|
|
98
87
|
hfRepo: "elizaos/eliza-1",
|
|
99
|
-
hfPath: "bundles/
|
|
88
|
+
hfPath: "bundles/2b/tts/kokoro/kokoro-82m-v1_0-Q4_K_M.gguf",
|
|
100
89
|
ggufFile: "tts/kokoro/kokoro-82m-v1_0-Q4_K_M.gguf",
|
|
101
90
|
expectedMinBytes: 150 * 1024 * 1024,
|
|
102
91
|
expectedMaxBytes: 200 * 1024 * 1024,
|
|
@@ -116,23 +105,27 @@ const VOICE_PRESET_KOKORO = {
|
|
|
116
105
|
|
|
117
106
|
export const DEFAULT_MODELS = [
|
|
118
107
|
CHAT_MODEL_ELIZA_1_MOBILE,
|
|
119
|
-
CHAT_MODEL_ELIZA_1_LITE,
|
|
120
108
|
VOICE_MODEL_KOKORO,
|
|
121
109
|
VOICE_PRESET_KOKORO,
|
|
122
110
|
];
|
|
123
111
|
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
112
|
+
export function resolveDefaultModelsAssetsDir(root = repoRoot) {
|
|
113
|
+
return path.join(
|
|
114
|
+
root,
|
|
115
|
+
"packages",
|
|
116
|
+
"app-core",
|
|
117
|
+
"platforms",
|
|
118
|
+
"android",
|
|
119
|
+
"app",
|
|
120
|
+
"src",
|
|
121
|
+
"main",
|
|
122
|
+
"assets",
|
|
123
|
+
"agent",
|
|
124
|
+
"models",
|
|
125
|
+
);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
const ASSETS_MODELS_DIR = resolveDefaultModelsAssetsDir(repoRoot);
|
|
136
129
|
|
|
137
130
|
const MANIFEST_PATH = path.join(ASSETS_MODELS_DIR, "manifest.json");
|
|
138
131
|
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { describe, expect, it } from "bun:test";
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
import { resolveDefaultModelsAssetsDir } from "./stage-default-models.mjs";
|
|
4
|
+
|
|
5
|
+
describe("stage-default-models", () => {
|
|
6
|
+
it("stages Android assets into the app-core Capacitor project", () => {
|
|
7
|
+
expect(resolveDefaultModelsAssetsDir("/repo")).toBe(
|
|
8
|
+
path.join(
|
|
9
|
+
"/repo",
|
|
10
|
+
"packages",
|
|
11
|
+
"app-core",
|
|
12
|
+
"platforms",
|
|
13
|
+
"android",
|
|
14
|
+
"app",
|
|
15
|
+
"src",
|
|
16
|
+
"main",
|
|
17
|
+
"assets",
|
|
18
|
+
"agent",
|
|
19
|
+
"models",
|
|
20
|
+
),
|
|
21
|
+
);
|
|
22
|
+
});
|
|
23
|
+
});
|
|
@@ -17,8 +17,8 @@ import { afterEach, beforeEach, describe, expect, it } from "vitest";
|
|
|
17
17
|
|
|
18
18
|
import {
|
|
19
19
|
assertRequiredBundledPackagesLanded,
|
|
20
|
-
getWorkspacePackageRuntimeCopyEntries,
|
|
21
20
|
getRuntimeDependencies,
|
|
21
|
+
getWorkspacePackageRuntimeCopyEntries,
|
|
22
22
|
selectCopyTargetNodeModules,
|
|
23
23
|
shouldCopyPackageEntry,
|
|
24
24
|
shouldCopyWorkspacePublishEntry,
|
|
@@ -367,6 +367,27 @@ describe("assertRequiredBundledPackagesLanded", () => {
|
|
|
367
367
|
).toBe(path.join(requesterDestDir, "node_modules"));
|
|
368
368
|
});
|
|
369
369
|
|
|
370
|
+
it("hoists the S3 client so packaged S3 adapters do not create tar-unsafe nested AWS paths", () => {
|
|
371
|
+
const rootDestDir = path.join(tmpDir, "dist");
|
|
372
|
+
const targetNodeModules = path.join(rootDestDir, "node_modules");
|
|
373
|
+
const requesterDestDir = path.join(
|
|
374
|
+
targetNodeModules,
|
|
375
|
+
"@brighter",
|
|
376
|
+
"storage-adapter-s3",
|
|
377
|
+
);
|
|
378
|
+
|
|
379
|
+
expect(
|
|
380
|
+
selectCopyTargetNodeModules({
|
|
381
|
+
name: "@aws-sdk/client-s3",
|
|
382
|
+
requesterDestDir,
|
|
383
|
+
rootDestDir,
|
|
384
|
+
targetNodeModules,
|
|
385
|
+
topLevelVersions: new Map([["@aws-sdk/client-s3", "3.1069.0"]]),
|
|
386
|
+
resolvedVersion: "3.1050.0",
|
|
387
|
+
}),
|
|
388
|
+
).toBe(targetNodeModules);
|
|
389
|
+
});
|
|
390
|
+
|
|
370
391
|
it("collapses WalletConnect patch drift to avoid duplicate desktop runtime copies", () => {
|
|
371
392
|
const rootDestDir = path.join(tmpDir, "dist");
|
|
372
393
|
const targetNodeModules = path.join(rootDestDir, "node_modules");
|
|
@@ -53,6 +53,32 @@ const STUB_MARKERS = Object.freeze([
|
|
|
53
53
|
"unsupported in ABI-only build",
|
|
54
54
|
]);
|
|
55
55
|
|
|
56
|
+
// #9508: the presence of this env-var name in libggml-vulkan.so proves the Mali
|
|
57
|
+
// scalar-flash-attn subgroup-race mitigation is compiled in — it is only emitted
|
|
58
|
+
// by source carrying the `VK_VENDOR_ID_ARM` `disable_subgroups` branch (the
|
|
59
|
+
// override knob for it). A Vulkan backend WITHOUT this marker is the stale
|
|
60
|
+
// pre-#9508 prebuilt that SIGABRTs mid-decode on Mali GPUs.
|
|
61
|
+
const MALI_FA_MITIGATION_MARKER = "GGML_VK_FA_ALLOW_SUBGROUPS";
|
|
62
|
+
|
|
63
|
+
// Mali flash-attn mitigation gate (#9508/#9528), extracted so the fail-closed
|
|
64
|
+
// behavior is unit-testable headless (it is pure fs marker-scanning, no nm/otool).
|
|
65
|
+
// A Vulkan fused build MUST ship a libggml-vulkan.so carrying the ARM
|
|
66
|
+
// subgroup-race mitigation marker, or it SIGABRTs mid-decode on Mali GPUs.
|
|
67
|
+
export function assertVulkanMaliMitigation({ lib, target }) {
|
|
68
|
+
if (!target.includes("vulkan")) return;
|
|
69
|
+
const vulkanBackend = path.join(path.dirname(lib), "libggml-vulkan.so");
|
|
70
|
+
if (!fs.existsSync(vulkanBackend)) {
|
|
71
|
+
throw new Error(
|
|
72
|
+
`[omnivoice-verify] symbol-verify: target=${target} is a Vulkan build but libggml-vulkan.so is missing next to ${lib} — the GPU backend did not build, so the fused lib would silently run CPU-only on device.`,
|
|
73
|
+
);
|
|
74
|
+
}
|
|
75
|
+
if (!binaryContainsAnyMarker(vulkanBackend, [MALI_FA_MITIGATION_MARKER])) {
|
|
76
|
+
throw new Error(
|
|
77
|
+
`[omnivoice-verify] symbol-verify: ${vulkanBackend} lacks the '${MALI_FA_MITIGATION_MARKER}' Mali flash-attn mitigation marker — this is a stale pre-#9508 GPU backend that SIGABRTs mid-decode on Mali. Build libggml-vulkan.so from source carrying the VK_VENDOR_ID_ARM disable_subgroups branch; never stage a prebuilt artifact into a release.`,
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
|
|
56
82
|
function pickToolForPlatform(target) {
|
|
57
83
|
// target is e.g. "darwin-arm64-metal-fused", "linux-x64-vulkan-fused", etc.
|
|
58
84
|
if (target.startsWith("darwin-") || target.startsWith("ios-")) {
|
|
@@ -421,6 +447,13 @@ function verifyFusedSymbolsInner({ outDir, target }) {
|
|
|
421
447
|
);
|
|
422
448
|
}
|
|
423
449
|
|
|
450
|
+
// Mali flash-attn mitigation gate (#9508). A Vulkan fused build MUST ship a
|
|
451
|
+
// libggml-vulkan.so that carries the ARM subgroup-race mitigation, or it
|
|
452
|
+
// SIGABRTs mid-decode on Mali GPUs (Tensor G-series etc.). Building from
|
|
453
|
+
// source emits the mitigation; copying a stale prebuilt does not. Fail-closed
|
|
454
|
+
// so a stale GPU backend can never be baked into a release APK.
|
|
455
|
+
assertVulkanMaliMitigation({ lib, target });
|
|
456
|
+
|
|
424
457
|
if (isIos) {
|
|
425
458
|
return {
|
|
426
459
|
ok: true,
|
|
Binary file
|
package/scripts/build-image.sh
CHANGED
|
@@ -115,9 +115,7 @@ load_env_file "deploy/deploy.env"
|
|
|
115
115
|
|
|
116
116
|
APP_IMAGE="${APP_IMAGE:-eliza/agent}"
|
|
117
117
|
APP_ENTRYPOINT="${APP_ENTRYPOINT:-app.mjs}"
|
|
118
|
-
|
|
119
|
-
# `.ts` specifiers rewritten to `.js`, so the tsx loader only added startup tax.
|
|
120
|
-
APP_CMD_START="${APP_CMD_START:-node ${APP_ENTRYPOINT} start}"
|
|
118
|
+
APP_CMD_START="${APP_CMD_START:-node --import ./node_modules/tsx/dist/loader.mjs ${APP_ENTRYPOINT} start}"
|
|
121
119
|
APP_PORT="${APP_PORT:-2138}"
|
|
122
120
|
APP_API_BIND="${APP_API_BIND:-127.0.0.1}"
|
|
123
121
|
OCI_SOURCE="${OCI_SOURCE:-}"
|
|
@@ -63,7 +63,13 @@ const DEPLOYMENT_TARGET =
|
|
|
63
63
|
// ios-deps tree is the historical fallback. Both carry the eliza kernels.
|
|
64
64
|
const FORK_SRC_CANDIDATES = [
|
|
65
65
|
process.env.ELIZA_MTP_LLAMA_CPP_SRC?.trim(),
|
|
66
|
-
path.join(
|
|
66
|
+
path.join(
|
|
67
|
+
repoRoot,
|
|
68
|
+
"plugins",
|
|
69
|
+
"plugin-local-inference",
|
|
70
|
+
"native",
|
|
71
|
+
"llama.cpp",
|
|
72
|
+
),
|
|
67
73
|
path.join(repoRoot, "packages", "native", "ios-deps", "llama.cpp", "src"),
|
|
68
74
|
].filter(Boolean);
|
|
69
75
|
|
|
@@ -75,7 +81,7 @@ const SUPPORTED_TARGETS = [
|
|
|
75
81
|
];
|
|
76
82
|
|
|
77
83
|
/** Per-target recipe. The iOS device + simulator slices differ only by SDK.
|
|
78
|
-
* The `-fused` variants additionally build the OmniVoice TTS +
|
|
84
|
+
* The `-fused` variants additionally build the OmniVoice TTS + local ASR FFI
|
|
79
85
|
* (the eliza_inference_* voice ABI = libelizainference) and libmtmd into the
|
|
80
86
|
* slice, so the iOS XCFramework carries the real voice runtime instead of the
|
|
81
87
|
* fail-closed runtime-symbol shim. */
|
|
@@ -105,7 +111,7 @@ const REQUIRED_KERNELS = [
|
|
|
105
111
|
{ id: "turbo4", pattern: /turbo4/i },
|
|
106
112
|
];
|
|
107
113
|
|
|
108
|
-
// ── Fused-only: the OmniVoice TTS +
|
|
114
|
+
// ── Fused-only: the OmniVoice TTS + local ASR FFI symbol set that distinguishes
|
|
109
115
|
// a real libelizainference (ABI v4) from the fail-closed runtime shim. These
|
|
110
116
|
// mirror the eliza_inference_* half of ios-xcframework/build-xcframework.mjs
|
|
111
117
|
// REQUIRED_IOS_KERNEL_SYMBOLS plus an mtmd presence probe (the ASR path wraps
|
|
@@ -219,7 +225,7 @@ function collectArchives(buildDir, outDir) {
|
|
|
219
225
|
.map((s) => s.trim())
|
|
220
226
|
.filter(Boolean)
|
|
221
227
|
.filter((p) =>
|
|
222
|
-
// Fused slices also stage libmtmd*.a (
|
|
228
|
+
// Fused slices also stage libmtmd*.a (local ASR projector),
|
|
223
229
|
// libkokoro_lib*.a (Kokoro-82M TTS, ABI v10), and libelizainference*.a
|
|
224
230
|
// (the eliza_inference_* voice ABI). NOT libomnivoice*.a —
|
|
225
231
|
// elizainference_static already compiles the omnivoice CORE sources, so
|
|
@@ -276,12 +282,7 @@ function buildTarget(target) {
|
|
|
276
282
|
log(`target=${target} sdk=${t.sdk} fork=${revision}`);
|
|
277
283
|
log(`source: ${srcDir}`);
|
|
278
284
|
|
|
279
|
-
const buildDir = path.join(
|
|
280
|
-
STATE_DIR,
|
|
281
|
-
"local-inference",
|
|
282
|
-
"mtp-build",
|
|
283
|
-
target,
|
|
284
|
-
);
|
|
285
|
+
const buildDir = path.join(STATE_DIR, "local-inference", "mtp-build", target);
|
|
285
286
|
if (process.env.ELIZA_MTP_FORCE_REBUILD === "1") {
|
|
286
287
|
fs.rmSync(buildDir, { recursive: true, force: true });
|
|
287
288
|
}
|
|
@@ -319,7 +320,7 @@ function buildTarget(target) {
|
|
|
319
320
|
"-DLLAMA_BUILD_TESTS=OFF",
|
|
320
321
|
"-DLLAMA_BUILD_SERVER=OFF",
|
|
321
322
|
"-DLLAMA_CURL=OFF",
|
|
322
|
-
// Fused voice slice: build the standalone libmtmd (the
|
|
323
|
+
// Fused voice slice: build the standalone libmtmd (the local ASR audio
|
|
323
324
|
// projector the eliza_inference ASR path wraps). The omnivoice subtree is
|
|
324
325
|
// already configured (LLAMA_BUILD_OMNIVOICE defaults ON); we only need the
|
|
325
326
|
// elizainference_static + mtmd targets, built by name below.
|
|
@@ -341,7 +342,7 @@ function buildTarget(target) {
|
|
|
341
342
|
// library targets carry the full kernel set and need no signing.
|
|
342
343
|
const buildTargets = ["llama", "ggml", "ggml-base", "ggml-cpu", "ggml-metal"];
|
|
343
344
|
if (t.fused) {
|
|
344
|
-
// mtmd (
|
|
345
|
+
// mtmd (local ASR projector) + kokoro_lib (Kokoro-82M TTS, ABI v10) + the
|
|
345
346
|
// STATIC eliza_inference_* FFI archive. kokoro_lib must build before
|
|
346
347
|
// elizainference_static links so the `if(TARGET kokoro_lib)` fold resolves.
|
|
347
348
|
// NOT omnivoice-tts / omnivoice-codec: those CLIs include audio-io.h
|
|
@@ -352,7 +353,7 @@ function buildTarget(target) {
|
|
|
352
353
|
}
|
|
353
354
|
log(
|
|
354
355
|
`cmake build (static libraries only) — compiles the Metal kernel set${
|
|
355
|
-
t.fused ? " + OmniVoice/
|
|
356
|
+
t.fused ? " + OmniVoice/local-ASR voice FFI" : ""
|
|
356
357
|
}`,
|
|
357
358
|
);
|
|
358
359
|
run("cmake", [
|
|
@@ -381,7 +382,7 @@ function buildTarget(target) {
|
|
|
381
382
|
);
|
|
382
383
|
}
|
|
383
384
|
|
|
384
|
-
// Fused-only: prove the REAL OmniVoice TTS +
|
|
385
|
+
// Fused-only: prove the REAL OmniVoice TTS + local ASR FFI (the eliza_inference_*
|
|
385
386
|
// voice ABI v4) and the mtmd projector are present in the staged archives, so
|
|
386
387
|
// the xcframework assembler's real-vs-fail-closed-shim decision (keyed off
|
|
387
388
|
// CAPABILITIES.omnivoice != null) is backed by actual symbols. The fork at
|
|
@@ -414,7 +415,7 @@ function buildTarget(target) {
|
|
|
414
415
|
archives: archives.map((a) => path.basename(a)),
|
|
415
416
|
// The xcframework assembler reads `omnivoice == null` as "use the
|
|
416
417
|
// fail-closed runtime symbol shim". Fused slices carry the real
|
|
417
|
-
// libelizainference (OmniVoice TTS +
|
|
418
|
+
// libelizainference (OmniVoice TTS + local ASR FFI), so they advertise a
|
|
418
419
|
// non-null capability object → the assembler compiles the shim with
|
|
419
420
|
// -DELIZA_IOS_REAL_ELIZAINFERENCE=1 (dropping the stub voice bodies) and the
|
|
420
421
|
// real symbols resolve from the staged archive.
|
|
@@ -434,7 +435,7 @@ function buildTarget(target) {
|
|
|
434
435
|
: 4,
|
|
435
436
|
library: "libelizainference",
|
|
436
437
|
tts: "omnivoice",
|
|
437
|
-
asr: "
|
|
438
|
+
asr: "local-asr",
|
|
438
439
|
vad: "silero",
|
|
439
440
|
kokoro: /(?:^|\s)_?eliza_inference_kokoro_synthesize\b/m.test(
|
|
440
441
|
symbolsText,
|
package/scripts/check-i18n.mjs
CHANGED
|
@@ -17,7 +17,6 @@ const LOCALE_DIR = path.join(repoRoot, "packages/ui/src/i18n/locales");
|
|
|
17
17
|
const SCAN_DIRS = [
|
|
18
18
|
path.join(repoRoot, "packages/app-core/src"),
|
|
19
19
|
path.join(repoRoot, "packages/ui/src"),
|
|
20
|
-
path.join(repoRoot, "packages/cloud-frontend/src"),
|
|
21
20
|
];
|
|
22
21
|
const ALLOWLIST_PATH = path.join(__dirname, "i18n-dynamic-keys.json");
|
|
23
22
|
const SOURCE_LOCALE = "en";
|