spawnllm 0.17.4__tar.gz → 0.17.6__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 (35) hide show
  1. {spawnllm-0.17.4 → spawnllm-0.17.6}/PKG-INFO +2 -2
  2. {spawnllm-0.17.4 → spawnllm-0.17.6}/README.md +1 -1
  3. {spawnllm-0.17.4 → spawnllm-0.17.6}/pyproject.toml +1 -1
  4. {spawnllm-0.17.4 → spawnllm-0.17.6}/pyproject.toml.orig +1 -1
  5. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/_core/__init__.py +8 -2
  6. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/_core/spawnllm_core.wasm +0 -0
  7. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/decide.py +2 -0
  8. {spawnllm-0.17.4 → spawnllm-0.17.6}/LICENSE +0 -0
  9. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/__init__.py +0 -0
  10. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/__main__.py +0 -0
  11. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/__init__.py +0 -0
  12. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/apple.py +0 -0
  13. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/base.py +0 -0
  14. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/claude.py +0 -0
  15. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/claude_sdk.py +0 -0
  16. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/codex.py +0 -0
  17. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/gemini.py +0 -0
  18. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/mlx.py +0 -0
  19. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/openai_endpoint.py +0 -0
  20. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/backends/registry.py +0 -0
  21. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/call.py +0 -0
  22. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/cli.py +0 -0
  23. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/extract.py +0 -0
  24. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/mlx/__init__.py +0 -0
  25. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/mlx/codec.py +0 -0
  26. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/mlx/engine.py +0 -0
  27. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/mlx/fuse.py +0 -0
  28. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/mlx/patches.py +0 -0
  29. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/proc.py +0 -0
  30. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/py.typed +0 -0
  31. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/response.py +0 -0
  32. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/run.py +0 -0
  33. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/spec.py +0 -0
  34. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/structured.py +0 -0
  35. {spawnllm-0.17.4 → spawnllm-0.17.6}/spawnllm/types.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: spawnllm
3
- Version: 0.17.4
3
+ Version: 0.17.6
4
4
  Summary: Delete your subprocess wrappers around claude, codex, and gemini.
5
5
  Keywords:
6
6
  Author: Yasyf Mohamedali
@@ -175,7 +175,7 @@ print(decision.answers["rollback"].p_yes) # 0.99
175
175
  print(decision.answers["action"].choice) # rollback
176
176
  ```
177
177
 
178
- On a warm keep-alive connection from a Mac, a three-question Jev call took 120 to 130 ms end to end. Pass `provider=OPENAI` to ask `gpt-6-luna` instead. Retries cover 408, 429, 5xx, and 529 and stop at `timeout`. Keys come from `TYPESAFE_API_KEY` or `OPENAI_API_KEY`, or on macOS from a Keychain item that `spawnllm key set jev` (or `openai`) writes from stdin.
178
+ On a warm keep-alive connection from a Mac, a three-question Jev call took 120 to 130 ms end to end. Pass `provider=OPENAI` to ask `gpt-6-luna` instead. Retries cover 408, 429, 5xx, and 529 and stop at `timeout`. Keys come from `TYPESAFE_API_KEY` or `OPENAI_API_KEY`, or on macOS from a Keychain item that `spawnllm key set jev` (or `openai`) writes from stdin. Set `TYPESAFE_BASE_URL` to send Jev calls through a gateway such as a Sprites Connector, which supplies the real key in place of a placeholder `TYPESAFE_API_KEY`.
179
179
 
180
180
  ### Call the same backends from Go or Rust
181
181
 
@@ -123,7 +123,7 @@ print(decision.answers["rollback"].p_yes) # 0.99
123
123
  print(decision.answers["action"].choice) # rollback
124
124
  ```
125
125
 
126
- On a warm keep-alive connection from a Mac, a three-question Jev call took 120 to 130 ms end to end. Pass `provider=OPENAI` to ask `gpt-6-luna` instead. Retries cover 408, 429, 5xx, and 529 and stop at `timeout`. Keys come from `TYPESAFE_API_KEY` or `OPENAI_API_KEY`, or on macOS from a Keychain item that `spawnllm key set jev` (or `openai`) writes from stdin.
126
+ On a warm keep-alive connection from a Mac, a three-question Jev call took 120 to 130 ms end to end. Pass `provider=OPENAI` to ask `gpt-6-luna` instead. Retries cover 408, 429, 5xx, and 529 and stop at `timeout`. Keys come from `TYPESAFE_API_KEY` or `OPENAI_API_KEY`, or on macOS from a Keychain item that `spawnllm key set jev` (or `openai`) writes from stdin. Set `TYPESAFE_BASE_URL` to send Jev calls through a gateway such as a Sprites Connector, which supplies the real key in place of a placeholder `TYPESAFE_API_KEY`.
127
127
 
128
128
  ### Call the same backends from Go or Rust
129
129
 
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "spawnllm"
3
- version = "0.17.4"
3
+ version = "0.17.6"
4
4
  description = "Delete your subprocess wrappers around claude, codex, and gemini."
5
5
  readme = "README.md"
6
6
  license = "MIT"
@@ -1,7 +1,7 @@
1
1
  [project]
2
2
  name = "spawnllm"
3
3
  # Inert sentinel: the real version is set from the release tag (uv version --frozen).
4
- version = "0.17.4"
4
+ version = "0.17.6"
5
5
  description = "Delete your subprocess wrappers around claude, codex, and gemini."
6
6
  readme = "README.md"
7
7
  license = "MIT"
@@ -6,6 +6,9 @@ wasmtime-py exposes no in-memory WASI stderr sink, so a panicking core's diagnos
6
6
  are routed to a process-lifetime temp file whose tail is read back into the raised
7
7
  `CoreTrap`. The core builds with panic=abort, so a trap leaves the allocator in an
8
8
  untrustworthy state: the cached runtime is dropped and the next call re-instantiates.
9
+ The engine compiles serially into wasmtime's on-disk code cache, so a process loads the
10
+ machine's one compiled artifact instead of standing up a Cranelift thread pool (one
11
+ thread per core, kept for the process's life) to recompile the blob.
9
12
  """
10
13
 
11
14
  from __future__ import annotations
@@ -91,12 +94,15 @@ def export[T](exports: InstanceExports, name: str, kind: type[T]) -> T:
91
94
 
92
95
 
93
96
  def build() -> Runtime:
94
- from wasmtime import Engine, Func, Linker, Memory, Module, Store, WasiConfig
97
+ from wasmtime import Config, Engine, Func, Linker, Memory, Module, Store, WasiConfig
95
98
 
96
99
  blob = files(__package__).joinpath(WASM_NAME)
97
100
  if not blob.is_file():
98
101
  raise FileNotFoundError(MISSING_BLOB)
99
- engine = Engine()
102
+ config = Config()
103
+ config.parallel_compilation = False
104
+ config.cache = True
105
+ engine = Engine(config)
100
106
  linker = Linker(engine)
101
107
  linker.define_wasi()
102
108
  store = Store(engine)
@@ -47,6 +47,7 @@ TDecideProvider = Literal["jev", "openai"]
47
47
  """A decision provider: TypeSafe's Jev (`jev`) or OpenAI Decisions (`openai`)."""
48
48
 
49
49
  KEY_ENV: dict[TDecideProvider, str] = {"jev": "TYPESAFE_API_KEY", "openai": "OPENAI_API_KEY"}
50
+ JEV_BASE_URL_ENV = "TYPESAFE_BASE_URL"
50
51
  KEY_PATTERN = re.compile(r"[A-Za-z0-9._-]+")
51
52
  DEFAULT_TIMEOUT = 10.0
52
53
 
@@ -356,6 +357,7 @@ class Call:
356
357
  planned = {
357
358
  "provider": {"name": provider.name, "model": provider.model},
358
359
  "api_key": key or api_key(provider, timeout=timeout),
360
+ "base_url": (provider.name == "jev" and os.environ.get(JEV_BASE_URL_ENV)) or None,
359
361
  "state": state,
360
362
  "questions": wired,
361
363
  }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes