zeroruntime 0.1.0__tar.gz

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 (92) hide show
  1. zeroruntime-0.1.0/LICENSE +54 -0
  2. zeroruntime-0.1.0/PKG-INFO +128 -0
  3. zeroruntime-0.1.0/README.md +94 -0
  4. zeroruntime-0.1.0/pyproject.toml +93 -0
  5. zeroruntime-0.1.0/setup.cfg +4 -0
  6. zeroruntime-0.1.0/zeroruntime.egg-info/PKG-INFO +128 -0
  7. zeroruntime-0.1.0/zeroruntime.egg-info/SOURCES.txt +90 -0
  8. zeroruntime-0.1.0/zeroruntime.egg-info/dependency_links.txt +1 -0
  9. zeroruntime-0.1.0/zeroruntime.egg-info/entry_points.txt +2 -0
  10. zeroruntime-0.1.0/zeroruntime.egg-info/requires.txt +9 -0
  11. zeroruntime-0.1.0/zeroruntime.egg-info/top_level.txt +1 -0
  12. zeroruntime-0.1.0/zrt/__init__.py +65 -0
  13. zeroruntime-0.1.0/zrt/_cli.py +193 -0
  14. zeroruntime-0.1.0/zrt/_cli_download.py +186 -0
  15. zeroruntime-0.1.0/zrt/_client/__init__.py +1 -0
  16. zeroruntime-0.1.0/zrt/_client/auth.py +122 -0
  17. zeroruntime-0.1.0/zrt/_client/channel.py +343 -0
  18. zeroruntime-0.1.0/zrt/_client/credentials.py +76 -0
  19. zeroruntime-0.1.0/zrt/_client/registry.py +483 -0
  20. zeroruntime-0.1.0/zrt/_client/tool_bridge.py +186 -0
  21. zeroruntime-0.1.0/zrt/_client/translate.py +165 -0
  22. zeroruntime-0.1.0/zrt/_invoke.py +242 -0
  23. zeroruntime-0.1.0/zrt/_log_format.py +72 -0
  24. zeroruntime-0.1.0/zrt/_mcp_client.py +250 -0
  25. zeroruntime-0.1.0/zrt/_plugins/__init__.py +14 -0
  26. zeroruntime-0.1.0/zrt/_plugins/_registry.py +104 -0
  27. zeroruntime-0.1.0/zrt/_plugins/anam.py +43 -0
  28. zeroruntime-0.1.0/zrt/_plugins/anthropic.py +52 -0
  29. zeroruntime-0.1.0/zrt/_plugins/assemblyai.py +51 -0
  30. zeroruntime-0.1.0/zrt/_plugins/aws.py +91 -0
  31. zeroruntime-0.1.0/zrt/_plugins/azure.py +91 -0
  32. zeroruntime-0.1.0/zrt/_plugins/cambai.py +51 -0
  33. zeroruntime-0.1.0/zrt/_plugins/cartesia.py +70 -0
  34. zeroruntime-0.1.0/zrt/_plugins/cerebras.py +49 -0
  35. zeroruntime-0.1.0/zrt/_plugins/cometapi.py +77 -0
  36. zeroruntime-0.1.0/zrt/_plugins/deepgram.py +100 -0
  37. zeroruntime-0.1.0/zrt/_plugins/elevenlabs.py +79 -0
  38. zeroruntime-0.1.0/zrt/_plugins/gladia.py +49 -0
  39. zeroruntime-0.1.0/zrt/_plugins/google.py +132 -0
  40. zeroruntime-0.1.0/zrt/_plugins/groq.py +46 -0
  41. zeroruntime-0.1.0/zrt/_plugins/humeai.py +44 -0
  42. zeroruntime-0.1.0/zrt/_plugins/inworldai.py +51 -0
  43. zeroruntime-0.1.0/zrt/_plugins/lmnt.py +52 -0
  44. zeroruntime-0.1.0/zrt/_plugins/murfai.py +49 -0
  45. zeroruntime-0.1.0/zrt/_plugins/navana.py +44 -0
  46. zeroruntime-0.1.0/zrt/_plugins/neuphonic.py +47 -0
  47. zeroruntime-0.1.0/zrt/_plugins/nvidia.py +68 -0
  48. zeroruntime-0.1.0/zrt/_plugins/openai.py +145 -0
  49. zeroruntime-0.1.0/zrt/_plugins/papla.py +42 -0
  50. zeroruntime-0.1.0/zrt/_plugins/resemble.py +44 -0
  51. zeroruntime-0.1.0/zrt/_plugins/rime.py +53 -0
  52. zeroruntime-0.1.0/zrt/_plugins/rnnoise.py +38 -0
  53. zeroruntime-0.1.0/zrt/_plugins/sarvamai.py +104 -0
  54. zeroruntime-0.1.0/zrt/_plugins/silero.py +60 -0
  55. zeroruntime-0.1.0/zrt/_plugins/simli.py +45 -0
  56. zeroruntime-0.1.0/zrt/_plugins/smallestai.py +56 -0
  57. zeroruntime-0.1.0/zrt/_plugins/speechify.py +48 -0
  58. zeroruntime-0.1.0/zrt/_plugins/ultravox.py +44 -0
  59. zeroruntime-0.1.0/zrt/_plugins/xai.py +106 -0
  60. zeroruntime-0.1.0/zrt/_serve.py +571 -0
  61. zeroruntime-0.1.0/zrt/_spec.py +185 -0
  62. zeroruntime-0.1.0/zrt/_version.py +5 -0
  63. zeroruntime-0.1.0/zrt/_wire/__init__.py +5 -0
  64. zeroruntime-0.1.0/zrt/_wire/zeroruntime_pb2.py +186 -0
  65. zeroruntime-0.1.0/zrt/_wire/zeroruntime_pb2.pyi +910 -0
  66. zeroruntime-0.1.0/zrt/_wire/zeroruntime_pb2_grpc.py +317 -0
  67. zeroruntime-0.1.0/zrt/core/__init__.py +1 -0
  68. zeroruntime-0.1.0/zrt/core/_tasks.py +49 -0
  69. zeroruntime-0.1.0/zrt/core/agent.py +302 -0
  70. zeroruntime-0.1.0/zrt/core/context.py +19 -0
  71. zeroruntime-0.1.0/zrt/core/enums.py +137 -0
  72. zeroruntime-0.1.0/zrt/core/errors.py +44 -0
  73. zeroruntime-0.1.0/zrt/core/events.py +146 -0
  74. zeroruntime-0.1.0/zrt/core/mcp.py +74 -0
  75. zeroruntime-0.1.0/zrt/core/pipeline.py +288 -0
  76. zeroruntime-0.1.0/zrt/core/room.py +322 -0
  77. zeroruntime-0.1.0/zrt/core/session.py +1377 -0
  78. zeroruntime-0.1.0/zrt/core/stt_stream.py +89 -0
  79. zeroruntime-0.1.0/zrt/core/tools.py +199 -0
  80. zeroruntime-0.1.0/zrt/core/transfer.py +160 -0
  81. zeroruntime-0.1.0/zrt/core/tuning.py +119 -0
  82. zeroruntime-0.1.0/zrt/core/utterance.py +47 -0
  83. zeroruntime-0.1.0/zrt/inference/__init__.py +80 -0
  84. zeroruntime-0.1.0/zrt/inference/_registry.py +45 -0
  85. zeroruntime-0.1.0/zrt/inference/denoise.py +44 -0
  86. zeroruntime-0.1.0/zrt/inference/llm.py +48 -0
  87. zeroruntime-0.1.0/zrt/inference/realtime.py +20 -0
  88. zeroruntime-0.1.0/zrt/inference/stt.py +76 -0
  89. zeroruntime-0.1.0/zrt/inference/tts.py +62 -0
  90. zeroruntime-0.1.0/zrt/inference/turn.py +54 -0
  91. zeroruntime-0.1.0/zrt/plugins/__init__.py +134 -0
  92. zeroruntime-0.1.0/zrt/py.typed +0 -0
@@ -0,0 +1,54 @@
1
+ Zeroruntime SDK — Proprietary License
2
+
3
+ Copyright (c) 2026 Zujo Tech Pvt Ltd. All rights reserved.
4
+
5
+ This software, including its source code, object code, and accompanying
6
+ documentation (collectively, the "Software"), is the proprietary and
7
+ confidential property of Zujo Tech Pvt Ltd ("Licensor"). The Software is
8
+ licensed, not sold. No ownership rights are transferred to you. "Zero Runtime"
9
+ and "ZRT" are products and services of Zujo Tech Pvt Ltd.
10
+
11
+ 1. License Grant. Subject to your continued compliance with this License (and
12
+ with any separate written agreement you have entered into with Licensor),
13
+ Licensor grants you a limited, non-exclusive, non-transferable, non-
14
+ sublicensable, revocable license to install and use the Software solely to
15
+ develop and operate applications that connect to and interoperate with the
16
+ Zero Runtime service.
17
+
18
+ 2. Restrictions. Except to the extent expressly permitted in Section 1, by a
19
+ separate written agreement with Licensor, or by applicable law that cannot
20
+ be contractually waived, you may NOT:
21
+ (a) copy, modify, adapt, translate, or create derivative works of the
22
+ Software;
23
+ (b) distribute, publish, sublicense, sell, rent, lease, lend, or
24
+ otherwise make the Software available to any third party;
25
+ (c) reverse engineer, decompile, or disassemble the Software, or attempt
26
+ to derive its source code where not provided;
27
+ (d) use the Software to build or operate a product or service that
28
+ competes with the Zero Runtime service; or
29
+ (e) remove, obscure, or alter any proprietary notices, labels, or marks
30
+ on or in the Software.
31
+
32
+ 3. Ownership. The Software is protected by copyright and other intellectual
33
+ property laws and treaties. Licensor and its licensors retain all right,
34
+ title, and interest in and to the Software, including all intellectual
35
+ property rights therein.
36
+
37
+ 4. Termination. This License is effective until terminated. It terminates
38
+ automatically, without notice, if you breach any of its terms. Upon
39
+ termination you must cease all use of the Software and destroy all copies
40
+ in your possession or control.
41
+
42
+ 5. No Warranty. THE SOFTWARE IS PROVIDED "AS IS" AND "AS AVAILABLE", WITHOUT
43
+ WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
44
+ WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, TITLE, AND
45
+ NONINFRINGEMENT.
46
+
47
+ 6. Limitation of Liability. TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT
48
+ SHALL LICENSOR BE LIABLE FOR ANY INDIRECT, INCIDENTAL, SPECIAL,
49
+ CONSEQUENTIAL, OR PUNITIVE DAMAGES, OR ANY LOSS OF PROFITS, DATA, OR USE,
50
+ ARISING OUT OF OR RELATED TO THIS LICENSE OR THE SOFTWARE, WHETHER IN
51
+ CONTRACT, TORT, OR OTHERWISE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH
52
+ DAMAGES.
53
+
54
+ For licensing inquiries, contact: support@videosdk.live
@@ -0,0 +1,128 @@
1
+ Metadata-Version: 2.4
2
+ Name: zeroruntime
3
+ Version: 0.1.0
4
+ Summary: Build real-time voice agents in Python.
5
+ Author: ZeroRuntime
6
+ License-Expression: LicenseRef-Proprietary
7
+ Project-URL: Homepage, https://github.com/ZeroRuntimeAI/zeroruntime-py
8
+ Project-URL: Repository, https://github.com/ZeroRuntimeAI/zeroruntime-py
9
+ Project-URL: Issues, https://github.com/ZeroRuntimeAI/zeroruntime-py/issues
10
+ Keywords: voice,voice-agents,realtime,speech,stt,tts,llm,grpc
11
+ Classifier: Development Status :: 5 - Production/Stable
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Programming Language :: Python :: 3.14
19
+ Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
20
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
21
+ Classifier: Typing :: Typed
22
+ Requires-Python: >=3.10
23
+ Description-Content-Type: text/markdown
24
+ License-File: LICENSE
25
+ Requires-Dist: grpcio>=1.83.0
26
+ Requires-Dist: protobuf<8.0,>=7.35.1
27
+ Requires-Dist: aiohttp>=3.9.0
28
+ Requires-Dist: python-dotenv>=1.0
29
+ Requires-Dist: mcp>=1.28.0
30
+ Provides-Extra: dev
31
+ Requires-Dist: pytest>=8.0; extra == "dev"
32
+ Requires-Dist: grpcio-tools==1.83.0; extra == "dev"
33
+ Dynamic: license-file
34
+
35
+ # zeroruntime
36
+
37
+ Build real-time voice agents in Python. You describe the agent — instructions,
38
+ tools, and a pipeline of providers — and the runtime runs it.
39
+
40
+ ## Install
41
+
42
+ ```bash
43
+ pip install zeroruntime
44
+ ```
45
+
46
+ or pin the version:
47
+
48
+ ```bash
49
+ pip install zeroruntime==0.1.0
50
+ ```
51
+
52
+ Requires Python 3.10 or newer.
53
+
54
+ Most providers need no extra: their credential is a string you set in the
55
+ environment, so the base install is enough.
56
+
57
+ ## Quickstart
58
+
59
+ ```python
60
+ import zrt
61
+ from zrt import Agent, Pipeline, Room, function_tool
62
+ from zrt.inference import TurnDetector
63
+ from zrt.plugins import CartesiaTTS, DeepgramSTT, GoogleLLM, SileroVAD
64
+
65
+ AGENT_ID = "cascade-basic-agent"
66
+
67
+
68
+ class VoiceAgent(Agent):
69
+ def __init__(self) -> None:
70
+ super().__init__(
71
+ agent_id=AGENT_ID,
72
+ instructions="You are a helpful voice assistant.",
73
+ pipeline=Pipeline(
74
+ stt=DeepgramSTT(),
75
+ llm=GoogleLLM(),
76
+ tts=CartesiaTTS(),
77
+ vad=SileroVAD(),
78
+ turn_detector=TurnDetector(),
79
+ ),
80
+ )
81
+
82
+ async def on_enter(self) -> None:
83
+ await self.session.say("Hello, how can I help you today?")
84
+
85
+ @function_tool
86
+ async def get_weather(self, latitude: str, longitude: str) -> dict:
87
+ """Fetch the current weather for a location.
88
+
89
+ Args:
90
+ latitude: Latitude of the location. Estimate it; do not ask.
91
+ longitude: Longitude of the location. Estimate it; do not ask.
92
+ """
93
+ return {"latitude": latitude, "longitude": longitude, "temperature_c": 28}
94
+
95
+
96
+ def invoke_agent() -> None:
97
+ zrt.invoke(AGENT_ID, room=Room(name="Cascade Agent", playground=True))
98
+
99
+
100
+ if __name__ == "__main__":
101
+ zrt.serve(VoiceAgent, on_ready=invoke_agent)
102
+ ```
103
+
104
+ Run it and the playground URL is printed once, on stdout. Open it to talk to
105
+ the agent.
106
+
107
+ ## Credentials
108
+
109
+ Set your runtime token in the environment before serving:
110
+
111
+ ```bash
112
+ export ZERORUNTIME_AUTH_TOKEN="..."
113
+ ```
114
+
115
+ Vendor keys go in the environment too, one per provider you use — each provider
116
+ names the variable it reads when the key is missing.
117
+
118
+ ## Providers
119
+
120
+ `zrt.plugins` calls the vendor directly with your key on your account.
121
+ `zrt.inference` reaches a subset of the same providers through the runtime
122
+ gateway instead. The names mirror each other, so swapping the import swaps who
123
+ makes the call and who is billed:
124
+
125
+ ```python
126
+ from zrt.plugins import DeepgramSTT # your Deepgram account
127
+ from zrt.inference import DeepgramSTT # through the gateway
128
+ ```
@@ -0,0 +1,94 @@
1
+ # zeroruntime
2
+
3
+ Build real-time voice agents in Python. You describe the agent — instructions,
4
+ tools, and a pipeline of providers — and the runtime runs it.
5
+
6
+ ## Install
7
+
8
+ ```bash
9
+ pip install zeroruntime
10
+ ```
11
+
12
+ or pin the version:
13
+
14
+ ```bash
15
+ pip install zeroruntime==0.1.0
16
+ ```
17
+
18
+ Requires Python 3.10 or newer.
19
+
20
+ Most providers need no extra: their credential is a string you set in the
21
+ environment, so the base install is enough.
22
+
23
+ ## Quickstart
24
+
25
+ ```python
26
+ import zrt
27
+ from zrt import Agent, Pipeline, Room, function_tool
28
+ from zrt.inference import TurnDetector
29
+ from zrt.plugins import CartesiaTTS, DeepgramSTT, GoogleLLM, SileroVAD
30
+
31
+ AGENT_ID = "cascade-basic-agent"
32
+
33
+
34
+ class VoiceAgent(Agent):
35
+ def __init__(self) -> None:
36
+ super().__init__(
37
+ agent_id=AGENT_ID,
38
+ instructions="You are a helpful voice assistant.",
39
+ pipeline=Pipeline(
40
+ stt=DeepgramSTT(),
41
+ llm=GoogleLLM(),
42
+ tts=CartesiaTTS(),
43
+ vad=SileroVAD(),
44
+ turn_detector=TurnDetector(),
45
+ ),
46
+ )
47
+
48
+ async def on_enter(self) -> None:
49
+ await self.session.say("Hello, how can I help you today?")
50
+
51
+ @function_tool
52
+ async def get_weather(self, latitude: str, longitude: str) -> dict:
53
+ """Fetch the current weather for a location.
54
+
55
+ Args:
56
+ latitude: Latitude of the location. Estimate it; do not ask.
57
+ longitude: Longitude of the location. Estimate it; do not ask.
58
+ """
59
+ return {"latitude": latitude, "longitude": longitude, "temperature_c": 28}
60
+
61
+
62
+ def invoke_agent() -> None:
63
+ zrt.invoke(AGENT_ID, room=Room(name="Cascade Agent", playground=True))
64
+
65
+
66
+ if __name__ == "__main__":
67
+ zrt.serve(VoiceAgent, on_ready=invoke_agent)
68
+ ```
69
+
70
+ Run it and the playground URL is printed once, on stdout. Open it to talk to
71
+ the agent.
72
+
73
+ ## Credentials
74
+
75
+ Set your runtime token in the environment before serving:
76
+
77
+ ```bash
78
+ export ZERORUNTIME_AUTH_TOKEN="..."
79
+ ```
80
+
81
+ Vendor keys go in the environment too, one per provider you use — each provider
82
+ names the variable it reads when the key is missing.
83
+
84
+ ## Providers
85
+
86
+ `zrt.plugins` calls the vendor directly with your key on your account.
87
+ `zrt.inference` reaches a subset of the same providers through the runtime
88
+ gateway instead. The names mirror each other, so swapping the import swaps who
89
+ makes the call and who is billed:
90
+
91
+ ```python
92
+ from zrt.plugins import DeepgramSTT # your Deepgram account
93
+ from zrt.inference import DeepgramSTT # through the gateway
94
+ ```
@@ -0,0 +1,93 @@
1
+ [build-system]
2
+ requires = ["setuptools>=77"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "zeroruntime"
7
+ dynamic = ["version"]
8
+ description = "Build real-time voice agents in Python."
9
+ readme = "README.md"
10
+ requires-python = ">=3.10" # dataclasses kw_only; the whole provider layer needs it
11
+ license = "LicenseRef-Proprietary"
12
+
13
+ license-files = ["LICENSE"]
14
+ authors = [{ name = "ZeroRuntime" }]
15
+ keywords = ["voice", "voice-agents", "realtime", "speech", "stt", "tts", "llm", "grpc"]
16
+
17
+ classifiers = [
18
+ "Development Status :: 5 - Production/Stable",
19
+ "Intended Audience :: Developers",
20
+ "Programming Language :: Python :: 3",
21
+ "Programming Language :: Python :: 3.10",
22
+ "Programming Language :: Python :: 3.11",
23
+ "Programming Language :: Python :: 3.12",
24
+ "Programming Language :: Python :: 3.13",
25
+ "Programming Language :: Python :: 3.14",
26
+ "Topic :: Multimedia :: Sound/Audio :: Speech",
27
+ "Topic :: Software Development :: Libraries :: Python Modules",
28
+ "Typing :: Typed",
29
+ ]
30
+
31
+ # The base install describes sessions and carries credentials. It does not run
32
+ # agents: no audio stack, no ML runtime, and -- by construction -- no vendor SDK.
33
+ # Anything added here is installed on every developer laptop that pip installs
34
+ # this package, so the list is closed and tests/test_packaging.py pins it.
35
+ dependencies = [
36
+ # Both floored by the grpcio-tools pin in [dev], and for the same reason:
37
+ # protoc 1.83.0 stamps its own version into the generated code, and a runtime
38
+ # older than the gencode refuses to load on the first wire import. Declaring a
39
+ # lower floor makes the package installable but not usable.
40
+ #
41
+ # zrt/_wire/*_pb2.py ValidateProtobufRuntimeVersion(7, 35, 1)
42
+ # zrt/_wire/*_pb2_grpc.py GRPC_GENERATED_VERSION = '1.83.0'
43
+ #
44
+ # grpcio said >=1.81.0 while the gencode demanded 1.83.0, so an environment
45
+ # holding 1.82.0 resolved happily and then died at `serve()` with "the grpc
46
+ # package installed is at version 1.82.0, but the generated code ... depends
47
+ # on grpcio>=1.83.0". Keep both floors equal to what scripts/gen.py stamped.
48
+ "grpcio>=1.83.0",
49
+ "protobuf>=7.35.1,<8.0",
50
+ "aiohttp>=3.9.0",
51
+ "python-dotenv>=1.0",
52
+ "mcp>=1.28.0",
53
+ ]
54
+
55
+ [project.scripts]
56
+ zrt = "zrt._cli:main"
57
+
58
+ [project.urls]
59
+ Homepage = "https://github.com/ZeroRuntimeAI/zeroruntime-py"
60
+ Repository = "https://github.com/ZeroRuntimeAI/zeroruntime-py"
61
+ Issues = "https://github.com/ZeroRuntimeAI/zeroruntime-py/issues"
62
+
63
+ [project.optional-dependencies]
64
+
65
+ # Not shipped to users. grpcio-tools carries protoc for scripts/gen.py; without
66
+ # it the wire stage of `gen.py --check` reports itself unavailable rather than
67
+ # passing silently.
68
+ #
69
+ # grpcio-tools is pinned exactly, not floored: `gen.py --check` compares
70
+ # generated bytes, and two protoc versions do not agree on them. A floor turns
71
+ # every grpcio-tools release into a red build on a file nobody touched. Moving
72
+ # the pin is a deliberate commit that regenerates zrt/_wire/ alongside it, and
73
+ # the pinned version decides the `protobuf` floor above -- 1.83.0 stamps the
74
+ # gencode as requiring runtime >= 7.35.1.
75
+ dev = [
76
+ "pytest>=8.0",
77
+ "grpcio-tools==1.83.0",
78
+ ]
79
+
80
+ [tool.setuptools.packages.find]
81
+ include = ["zrt*"]
82
+ namespaces = false
83
+
84
+ [tool.setuptools.package-data]
85
+ zrt = ["py.typed"]
86
+
87
+ [tool.setuptools.dynamic]
88
+ # Read statically out of zrt/_version.py. Pointing this at `zrt.__version__`
89
+ # also works but makes the build import the package.
90
+ version = { attr = "zrt._version.__version__" }
91
+
92
+ [tool.pytest.ini_options]
93
+ testpaths = ["tests"]
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,128 @@
1
+ Metadata-Version: 2.4
2
+ Name: zeroruntime
3
+ Version: 0.1.0
4
+ Summary: Build real-time voice agents in Python.
5
+ Author: ZeroRuntime
6
+ License-Expression: LicenseRef-Proprietary
7
+ Project-URL: Homepage, https://github.com/ZeroRuntimeAI/zeroruntime-py
8
+ Project-URL: Repository, https://github.com/ZeroRuntimeAI/zeroruntime-py
9
+ Project-URL: Issues, https://github.com/ZeroRuntimeAI/zeroruntime-py/issues
10
+ Keywords: voice,voice-agents,realtime,speech,stt,tts,llm,grpc
11
+ Classifier: Development Status :: 5 - Production/Stable
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Classifier: Programming Language :: Python :: 3.12
17
+ Classifier: Programming Language :: Python :: 3.13
18
+ Classifier: Programming Language :: Python :: 3.14
19
+ Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
20
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
21
+ Classifier: Typing :: Typed
22
+ Requires-Python: >=3.10
23
+ Description-Content-Type: text/markdown
24
+ License-File: LICENSE
25
+ Requires-Dist: grpcio>=1.83.0
26
+ Requires-Dist: protobuf<8.0,>=7.35.1
27
+ Requires-Dist: aiohttp>=3.9.0
28
+ Requires-Dist: python-dotenv>=1.0
29
+ Requires-Dist: mcp>=1.28.0
30
+ Provides-Extra: dev
31
+ Requires-Dist: pytest>=8.0; extra == "dev"
32
+ Requires-Dist: grpcio-tools==1.83.0; extra == "dev"
33
+ Dynamic: license-file
34
+
35
+ # zeroruntime
36
+
37
+ Build real-time voice agents in Python. You describe the agent — instructions,
38
+ tools, and a pipeline of providers — and the runtime runs it.
39
+
40
+ ## Install
41
+
42
+ ```bash
43
+ pip install zeroruntime
44
+ ```
45
+
46
+ or pin the version:
47
+
48
+ ```bash
49
+ pip install zeroruntime==0.1.0
50
+ ```
51
+
52
+ Requires Python 3.10 or newer.
53
+
54
+ Most providers need no extra: their credential is a string you set in the
55
+ environment, so the base install is enough.
56
+
57
+ ## Quickstart
58
+
59
+ ```python
60
+ import zrt
61
+ from zrt import Agent, Pipeline, Room, function_tool
62
+ from zrt.inference import TurnDetector
63
+ from zrt.plugins import CartesiaTTS, DeepgramSTT, GoogleLLM, SileroVAD
64
+
65
+ AGENT_ID = "cascade-basic-agent"
66
+
67
+
68
+ class VoiceAgent(Agent):
69
+ def __init__(self) -> None:
70
+ super().__init__(
71
+ agent_id=AGENT_ID,
72
+ instructions="You are a helpful voice assistant.",
73
+ pipeline=Pipeline(
74
+ stt=DeepgramSTT(),
75
+ llm=GoogleLLM(),
76
+ tts=CartesiaTTS(),
77
+ vad=SileroVAD(),
78
+ turn_detector=TurnDetector(),
79
+ ),
80
+ )
81
+
82
+ async def on_enter(self) -> None:
83
+ await self.session.say("Hello, how can I help you today?")
84
+
85
+ @function_tool
86
+ async def get_weather(self, latitude: str, longitude: str) -> dict:
87
+ """Fetch the current weather for a location.
88
+
89
+ Args:
90
+ latitude: Latitude of the location. Estimate it; do not ask.
91
+ longitude: Longitude of the location. Estimate it; do not ask.
92
+ """
93
+ return {"latitude": latitude, "longitude": longitude, "temperature_c": 28}
94
+
95
+
96
+ def invoke_agent() -> None:
97
+ zrt.invoke(AGENT_ID, room=Room(name="Cascade Agent", playground=True))
98
+
99
+
100
+ if __name__ == "__main__":
101
+ zrt.serve(VoiceAgent, on_ready=invoke_agent)
102
+ ```
103
+
104
+ Run it and the playground URL is printed once, on stdout. Open it to talk to
105
+ the agent.
106
+
107
+ ## Credentials
108
+
109
+ Set your runtime token in the environment before serving:
110
+
111
+ ```bash
112
+ export ZERORUNTIME_AUTH_TOKEN="..."
113
+ ```
114
+
115
+ Vendor keys go in the environment too, one per provider you use — each provider
116
+ names the variable it reads when the key is missing.
117
+
118
+ ## Providers
119
+
120
+ `zrt.plugins` calls the vendor directly with your key on your account.
121
+ `zrt.inference` reaches a subset of the same providers through the runtime
122
+ gateway instead. The names mirror each other, so swapping the import swaps who
123
+ makes the call and who is billed:
124
+
125
+ ```python
126
+ from zrt.plugins import DeepgramSTT # your Deepgram account
127
+ from zrt.inference import DeepgramSTT # through the gateway
128
+ ```
@@ -0,0 +1,90 @@
1
+ LICENSE
2
+ README.md
3
+ pyproject.toml
4
+ zeroruntime.egg-info/PKG-INFO
5
+ zeroruntime.egg-info/SOURCES.txt
6
+ zeroruntime.egg-info/dependency_links.txt
7
+ zeroruntime.egg-info/entry_points.txt
8
+ zeroruntime.egg-info/requires.txt
9
+ zeroruntime.egg-info/top_level.txt
10
+ zrt/__init__.py
11
+ zrt/_cli.py
12
+ zrt/_cli_download.py
13
+ zrt/_invoke.py
14
+ zrt/_log_format.py
15
+ zrt/_mcp_client.py
16
+ zrt/_serve.py
17
+ zrt/_spec.py
18
+ zrt/_version.py
19
+ zrt/py.typed
20
+ zrt/_client/__init__.py
21
+ zrt/_client/auth.py
22
+ zrt/_client/channel.py
23
+ zrt/_client/credentials.py
24
+ zrt/_client/registry.py
25
+ zrt/_client/tool_bridge.py
26
+ zrt/_client/translate.py
27
+ zrt/_plugins/__init__.py
28
+ zrt/_plugins/_registry.py
29
+ zrt/_plugins/anam.py
30
+ zrt/_plugins/anthropic.py
31
+ zrt/_plugins/assemblyai.py
32
+ zrt/_plugins/aws.py
33
+ zrt/_plugins/azure.py
34
+ zrt/_plugins/cambai.py
35
+ zrt/_plugins/cartesia.py
36
+ zrt/_plugins/cerebras.py
37
+ zrt/_plugins/cometapi.py
38
+ zrt/_plugins/deepgram.py
39
+ zrt/_plugins/elevenlabs.py
40
+ zrt/_plugins/gladia.py
41
+ zrt/_plugins/google.py
42
+ zrt/_plugins/groq.py
43
+ zrt/_plugins/humeai.py
44
+ zrt/_plugins/inworldai.py
45
+ zrt/_plugins/lmnt.py
46
+ zrt/_plugins/murfai.py
47
+ zrt/_plugins/navana.py
48
+ zrt/_plugins/neuphonic.py
49
+ zrt/_plugins/nvidia.py
50
+ zrt/_plugins/openai.py
51
+ zrt/_plugins/papla.py
52
+ zrt/_plugins/resemble.py
53
+ zrt/_plugins/rime.py
54
+ zrt/_plugins/rnnoise.py
55
+ zrt/_plugins/sarvamai.py
56
+ zrt/_plugins/silero.py
57
+ zrt/_plugins/simli.py
58
+ zrt/_plugins/smallestai.py
59
+ zrt/_plugins/speechify.py
60
+ zrt/_plugins/ultravox.py
61
+ zrt/_plugins/xai.py
62
+ zrt/_wire/__init__.py
63
+ zrt/_wire/zeroruntime_pb2.py
64
+ zrt/_wire/zeroruntime_pb2.pyi
65
+ zrt/_wire/zeroruntime_pb2_grpc.py
66
+ zrt/core/__init__.py
67
+ zrt/core/_tasks.py
68
+ zrt/core/agent.py
69
+ zrt/core/context.py
70
+ zrt/core/enums.py
71
+ zrt/core/errors.py
72
+ zrt/core/events.py
73
+ zrt/core/mcp.py
74
+ zrt/core/pipeline.py
75
+ zrt/core/room.py
76
+ zrt/core/session.py
77
+ zrt/core/stt_stream.py
78
+ zrt/core/tools.py
79
+ zrt/core/transfer.py
80
+ zrt/core/tuning.py
81
+ zrt/core/utterance.py
82
+ zrt/inference/__init__.py
83
+ zrt/inference/_registry.py
84
+ zrt/inference/denoise.py
85
+ zrt/inference/llm.py
86
+ zrt/inference/realtime.py
87
+ zrt/inference/stt.py
88
+ zrt/inference/tts.py
89
+ zrt/inference/turn.py
90
+ zrt/plugins/__init__.py
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ zrt = zrt._cli:main
@@ -0,0 +1,9 @@
1
+ grpcio>=1.83.0
2
+ protobuf<8.0,>=7.35.1
3
+ aiohttp>=3.9.0
4
+ python-dotenv>=1.0
5
+ mcp>=1.28.0
6
+
7
+ [dev]
8
+ pytest>=8.0
9
+ grpcio-tools==1.83.0
@@ -0,0 +1,65 @@
1
+ from __future__ import annotations
2
+
3
+ import importlib
4
+ from typing import Any
5
+
6
+ from ._version import __version__
7
+
8
+ _LAZY: dict[str, tuple[str, str]] = {
9
+ "Agent": ("zrt.core.agent", "Agent"),
10
+ "AgentContext": ("zrt.core.context", "AgentContext"),
11
+ "BackgroundAudio": ("zrt.core.agent", "BackgroundAudio"),
12
+ "CallSummary": ("zrt.core.agent", "CallSummary"),
13
+ "Pipeline": ("zrt.core.pipeline", "Pipeline"),
14
+ "NO_CHANGE": ("zrt.core.pipeline", "NO_CHANGE"),
15
+ "EOUConfig": ("zrt.core.tuning", "EOUConfig"),
16
+ "InterruptConfig": ("zrt.core.tuning", "InterruptConfig"),
17
+ "function_tool": ("zrt.core.tools", "function_tool"),
18
+ "MCPServerStdio": ("zrt.core.mcp", "MCPServerStdio"),
19
+ "MCPServerHTTP": ("zrt.core.mcp", "MCPServerHTTP"),
20
+ "SIPDestination": ("zrt.core.transfer", "SIPDestination"),
21
+ "WarmTransferConfig": ("zrt.core.transfer", "WarmTransferConfig"),
22
+ "WarmTransferPhase": ("zrt.core.transfer", "WarmTransferPhase"),
23
+ "WarmTransferResult": ("zrt.core.transfer", "WarmTransferResult"),
24
+ "run_stt": ("zrt.core.stt_stream", "run_stt"),
25
+ "Room": ("zrt.core.room", "Room"),
26
+ "UNSET": ("zrt.core.room", "UNSET"),
27
+ "Sip": ("zrt.core.room", "Sip"),
28
+ "Observability": ("zrt.core.room", "Observability"),
29
+ "Exporter": ("zrt.core.room", "Exporter"),
30
+ "Session": ("zrt.core.session", "Session"),
31
+ "UtteranceHandle": ("zrt.core.utterance", "UtteranceHandle"),
32
+ "PronunciationRule": ("zrt.core.pipeline", "PronunciationRule"),
33
+ "ContextWindow": ("zrt.core.pipeline", "ContextWindow"),
34
+ "RoomMessage": ("zrt.core.session", "RoomMessage"),
35
+ "Participant": ("zrt.core.session", "Participant"),
36
+ "serve": ("zrt._serve", "serve"),
37
+ "invoke": ("zrt._invoke", "invoke"),
38
+ "ZeroRuntimeChannel": ("zrt._client.channel", "ZeroRuntimeChannel"),
39
+ "ZrtError": ("zrt.core.errors", "ZrtError"),
40
+ "SessionRejected": ("zrt.core.errors", "SessionRejected"),
41
+ "ProviderUnavailable": ("zrt.core.errors", "ProviderUnavailable"),
42
+ "ZeroRuntimeUnreachable": ("zrt.core.errors", "ZeroRuntimeUnreachable"),
43
+ "ToolTimeout": ("zrt.core.errors", "ToolTimeout"),
44
+ "AgentState": ("zrt.core.enums", "AgentState"),
45
+ "UserState": ("zrt.core.enums", "UserState"),
46
+ "PipelineMode": ("zrt.core.enums", "PipelineMode"),
47
+ "ChatRole": ("zrt.core.enums", "ChatRole"),
48
+ }
49
+
50
+
51
+ def __getattr__(name: str) -> Any:
52
+ try:
53
+ module, attr = _LAZY[name]
54
+ except KeyError:
55
+ raise AttributeError(f"module 'zrt' has no attribute {name!r}") from None
56
+ value = getattr(importlib.import_module(module), attr)
57
+ globals()[name] = value
58
+ return value
59
+
60
+
61
+ def __dir__() -> list[str]:
62
+ return sorted(_LAZY)
63
+
64
+
65
+ __all__ = [*sorted(_LAZY), "__version__"]