lex-llm-anthropic 0.2.28 → 0.3.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c435b967347c36e1eefaad9266a0d819f1862f5f7ab0a0ca8606c25352191657
4
- data.tar.gz: 9f1a21331ee5108e1ed5082a0fb9d91866240d6e4d90fb69b9fb8c19ea6e58c4
3
+ metadata.gz: 2a55d5c398f1718d6cb12d15d3c2aa5c5b5e40216ac1de25119ad5ab36bfc04e
4
+ data.tar.gz: 29f41f8a7d528f3b25055368daa731ed87fb16c64680ae3c6bd7267e33227313
5
5
  SHA512:
6
- metadata.gz: eed3b29603fb58b3b5869d04c0b49239e2039e4b6ba8841da9faa587dda374d44f60ec5535a894b0eada2634211b790cab079a6723f3b9c516c4ee812e068b4e
7
- data.tar.gz: 1d73e364e5773b9c763d6bb433768ddf7bbfc6b3003e347caf9920259ed711009da7fc7369149d2a0d4856ee7a256a2041ee7e1894925a766dc0c757a9e6e402
6
+ metadata.gz: 06a7a0c4e20303cc0fd969c18409e11a3daf88cc3c9b02907b3d3b5fff77cf53b3f04f24b4541d9c49eb879f336d0fdda10767840748c3dfddc405474eb1dc61
7
+ data.tar.gz: ca5ba8689d3ee56ec091a6adcedfd98c9ce37697e8bab4c3e21a0dacd7784ca03071fee2387da41c9fb833e54a7217b60a4d3c9198484f192fa2121c146e6c3a
data/CHANGELOG.md CHANGED
@@ -1,5 +1,104 @@
1
1
  # Changelog
2
2
 
3
+ ## [0.3.4] - 2026-08-18
4
+
5
+ ### Fixed
6
+ - **Synthetic default is claimable** — Removed the discovery skip branch and once-per-boot warning for the synthetic `instances.default` configuration; normal credential validation now decides whether it can be activated.
7
+
8
+ ## [0.3.3] - 2026-08-17
9
+
10
+ ### Changed
11
+ - **SSOT v3 fail-forward instance identity** — `DiscoveryRefresh` now publishes the operator's
12
+ config NAME as the `InstanceKey` `instance_id` (the key the router resolves `instances.<name>`
13
+ settings by); the derived `host:port` / `host:port/ak:<8-char credential digest>` rides along as
14
+ the secondary `physical_id` for dedup and diagnostics only (excluded from InstanceKey
15
+ equality/hash). Two config names on the same endpoint + credential stay distinct instances
16
+ (no collapse). Reserved config names (`default` — the synthetic settings bucket) are skipped at
17
+ the claim boundary with a log instead of raising `ValidationError` every tick.
18
+ - **Embedding models publish authoritative operation evidence** — Models served as the embedding
19
+ class (catalog `type: 'embedding'` or `embed` in the model id) publish `chat: :unsupported`
20
+ (all chat operations unsupported) and `embed: :supported` with `:provider_catalog` source, so a
21
+ plain chat request can never misroute to them; their capability evidence is
22
+ `embedding: :supported` and nothing else (no completion/tools/etc.). Non-embedding models are
23
+ unchanged.
24
+ - **lex-llm floor raised to 0.7.1** — Requires the SSOT v3 inventory foundation with config-name
25
+ `instance_id` + secondary `physical_id` support on `InstanceKey` and the publisher API.
26
+
27
+ ### Fixed
28
+ - **Single actor registration** — The provider module no longer extends Core at file level, so the
29
+ boot-time submodule walk skips it and the gem's own top-level extension load is the sole actor
30
+ registration (eliminates the double-claim / `FencedPublisherError`).
31
+ - **Synthetic-default skip warn now fires once per boot** — The `synthetic_default` skip warning
32
+ (unmodified `instances.default` template) is throttled to once per actor lifetime instead of
33
+ every discovery tick (was permanent WARN noise — an unconfigured provider is the normal state).
34
+
35
+ ## [0.3.2] - 2026-08-13
36
+
37
+ ### Fixed
38
+ - **§1 settings guards removed (R2 pass)** — Eliminated remaining `||` fallbacks on registered
39
+ settings in `Provider#render_payload` (`|| 4096` on `settings[:default_max_tokens]`) and
40
+ `Translator#settings_default_max_tokens` / `#default_thinking_budget` / `#prompt_caching_settings`.
41
+ Registered `default_thinking_budget: 1024` as a canonical default in `Anthropic.default_settings`.
42
+ Replaced `Legion::Settings.dig(...)` + `|| {}` in `Translator#prompt_caching_settings` with direct
43
+ access via the registered default — `Translator#initialize` now seeds `@config` from the
44
+ registered instance defaults so all settings keys are always present without a Settings fallback.
45
+ - **§2 dead second publication engine removed** — Deleted `attr_writer :registry_publisher` and the
46
+ `registry_publisher` class method from `Provider`. The artifact was non-functional (no callers)
47
+ but violated the single-publication-path invariant by keeping the old `RegistryPublisher`
48
+ reachable from the class interface.
49
+
50
+ ## [0.3.1] - 2026-08-13
51
+
52
+ ### Fixed
53
+ - **§8 health firewall** — Removed the connection_failure → :instance_unavailable promotion from
54
+ `AnthropicSsotHarness#apply_anthropic_escalation`. Connection failures, timeouts, 529
55
+ `overloaded_error`, and generic 5xx are all request-local and must never mutate global instance
56
+ availability. Added `AnthropicExplicitUnavailableError` as the explicit service-unavailable signal
57
+ for conformance harness testing; rewrote the firewall assertion to prove `Faraday::ConnectionFailed`
58
+ stays `:connection_failure`, never `:instance_unavailable`.
59
+ - **§9 default model injection removed** — `Translator#render_request` no longer injects
60
+ `'claude-sonnet-4'` when the canonical request carries no model. An omitted model is an empty
61
+ constraint, never a default; the Anthropic API will reject the request if required fields are absent.
62
+ - **§2/§5 second publication engine removed** — `Provider#discover_offerings` no longer calls
63
+ `registry_publisher.publish_models_async`. The SSOT v3 `DiscoveryRefresh` actor is now the only
64
+ publication path. Removed the now-unused `discovery_registry_readiness` private method.
65
+ - **§1 swallowed rescue removed** — Replaced `coordinator&.finish_probe rescue nil` with
66
+ explicit `begin/rescue` that calls `handle_exception` so finish_probe errors are logged and never
67
+ silently swallowed. Removed `# rubocop:disable Style/RescueModifier` inline annotations.
68
+ - **§1 settings guards removed** — Eliminated `||` fallbacks and `.dig` guards on registered
69
+ settings in `DiscoveryRefresh`. Added `discovery_interval: 3600` as a registered default in
70
+ `Anthropic.default_settings`; all settings are now read through the standards-defined access path.
71
+
72
+ ## [0.3.0] - 2026-08-13
73
+
74
+ ### Changed
75
+ - **SSOT v3 provider migration** — Replaced the ScopedRefresher-based `DiscoveryRefresh` actor with a
76
+ full SSOT v3 actor backed by `Legion::Extensions::Llm::Inventory::Publisher`. The actor claims instances,
77
+ discovers models via safe `GET /v1/models` (no inference), runs readiness probing, and publishes complete
78
+ `OfferingDraft` snapshots atomically. Supports tick-based refresh and coalesced reactive probes via
79
+ `ProbeCoordinator` after dispatch-triggered `instance_unavailable` transitions.
80
+ - **`AnthropicCallable`** — New callable wrapper implementing `disconnect` and
81
+ `normalize_dispatch_error(error:)`. Anthropic 529 `overloaded_error` is always `:overloaded`, never
82
+ `:instance_unavailable`. Only transport-layer `ConnectionFailed` maps to `:connection_failure` (which
83
+ the actor harness may escalate). 429 → `:rate_limited`, timeouts → `:timeout`.
84
+ - **Instance identity** — Derived from normalized endpoint host:port + SHA256 8-char credential fingerprint
85
+ (`host:port/ak:XXXXXXXX`). Stable across restarts; deterministic from inputs.
86
+ - **Operations** — chat/stream_chat: supported; embed/image/transcribe/translate/speak/moderate: unsupported;
87
+ count_tokens: unknown. Source evidence: `:provider_implementation` for supported/unsupported,
88
+ `:default_false` for unknown.
89
+ - **Capabilities** — completion/streaming/tools/vision: supported (`:provider_implementation`); thinking:
90
+ unknown (`:default_false` unless model metadata indicates reasoning); embedding: unsupported.
91
+ - **Removed** `DEFAULT_MODEL` constant, `resolve_default_model` method, and `default_model` injection
92
+ from `discover_instances`. No default model or provider in SSOT v3.
93
+ - **Removed** `RegistryEventBuilder` — replaced by the common `Inventory::Publisher`.
94
+ - **Fleet worker** — Added `registry: Legion::Extensions::Llm::Inventory::Registry` kwarg to
95
+ `ProviderResponder.call`.
96
+ - **Gemspec** — Raised `lex-llm` floor to `>= 0.7.0`.
97
+ - **Conformance spec** — Added `spec/legion/extensions/llm/anthropic_ssot_v3_conformance_spec.rb` with
98
+ `AnthropicSsotHarness` and `it_behaves_like 'an SSOT v3 provider adapter'` plus provider-specific
99
+ assertions (identity, 529-always-overloaded, two-instance lane isolation, ProbeCoordinator coalescing,
100
+ no DEFAULT_MODEL, no Legion::LLM reverse dependency).
101
+
3
102
  ## [0.2.28] - 2026-08-04
4
103
 
5
104
  ### Changed
data/Gemfile CHANGED
@@ -2,6 +2,8 @@
2
2
 
3
3
  source 'https://rubygems.org'
4
4
 
5
+ gem 'lex-llm'
6
+
5
7
  gemspec
6
8
 
7
9
  group :development do
@@ -25,7 +25,7 @@ Gem::Specification.new do |spec|
25
25
 
26
26
  spec.add_dependency 'legion-json', '>= 1.2.1'
27
27
  spec.add_dependency 'legion-logging', '>= 1.3.2'
28
- spec.add_dependency 'legion-settings', '>= 1.3.14'
28
+ spec.add_dependency 'legion-settings', '>= 1.4.2'
29
29
  spec.add_dependency 'legion-transport', '>= 1.4.14'
30
- spec.add_dependency 'lex-llm', '>= 0.6.0'
30
+ spec.add_dependency 'lex-llm', '>= 0.7.1'
31
31
  end