Skip to content

Comments

refactor(llm): clean up provider layer — fix leak, deduplicate, optimize#671

Merged
bug-ops merged 1 commit intomainfrom
feat/llm-provider-cleanup
Feb 19, 2026
Merged

refactor(llm): clean up provider layer — fix leak, deduplicate, optimize#671
bug-ops merged 1 commit intomainfrom
feat/llm-provider-cleanup

Conversation

@bug-ops
Copy link
Owner

@bug-ops bug-ops commented Feb 19, 2026

Summary

Net: 14 files changed, +466 -527 lines (all within zeph-llm crate).

Closes #620, #633, #634, #635, #636, #637, #638

Test plan

  • cargo +nightly fmt --check — pass
  • cargo clippy --workspace -- -D warnings — 0 warnings
  • cargo nextest run --workspace --lib --bins — 2016 passed, 9 skipped

@github-actions github-actions bot added documentation Improvements or additions to documentation llm LLM provider related rust refactor size/XL labels Feb 19, 2026
…ize (#620)

Eliminate Box::leak in CompatibleProvider::name() by changing LlmProvider::name()
return type from &'static str to &str. Extract send_with_retry() and SSE stream
helpers to remove duplicated retry/parsing logic across Claude and OpenAI providers.
Replace double AnyProvider clone in embed_fn with Arc, add with_client() builder
for shared reqwest::Client, and cache JsonSchema per TypeId in chat_typed.

Closes #633, #634, #635, #636, #637, #638
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation llm LLM provider related refactor rust size/XL

Projects

None yet

1 participant