boazchung commited on
Commit
d7cab08
1 Parent(s): 74e6aa1

Update translation.html

Browse files
Files changed (1) hide show
  1. translation.html +0 -29
translation.html CHANGED
@@ -4,15 +4,6 @@
4
  <head>
5
  <meta charset="UTF-8">
6
  <title>Translation - huggingface.js</title>
7
- <!--
8
- <script type="module">
9
- // Import the library
10
- //import { pipeline } from 'https://cdn.jsdelivr.net/npm/@xenova/transformers@2.5.4';
11
-
12
- // Make it available globally
13
- //window.pipeline = pipeline;
14
- </script>
15
- -->
16
  <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.0/dist/css/bootstrap.min.css" rel="stylesheet">
17
  <link rel="stylesheet" href="css/styles.css">
18
  </head>
@@ -108,26 +99,6 @@
108
  console.error("Error during translation:", error);
109
  }
110
  }
111
-
112
-
113
- /*
114
- document.getElementById('hf-form').addEventListener('submit', async (event) => {
115
- event.preventDefault();
116
-
117
-
118
-
119
- // You can also omit "model" to use the recommended model for the task
120
- let result = await hf.translation({
121
- model: 't5-base',
122
- inputs: textFieldValue,
123
- document.getElementById("outputArea2").innerText = JSON.stringify(result, null, 2);
124
- });
125
-
126
- console.log(result);
127
- });
128
-
129
- */
130
- // Initialize the model after the DOM is completely loaded
131
 
132
  window.addEventListener("DOMContentLoaded", (event) => {
133
  initializeModel();
 
4
  <head>
5
  <meta charset="UTF-8">
6
  <title>Translation - huggingface.js</title>
 
 
 
 
 
 
 
 
 
7
  <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.0/dist/css/bootstrap.min.css" rel="stylesheet">
8
  <link rel="stylesheet" href="css/styles.css">
9
  </head>
 
99
  console.error("Error during translation:", error);
100
  }
101
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
102
 
103
  window.addEventListener("DOMContentLoaded", (event) => {
104
  initializeModel();