This commit is contained in:
buzzcode2007 2025-05-08 03:20:11 +00:00
parent ca03f5c5a4
commit 5d8eed54d8

View file

@ -1,17 +1,39 @@
import Tests from './prompt.js';
import { Buffer } from 'buffer';
// Importing modules for simulated data
import fs from 'fs';
class main {
constructor() {
this.platform = new Tests();
this.first();
// this.first()
this.testWithData()
}
first () {
let result = this.platform.generate("gemini-1.5-flash", "What is a TPU?");
result.then((log) => {
console.log(log.text)
})
}
let result = this.platform.generate("gemini-1.5-flash", "What is a TPU?");
result.then((log) => {
console.log(log.text)
})
};
testWithData () {
let results = [];
let files = [{
inlineData: {
mimeType: 'text/csv',
data: Buffer.from(fs.readFileSync("data/test.csv")).toString("base64")
}
}];
let result = this.platform.analyzefile("gemini-1.5-flash", "Please summarize this document. Also, how many unique groups are there? ", files);
result.then((log) => {
console.log(log.text)
})
};
}
let runtime = new main();