@zerogpu/expo-android-sdk 0.2.0 → 0.3.0-dev.202609241109.gd2de40c

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.
@@ -4,7 +4,7 @@ apply plugin: 'com.android.library'
4
4
  apply plugin: 'kotlin-android'
5
5
 
6
6
  group = 'ai.zerogpu.expo'
7
- version = '0.2.0'
7
+ version = '0.2.1'
8
8
 
9
9
  def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
10
10
  apply from: expoModulesCorePlugin
@@ -11,4 +11,3 @@ export interface ZeroGpuAndroidSdkNativeModule {
11
11
  }
12
12
  declare const _default: ZeroGpuAndroidSdkNativeModule;
13
13
  export default _default;
14
- //# sourceMappingURL=ZeroGpuAndroidSdkModule.d.ts.map
@@ -1,4 +1,3 @@
1
1
  import { requireNativeModule } from 'expo-modules-core';
2
2
  // The name must match `Name(...)` in the native module definitions.
3
3
  export default requireNativeModule('ZeroGpuAndroidSdk');
4
- //# sourceMappingURL=ZeroGpuAndroidSdkModule.js.map
package/build/index.d.ts CHANGED
@@ -24,4 +24,3 @@ export declare function stop(): Promise<void>;
24
24
  * {@link start} are kept and used when it starts. No-op on iOS.
25
25
  */
26
26
  export declare function setCustomParams(customParams: CustomParams): Promise<void>;
27
- //# sourceMappingURL=index.d.ts.map
package/build/index.js CHANGED
@@ -29,4 +29,3 @@ export function stop() {
29
29
  export function setCustomParams(customParams) {
30
30
  return ZeroGpuAndroidSdkModule.setCustomParams(customParams);
31
31
  }
32
- //# sourceMappingURL=index.js.map
package/build/types.d.ts CHANGED
@@ -25,4 +25,3 @@ export type CustomParams = {
25
25
  cust_param2?: string;
26
26
  cust_param3?: string;
27
27
  };
28
- //# sourceMappingURL=types.d.ts.map
package/build/types.js CHANGED
@@ -1,2 +1 @@
1
1
  export {};
2
- //# sourceMappingURL=types.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zerogpu/expo-android-sdk",
3
- "version": "0.2.0",
3
+ "version": "0.3.0-dev.202609241109.gd2de40c",
4
4
  "description": "Expo/React Native module that runs a ZeroGPU on-device inference node on Android by wrapping the native ai.zerogpu:android-sdk AAR.",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",
@@ -1 +0,0 @@
1
- {"version":3,"file":"ZeroGpuAndroidSdkModule.d.ts","sourceRoot":"","sources":["../src/ZeroGpuAndroidSdkModule.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE5D;;;;GAIG;AACH,MAAM,WAAW,6BAA6B;IAC5C,KAAK,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IACpE,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACtB,eAAe,CAAC,YAAY,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC5D;;AAGD,wBAAuF"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"ZeroGpuAndroidSdkModule.js","sourceRoot":"","sources":["../src/ZeroGpuAndroidSdkModule.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAexD,oEAAoE;AACpE,eAAe,mBAAmB,CAAgC,mBAAmB,CAAC,CAAC","sourcesContent":["import { requireNativeModule } from 'expo-modules-core';\n\nimport type { CustomParams, ZeroGpuOptions } from './types';\n\n/**\n * Native-module contract. Backed by the Android implementation\n * (`ai.zerogpu.expo.ZeroGpuAndroidSdkModule`) and a no-op iOS stub, so both\n * methods resolve on every platform.\n */\nexport interface ZeroGpuAndroidSdkNativeModule {\n start(operatorKey: string, options?: ZeroGpuOptions): Promise<void>;\n stop(): Promise<void>;\n setCustomParams(customParams: CustomParams): Promise<void>;\n}\n\n// The name must match `Name(...)` in the native module definitions.\nexport default requireNativeModule<ZeroGpuAndroidSdkNativeModule>('ZeroGpuAndroidSdk');\n"]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE5D,YAAY,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE5D;;;;;;;;;;;GAWG;AACH,wBAAgB,KAAK,CAAC,WAAW,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,OAAO,CAAC,IAAI,CAAC,CAElF;AAED;;;GAGG;AACH,wBAAgB,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC,CAEpC;AAED;;;;GAIG;AACH,wBAAgB,eAAe,CAAC,YAAY,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC,CAEzE"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,uBAAuB,MAAM,2BAA2B,CAAC;AAKhE;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,KAAK,CAAC,WAAmB,EAAE,OAAwB;IACjE,OAAO,uBAAuB,CAAC,KAAK,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC;AAC7D,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,IAAI;IAClB,OAAO,uBAAuB,CAAC,IAAI,EAAE,CAAC;AACxC,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,eAAe,CAAC,YAA0B;IACxD,OAAO,uBAAuB,CAAC,eAAe,CAAC,YAAY,CAAC,CAAC;AAC/D,CAAC","sourcesContent":["import ZeroGpuAndroidSdkModule from './ZeroGpuAndroidSdkModule';\nimport type { CustomParams, ZeroGpuOptions } from './types';\n\nexport type { CustomParams, ZeroGpuOptions } from './types';\n\n/**\n * Start the ZeroGPU node. The device registers with the ZeroGPU backend using the\n * operator key, downloads its assigned model(s), and serves on-device inference\n * while the app is foregrounded (the native SDK manages the socket lifecycle).\n *\n * Idempotent: calling `start` again while already running is a no-op. On iOS this\n * resolves without doing anything — the SDK is Android-only.\n *\n * @param operatorKey Your operator key from the ZeroGPU dashboard (`zgpu-sdk-…`).\n * @param options Optional base URL / environment / telemetry overrides and\n * initial `customParams`.\n */\nexport function start(operatorKey: string, options?: ZeroGpuOptions): Promise<void> {\n return ZeroGpuAndroidSdkModule.start(operatorKey, options);\n}\n\n/**\n * Stop the ZeroGPU node: close the socket, release model adapters, and shut the\n * SDK down. A subsequent {@link start} spins up a fresh instance. No-op on iOS.\n */\nexport function stop(): Promise<void> {\n return ZeroGpuAndroidSdkModule.stop();\n}\n\n/**\n * Replace the operator macros on the running node; `{}` clears them. Applies\n * from the next task the device serves — no re-register. Values set before\n * {@link start} are kept and used when it starts. No-op on iOS.\n */\nexport function setCustomParams(customParams: CustomParams): Promise<void> {\n return ZeroGpuAndroidSdkModule.setCustomParams(customParams);\n}\n"]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B,8EAA8E;IAC9E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,kDAAkD;IAClD,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,uEAAuE;IACvE,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,2FAA2F;IAC3F,YAAY,CAAC,EAAE,YAAY,CAAC;CAC7B,CAAC;AAEF;;;;;;;GAOG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"types.js","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["/**\n * Optional overrides for {@link start}. All fields default to production values\n * inside the native SDK, so a typical caller only passes the operator key.\n */\nexport type ZeroGpuOptions = {\n /** Device-registration base URL. Defaults to `https://devices.zerogpu.ai`. */\n baseUrl?: string;\n /** Environment name. Defaults to `production`. */\n env?: string;\n /** Whether the SDK reports anonymous telemetry. Defaults to `true`. */\n enableTelemetry?: boolean;\n /** Operator macros attached to every task this device serves. See {@link CustomParams}. */\n customParams?: CustomParams;\n};\n\n/**\n * Operator-defined macros: opaque values (placement, cohort, campaign…) that\n * ZeroGPU stores and counts per request and never interprets, so you can\n * segment your earnings by them. A slot takes just a value (letters, digits,\n * `.` `_` `-`), never a nested parameter like `user-id=123`, which is dropped.\n * Values are truncated to 128 characters; unset or empty slots are omitted. Never put PII (emails, phone numbers, names) in a\n * slot — email-shaped values are dropped with a logcat warning.\n */\nexport type CustomParams = {\n cust_param1?: string;\n cust_param2?: string;\n cust_param3?: string;\n};\n"]}