Files
open-web-agent-rs/assets/index.html
geoffsee 2c46e7b2fc Remove Perigon News integration and related SDK components
The Perigon News integration, SDK, and associated tools were removed from the repository. This includes the agent script, API SDK, and OpenAPI definitions for managing news-related operations. The changes simplify the codebase, eliminating unused or outdated dependencies.
2025-05-27 13:11:52 -04:00

62 lines
1.6 KiB
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Axum Server UI</title>
<style>
body {
font-family: Arial, sans-serif;
margin: 40px;
}
h1 {
color: #333;
}
#output {
margin-top: 20px;
padding: 15px;
border: 1px solid #ddd;
background-color: #f9f9f9;
white-space: pre-wrap;
height: 300px;
overflow-y: auto;
}
input[type="text"] {
width: 60%;
padding: 10px;
font-size: 16px;
}
button {
padding: 11px 20px;
font-size: 16px;
margin-left: 10px;
}
</style>
<script>
async function sendRequest() {
const input = document.getElementById('userInput').value;
const response = await fetch(`/api/agents?resource=web-search&input=${encodeURIComponent(input)}`);
const reader = response.body.getReader();
const decoder = new TextDecoder('utf-8');
let result = '';
const outputDiv = document.getElementById('output');
while (true) {
const {done, value} = await reader.read();
if (done) break;
result += decoder.decode(value);
outputDiv.textContent = result;
}
}
</script>
</head>
<body>
<h1>Axum Server UI</h1>
<input type="text" id="userInput" placeholder="Enter your query here">
<button onclick="sendRequest()">Submit</button>
<div id="output"></div>
</body>
</html>