VIBN Frontend for Coolify deployment
This commit is contained in:
39
test-gemini-3-simple.js
Normal file
39
test-gemini-3-simple.js
Normal file
@@ -0,0 +1,39 @@
|
||||
const { VertexAI } = require('@google-cloud/vertexai');
|
||||
|
||||
async function testSimple() {
|
||||
console.log('🧪 Testing Gemini 3 Pro Preview (simple text)...\n');
|
||||
|
||||
const vertexAI = new VertexAI({
|
||||
project: 'gen-lang-client-0980079410',
|
||||
location: 'global',
|
||||
});
|
||||
|
||||
try {
|
||||
const model = vertexAI.getGenerativeModel({
|
||||
model: 'gemini-3-pro-preview',
|
||||
generationConfig: { temperature: 1.0 },
|
||||
});
|
||||
|
||||
console.log('⏳ Sending simple text request...\n');
|
||||
|
||||
const response = await model.generateContent({
|
||||
contents: [{
|
||||
role: 'user',
|
||||
parts: [{ text: 'Say "Hello from Gemini 3!" in exactly those words.' }],
|
||||
}],
|
||||
});
|
||||
|
||||
const text = response.response?.candidates?.[0]?.content?.parts?.[0]?.text || 'No response';
|
||||
console.log('✅ Response:', text, '\n');
|
||||
|
||||
if (text.includes('Gemini 3') || text.includes('Hello')) {
|
||||
console.log('🎉 SUCCESS! Gemini 3 Pro Preview is responding!');
|
||||
return true;
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('❌ Full error:', error);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
testSimple();
|
||||
Reference in New Issue
Block a user