Based on manvalan/pinscope main. Default LLM is DeepSeek with local skills and PDF ingest. Datasheets are fetched from LCSC/TI, stored in the component library, and review extracts abs-max with a deeper checklist. Adds scripts/update-pinscope.sh for the production host.
37 lines
810 B
Python
37 lines
810 B
Python
"""Provider-agnostic LLM client layer.
|
|
|
|
All model calls in the backend route through this package via the
|
|
``LLMProvider`` interface. The default provider is DeepSeek; per-stage
|
|
overrides via ``Settings.provider_*`` env vars route specific stages to
|
|
Anthropic or Gemini if those keys are configured.
|
|
"""
|
|
|
|
from backend.services.llm.factory import call_with_fallback, get_provider
|
|
from backend.services.llm.types import (
|
|
Completion,
|
|
ContentBlock,
|
|
Message,
|
|
PdfBlock,
|
|
TextBlock,
|
|
ToolCall,
|
|
ToolChoice,
|
|
ToolResultBlock,
|
|
ToolSchema,
|
|
Usage,
|
|
)
|
|
|
|
__all__ = [
|
|
"Completion",
|
|
"ContentBlock",
|
|
"Message",
|
|
"PdfBlock",
|
|
"TextBlock",
|
|
"ToolCall",
|
|
"ToolChoice",
|
|
"ToolResultBlock",
|
|
"ToolSchema",
|
|
"Usage",
|
|
"call_with_fallback",
|
|
"get_provider",
|
|
]
|