Initial commit: Doctor-Patient clinical transcription and structured summary pipeline
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
const fs = require('fs');
|
||||
const dotenv = require('dotenv');
|
||||
dotenv.config();
|
||||
|
||||
async function test() {
|
||||
const ep = 'https://api.sarvam.ai/speech-to-text/job/v1';
|
||||
|
||||
console.log("Creating Job...");
|
||||
let res = await fetch(ep, {
|
||||
method: 'POST',
|
||||
headers: {
|
||||
'api-subscription-key': process.env.SARVAM_API_KEY,
|
||||
'Content-Type': 'application/json'
|
||||
},
|
||||
body: JSON.stringify({
|
||||
files: ["test.wav"],
|
||||
job_parameters: {
|
||||
model: "saaras:v4",
|
||||
with_diarization: true
|
||||
}
|
||||
})
|
||||
});
|
||||
console.log(res.status);
|
||||
let data = await res.json();
|
||||
console.log(JSON.stringify(data, null, 2));
|
||||
}
|
||||
test();
|
||||
Reference in New Issue
Block a user