diff --git a/oauth/src/components/CommentForm.jsx b/oauth/src/components/CommentForm.jsx index 634d954..50176ac 100644 --- a/oauth/src/components/CommentForm.jsx +++ b/oauth/src/components/CommentForm.jsx @@ -125,7 +125,7 @@ export default function CommentForm({ user, agent, onCommentPosted }) { disabled={loading || !text.trim()} className={`btn ${loading ? 'btn-outline' : 'btn-primary'}`} > - {loading ? 'posting...' : 'post comment'} + {loading ? 'posting...' : 'post'} diff --git a/oauth/src/hooks/useAskAI.js b/oauth/src/hooks/useAskAI.js index c9526d8..34900e0 100644 --- a/oauth/src/hooks/useAskAI.js +++ b/oauth/src/hooks/useAskAI.js @@ -25,8 +25,12 @@ export function useAskAI(adminData, userProfile, agent) { try { logger.log('Sending question to Ollama:', question) + // ユーザー情報を含むシステムプロンプトを構築 + const userInfo = userProfile ? `相手の名前は${userProfile.displayName || userProfile.handle}です。` : '' + const enhancedSystemPrompt = `${aiConfig.systemPrompt} ${userInfo}` + // Ollamaに直接リクエスト送信(oauth_oldと同じ方式) - const prompt = `${aiConfig.systemPrompt} + const prompt = `${enhancedSystemPrompt} Question: ${question}