Spaces:
Running
Running
Update index.js
Browse files
index.js
CHANGED
@@ -5,9 +5,11 @@ const status = document.getElementById('status');
|
|
5 |
const inputText = document.getElementById('text-field');
|
6 |
const inputSubmitBtn = document.getElementById('submit');
|
7 |
|
|
|
|
|
8 |
// Create a new object detection pipeline
|
9 |
status.textContent = 'Loading model...';
|
10 |
-
const detector = await pipeline(
|
11 |
status.textContent = 'Ready';
|
12 |
|
13 |
inputSubmitBtn.addEventListener('click', async (e) => {
|
|
|
5 |
const inputText = document.getElementById('text-field');
|
6 |
const inputSubmitBtn = document.getElementById('submit');
|
7 |
|
8 |
+
const pipelineConfig = ('token-classification', 'Setosm/bert-finetuned-for-medical-ner');
|
9 |
+
|
10 |
// Create a new object detection pipeline
|
11 |
status.textContent = 'Loading model...';
|
12 |
+
const detector = await pipeline(pipelineConfig);
|
13 |
status.textContent = 'Ready';
|
14 |
|
15 |
inputSubmitBtn.addEventListener('click', async (e) => {
|