WIP push-to-talk Letta chat frontend
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

stub letta manager

+601 -8
+16
deno.lock
··· 12 12 "npm:@tailwindcss/vite@^4.1.12": "4.1.12_vite@6.3.5__picomatch@4.0.3", 13 13 "npm:@tauri-apps/api@2": "2.8.0", 14 14 "npm:@tauri-apps/cli@2": "2.8.2", 15 + "npm:@tauri-apps/plugin-http@~2.5.2": "2.5.2", 15 16 "npm:@tauri-apps/plugin-opener@2": "2.5.0", 16 17 "npm:@tauri-apps/plugin-positioner@2.3": "2.3.0", 18 + "npm:@tauri-apps/plugin-store@2.4": "2.4.0", 17 19 "npm:@tauri-apps/plugin-window-state@2.4": "2.4.0", 18 20 "npm:svelte-check@4": "4.3.1_svelte@5.38.3__acorn@8.15.0_typescript@5.6.3", 19 21 "npm:svelte@5": "5.38.3_acorn@8.15.0", ··· 614 616 ], 615 617 "bin": true 616 618 }, 619 + "@tauri-apps/plugin-http@2.5.2": { 620 + "integrity": "sha512-x1mQKHSLDk4mS2S938OTeyk8L7QyLpCrKZCZcjkljGsvTvRMojCvI9SeJ1kaxc7t8xSilkC7WdId8xER9TIGLg==", 621 + "dependencies": [ 622 + "@tauri-apps/api" 623 + ] 624 + }, 617 625 "@tauri-apps/plugin-opener@2.5.0": { 618 626 "integrity": "sha512-B0LShOYae4CZjN8leiNDbnfjSrTwoZakqKaWpfoH6nXiJwt6Rgj6RnVIffG3DoJiKsffRhMkjmBV9VeilSb4TA==", 619 627 "dependencies": [ ··· 622 630 }, 623 631 "@tauri-apps/plugin-positioner@2.3.0": { 624 632 "integrity": "sha512-YMRcvA+WcULnAS+UjqGLP9ekWAgmBCgvkzT2OTkE8TWcu9jVo/Z79K0nEJhDuhZO/O0b77X0Opd+wDkEDYPeDw==", 633 + "dependencies": [ 634 + "@tauri-apps/api" 635 + ] 636 + }, 637 + "@tauri-apps/plugin-store@2.4.0": { 638 + "integrity": "sha512-PjBnlnH6jyI71MGhrPaxUUCsOzc7WO1mbc4gRhME0m2oxLgCqbksw6JyeKQimuzv4ysdpNO3YbmaY2haf82a3A==", 625 639 "dependencies": [ 626 640 "@tauri-apps/api" 627 641 ] ··· 1112 1126 "npm:@tailwindcss/vite@^4.1.12", 1113 1127 "npm:@tauri-apps/api@2", 1114 1128 "npm:@tauri-apps/cli@2", 1129 + "npm:@tauri-apps/plugin-http@~2.5.2", 1115 1130 "npm:@tauri-apps/plugin-opener@2", 1116 1131 "npm:@tauri-apps/plugin-positioner@2.3", 1132 + "npm:@tauri-apps/plugin-store@2.4", 1117 1133 "npm:@tauri-apps/plugin-window-state@2.4", 1118 1134 "npm:svelte-check@4", 1119 1135 "npm:svelte@5",
+2
package.json
··· 19 19 "@iconify/tailwind4": "^1.0.6", 20 20 "@tailwindcss/vite": "^4.1.12", 21 21 "@tauri-apps/api": "^2", 22 + "@tauri-apps/plugin-http": "~2.5.2", 22 23 "@tauri-apps/plugin-opener": "^2", 23 24 "@tauri-apps/plugin-positioner": "~2.3.0", 25 + "@tauri-apps/plugin-store": "~2.4.0", 24 26 "@tauri-apps/plugin-window-state": "~2.4.0", 25 27 "tailwindcss": "^4.1.12" 26 28 },
+428
src-tauri/Cargo.lock
··· 539 539 source = "registry+https://github.com/rust-lang/crates.io-index" 540 540 checksum = "4ddef33a339a91ea89fb53151bd0a4689cfce27055c291dfa69945475d22c747" 541 541 dependencies = [ 542 + "percent-encoding", 542 543 "time", 543 544 "version_check", 545 + ] 546 + 547 + [[package]] 548 + name = "cookie_store" 549 + version = "0.21.1" 550 + source = "registry+https://github.com/rust-lang/crates.io-index" 551 + checksum = "2eac901828f88a5241ee0600950ab981148a18f2f756900ffba1b125ca6a3ef9" 552 + dependencies = [ 553 + "cookie", 554 + "document-features", 555 + "idna", 556 + "log", 557 + "publicsuffix", 558 + "serde", 559 + "serde_derive", 560 + "serde_json", 561 + "time", 562 + "url", 544 563 ] 545 564 546 565 [[package]] ··· 874 893 checksum = "2a2330da5de22e8a3cb63252ce2abb30116bf5265e89c0e01bc17015ce30a476" 875 894 876 895 [[package]] 896 + name = "data-url" 897 + version = "0.3.2" 898 + source = "registry+https://github.com/rust-lang/crates.io-index" 899 + checksum = "be1e0bca6c3637f992fc1cc7cbc52a78c1ef6db076dbf1059c4323d6a2048376" 900 + 901 + [[package]] 877 902 name = "dbus" 878 903 version = "0.9.9" 879 904 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 999 1024 ] 1000 1025 1001 1026 [[package]] 1027 + name = "document-features" 1028 + version = "0.2.11" 1029 + source = "registry+https://github.com/rust-lang/crates.io-index" 1030 + checksum = "95249b50c6c185bee49034bcb378a49dc2b5dff0be90ff6616d31d64febab05d" 1031 + dependencies = [ 1032 + "litrs", 1033 + ] 1034 + 1035 + [[package]] 1002 1036 name = "dpi" 1003 1037 version = "0.1.2" 1004 1038 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 1053 1087 version = "1.2.2" 1054 1088 source = "registry+https://github.com/rust-lang/crates.io-index" 1055 1089 checksum = "4ef6b89e5b37196644d8796de5268852ff179b44e96276cf4290264843743bb7" 1090 + 1091 + [[package]] 1092 + name = "encoding_rs" 1093 + version = "0.8.35" 1094 + source = "registry+https://github.com/rust-lang/crates.io-index" 1095 + checksum = "75030f3c4f45dafd7586dd6780965a8c7e8e285a5ecb86713e63a79c5b2766f3" 1096 + dependencies = [ 1097 + "cfg-if", 1098 + ] 1056 1099 1057 1100 [[package]] 1058 1101 name = "endi" ··· 1451 1494 checksum = "335ff9f135e4384c8150d6f27c6daed433577f86b4750418338c01a1a2528592" 1452 1495 dependencies = [ 1453 1496 "cfg-if", 1497 + "js-sys", 1454 1498 "libc", 1455 1499 "wasi 0.11.1+wasi-snapshot-preview1", 1500 + "wasm-bindgen", 1456 1501 ] 1457 1502 1458 1503 [[package]] ··· 1462 1507 checksum = "26145e563e54f2cadc477553f1ec5ee650b00862f0a58bcd12cbdc5f0ea2d2f4" 1463 1508 dependencies = [ 1464 1509 "cfg-if", 1510 + "js-sys", 1465 1511 "libc", 1466 1512 "r-efi", 1467 1513 "wasi 0.14.2+wasi-0.2.4", 1514 + "wasm-bindgen", 1468 1515 ] 1469 1516 1470 1517 [[package]] ··· 1622 1669 ] 1623 1670 1624 1671 [[package]] 1672 + name = "h2" 1673 + version = "0.4.12" 1674 + source = "registry+https://github.com/rust-lang/crates.io-index" 1675 + checksum = "f3c0b69cfcb4e1b9f1bf2f53f95f766e4661169728ec61cd3fe5a0166f2d1386" 1676 + dependencies = [ 1677 + "atomic-waker", 1678 + "bytes", 1679 + "fnv", 1680 + "futures-core", 1681 + "futures-sink", 1682 + "http", 1683 + "indexmap 2.11.0", 1684 + "slab", 1685 + "tokio", 1686 + "tokio-util", 1687 + "tracing", 1688 + ] 1689 + 1690 + [[package]] 1625 1691 name = "hashbrown" 1626 1692 version = "0.12.3" 1627 1693 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 1719 1785 "bytes", 1720 1786 "futures-channel", 1721 1787 "futures-core", 1788 + "h2", 1722 1789 "http", 1723 1790 "http-body", 1724 1791 "httparse", ··· 1731 1798 ] 1732 1799 1733 1800 [[package]] 1801 + name = "hyper-rustls" 1802 + version = "0.27.7" 1803 + source = "registry+https://github.com/rust-lang/crates.io-index" 1804 + checksum = "e3c93eb611681b207e1fe55d5a71ecf91572ec8a6705cdb6857f7d8d5242cf58" 1805 + dependencies = [ 1806 + "http", 1807 + "hyper", 1808 + "hyper-util", 1809 + "rustls", 1810 + "rustls-pki-types", 1811 + "tokio", 1812 + "tokio-rustls", 1813 + "tower-service", 1814 + "webpki-roots", 1815 + ] 1816 + 1817 + [[package]] 1818 + name = "hyper-tls" 1819 + version = "0.6.0" 1820 + source = "registry+https://github.com/rust-lang/crates.io-index" 1821 + checksum = "70206fc6890eaca9fde8a0bf71caa2ddfc9fe045ac9e5c70df101a7dbde866e0" 1822 + dependencies = [ 1823 + "bytes", 1824 + "http-body-util", 1825 + "hyper", 1826 + "hyper-util", 1827 + "native-tls", 1828 + "tokio", 1829 + "tokio-native-tls", 1830 + "tower-service", 1831 + ] 1832 + 1833 + [[package]] 1734 1834 name = "hyper-util" 1735 1835 version = "0.1.16" 1736 1836 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 1749 1849 "percent-encoding", 1750 1850 "pin-project-lite", 1751 1851 "socket2", 1852 + "system-configuration", 1752 1853 "tokio", 1753 1854 "tower-service", 1754 1855 "tracing", 1856 + "windows-registry", 1755 1857 ] 1756 1858 1757 1859 [[package]] ··· 2177 2279 checksum = "241eaef5fd12c88705a01fc1066c48c4b36e0dd4377dcdc7ec3942cea7a69956" 2178 2280 2179 2281 [[package]] 2282 + name = "litrs" 2283 + version = "0.4.2" 2284 + source = "registry+https://github.com/rust-lang/crates.io-index" 2285 + checksum = "f5e54036fe321fd421e10d732f155734c4e4afd610dd556d9a82833ab3ee0bed" 2286 + 2287 + [[package]] 2180 2288 name = "lock_api" 2181 2289 version = "0.4.13" 2182 2290 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 2191 2299 version = "0.4.27" 2192 2300 source = "registry+https://github.com/rust-lang/crates.io-index" 2193 2301 checksum = "13dc2df351e3202783a1fe0d44375f7295ffb4049267b0f3018346dc122a1d94" 2302 + 2303 + [[package]] 2304 + name = "lru-slab" 2305 + version = "0.1.2" 2306 + source = "registry+https://github.com/rust-lang/crates.io-index" 2307 + checksum = "112b39cec0b298b6c1999fee3e31427f74f676e4cb9879ed1a121b43661a4154" 2194 2308 2195 2309 [[package]] 2196 2310 name = "mac" ··· 2288 2402 "dasp", 2289 2403 "futures-util", 2290 2404 "keyring", 2405 + "reqwest", 2291 2406 "serde", 2292 2407 "serde_json", 2293 2408 "strum", 2294 2409 "tauri", 2295 2410 "tauri-build", 2411 + "tauri-plugin-http", 2296 2412 "tauri-plugin-opener", 2297 2413 "tauri-plugin-positioner", 2298 2414 "tauri-plugin-single-instance", 2415 + "tauri-plugin-store", 2299 2416 "tauri-plugin-window-state", 2300 2417 "tokio", 2301 2418 "tokio-tungstenite", ··· 3171 3288 ] 3172 3289 3173 3290 [[package]] 3291 + name = "psl-types" 3292 + version = "2.0.11" 3293 + source = "registry+https://github.com/rust-lang/crates.io-index" 3294 + checksum = "33cb294fe86a74cbcf50d4445b37da762029549ebeea341421c7c70370f86cac" 3295 + 3296 + [[package]] 3297 + name = "publicsuffix" 3298 + version = "2.3.0" 3299 + source = "registry+https://github.com/rust-lang/crates.io-index" 3300 + checksum = "6f42ea446cab60335f76979ec15e12619a2165b5ae2c12166bef27d283a9fadf" 3301 + dependencies = [ 3302 + "idna", 3303 + "psl-types", 3304 + ] 3305 + 3306 + [[package]] 3174 3307 name = "quick-xml" 3175 3308 version = "0.38.3" 3176 3309 source = "registry+https://github.com/rust-lang/crates.io-index" 3177 3310 checksum = "42a232e7487fc2ef313d96dde7948e7a3c05101870d8985e4fd8d26aedd27b89" 3178 3311 dependencies = [ 3179 3312 "memchr", 3313 + ] 3314 + 3315 + [[package]] 3316 + name = "quinn" 3317 + version = "0.11.9" 3318 + source = "registry+https://github.com/rust-lang/crates.io-index" 3319 + checksum = "b9e20a958963c291dc322d98411f541009df2ced7b5a4f2bd52337638cfccf20" 3320 + dependencies = [ 3321 + "bytes", 3322 + "cfg_aliases", 3323 + "pin-project-lite", 3324 + "quinn-proto", 3325 + "quinn-udp", 3326 + "rustc-hash", 3327 + "rustls", 3328 + "socket2", 3329 + "thiserror 2.0.16", 3330 + "tokio", 3331 + "tracing", 3332 + "web-time", 3333 + ] 3334 + 3335 + [[package]] 3336 + name = "quinn-proto" 3337 + version = "0.11.13" 3338 + source = "registry+https://github.com/rust-lang/crates.io-index" 3339 + checksum = "f1906b49b0c3bc04b5fe5d86a77925ae6524a19b816ae38ce1e426255f1d8a31" 3340 + dependencies = [ 3341 + "bytes", 3342 + "getrandom 0.3.3", 3343 + "lru-slab", 3344 + "rand 0.9.2", 3345 + "ring", 3346 + "rustc-hash", 3347 + "rustls", 3348 + "rustls-pki-types", 3349 + "slab", 3350 + "thiserror 2.0.16", 3351 + "tinyvec", 3352 + "tracing", 3353 + "web-time", 3354 + ] 3355 + 3356 + [[package]] 3357 + name = "quinn-udp" 3358 + version = "0.5.14" 3359 + source = "registry+https://github.com/rust-lang/crates.io-index" 3360 + checksum = "addec6a0dcad8a8d96a771f815f0eaf55f9d1805756410b39f5fa81332574cbd" 3361 + dependencies = [ 3362 + "cfg_aliases", 3363 + "libc", 3364 + "once_cell", 3365 + "socket2", 3366 + "tracing", 3367 + "windows-sys 0.60.2", 3180 3368 ] 3181 3369 3182 3370 [[package]] ··· 3387 3575 dependencies = [ 3388 3576 "base64 0.22.1", 3389 3577 "bytes", 3578 + "cookie", 3579 + "cookie_store", 3580 + "encoding_rs", 3390 3581 "futures-core", 3391 3582 "futures-util", 3583 + "h2", 3392 3584 "http", 3393 3585 "http-body", 3394 3586 "http-body-util", 3395 3587 "hyper", 3588 + "hyper-rustls", 3589 + "hyper-tls", 3396 3590 "hyper-util", 3397 3591 "js-sys", 3398 3592 "log", 3593 + "mime", 3594 + "native-tls", 3399 3595 "percent-encoding", 3400 3596 "pin-project-lite", 3597 + "quinn", 3598 + "rustls", 3599 + "rustls-pki-types", 3401 3600 "serde", 3402 3601 "serde_json", 3403 3602 "serde_urlencoded", 3404 3603 "sync_wrapper", 3405 3604 "tokio", 3605 + "tokio-native-tls", 3606 + "tokio-rustls", 3406 3607 "tokio-util", 3407 3608 "tower", 3408 3609 "tower-http", ··· 3412 3613 "wasm-bindgen-futures", 3413 3614 "wasm-streams", 3414 3615 "web-sys", 3616 + "webpki-roots", 3617 + ] 3618 + 3619 + [[package]] 3620 + name = "ring" 3621 + version = "0.17.14" 3622 + source = "registry+https://github.com/rust-lang/crates.io-index" 3623 + checksum = "a4689e6c2294d81e88dc6261c768b63bc4fcdb852be6d1352498b114f61383b7" 3624 + dependencies = [ 3625 + "cc", 3626 + "cfg-if", 3627 + "getrandom 0.2.16", 3628 + "libc", 3629 + "untrusted", 3630 + "windows-sys 0.52.0", 3415 3631 ] 3416 3632 3417 3633 [[package]] ··· 3419 3635 version = "0.1.26" 3420 3636 source = "registry+https://github.com/rust-lang/crates.io-index" 3421 3637 checksum = "56f7d92ca342cea22a06f2121d944b4fd82af56988c270852495420f961d4ace" 3638 + 3639 + [[package]] 3640 + name = "rustc-hash" 3641 + version = "2.1.1" 3642 + source = "registry+https://github.com/rust-lang/crates.io-index" 3643 + checksum = "357703d41365b4b27c590e3ed91eabb1b663f07c4c084095e60cbed4362dff0d" 3422 3644 3423 3645 [[package]] 3424 3646 name = "rustc_version" ··· 3440 3662 "libc", 3441 3663 "linux-raw-sys", 3442 3664 "windows-sys 0.60.2", 3665 + ] 3666 + 3667 + [[package]] 3668 + name = "rustls" 3669 + version = "0.23.31" 3670 + source = "registry+https://github.com/rust-lang/crates.io-index" 3671 + checksum = "c0ebcbd2f03de0fc1122ad9bb24b127a5a6cd51d72604a3f3c50ac459762b6cc" 3672 + dependencies = [ 3673 + "once_cell", 3674 + "ring", 3675 + "rustls-pki-types", 3676 + "rustls-webpki", 3677 + "subtle", 3678 + "zeroize", 3679 + ] 3680 + 3681 + [[package]] 3682 + name = "rustls-pki-types" 3683 + version = "1.12.0" 3684 + source = "registry+https://github.com/rust-lang/crates.io-index" 3685 + checksum = "229a4a4c221013e7e1f1a043678c5cc39fe5171437c88fb47151a21e6f5b5c79" 3686 + dependencies = [ 3687 + "web-time", 3688 + "zeroize", 3689 + ] 3690 + 3691 + [[package]] 3692 + name = "rustls-webpki" 3693 + version = "0.103.4" 3694 + source = "registry+https://github.com/rust-lang/crates.io-index" 3695 + checksum = "0a17884ae0c1b773f1ccd2bd4a8c72f16da897310a98b0e84bf349ad5ead92fc" 3696 + dependencies = [ 3697 + "ring", 3698 + "rustls-pki-types", 3699 + "untrusted", 3443 3700 ] 3444 3701 3445 3702 [[package]] ··· 3941 4198 ] 3942 4199 3943 4200 [[package]] 4201 + name = "subtle" 4202 + version = "2.6.1" 4203 + source = "registry+https://github.com/rust-lang/crates.io-index" 4204 + checksum = "13c2bddecc57b384dee18652358fb23172facb8a2c51ccc10d74c157bdea3292" 4205 + 4206 + [[package]] 3944 4207 name = "swift-rs" 3945 4208 version = "1.0.7" 3946 4209 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 3991 4254 "proc-macro2", 3992 4255 "quote", 3993 4256 "syn 2.0.106", 4257 + ] 4258 + 4259 + [[package]] 4260 + name = "system-configuration" 4261 + version = "0.6.1" 4262 + source = "registry+https://github.com/rust-lang/crates.io-index" 4263 + checksum = "3c879d448e9d986b661742763247d3693ed13609438cf3d006f51f5368a5ba6b" 4264 + dependencies = [ 4265 + "bitflags 2.9.3", 4266 + "core-foundation 0.9.4", 4267 + "system-configuration-sys", 4268 + ] 4269 + 4270 + [[package]] 4271 + name = "system-configuration-sys" 4272 + version = "0.6.0" 4273 + source = "registry+https://github.com/rust-lang/crates.io-index" 4274 + checksum = "8e1d1b10ced5ca923a1fcb8d03e96b8d3268065d724548c0211415ff6ac6bac4" 4275 + dependencies = [ 4276 + "core-foundation-sys", 4277 + "libc", 3994 4278 ] 3995 4279 3996 4280 [[package]] ··· 4196 4480 ] 4197 4481 4198 4482 [[package]] 4483 + name = "tauri-plugin-fs" 4484 + version = "2.4.2" 4485 + source = "registry+https://github.com/rust-lang/crates.io-index" 4486 + checksum = "315784ec4be45e90a987687bae7235e6be3d6e9e350d2b75c16b8a4bf22c1db7" 4487 + dependencies = [ 4488 + "anyhow", 4489 + "dunce", 4490 + "glob", 4491 + "percent-encoding", 4492 + "schemars 0.8.22", 4493 + "serde", 4494 + "serde_json", 4495 + "serde_repr", 4496 + "tauri", 4497 + "tauri-plugin", 4498 + "tauri-utils", 4499 + "thiserror 2.0.16", 4500 + "toml 0.9.5", 4501 + "url", 4502 + ] 4503 + 4504 + [[package]] 4505 + name = "tauri-plugin-http" 4506 + version = "2.5.2" 4507 + source = "registry+https://github.com/rust-lang/crates.io-index" 4508 + checksum = "938a3d7051c9a82b431e3a0f3468f85715b3442b3c3a3913095e9fa509e2652c" 4509 + dependencies = [ 4510 + "bytes", 4511 + "cookie_store", 4512 + "data-url", 4513 + "http", 4514 + "regex", 4515 + "reqwest", 4516 + "schemars 0.8.22", 4517 + "serde", 4518 + "serde_json", 4519 + "tauri", 4520 + "tauri-plugin", 4521 + "tauri-plugin-fs", 4522 + "thiserror 2.0.16", 4523 + "tokio", 4524 + "url", 4525 + "urlpattern", 4526 + ] 4527 + 4528 + [[package]] 4199 4529 name = "tauri-plugin-opener" 4200 4530 version = "2.5.0" 4201 4531 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 4245 4575 "tracing", 4246 4576 "windows-sys 0.60.2", 4247 4577 "zbus", 4578 + ] 4579 + 4580 + [[package]] 4581 + name = "tauri-plugin-store" 4582 + version = "2.4.0" 4583 + source = "registry+https://github.com/rust-lang/crates.io-index" 4584 + checksum = "d85dd80d60a76ee2c2fdce09e9ef30877b239c2a6bb76e6d7d03708aa5f13a19" 4585 + dependencies = [ 4586 + "dunce", 4587 + "serde", 4588 + "serde_json", 4589 + "tauri", 4590 + "tauri-plugin", 4591 + "thiserror 2.0.16", 4592 + "tokio", 4593 + "tracing", 4248 4594 ] 4249 4595 4250 4596 [[package]] ··· 4468 4814 ] 4469 4815 4470 4816 [[package]] 4817 + name = "tinyvec" 4818 + version = "1.10.0" 4819 + source = "registry+https://github.com/rust-lang/crates.io-index" 4820 + checksum = "bfa5fdc3bce6191a1dbc8c02d5c8bffcf557bafa17c124c5264a458f1b0613fa" 4821 + dependencies = [ 4822 + "tinyvec_macros", 4823 + ] 4824 + 4825 + [[package]] 4826 + name = "tinyvec_macros" 4827 + version = "0.1.1" 4828 + source = "registry+https://github.com/rust-lang/crates.io-index" 4829 + checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" 4830 + 4831 + [[package]] 4471 4832 name = "tokio" 4472 4833 version = "1.47.1" 4473 4834 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 4481 4842 "pin-project-lite", 4482 4843 "slab", 4483 4844 "socket2", 4845 + "tokio-macros", 4484 4846 "windows-sys 0.59.0", 4485 4847 ] 4486 4848 4487 4849 [[package]] 4850 + name = "tokio-macros" 4851 + version = "2.5.0" 4852 + source = "registry+https://github.com/rust-lang/crates.io-index" 4853 + checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8" 4854 + dependencies = [ 4855 + "proc-macro2", 4856 + "quote", 4857 + "syn 2.0.106", 4858 + ] 4859 + 4860 + [[package]] 4488 4861 name = "tokio-native-tls" 4489 4862 version = "0.3.1" 4490 4863 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 4495 4868 ] 4496 4869 4497 4870 [[package]] 4871 + name = "tokio-rustls" 4872 + version = "0.26.2" 4873 + source = "registry+https://github.com/rust-lang/crates.io-index" 4874 + checksum = "8e727b36a1a0e8b74c376ac2211e40c2c8af09fb4013c60d910495810f008e9b" 4875 + dependencies = [ 4876 + "rustls", 4877 + "tokio", 4878 + ] 4879 + 4880 + [[package]] 4498 4881 name = "tokio-tungstenite" 4499 4882 version = "0.27.0" 4500 4883 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 4815 5198 checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493" 4816 5199 4817 5200 [[package]] 5201 + name = "untrusted" 5202 + version = "0.9.0" 5203 + source = "registry+https://github.com/rust-lang/crates.io-index" 5204 + checksum = "8ecb6da28b8a351d773b68d5825ac39017e680750f980f3a1a85cd8dd28a47c1" 5205 + 5206 + [[package]] 4818 5207 name = "url" 4819 5208 version = "2.5.7" 4820 5209 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 5035 5424 ] 5036 5425 5037 5426 [[package]] 5427 + name = "web-time" 5428 + version = "1.1.0" 5429 + source = "registry+https://github.com/rust-lang/crates.io-index" 5430 + checksum = "5a6580f308b1fad9207618087a65c04e7a10bc77e02c8e84e9b00dd4b12fa0bb" 5431 + dependencies = [ 5432 + "js-sys", 5433 + "wasm-bindgen", 5434 + ] 5435 + 5436 + [[package]] 5038 5437 name = "webkit2gtk" 5039 5438 version = "2.0.1" 5040 5439 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 5079 5478 ] 5080 5479 5081 5480 [[package]] 5481 + name = "webpki-roots" 5482 + version = "1.0.2" 5483 + source = "registry+https://github.com/rust-lang/crates.io-index" 5484 + checksum = "7e8983c3ab33d6fb807cfcdad2491c4ea8cbc8ed839181c7dfd9c67c83e261b2" 5485 + dependencies = [ 5486 + "rustls-pki-types", 5487 + ] 5488 + 5489 + [[package]] 5082 5490 name = "webview2-com" 5083 5491 version = "0.38.0" 5084 5492 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 5265 5673 ] 5266 5674 5267 5675 [[package]] 5676 + name = "windows-registry" 5677 + version = "0.5.3" 5678 + source = "registry+https://github.com/rust-lang/crates.io-index" 5679 + checksum = "5b8a9ed28765efc97bbc954883f4e6796c33a06546ebafacbabee9696967499e" 5680 + dependencies = [ 5681 + "windows-link", 5682 + "windows-result 0.3.4", 5683 + "windows-strings", 5684 + ] 5685 + 5686 + [[package]] 5268 5687 name = "windows-result" 5269 5688 version = "0.1.2" 5270 5689 source = "registry+https://github.com/rust-lang/crates.io-index" ··· 5298 5717 checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" 5299 5718 dependencies = [ 5300 5719 "windows-targets 0.42.2", 5720 + ] 5721 + 5722 + [[package]] 5723 + name = "windows-sys" 5724 + version = "0.52.0" 5725 + source = "registry+https://github.com/rust-lang/crates.io-index" 5726 + checksum = "282be5f36a8ce781fad8c8ae18fa3f9beff57ec1b52cb3de0789201425d9a33d" 5727 + dependencies = [ 5728 + "windows-targets 0.52.6", 5301 5729 ] 5302 5730 5303 5731 [[package]]
+3
src-tauri/Cargo.toml
··· 30 30 dasp = { version = "0.11.0", features = ["all"] } 31 31 keyring = { version = "3.6.3", features = ["apple-native", "windows-native", "sync-secret-service"] } 32 32 strum = {version = "0.27.2", features = ["derive"] } 33 + tauri-plugin-store = "2" 34 + tauri-plugin-http = "2" 35 + reqwest = { version = "0.12.23", features = ["json"]} 33 36 34 37 [target.'cfg(not(any(target_os = "android", target_os = "ios")))'.dependencies] 35 38 tauri-plugin-positioner = "2"
+40
src-tauri/src/letta/commands.rs
··· 1 + use crate::{ 2 + letta::{LettaAgentInfo, LettaConfig}, 3 + state::AppState, 4 + }; 5 + 6 + #[tauri::command] 7 + pub async fn list_agents(state: tauri::State<'_, AppState>) -> Result<Vec<LettaAgentInfo>, ()> { 8 + Ok(state.letta_manager.list_agents().await) 9 + } 10 + 11 + #[tauri::command] 12 + pub async fn get_config(state: tauri::State<'_, AppState>) -> Result<LettaConfig, ()> { 13 + let config = state.letta_manager.config.lock().await; 14 + 15 + Ok(config.clone()) 16 + } 17 + 18 + #[tauri::command] 19 + pub async fn update_config( 20 + state: tauri::State<'_, AppState>, 21 + base_url: Option<String>, 22 + agent_id: Option<String>, 23 + ) -> Result<(), ()> { 24 + let mut config = state.letta_manager.config.lock().await; 25 + 26 + *config = LettaConfig { 27 + base_url: if base_url.is_some() { 28 + base_url.unwrap() 29 + } else { 30 + config.base_url.clone() 31 + }, 32 + agent_id: if agent_id.is_some() { 33 + agent_id.unwrap() 34 + } else { 35 + config.agent_id.clone() 36 + }, 37 + }; 38 + 39 + Ok(()) 40 + }
+85
src-tauri/src/letta/mod.rs
··· 1 + use std::sync::Arc; 2 + 3 + use reqwest::Client; 4 + use serde::{Deserialize, Serialize}; 5 + use serde_json::from_value; 6 + use tauri::async_runtime::Mutex; 7 + use tauri::Wry; 8 + use tauri_plugin_store::Store; 9 + 10 + use crate::secrets::SecretsManager; 11 + 12 + pub mod commands; 13 + 14 + #[derive(Serialize, Deserialize, Clone)] 15 + struct LettaConfig { 16 + base_url: String, 17 + agent_id: String, 18 + } 19 + 20 + #[derive(Serialize, Deserialize)] 21 + pub struct LettaAgentInfo { 22 + id: String, 23 + name: String, 24 + } 25 + 26 + pub struct LettaManager { 27 + http_client: Client, 28 + secrets_manager: Arc<SecretsManager>, 29 + store: Arc<Store<Wry>>, 30 + config: Arc<Mutex<LettaConfig>>, 31 + } 32 + impl LettaManager { 33 + pub fn new( 34 + http_client: Client, 35 + store: Arc<Store<Wry>>, 36 + secrets_manager: Arc<SecretsManager>, 37 + ) -> Self { 38 + match store.get("letta-config") { 39 + Some(config) => Self { 40 + http_client, 41 + secrets_manager, 42 + store, 43 + config: Arc::new(Mutex::new( 44 + from_value::<LettaConfig>(config).expect("failed to deserialize Letta config"), 45 + )), 46 + }, 47 + None => Self { 48 + http_client, 49 + secrets_manager, 50 + store, 51 + config: Arc::new(Mutex::new(LettaConfig { 52 + base_url: "https://api.letta.com".to_string(), 53 + agent_id: "".to_string(), 54 + })), 55 + }, 56 + } 57 + } 58 + 59 + pub async fn list_agents(&self) -> Vec<LettaAgentInfo> { 60 + match self 61 + .secrets_manager 62 + .get_secret(crate::secrets::SecretName::LettaApiKey) 63 + { 64 + Ok(api_key) => { 65 + let config = self.config.lock().await; 66 + let base_url = config.base_url.clone(); 67 + let req = self 68 + .http_client 69 + .get(format!("{base_url}/api/v1/agents")) 70 + .header("Authorization", format!("Bearer {api_key}")); 71 + 72 + let res = req 73 + .send() 74 + .await 75 + .expect("failed to list Letta agents") 76 + .json::<Vec<LettaAgentInfo>>() 77 + .await 78 + .expect("failed to parse agent list result"); 79 + 80 + res 81 + } 82 + Err(_) => Vec::new(), 83 + } 84 + } 85 + }
+9 -7
src-tauri/src/lib.rs
··· 1 1 use crate::state::AppState; 2 2 use tauri::{Manager, WebviewUrl, WebviewWindowBuilder}; 3 3 use tauri_plugin_positioner::{Position, WindowExt}; 4 + use tauri_plugin_store::StoreExt; 4 5 use tauri_plugin_window_state::{StateFlags, WindowExt as StateWindowExt}; 5 6 6 7 mod cartesia; 7 8 mod devices; 9 + mod letta; 8 10 mod secrets; 9 11 mod state; 10 - 11 - // Learn more about Tauri commands at https://tauri.app/develop/calling-rust/ 12 - #[tauri::command] 13 - fn greet(name: &str) -> String { 14 - format!("Hello, {}! You've been greeted from Rust!", name) 15 - } 16 12 17 13 #[cfg_attr(mobile, tauri::mobile_entry_point)] 18 14 pub fn run() { 19 15 let mut builder = tauri::Builder::default() 16 + .plugin(tauri_plugin_http::init()) 17 + .plugin(tauri_plugin_store::Builder::new().build()) 20 18 .plugin(tauri_plugin_opener::init()) 21 19 .plugin(tauri_plugin_window_state::Builder::new().build()) 22 20 .plugin(tauri_plugin_positioner::init()); ··· 35 33 36 34 builder 37 35 .setup(|app| { 38 - let app_state = AppState::new().expect("failed to initialize application state"); 36 + let store = app.store("config.json")?; 37 + let app_state = AppState::new(store).expect("failed to initialize application state"); 39 38 40 39 app.manage(app_state); 41 40 ··· 69 68 .invoke_handler(tauri::generate_handler![ 70 69 cartesia::commands::start_stt, 71 70 cartesia::commands::stop_stt, 71 + letta::commands::list_agents, 72 + letta::commands::get_config, 73 + letta::commands::update_config, 72 74 secrets::commands::has_secret, 73 75 secrets::commands::set_secret, 74 76 secrets::commands::delete_secret,
+2
src-tauri/src/secrets/mod.rs
··· 7 7 pub enum SecretName { 8 8 #[strum(to_string = "cartesia_api_key")] 9 9 CartesiaApiKey, 10 + #[strum(to_string = "letta_api_key")] 11 + LettaApiKey, 10 12 } 11 13 12 14 const SERVICE_NAME: &'static str = "miwiwi";
+16 -1
src-tauri/src/state.rs
··· 1 1 use std::sync::Arc; 2 2 3 + use tauri::Wry; 4 + use tauri_plugin_http::reqwest::Client; 5 + use tauri_plugin_store::Store; 6 + 3 7 use crate::{ 4 8 cartesia::{client::CartesiaClient, stt::SttManager}, 5 9 devices::{input::InputDeviceManager, output::OutputDeviceManager, types::AudioDeviceError}, 10 + letta::LettaManager, 6 11 secrets::SecretsManager, 7 12 }; 8 13 9 14 pub struct AppState { 10 15 pub cartesia_client: Arc<CartesiaClient>, 11 16 pub stt_manager: Arc<SttManager>, 17 + pub letta_manager: Arc<LettaManager>, 12 18 pub secrets_manager: Arc<SecretsManager>, 13 19 pub input_device_manager: Arc<InputDeviceManager>, 14 20 pub output_device_manager: Arc<OutputDeviceManager>, 15 21 } 16 22 17 23 impl AppState { 18 - pub fn new() -> Result<Self, AudioDeviceError> { 24 + pub fn new(store: Arc<Store<Wry>>) -> Result<Self, AudioDeviceError> { 19 25 let input_device_manager = Arc::new(InputDeviceManager::new()?); 20 26 let output_device_manager = Arc::new(OutputDeviceManager::new()?); 21 27 let secrets_manager = Arc::new(SecretsManager::new()); 28 + 29 + let http_client = Client::new(); 30 + let letta_manager = Arc::new(LettaManager::new( 31 + http_client, 32 + store.clone(), 33 + secrets_manager.clone(), 34 + )); 35 + 22 36 let cartesia_client = Arc::new(CartesiaClient::new(secrets_manager.clone())); 23 37 let stt_manager = Arc::new(SttManager::new( 24 38 cartesia_client.clone(), ··· 29 43 input_device_manager, 30 44 output_device_manager, 31 45 secrets_manager, 46 + letta_manager, 32 47 cartesia_client, 33 48 stt_manager, 34 49 })