refactor: simplify AI moderation pipeline to Primary AI only, fix stickerCache executeGet
- Remove Groq and NVIDIA fallback from text moderation pipeline - Remove GROQ_API_KEY, GROQ_MODERATION_*, NVIDIA_NEMOTRON_* config vars - Update source enum: remove 'groq' and 'nvidia' from cache/schema types - Rewrite indonesianTextNormalizer to use Primary AI only (no fallback chain) - Rewrite remote test to test Primary AI only - Fix stickerCache executeGet missing empty params array Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
049fd49737
commit
1bc0b7c7bb
@@ -7,14 +7,10 @@ import {
|
||||
normalizeDiscordCustomEmoji,
|
||||
} from "../../src/moderation/indonesianTextNormalizer";
|
||||
|
||||
const originalNemotronKey = config.NVIDIA_NEMOTRON_API_KEY;
|
||||
const originalPrimaryAiKey = config.AI_LLM_API_KEY;
|
||||
const originalGroqKey = config.GROQ_API_KEY;
|
||||
|
||||
function disableRemoteModeration(): void {
|
||||
config.NVIDIA_NEMOTRON_API_KEY = undefined;
|
||||
config.AI_LLM_API_KEY = undefined;
|
||||
config.GROQ_API_KEY = undefined;
|
||||
}
|
||||
|
||||
disableRemoteModeration();
|
||||
@@ -24,9 +20,7 @@ afterEach(() => {
|
||||
});
|
||||
|
||||
afterAll(() => {
|
||||
config.NVIDIA_NEMOTRON_API_KEY = originalNemotronKey;
|
||||
config.AI_LLM_API_KEY = originalPrimaryAiKey;
|
||||
config.GROQ_API_KEY = originalGroqKey;
|
||||
});
|
||||
|
||||
describe("normalizeDiscordCustomEmoji", () => {
|
||||
|
||||
Reference in New Issue
Block a user