انتقل للمحتوى الرئيسي
الإصدار: 1.0.0-beta

إعداد مزود الذكاء الاصطناعي

Configure AI model providers through the Admin UI. Switch between local (Ollama) and cloud (Gemini, OpenAI, Anthropic, DeepSeek) providers without code changes.

الوصولing نماذج الذكاء الاصطناعي Settings​

Navigate to Administration → AI Models.

Adding a Provider​

Step 1 — Click "+ Add Model"​

Step 2 — Select Provider​

ProviderBest ForRequires Internet
OllamaOn-prem, air-gapped, data-sensitive environments❌
GeminiBest overall quality and speed✅
OpenAIGPT-4o for complex reasoning✅
AnthropicClaude for long-context analysis✅
DeepSeekCost-effective alternative✅
CustomAny OpenAI-compatible endpointDepends

Step 3 — Configure​

FieldRequiredDescription
Name✅Display name (e.g., "Gemini Flash")
Provider✅Select from list
Model ID✅Model identifier (e.g., gemini-2.0-flash)
API URL✅Endpoint URL
API KeyDependsRequired for cloud providers
Type✅llm, reasoning, or embedding
System PromptOptionalCustom system instructions
TemperatureOptionalCreativity level (0.0 – 1.0)
Max TokensOptionalMaximum response length

Step 4 — Test Connection​

Click Test Connection to verify:

  • ✅ API endpoint is reachable
  • ✅ API key is valid (for cloud providers)
  • ✅ Model responds to a test prompt
  • ✅ Response time is acceptable

Step 5 — Save​

Click Save. The provider is now available for use.

Provider-Specific Setup​

Ollama (Local / On-Prem)​

Provider: Ollama
API URL: http://localhost:11434
API Key: (leave empty)
Model ID: llama3.1:8b (or your preferred model)

No API key needed. Requires Ollama running locally with models downloaded.

Geدقيقةi​

Provider: Gemini
API URL: https://generativelanguage.googleapis.com
API Key: (your Google AI Studio key)
Model ID: gemini-2.0-flash

مفتوحAI​

Provider: OpenAI
API URL: https://api.openai.com/v1
API Key: (your OpenAI API key)
Model ID: gpt-4o

Anthropic​

Provider: Anthropic
API URL: https://api.anthropic.com
API Key: (your Anthropic API key)
Model ID: claude-sonnet-4-20250514

Security​

  • API keys are encrypted at rest using AES-256-GCM
  • Keys are encrypted using the SECRET_ENCRYPTION_KEY environment variable
  • After saving, keys are displayed as •••••{last 4 chars} — never shown in full
  • Keys are transmitted over TLS only
  • Key rotation: delete and re-add the provider with a new key

Switching افتراضي Provider​

  1. Navigate to Administration → AI Models
  2. Click the ⭐ icon next to the desired provider
  3. The selected provider becomes the default for all AI operations
  4. No code changes needed — routing is automatic

On-Prem / Air-Gapped النشر والتوزيع​

For environments without internet access:

  1. Install Ollama on a local server
  2. Download models offline: ollama pull llama3.1:8b
  3. Configure AIIA to point to the local Ollama instance
  4. All AI features work without internet connectivity