Spaces:
Build error
Build error
Update agent.py
Browse files
agent.py
CHANGED
|
@@ -16,7 +16,6 @@ Action Input:
|
|
| 16 |
align-items: center;
|
| 17 |
padding: 20px;
|
| 18 |
}
|
| 19 |
-
|
| 20 |
#code-input {
|
| 21 |
width: 500px;
|
| 22 |
height: 200px;
|
|
@@ -25,7 +24,6 @@ Action Input:
|
|
| 25 |
border: 1px solid #ccc;
|
| 26 |
resize: vertical;
|
| 27 |
}
|
| 28 |
-
|
| 29 |
#execution-results {
|
| 30 |
margin-top: 10px;
|
| 31 |
padding: 10px;
|
|
@@ -45,19 +43,16 @@ Action Input:
|
|
| 45 |
</form>
|
| 46 |
<div id="execution-results"></div>
|
| 47 |
</div>
|
| 48 |
-
|
| 49 |
<script>
|
| 50 |
const codeForm = document.getElementById('code-form');
|
| 51 |
const codeInput = document.getElementById('code-input');
|
| 52 |
const executionResultsDiv = document.getElementById('execution-results');
|
| 53 |
-
|
| 54 |
codeForm.addEventListener('submit', (event) => {
|
| 55 |
event.preventDefault();
|
| 56 |
executionResultsDiv.innerHTML = "";
|
| 57 |
const code = codeInput.value;
|
| 58 |
const language = "python";
|
| 59 |
const version = "3.8";
|
| 60 |
-
|
| 61 |
try {
|
| 62 |
const result = eval(code);
|
| 63 |
executionResultsDiv.innerHTML = "Execution successful!<br>" + result;
|
|
@@ -275,4 +270,4 @@ RESPONSE
|
|
| 275 |
**************************************
|
| 276 |
{}
|
| 277 |
**************************************
|
| 278 |
-
"""
|
|
|
|
| 16 |
align-items: center;
|
| 17 |
padding: 20px;
|
| 18 |
}
|
|
|
|
| 19 |
#code-input {
|
| 20 |
width: 500px;
|
| 21 |
height: 200px;
|
|
|
|
| 24 |
border: 1px solid #ccc;
|
| 25 |
resize: vertical;
|
| 26 |
}
|
|
|
|
| 27 |
#execution-results {
|
| 28 |
margin-top: 10px;
|
| 29 |
padding: 10px;
|
|
|
|
| 43 |
</form>
|
| 44 |
<div id="execution-results"></div>
|
| 45 |
</div>
|
|
|
|
| 46 |
<script>
|
| 47 |
const codeForm = document.getElementById('code-form');
|
| 48 |
const codeInput = document.getElementById('code-input');
|
| 49 |
const executionResultsDiv = document.getElementById('execution-results');
|
|
|
|
| 50 |
codeForm.addEventListener('submit', (event) => {
|
| 51 |
event.preventDefault();
|
| 52 |
executionResultsDiv.innerHTML = "";
|
| 53 |
const code = codeInput.value;
|
| 54 |
const language = "python";
|
| 55 |
const version = "3.8";
|
|
|
|
| 56 |
try {
|
| 57 |
const result = eval(code);
|
| 58 |
executionResultsDiv.innerHTML = "Execution successful!<br>" + result;
|
|
|
|
| 270 |
**************************************
|
| 271 |
{}
|
| 272 |
**************************************
|
| 273 |
+
"""
|