@infilectai/aira 0.0.0-stage → 0.1.0

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.
Files changed (57) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +74 -2
  3. package/bin/aira-capture +0 -0
  4. package/dist/attribution.d.ts +118 -0
  5. package/dist/attribution.d.ts.map +1 -0
  6. package/dist/attribution.js +626 -0
  7. package/dist/attribution.js.map +1 -0
  8. package/dist/audio.d.ts +26 -0
  9. package/dist/audio.d.ts.map +1 -0
  10. package/dist/audio.js +172 -0
  11. package/dist/audio.js.map +1 -0
  12. package/dist/brain.d.ts +11 -0
  13. package/dist/brain.d.ts.map +1 -0
  14. package/dist/brain.js +70 -0
  15. package/dist/brain.js.map +1 -0
  16. package/dist/capture.d.ts +48 -0
  17. package/dist/capture.d.ts.map +1 -0
  18. package/dist/capture.js +195 -0
  19. package/dist/capture.js.map +1 -0
  20. package/dist/engine.d.ts +61 -0
  21. package/dist/engine.d.ts.map +1 -0
  22. package/dist/engine.js +471 -0
  23. package/dist/engine.js.map +1 -0
  24. package/dist/eyes.d.ts +60 -0
  25. package/dist/eyes.d.ts.map +1 -0
  26. package/dist/eyes.js +173 -0
  27. package/dist/eyes.js.map +1 -0
  28. package/dist/index.d.ts +11 -0
  29. package/dist/index.d.ts.map +1 -0
  30. package/dist/index.js +9 -0
  31. package/dist/index.js.map +1 -0
  32. package/dist/lockfile.d.ts +14 -0
  33. package/dist/lockfile.d.ts.map +1 -0
  34. package/dist/lockfile.js +38 -0
  35. package/dist/lockfile.js.map +1 -0
  36. package/dist/providers.d.ts +162 -0
  37. package/dist/providers.d.ts.map +1 -0
  38. package/dist/providers.js +374 -0
  39. package/dist/providers.js.map +1 -0
  40. package/dist/transport.d.ts +14 -0
  41. package/dist/transport.d.ts.map +1 -0
  42. package/dist/transport.js +44 -0
  43. package/dist/transport.js.map +1 -0
  44. package/dist/types.d.ts +175 -0
  45. package/dist/types.d.ts.map +1 -0
  46. package/dist/types.js +2 -0
  47. package/dist/types.js.map +1 -0
  48. package/dist/vectors.d.ts +10 -0
  49. package/dist/vectors.d.ts.map +1 -0
  50. package/dist/vectors.js +66 -0
  51. package/dist/vectors.js.map +1 -0
  52. package/native/AiraCapture.swift +1142 -0
  53. package/native/Info.plist +26 -0
  54. package/native/NativeMeetingScraper.swift +1277 -0
  55. package/package.json +84 -4
  56. package/scripts/build-capture.cjs +57 -0
  57. package/scripts/postinstall.cjs +29 -0
package/package.json CHANGED
@@ -1,6 +1,86 @@
1
1
  {
2
2
  "name": "@infilectai/aira",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "0.1.0",
4
+ "description": "Standalone macOS meeting detection, speaker attribution, and audio capture SDK — pluggable with any STT/Diarization endpoint or AiraEngine.",
5
+ "license": "MIT",
6
+ "private": false,
7
+ "publishConfig": {
8
+ "access": "public"
9
+ },
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "git+https://github.com/InfilectAI/AiraSDK.git"
13
+ },
14
+ "homepage": "https://github.com/InfilectAI/AiraSDK#readme",
15
+ "bugs": {
16
+ "url": "https://github.com/InfilectAI/AiraSDK/issues"
17
+ },
18
+ "keywords": [
19
+ "aira",
20
+ "meeting-detection",
21
+ "speaker-attribution",
22
+ "diarization",
23
+ "transcription",
24
+ "stt",
25
+ "macos",
26
+ "coreaudio",
27
+ "google-meet",
28
+ "zoom",
29
+ "microsoft-teams"
30
+ ],
31
+ "type": "module",
32
+ "os": [
33
+ "darwin"
34
+ ],
35
+ "cpu": [
36
+ "arm64"
37
+ ],
38
+ "engines": {
39
+ "node": ">=22"
40
+ },
41
+ "main": "./dist/index.js",
42
+ "types": "./dist/index.d.ts",
43
+ "exports": {
44
+ ".": {
45
+ "types": "./dist/index.d.ts",
46
+ "import": "./dist/index.js"
47
+ },
48
+ "./engine": {
49
+ "types": "./dist/engine.d.ts",
50
+ "import": "./dist/engine.js"
51
+ },
52
+ "./providers": {
53
+ "types": "./dist/providers.d.ts",
54
+ "import": "./dist/providers.js"
55
+ }
56
+ },
57
+ "files": [
58
+ "dist",
59
+ "bin/aira-capture",
60
+ "native",
61
+ "scripts/build-capture.cjs",
62
+ "scripts/postinstall.cjs"
63
+ ],
64
+ "bin": {
65
+ "aira-capture-install": "scripts/postinstall.cjs"
66
+ },
67
+ "scripts": {
68
+ "build": "node scripts/build-capture.cjs && tsc",
69
+ "build:capture": "node scripts/build-capture.cjs",
70
+ "build:ts": "tsc",
71
+ "pack:engine": "node scripts/pack-engine.cjs",
72
+ "prepublishOnly": "npm run build",
73
+ "dev": "tsc --watch",
74
+ "clean": "rm -rf dist bin",
75
+ "postinstall": "node scripts/postinstall.cjs"
76
+ },
77
+ "dependencies": {
78
+ "sqlite-vec": "^0.1.6",
79
+ "ws": "^8.18.0"
80
+ },
81
+ "devDependencies": {
82
+ "@types/node": "^22.0.0",
83
+ "@types/ws": "^8.5.13",
84
+ "typescript": "^5.6.0"
85
+ }
86
+ }
@@ -0,0 +1,57 @@
1
+ #!/usr/bin/env node
2
+ // Compiles the lightweight, zero-dependency macOS native capture helper
3
+ // (`native/AiraCapture.swift` + `native/NativeMeetingScraper.swift`) into
4
+ // `bin/aira-capture`. Uses only Apple system frameworks (~300 KB binary)
5
+ // so `@infilectai/aira` is self-contained and npm-publishable without bundling
6
+ // any 60 MB ML engine or frameworks.
7
+
8
+ const { execFileSync } = require('node:child_process')
9
+ const fs = require('node:fs')
10
+ const path = require('node:path')
11
+
12
+ const rootDir = path.resolve(__dirname, '..')
13
+ const nativeDir = path.join(rootDir, 'native')
14
+ const binDir = path.join(rootDir, 'bin')
15
+ const outBin = path.join(binDir, 'aira-capture')
16
+
17
+ if (process.platform !== 'darwin') {
18
+ console.warn(`[aira] skipping native aira-capture build on ${process.platform}`)
19
+ process.exit(0)
20
+ }
21
+
22
+ fs.rmSync(binDir, { recursive: true, force: true })
23
+ fs.mkdirSync(binDir, { recursive: true })
24
+
25
+ const sources = [
26
+ path.join(nativeDir, 'NativeMeetingScraper.swift'),
27
+ path.join(nativeDir, 'AiraCapture.swift'),
28
+ ]
29
+ const infoPlist = path.join(nativeDir, 'Info.plist')
30
+
31
+ const args = [
32
+ '-O',
33
+ '-target', 'arm64-apple-macosx14.0',
34
+ '-parse-as-library',
35
+ ...sources,
36
+ '-framework', 'Foundation',
37
+ '-framework', 'AppKit',
38
+ '-framework', 'ApplicationServices',
39
+ '-framework', 'CoreGraphics',
40
+ '-framework', 'CoreAudio',
41
+ '-framework', 'AudioToolbox',
42
+ '-framework', 'AVFoundation',
43
+ '-framework', 'CoreMedia',
44
+ '-framework', 'ScreenCaptureKit',
45
+ '-framework', 'JavaScriptCore',
46
+ '-Xlinker', '-sectcreate',
47
+ '-Xlinker', '__TEXT',
48
+ '-Xlinker', '__info_plist',
49
+ '-Xlinker', infoPlist,
50
+ '-o', outBin,
51
+ ]
52
+
53
+ execFileSync('swiftc', args, { stdio: 'inherit' })
54
+ fs.chmodSync(outBin, 0o755)
55
+
56
+ const sizeKb = (fs.statSync(outBin).size / 1024).toFixed(1)
57
+ console.log(`built bin/aira-capture (${sizeKb} KB, zero external dependencies)`)
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env node
2
+ // Verify the bundled aira-capture binary survived the install, or build it
3
+ // from native/ if swiftc is available.
4
+
5
+ const fs = require('node:fs')
6
+ const path = require('node:path')
7
+ const { execFileSync } = require('node:child_process')
8
+
9
+ const PLATFORM = `${process.platform}-${process.arch}`
10
+ const SUPPORTED = new Set(['darwin-arm64'])
11
+
12
+ const capturePath = path.resolve(__dirname, '..', 'bin', 'aira-capture')
13
+ const buildScript = path.resolve(__dirname, 'build-capture.cjs')
14
+
15
+ function log(msg) { process.stderr.write(`[aira] ${msg}\n`) }
16
+
17
+ if (fs.existsSync(capturePath)) {
18
+ try { fs.chmodSync(capturePath, 0o755) } catch { /* ignore */ }
19
+ log(`aira-capture bundled at ${capturePath}`)
20
+ } else if (SUPPORTED.has(PLATFORM) && fs.existsSync(buildScript)) {
21
+ try {
22
+ execFileSync(process.execPath, [buildScript], { stdio: 'inherit' })
23
+ } catch {
24
+ log(`could not build aira-capture automatically; set AIRA_CAPTURE_BIN at runtime`)
25
+ }
26
+ } else if (!SUPPORTED.has(PLATFORM)) {
27
+ log(`platform ${PLATFORM} not supported — macOS Apple Silicon (darwin-arm64) required`)
28
+ }
29
+