refactor: move troubleshoot-agent to agents directory

- Move troubleshoot-agent.ts to src/agents/
- Update import paths in dependent files

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
kappa
2026-02-05 09:43:07 +09:00
parent 4642c1ff94
commit 8f16de40cc
3 changed files with 7 additions and 7 deletions

View File

@@ -14,10 +14,10 @@
* 4. Expected: Session deleted * 4. Expected: Session deleted
*/ */
import type { Env, TroubleshootSession } from './types'; import type { Env, TroubleshootSession } from '../types';
import { createLogger } from './utils/logger'; import { createLogger } from '../utils/logger';
import { executeSearchWeb, executeLookupDocs } from './tools/search-tool'; import { executeSearchWeb, executeLookupDocs } from '../tools/search-tool';
import { TROUBLESHOOT_STATUS } from './constants'; import { TROUBLESHOOT_STATUS } from '../constants';
const logger = createLogger('troubleshoot-agent'); const logger = createLogger('troubleshoot-agent');
@@ -184,7 +184,7 @@ async function callTroubleshootExpertAI(
throw new Error('OPENAI_API_KEY not configured'); throw new Error('OPENAI_API_KEY not configured');
} }
const { getOpenAIUrl } = await import('./utils/api-urls'); const { getOpenAIUrl } = await import('../utils/api-urls');
// Build conversation history // Build conversation history
const conversationHistory = session.messages.map(m => ({ const conversationHistory = session.messages.map(m => ({

View File

@@ -7,7 +7,7 @@ import { metrics } from './utils/metrics';
import { getOpenAIUrl } from './utils/api-urls'; import { getOpenAIUrl } from './utils/api-urls';
import { ERROR_MESSAGES } from './constants/messages'; import { ERROR_MESSAGES } from './constants/messages';
import { getServerSession, processServerConsultation } from './agents/server-agent'; import { getServerSession, processServerConsultation } from './agents/server-agent';
import { getTroubleshootSession, processTroubleshoot } from './troubleshoot-agent'; import { getTroubleshootSession, processTroubleshoot } from './agents/troubleshoot-agent';
import { sendMessage } from './telegram'; import { sendMessage } from './telegram';
const logger = createLogger('openai'); const logger = createLogger('openai');

View File

@@ -35,7 +35,7 @@ export async function executeManageTroubleshoot(
return '🚫 트러블슈팅 기능을 사용할 수 없습니다.'; return '🚫 트러블슈팅 기능을 사용할 수 없습니다.';
} }
const { getTroubleshootSession, saveTroubleshootSession, deleteTroubleshootSession } = await import('../troubleshoot-agent'); const { getTroubleshootSession, saveTroubleshootSession, deleteTroubleshootSession } = await import('../agents/troubleshoot-agent');
if (action === 'cancel') { if (action === 'cancel') {
await deleteTroubleshootSession(env.SESSION_KV, telegramUserId); await deleteTroubleshootSession(env.SESSION_KV, telegramUserId);