feat: iddianame-first case summary + remove hardcoded AI endpoint
- summarizeCase: if an iddianame is among the case's documents, run a narrow first-pass analysis on it alone (isnatEdilenSuc, iddiaOzeti, onemliTarihler), then feed that as context into the general case-wide evaluation instead of treating every document equally. - ANALYSIS_SYSTEM_PROMPT no longer asks the AI to guess "taraflar" - that now comes from real UYAP data (cases.parties) instead. - Removed the hardcoded RunPod proxy URL fallback from every call site (document/chat/precedent controllers + lib/openai.ts) - it was a real infra endpoint checked into source. New lib/aiConfig.ts throws if RUNPOD_API_BASE_URL isn't set rather than silently falling back to it. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
af5a03db92
commit
c939dcf564
+5
-5
@@ -15,11 +15,11 @@ dotenv.config();
|
||||
// ----------------------------------------------
|
||||
|
||||
// --- MİZAN (RUNPOD) CONFIGURATION ---
|
||||
const runpodBaseUrl = process.env.RUNPOD_API_BASE_URL || 'https://q190env94stwis-11434.proxy.runpod.net/v1';
|
||||
// Gerçek adresi kod içinde sabit tutmuyoruz (bkz. lib/aiConfig.ts) — sadece env'den okunuyor.
|
||||
const runpodBaseUrl = process.env.RUNPOD_API_BASE_URL ? `${process.env.RUNPOD_API_BASE_URL}/v1` : undefined;
|
||||
const runpodApiKey = process.env.RUNPOD_API_KEY || 'dummy-key';
|
||||
|
||||
export const openai = new OpenAI({
|
||||
baseURL: runpodBaseUrl,
|
||||
apiKey: runpodApiKey,
|
||||
});
|
||||
export const openai = runpodBaseUrl
|
||||
? new OpenAI({ baseURL: runpodBaseUrl, apiKey: runpodApiKey })
|
||||
: null;
|
||||
// ------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user