stark-engine 4.5.0__tar.gz → 4.5.2__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 (74) hide show
  1. stark_engine-4.5.2/PKG-INFO +175 -0
  2. stark_engine-4.5.2/README.md +138 -0
  3. {stark_engine-4.5.0 → stark_engine-4.5.2}/pyproject.toml +2 -1
  4. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/command.py +7 -0
  5. stark_engine-4.5.0/PKG-INFO +0 -44
  6. stark_engine-4.5.0/README.md +0 -7
  7. {stark_engine-4.5.0 → stark_engine-4.5.2}/LICENSE.md +0 -0
  8. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/__init__.py +0 -0
  9. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/__init__.py +0 -0
  10. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/commands_context.py +0 -0
  11. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/commands_context_processor.py +0 -0
  12. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/commands_manager.py +0 -0
  13. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/health_check.py +0 -0
  14. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/parsing.py +0 -0
  15. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/patterns/__init__.py +0 -0
  16. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/patterns/pattern.py +0 -0
  17. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/patterns/rules.py +0 -0
  18. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/processors/__init__.py +0 -0
  19. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/processors/corrections_processor.py +0 -0
  20. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/processors/search_processor.py +0 -0
  21. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/processors/spacy_ner_processor.py +0 -0
  22. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/__init__.py +0 -0
  23. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/location.py +0 -0
  24. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/object.py +0 -0
  25. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/slots.py +0 -0
  26. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/string.py +0 -0
  27. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/core/types/word.py +0 -0
  28. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/blockage_detector.py +0 -0
  29. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/cache.py +0 -0
  30. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/classproperty.py +0 -0
  31. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/dependencies.py +0 -0
  32. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/feature_flags.py +0 -0
  33. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/json_encoder.py +0 -0
  34. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/__init__.py +0 -0
  35. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/language_code.py +0 -0
  36. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/locale_string.py +0 -0
  37. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/localizable_string.py +0 -0
  38. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/localizer.py +0 -0
  39. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/general/localisation/strings.py +0 -0
  40. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/gcloud.py +0 -0
  41. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/microphone.py +0 -0
  42. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/protocols.py +0 -0
  43. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/recognizer_relay.py +0 -0
  44. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/silero.py +0 -0
  45. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/interfaces/vosk.py +0 -0
  46. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/models/__init__.py +0 -0
  47. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/models/transcription_string.py +0 -0
  48. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/models/voice_transcription.py +0 -0
  49. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/models/voice_transcription_string.py +0 -0
  50. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/common/span.py +0 -0
  51. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/!examples.py +0 -0
  52. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/__init__.py +0 -0
  53. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/dictionary.py +0 -0
  54. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/models.py +0 -0
  55. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/nl_dictionary_name.py +0 -0
  56. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/recognizable_dictionary.py +0 -0
  57. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/storage/__init__.py +0 -0
  58. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/storage/storage_memory.py +0 -0
  59. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/dictionary/storage/storage_sqlite.py +0 -0
  60. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/levenshtein/__init__.py +0 -0
  61. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/levenshtein/levenshtein.pyi +0 -0
  62. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/levenshtein/levenshtein.pyx +0 -0
  63. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/simplephone.py +0 -0
  64. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/__init__.py +0 -0
  65. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/epitran.py +0 -0
  66. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/espeak.py +0 -0
  67. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/ipa2lat.py +0 -0
  68. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/latin_passthrough.py +0 -0
  69. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/phonetic/transcription/protocol.py +0 -0
  70. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/sliding_window_parser.py +0 -0
  71. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/tools/strtools.py +0 -0
  72. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/voice_assistant/__init__.py +0 -0
  73. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/voice_assistant/mode.py +0 -0
  74. {stark_engine-4.5.0 → stark_engine-4.5.2}/stark/voice_assistant/voice_assistant.py +0 -0
@@ -0,0 +1,175 @@
1
+ Metadata-Version: 2.4
2
+ Name: stark-engine
3
+ Version: 4.5.2
4
+ Summary: S.T.A.R.K - Speech and Text Algorithmic Recognition Kit. Modern framework for creating powerfull voice assistants.
5
+ License: CC BY-NC-SA 4.0
6
+ License-File: LICENSE.md
7
+ Keywords: python,open-source,natural-language-processing,framework,cross-platform,natural-language,voice,voice-commands,python3,voice-recognition,speech-recognition,speech-to-text,community-project,voice-assistant,voice-interface,NLP,machine-learning,AI,text-analysis,stark,stark-place,stark-engine,mark parker
8
+ Author: MarkParker5
9
+ Author-email: mark@parker-programs.com
10
+ Requires-Python: >=3.12,<3.15
11
+ Classifier: License :: Other/Proprietary License
12
+ Classifier: Programming Language :: Python :: 3
13
+ Classifier: Programming Language :: Python :: 3.12
14
+ Classifier: Programming Language :: Python :: 3.13
15
+ Classifier: Programming Language :: Python :: 3.14
16
+ Provides-Extra: all
17
+ Provides-Extra: gcloud
18
+ Provides-Extra: silero
19
+ Provides-Extra: sound
20
+ Provides-Extra: spacy
21
+ Provides-Extra: vosk
22
+ Requires-Dist: anyio (>=4.0.0,<5.0.0)
23
+ Requires-Dist: asyncer (>=0.0.8,<1.0.0)
24
+ Requires-Dist: google-cloud-texttospeech (>=2.14.1,<3.0.0) ; extra == "gcloud" or extra == "all"
25
+ Requires-Dist: numpy (>=2.3.3,<3.0.0) ; extra == "silero" or extra == "all"
26
+ Requires-Dist: pydantic (>=2.0.0,<3.0.0)
27
+ Requires-Dist: sounddevice (>=0.4.5,<0.5.0) ; extra == "gcloud" or extra == "vosk" or extra == "silero" or extra == "sound" or extra == "all"
28
+ Requires-Dist: soundfile (>=0.11.0,<0.12.0) ; extra == "gcloud" or extra == "sound" or extra == "all"
29
+ Requires-Dist: spacy (>=3.8.11,<4.0.0) ; extra == "spacy" or extra == "all"
30
+ Requires-Dist: torch (>=1.13.1,<2.0.0) ; extra == "silero" or extra == "all"
31
+ Requires-Dist: vosk (==0.3.44) ; extra == "vosk" or extra == "all"
32
+ Project-URL: Documentation, https://stark.markparker.me
33
+ Project-URL: Homepage, https://pypi.org/project/stark-engine/
34
+ Project-URL: Repository, https://github.com/MarkParker5/STARK
35
+ Description-Content-Type: text/markdown
36
+
37
+ # S.T.A.R.K.
38
+
39
+ **Speech and Text Algorithmic Recognition Kit**: a modern, async Python framework for building voice assistants and natural language interfaces. Think [FastAPI](https://fastapi.tiangolo.com/), but for speech instead of HTTP.
40
+
41
+ No need to build alone. See [Get Involved](#community) below.
42
+
43
+ ## Hello, Stark!
44
+
45
+ ```py
46
+ import anyio
47
+ from stark import run, CommandsManager, Response
48
+ from stark.interfaces.vosk import VoskSpeechRecognizer
49
+ from stark.interfaces.silero import SileroSpeechSynthesizer
50
+
51
+ VOSK_MODEL_URL = '...' # pick one: https://alphacephei.com/vosk/models
52
+ SILERO_MODEL_URL = '...' # pick one: https://github.com/snakers4/silero-models
53
+
54
+ manager = CommandsManager()
55
+
56
+ @manager.new('hello') # 1
57
+ def hello_command() -> Response:
58
+ return Response('Hello, Stark!')
59
+
60
+ async def main():
61
+ recognizer = VoskSpeechRecognizer(model_url=VOSK_MODEL_URL) # 2
62
+ synthesizer = SileroSpeechSynthesizer(model_url=SILERO_MODEL_URL)
63
+ await run(manager, recognizer, synthesizer) # 3
64
+
65
+ if __name__ == '__main__':
66
+ anyio.run(main)
67
+ ```
68
+
69
+ 1. Register a command with `@manager.new(...)`. The string is the pattern STARK matches against what the user says.
70
+ 2. Pick a speech recognizer and synthesizer. STARK ships ready-to-use ones (offline Vosk + Silero here); see [Default Speech Interfaces](https://stark.markparker.me/default-speech-interfaces/).
71
+ 3. `run()` wires everything together and starts listening. This is the whole assistant.
72
+
73
+ That's a complete, working voice assistant: no cloud, no API keys. Want text-only, no microphone needed? See [How to Run](https://stark.markparker.me/how-to-run/).
74
+
75
+ ## Patterns parse parameters too
76
+
77
+ ```py
78
+ @manager.new('hello $name:Word')
79
+ def hello(name: str) -> Response:
80
+ return Response(f'Hello, {name}!')
81
+
82
+ # "hello Mark" -> "Hello, Mark!"
83
+ # "hello Archie" -> "Hello, Archie!"
84
+ ```
85
+
86
+ Patterns aren't fixed phrases. `$name:Word` extracts a parameter and hands it straight to your function, typed and ready to use. See [Patterns](https://stark.markparker.me/patterns/).
87
+
88
+ ## One sentence, multiple commands
89
+
90
+ ```py
91
+ # user says: "turn off the light and play some music"
92
+
93
+ @manager.new('turn off the light')
94
+ def lights_off() -> Response:
95
+ return Response('Lights off.')
96
+
97
+ @manager.new('play (some|the) music')
98
+ def play_music() -> Response:
99
+ return Response('Playing music.')
100
+
101
+ # both commands fire from that single sentence, no extra wiring required
102
+ ```
103
+
104
+ STARK's pattern matcher parses multiple commands out of one utterance on its own, even across two separate phrases stitched together. Most voice assistants still can't do that.
105
+
106
+ ## Background commands
107
+
108
+ ```py
109
+ import anyio
110
+ from stark.core import AsyncResponseHandler
111
+
112
+ timer_cancelled = False
113
+
114
+ @manager.new('start timer')
115
+ async def start_timer(handler: AsyncResponseHandler) -> Response:
116
+ global timer_cancelled
117
+ timer_cancelled = False
118
+ await handler.respond(Response('Timer started.', commands=[stop_timer])) # 1
119
+ for percent in (25, 50, 75, 100):
120
+ await anyio.sleep(15) # 2
121
+ if timer_cancelled:
122
+ return Response('Timer stopped.') # 3
123
+ await handler.respond(Response(f'Timer {percent}% done.'))
124
+ return Response('Timer finished!')
125
+
126
+ @manager.new('stop timer', hidden=True)
127
+ async def stop_timer(handler: AsyncResponseHandler) -> Response:
128
+ global timer_cancelled
129
+ timer_cancelled = True
130
+ handler.pop_context()
131
+ return Response('Stopping timer...')
132
+ ```
133
+
134
+ 1. Responds immediately and offers a `stop timer` command, scoped to this context only. It won't show up anywhere else.
135
+ 2. Keeps running in the background: four checkpoints, 15 seconds apart, a minute total. The assistant is free to handle other input the whole time.
136
+ 3. A plain global flag is enough to cancel it, no extra machinery needed. (If your command needs local state instead of a shared flag, define `stop_timer` inside `start_timer` so it closes over the same variables.)
137
+
138
+ This pattern, immediate response, async progress updates, an optional cancel command, is what powers timers, downloads, or any long-running task. See [Sync vs Async Commands](https://stark.markparker.me/sync-vs-async-commands/#background-commands) and [Commands Context](https://stark.markparker.me/commands-context/).
139
+
140
+ ## Why STARK
141
+
142
+ - **4 required dependencies**: `pydantic`, `asyncer`, `anyio`, `numpy`. Everything else (STT/TTS backends, NLP) is opt-in. See [Installation](https://stark.markparker.me/installation/).
143
+ - **No AI required**: pattern, phonetic, and fuzzy matching are deterministic and fast. LLM integration is opt-in, not a dependency. See [Fallback Command / LLM Integration](https://stark.markparker.me/advanced/fallback-command-llm-integration/) and where this is headed in [AI Agent Platform](https://stark.markparker.me/agent-platform/).
144
+ - **Multilingual by design**: including commands that mix languages mid-sentence.
145
+ - **Phonetic and fuzzy matching**: misspellings, accents, and cross-language name lookup, handled out of the box. See [Tools](https://stark.markparker.me/tools/).
146
+ - **Nested contexts**: multi-level menus, follow-ups, and stateful conversations. See [Commands Context](https://stark.markparker.me/commands-context/).
147
+ - **Background commands & multiple responses**: fire a task, keep listening, get notified as it progresses. See [Sync vs Async Commands](https://stark.markparker.me/sync-vs-async-commands/#background-commands).
148
+ - **Assistant modes**: active, waiting, inactive, sleeping (wake-word), explicit, and external-trigger modes. See [Running Your Assistant](https://stark.markparker.me/running-your-assistant/).
149
+ - **Modular by design**: swap commands, processors, type parsers, or the entire IO layer (voice, text, a [Telegram bot](https://stark.markparker.me/advanced/custom-interfaces/#telegram-bot), your own). See [How to Run](https://stark.markparker.me/how-to-run/).
150
+ - **100% on-device**: runs fully offline, your data stays yours.
151
+
152
+ ## Powered by STARK
153
+
154
+ [Archie](https://majordom.io), the voice assistant built for [MajorDom](https://majordom.io), runs on STARK: nested contexts for device control, multilingual input, fully offline.
155
+
156
+ ## Quick start
157
+
158
+ ```bash
159
+ pip install stark-engine
160
+ ```
161
+
162
+ Full docs, including installation options and extras, at **[stark.markparker.me](https://stark.markparker.me/)**.
163
+
164
+ ## Community
165
+
166
+ - 💬 [Discussions](https://github.com/MarkParker5/STARK/discussions): questions, feedback, showcase what you built. We need all the feedback we can get to make STARK better, so don't be afraid to be first, every thread starts empty.
167
+ - 📦 [STARK-PLACE](https://github.com/MarkParker5/STARK-PLACE): community commands and reference implementations
168
+ - 🐛 [Issues](https://github.com/MarkParker5/STARK/issues): found a bug?
169
+
170
+ ## License
171
+
172
+ The S.T.A.R.K. project is licensed under the [CC BY-NC-SA 4.0 International license](https://github.com/MarkParker5/STARK/tree/master/LICENSE.md). You're welcome to modify, contribute to the repository, create, and share forks. Just remember to attribute the original repository and its creator, abstain from commercial use, and retain the existing license.
173
+
174
+ Want to use STARK commercially, or talk about a partnership? Joint projects, hardware, contract development, anything related. Reach out via [parker-industries.org/partnership](https://parker-industries.org/partnership). We're genuinely open to it.
175
+
@@ -0,0 +1,138 @@
1
+ # S.T.A.R.K.
2
+
3
+ **Speech and Text Algorithmic Recognition Kit**: a modern, async Python framework for building voice assistants and natural language interfaces. Think [FastAPI](https://fastapi.tiangolo.com/), but for speech instead of HTTP.
4
+
5
+ No need to build alone. See [Get Involved](#community) below.
6
+
7
+ ## Hello, Stark!
8
+
9
+ ```py
10
+ import anyio
11
+ from stark import run, CommandsManager, Response
12
+ from stark.interfaces.vosk import VoskSpeechRecognizer
13
+ from stark.interfaces.silero import SileroSpeechSynthesizer
14
+
15
+ VOSK_MODEL_URL = '...' # pick one: https://alphacephei.com/vosk/models
16
+ SILERO_MODEL_URL = '...' # pick one: https://github.com/snakers4/silero-models
17
+
18
+ manager = CommandsManager()
19
+
20
+ @manager.new('hello') # 1
21
+ def hello_command() -> Response:
22
+ return Response('Hello, Stark!')
23
+
24
+ async def main():
25
+ recognizer = VoskSpeechRecognizer(model_url=VOSK_MODEL_URL) # 2
26
+ synthesizer = SileroSpeechSynthesizer(model_url=SILERO_MODEL_URL)
27
+ await run(manager, recognizer, synthesizer) # 3
28
+
29
+ if __name__ == '__main__':
30
+ anyio.run(main)
31
+ ```
32
+
33
+ 1. Register a command with `@manager.new(...)`. The string is the pattern STARK matches against what the user says.
34
+ 2. Pick a speech recognizer and synthesizer. STARK ships ready-to-use ones (offline Vosk + Silero here); see [Default Speech Interfaces](https://stark.markparker.me/default-speech-interfaces/).
35
+ 3. `run()` wires everything together and starts listening. This is the whole assistant.
36
+
37
+ That's a complete, working voice assistant: no cloud, no API keys. Want text-only, no microphone needed? See [How to Run](https://stark.markparker.me/how-to-run/).
38
+
39
+ ## Patterns parse parameters too
40
+
41
+ ```py
42
+ @manager.new('hello $name:Word')
43
+ def hello(name: str) -> Response:
44
+ return Response(f'Hello, {name}!')
45
+
46
+ # "hello Mark" -> "Hello, Mark!"
47
+ # "hello Archie" -> "Hello, Archie!"
48
+ ```
49
+
50
+ Patterns aren't fixed phrases. `$name:Word` extracts a parameter and hands it straight to your function, typed and ready to use. See [Patterns](https://stark.markparker.me/patterns/).
51
+
52
+ ## One sentence, multiple commands
53
+
54
+ ```py
55
+ # user says: "turn off the light and play some music"
56
+
57
+ @manager.new('turn off the light')
58
+ def lights_off() -> Response:
59
+ return Response('Lights off.')
60
+
61
+ @manager.new('play (some|the) music')
62
+ def play_music() -> Response:
63
+ return Response('Playing music.')
64
+
65
+ # both commands fire from that single sentence, no extra wiring required
66
+ ```
67
+
68
+ STARK's pattern matcher parses multiple commands out of one utterance on its own, even across two separate phrases stitched together. Most voice assistants still can't do that.
69
+
70
+ ## Background commands
71
+
72
+ ```py
73
+ import anyio
74
+ from stark.core import AsyncResponseHandler
75
+
76
+ timer_cancelled = False
77
+
78
+ @manager.new('start timer')
79
+ async def start_timer(handler: AsyncResponseHandler) -> Response:
80
+ global timer_cancelled
81
+ timer_cancelled = False
82
+ await handler.respond(Response('Timer started.', commands=[stop_timer])) # 1
83
+ for percent in (25, 50, 75, 100):
84
+ await anyio.sleep(15) # 2
85
+ if timer_cancelled:
86
+ return Response('Timer stopped.') # 3
87
+ await handler.respond(Response(f'Timer {percent}% done.'))
88
+ return Response('Timer finished!')
89
+
90
+ @manager.new('stop timer', hidden=True)
91
+ async def stop_timer(handler: AsyncResponseHandler) -> Response:
92
+ global timer_cancelled
93
+ timer_cancelled = True
94
+ handler.pop_context()
95
+ return Response('Stopping timer...')
96
+ ```
97
+
98
+ 1. Responds immediately and offers a `stop timer` command, scoped to this context only. It won't show up anywhere else.
99
+ 2. Keeps running in the background: four checkpoints, 15 seconds apart, a minute total. The assistant is free to handle other input the whole time.
100
+ 3. A plain global flag is enough to cancel it, no extra machinery needed. (If your command needs local state instead of a shared flag, define `stop_timer` inside `start_timer` so it closes over the same variables.)
101
+
102
+ This pattern, immediate response, async progress updates, an optional cancel command, is what powers timers, downloads, or any long-running task. See [Sync vs Async Commands](https://stark.markparker.me/sync-vs-async-commands/#background-commands) and [Commands Context](https://stark.markparker.me/commands-context/).
103
+
104
+ ## Why STARK
105
+
106
+ - **4 required dependencies**: `pydantic`, `asyncer`, `anyio`, `numpy`. Everything else (STT/TTS backends, NLP) is opt-in. See [Installation](https://stark.markparker.me/installation/).
107
+ - **No AI required**: pattern, phonetic, and fuzzy matching are deterministic and fast. LLM integration is opt-in, not a dependency. See [Fallback Command / LLM Integration](https://stark.markparker.me/advanced/fallback-command-llm-integration/) and where this is headed in [AI Agent Platform](https://stark.markparker.me/agent-platform/).
108
+ - **Multilingual by design**: including commands that mix languages mid-sentence.
109
+ - **Phonetic and fuzzy matching**: misspellings, accents, and cross-language name lookup, handled out of the box. See [Tools](https://stark.markparker.me/tools/).
110
+ - **Nested contexts**: multi-level menus, follow-ups, and stateful conversations. See [Commands Context](https://stark.markparker.me/commands-context/).
111
+ - **Background commands & multiple responses**: fire a task, keep listening, get notified as it progresses. See [Sync vs Async Commands](https://stark.markparker.me/sync-vs-async-commands/#background-commands).
112
+ - **Assistant modes**: active, waiting, inactive, sleeping (wake-word), explicit, and external-trigger modes. See [Running Your Assistant](https://stark.markparker.me/running-your-assistant/).
113
+ - **Modular by design**: swap commands, processors, type parsers, or the entire IO layer (voice, text, a [Telegram bot](https://stark.markparker.me/advanced/custom-interfaces/#telegram-bot), your own). See [How to Run](https://stark.markparker.me/how-to-run/).
114
+ - **100% on-device**: runs fully offline, your data stays yours.
115
+
116
+ ## Powered by STARK
117
+
118
+ [Archie](https://majordom.io), the voice assistant built for [MajorDom](https://majordom.io), runs on STARK: nested contexts for device control, multilingual input, fully offline.
119
+
120
+ ## Quick start
121
+
122
+ ```bash
123
+ pip install stark-engine
124
+ ```
125
+
126
+ Full docs, including installation options and extras, at **[stark.markparker.me](https://stark.markparker.me/)**.
127
+
128
+ ## Community
129
+
130
+ - 💬 [Discussions](https://github.com/MarkParker5/STARK/discussions): questions, feedback, showcase what you built. We need all the feedback we can get to make STARK better, so don't be afraid to be first, every thread starts empty.
131
+ - 📦 [STARK-PLACE](https://github.com/MarkParker5/STARK-PLACE): community commands and reference implementations
132
+ - 🐛 [Issues](https://github.com/MarkParker5/STARK/issues): found a bug?
133
+
134
+ ## License
135
+
136
+ The S.T.A.R.K. project is licensed under the [CC BY-NC-SA 4.0 International license](https://github.com/MarkParker5/STARK/tree/master/LICENSE.md). You're welcome to modify, contribute to the repository, create, and share forks. Just remember to attribute the original repository and its creator, abstain from commercial use, and retain the existing license.
137
+
138
+ Want to use STARK commercially, or talk about a partnership? Joint projects, hardware, contract development, anything related. Reach out via [parker-industries.org/partnership](https://parker-industries.org/partnership). We're genuinely open to it.
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "stark-engine"
3
- version = "4.5.0"
3
+ version = "4.5.2"
4
4
  description = "S.T.A.R.K - Speech and Text Algorithmic Recognition Kit. Modern framework for creating powerfull voice assistants."
5
5
  authors = ["MarkParker5 <mark@parker-programs.com>"]
6
6
  license = "CC BY-NC-SA 4.0"
@@ -87,6 +87,7 @@ faker = "^37.11.0"
87
87
  pympler = "^1.1"
88
88
  psutil = "^7.1.1"
89
89
  trio = "^0.33.0"
90
+ mkdocs-llmstxt = "^0.5.0"
90
91
 
91
92
  [build-system]
92
93
  requires = ["poetry-core"]
@@ -142,6 +142,13 @@ class Response(BaseModel):
142
142
  id: UUID = Field(default_factory=uuid4)
143
143
  time: datetime = Field(default_factory=datetime.now)
144
144
 
145
+ def __init__(self, *args, **kwargs):
146
+ if args:
147
+ kwargs["text"] = args[0]
148
+ if voice := kwargs.get("voice", kwargs.get("text")): # fallback voice to text if text present
149
+ kwargs["voice"] = voice
150
+ super().__init__(**kwargs)
151
+
145
152
  _repeat_last: ClassVar[Response | None] = None # static instance
146
153
 
147
154
  @classproperty
@@ -1,44 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: stark-engine
3
- Version: 4.5.0
4
- Summary: S.T.A.R.K - Speech and Text Algorithmic Recognition Kit. Modern framework for creating powerfull voice assistants.
5
- License: CC BY-NC-SA 4.0
6
- License-File: LICENSE.md
7
- Keywords: python,open-source,natural-language-processing,framework,cross-platform,natural-language,voice,voice-commands,python3,voice-recognition,speech-recognition,speech-to-text,community-project,voice-assistant,voice-interface,NLP,machine-learning,AI,text-analysis,stark,stark-place,stark-engine,mark parker
8
- Author: MarkParker5
9
- Author-email: mark@parker-programs.com
10
- Requires-Python: >=3.12,<3.15
11
- Classifier: License :: Other/Proprietary License
12
- Classifier: Programming Language :: Python :: 3
13
- Classifier: Programming Language :: Python :: 3.12
14
- Classifier: Programming Language :: Python :: 3.13
15
- Classifier: Programming Language :: Python :: 3.14
16
- Provides-Extra: all
17
- Provides-Extra: gcloud
18
- Provides-Extra: silero
19
- Provides-Extra: sound
20
- Provides-Extra: spacy
21
- Provides-Extra: vosk
22
- Requires-Dist: anyio (>=4.0.0,<5.0.0)
23
- Requires-Dist: asyncer (>=0.0.8,<1.0.0)
24
- Requires-Dist: google-cloud-texttospeech (>=2.14.1,<3.0.0) ; extra == "gcloud" or extra == "all"
25
- Requires-Dist: numpy (>=2.3.3,<3.0.0) ; extra == "silero" or extra == "all"
26
- Requires-Dist: pydantic (>=2.0.0,<3.0.0)
27
- Requires-Dist: sounddevice (>=0.4.5,<0.5.0) ; extra == "gcloud" or extra == "vosk" or extra == "silero" or extra == "sound" or extra == "all"
28
- Requires-Dist: soundfile (>=0.11.0,<0.12.0) ; extra == "gcloud" or extra == "sound" or extra == "all"
29
- Requires-Dist: spacy (>=3.8.11,<4.0.0) ; extra == "spacy" or extra == "all"
30
- Requires-Dist: torch (>=1.13.1,<2.0.0) ; extra == "silero" or extra == "all"
31
- Requires-Dist: vosk (==0.3.44) ; extra == "vosk" or extra == "all"
32
- Project-URL: Documentation, https://stark.markparker.me
33
- Project-URL: Homepage, https://pypi.org/project/stark-engine/
34
- Project-URL: Repository, https://github.com/MarkParker5/STARK
35
- Description-Content-Type: text/markdown
36
-
37
- # S.T.A.R.K.
38
-
39
- **Speech and Text Algorithmic Recognition Kit**
40
-
41
- Modern, advanced, and fast framework for creating natural language (especially voice) interfaces. Like [FastAPI](https://fastapi.tiangolo.com/), but with speech instead of http.
42
-
43
- Check [docs](https://stark.markparker.me/) for more information.
44
-
@@ -1,7 +0,0 @@
1
- # S.T.A.R.K.
2
-
3
- **Speech and Text Algorithmic Recognition Kit**
4
-
5
- Modern, advanced, and fast framework for creating natural language (especially voice) interfaces. Like [FastAPI](https://fastapi.tiangolo.com/), but with speech instead of http.
6
-
7
- Check [docs](https://stark.markparker.me/) for more information.
File without changes