feat/rich chat output#106
Merged
Merged
Conversation
Patel230
commented
Jul 20, 2026
Contributor
- feat: polish config and chat UI
- refactor(gateway): consolidate eyrie access behind Provider interface
- perf(gateway): cache shared default gateway with sync.Once
- refactor(gateway): split Provider into role interfaces
- test: migrate eyrie imports to gateway boundary
- chore: repin eyrie submodule to neutral-defaults commit
Single gateway package owns all eyrie imports via a hawk-owned Provider interface. Config, routing, and engine wiring delegate through it, giving a swappable provider seam (verified by a stub test), centralized type translation, and one boundary that the audit rules can guard. The submodule pointer moves to the neutral-host-defaults eyrie commit that makes the credential-store default host-neutral.
Stateless model-lookup helpers (DefaultModel, Find, RecommendedModel, ...) previously built a fresh eyrie engine on every call. eyrie's Engine reloads its catalog and provider config from disk on each method call, so a single long-lived gateway returns identical freshness — construct it once. Keeps the defaultGateway(ctx) signature unchanged; ctx still flows through to every data call via the helpers.
Provider is now a composition of 7 role interfaces (Generator, NativeCompactor, ModelCatalog, CredentialManager, SelectionManager, GatewayInspector, CatalogMaintenance). Gateway embeds the roles directly so every existing caller (session_factory, translateProvider, config, routing) keeps working via the composite Provider. Drops 4 unused methods (Resolve, bare Preflight, ApplyGatewayEnvironment, MigrateProviderSecretsContext) that grep confirmed had no callers. provider_stub_test.go now builds Gateway with only the Generator role, proving stubs can depend on a narrow facet.
23 test files now import gateway instead of eyrie directly: - 22 fixture-only files use gateway.SetDefaultStore/MapStore/etc - session_factory_test.go uses gateway.Selection Gateway re-exports the credential test fixtures (SetDefaultStore, DefaultStore, MapStore, AccountForEnv, HasSecret) so tests inject fixtures through the single boundary. 11 genuine keepers stay exempt (they test eyrie itself: engine construction, event translation, Provider stub, catalog/config/registry internals). audit_test.go is a string-literal false positive.
go.mod eyrie pseudo-version now points at cb1efad (the Phase-0 commit that makes the credential-store service name and config-dir default host-neutral). go.sum refreshed. Verified build + test pass both with go.work (local replace) and GOWORK=off (CI/upstream path using the version string).
…icit
- translateProvider now holds only Generator + NativeCompactor (the two
roles it uses) instead of the full Provider.
- Extract the SetServiceName('hawk') side-effect out of New into a
documented, sync.Once-guarded declareHawkIdentity so it is explicit
and runs exactly once.
- Repin eyrie to 637ce7a (adds the legacy provider.json migration).
eyrie changes merged via PR #77 (not the closed neutral-host-defaults PR): host-neutral defaults, provider.json + categories.json legacy migration, poolside adapter. Repin to actual main tip.
# Conflicts: # cmd/chat_config_gateways_test.go # cmd/chat_config_keys_test.go # cmd/chat_config_remove_test.go # cmd/chat_config_tabs_test.go # cmd/chat_config_xiaomi_test.go # cmd/chat_journey_e2e_test.go # cmd/chat_model_test.go # cmd/chat_multiturn_e2e_test.go # cmd/chat_status_test.go # cmd/diagnostics_test.go # cmd/options_welcome_test.go # cmd/path_test.go # cmd/session_sync_test.go # cmd/version_display_test.go # go.mod # go.sum # internal/config/developer_path.go # internal/config/eyrie_engine.go # internal/engine/compact_provider_native.go # internal/engine/session_factory.go # internal/engine/stream.go # internal/provider/gateway/engine_client.go # internal/provider/gateway/gateway.go # internal/provider/gateway/provider_stub_test.go
Patel230
enabled auto-merge (squash)
July 21, 2026 05:41
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.