Download index.html from moosee/teste: direct link, hf CLI and curl.
- Browser
- Download file 18.5 kB
-
https://huggingface.co/spaces/moosee/teste/resolve/main/index.html
- Command line
-
hf download hf://spaces/moosee/teste/index.html
-
curl -L -o index.html https://huggingface.co/spaces/moosee/teste/resolve/main/index.html
18.5 kB
| <html lang="pt-BR"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Análise Sentimental de Ações B3</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> | |
| <style> | |
| .gradient-bg { | |
| background: linear-gradient(135deg, #1e3a8a 0%, #0ea5e9 100%); | |
| } | |
| .pulse-animation { | |
| animation: pulse 2s infinite; | |
| } | |
| @keyframes pulse { | |
| 0% { transform: scale(1); } | |
| 50% { transform: scale(1.05); } | |
| 100% { transform: scale(1); } | |
| } | |
| .sentiment-positive { | |
| background-color: #10b981; | |
| } | |
| .sentiment-neutral { | |
| background-color: #f59e0b; | |
| } | |
| .sentiment-negative { | |
| background-color: #ef4444; | |
| } | |
| </style> | |
| </head> | |
| <body class="bg-gray-100 min-h-screen"> | |
| <div class="gradient-bg text-white py-8 px-4 shadow-lg"> | |
| <div class="container mx-auto"> | |
| <div class="flex items-center justify-between"> | |
| <div> | |
| <h1 class="text-3xl font-bold">StockSense B3</h1> | |
| <p class="mt-2">Análise sentimental simplificada para investidores</p> | |
| </div> | |
| <div class="bg-white/20 p-3 rounded-full"> | |
| <i class="fas fa-chart-line text-2xl"></i> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="container mx-auto px-4 py-8 -mt-10"> | |
| <div class="bg-white rounded-xl shadow-lg p-6 max-w-4xl mx-auto"> | |
| <div class="flex flex-col md:flex-row gap-6"> | |
| <div class="flex-1"> | |
| <h2 class="text-2xl font-bold text-gray-800 mb-4">Analisar Ação</h2> | |
| <p class="text-gray-600 mb-6">Digite o código da ação da B3 para receber uma análise sentimental completa em linguagem simples.</p> | |
| <div class="relative"> | |
| <input type="text" id="stockInput" placeholder="Ex: PETR4, VALE3, ITUB4..." | |
| class="w-full px-4 py-3 border border-gray-300 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500"> | |
| <button id="analyzeBtn" class="absolute right-2 top-1/2 transform -translate-y-1/2 bg-blue-600 text-white px-4 py-2 rounded-lg hover:bg-blue-700 transition"> | |
| Analisar <i class="fas fa-search ml-2"></i> | |
| </button> | |
| </div> | |
| <div class="mt-4 flex items-center text-sm text-gray-500"> | |
| <i class="fas fa-info-circle mr-2"></i> | |
| <span>Exemplos populares: PETR4, VALE3, BBDC4, ITUB4</span> | |
| </div> | |
| </div> | |
| <div class="md:w-1/3 bg-gray-50 rounded-lg p-4 flex flex-col items-center justify-center"> | |
| <div class="w-16 h-16 bg-blue-100 rounded-full flex items-center justify-center mb-3"> | |
| <i class="fas fa-bolt text-blue-600 text-2xl"></i> | |
| </div> | |
| <h3 class="font-semibold text-center">Análise em 3 Passos</h3> | |
| <ol class="mt-3 space-y-2 text-sm text-gray-600"> | |
| <li class="flex items-start"> | |
| <span class="bg-blue-600 text-white rounded-full w-5 h-5 flex items-center justify-center text-xs mr-2">1</span> | |
| <span>Sentimento do mercado</span> | |
| </li> | |
| <li class="flex items-start"> | |
| <span class="bg-blue-600 text-white rounded-full w-5 h-5 flex items-center justify-center text-xs mr-2">2</span> | |
| <span>Análise técnica simplificada</span> | |
| </li> | |
| <li class="flex items-start"> | |
| <span class="bg-blue-600 text-white rounded-full w-5 h-5 flex items-center justify-center text-xs mr-2">3</span> | |
| <span>Recomendação clara</span> | |
| </li> | |
| </ol> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div id="resultsSection" class="container mx-auto px-4 py-8 hidden"> | |
| <div class="bg-white rounded-xl shadow-lg p-6 max-w-4xl mx-auto"> | |
| <div class="flex justify-between items-start mb-6"> | |
| <div> | |
| <h2 class="text-2xl font-bold text-gray-800"> | |
| <span id="stockSymbol" class="bg-blue-100 text-blue-800 px-3 py-1 rounded-lg">PETR4</span> | |
| <span id="stockName" class="ml-2">Petróleo Brasileiro S.A.</span> | |
| </h2> | |
| <div class="flex items-center mt-2"> | |
| <span id="currentPrice" class="text-2xl font-bold">R$ 32,15</span> | |
| <span id="priceChange" class="ml-3 px-2 py-1 rounded text-sm font-medium bg-red-100 text-red-800">-1,2%</span> | |
| </div> | |
| </div> | |
| <div id="sentimentBadge" class="px-4 py-2 rounded-full text-white font-medium sentiment-neutral"> | |
| Neutro | |
| </div> | |
| </div> | |
| <div class="grid md:grid-cols-3 gap-6 mb-8"> | |
| <div class="bg-gray-50 p-4 rounded-lg"> | |
| <h3 class="font-semibold text-gray-700 mb-2 flex items-center"> | |
| <i class="fas fa-comments mr-2 text-blue-500"></i> Sentimento Geral | |
| </h3> | |
| <p id="generalSentiment" class="text-gray-600">O mercado está dividido sobre esta ação, com análises neutras predominando.</p> | |
| </div> | |
| <div class="bg-gray-50 p-4 rounded-lg"> | |
| <h3 class="font-semibold text-gray-700 mb-2 flex items-center"> | |
| <i class="fas fa-chart-bar mr-2 text-blue-500"></i> Tendência Técnica | |
| </h3> | |
| <p id="technicalTrend" class="text-gray-600">A ação está em uma fase de consolidação após queda recente.</p> | |
| </div> | |
| <div class="bg-gray-50 p-4 rounded-lg"> | |
| <h3 class="font-semibold text-gray-700 mb-2 flex items-center"> | |
| <i class="fas fa-lightbulb mr-2 text-blue-500"></i> Recomendação | |
| </h3> | |
| <p id="recommendation" class="text-gray-600">Aguardar melhores oportunidades de entrada.</p> | |
| </div> | |
| </div> | |
| <h3 class="text-lg font-semibold text-gray-800 mb-3">Análise Detalhada</h3> | |
| <div id="detailedAnalysis" class="bg-gray-50 p-4 rounded-lg mb-6"> | |
| <p>A ação <span class="font-medium">PETR4</span> apresenta um momento de indecisão no mercado. Nos últimos 15 dias, o volume negociado ficou 12% abaixo da média histórica, indicando cautela dos investidores.</p> | |
| <p class="mt-3">Analistas apontam que o preço do petróleo e a política de dividendos são os principais fatores que estão influenciando o sentimento no momento. Recomenda-se acompanhar os próximos balanços trimestrais.</p> | |
| </div> | |
| <div class="border-t pt-4"> | |
| <h3 class="text-lg font-semibold text-gray-800 mb-3">Fatores Chave</h3> | |
| <div class="space-y-3"> | |
| <div class="flex items-start"> | |
| <div class="flex-shrink-0 h-5 w-5 text-green-500 mt-1"> | |
| <i class="fas fa-check-circle"></i> | |
| </div> | |
| <div class="ml-3"> | |
| <p class="text-sm font-medium text-gray-900">Setor em recuperação</p> | |
| <p class="text-sm text-gray-500">O setor de energia tem mostrado sinais de melhora nos últimos meses.</p> | |
| </div> | |
| </div> | |
| <div class="flex items-start"> | |
| <div class="flex-shrink-0 h-5 w-5 text-red-500 mt-1"> | |
| <i class="fas fa-exclamation-circle"></i> | |
| </div> | |
| <div class="ml-3"> | |
| <p class="text-sm font-medium text-gray-900">Pressão regulatória</p> | |
| <p class="text-sm text-gray-500">Novas regulamentações podem impactar os resultados.</p> | |
| </div> | |
| </div> | |
| <div class="flex items-start"> | |
| <div class="flex-shrink-0 h-5 w-5 text-yellow-500 mt-1"> | |
| <i class="fas fa-info-circle"></i> | |
| </div> | |
| <div class="ml-3"> | |
| <p class="text-sm font-medium text-gray-900">Dividendos estáveis</p> | |
| <p class="text-sm text-gray-500">Histórico de pagamento de dividendos acima da média do mercado.</p> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="mt-6 flex justify-between items-center"> | |
| <button id="newAnalysisBtn" class="px-4 py-2 border border-gray-300 rounded-lg text-gray-700 hover:bg-gray-50"> | |
| <i class="fas fa-redo mr-2"></i> Nova Análise | |
| </button> | |
| <div class="text-sm text-gray-500"> | |
| <i class="fas fa-clock mr-1"></i> Atualizado em <span id="updateTime">05/07/2023 15:42</span> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="bg-gray-800 text-white py-8 mt-12"> | |
| <div class="container mx-auto px-4"> | |
| <div class="flex flex-col md:flex-row justify-between"> | |
| <div class="mb-6 md:mb-0"> | |
| <h3 class="text-xl font-bold mb-4">StockSense B3</h3> | |
| <p class="text-gray-400">Análises simplificadas para investidores de todos os níveis.</p> | |
| </div> | |
| <div> | |
| <h4 class="text-lg font-semibold mb-3">Aprenda mais</h4> | |
| <ul class="space-y-2"> | |
| <li><a href="#" class="text-gray-400 hover:text-white">Termos de Uso</a></li> | |
| <li><a href="#" class="text-gray-400 hover:text-white">Política de Privacidade</a></li> | |
| <li><a href="#" class="text-gray-400 hover:text-white">Dúvidas Frequentes</a></li> | |
| </ul> | |
| </div> | |
| </div> | |
| <div class="mt-8 pt-6 border-t border-gray-700 text-center text-gray-400 text-sm"> | |
| <p>© 2023 StockSense B3. Este site não oferece recomendações de investimento.</p> | |
| </div> | |
| </div> | |
| </div> | |
| <script> | |
| document.addEventListener('DOMContentLoaded', function() { | |
| const analyzeBtn = document.getElementById('analyzeBtn'); | |
| const stockInput = document.getElementById('stockInput'); | |
| const resultsSection = document.getElementById('resultsSection'); | |
| const newAnalysisBtn = document.getElementById('newAnalysisBtn'); | |
| // Sample stock data (in a real app, this would come from an API) | |
| const stockDatabase = { | |
| 'PETR4': { | |
| name: 'Petróleo Brasileiro S.A.', | |
| price: 32.15, | |
| change: -1.2, | |
| sentiment: 'neutral', | |
| generalSentiment: 'O mercado está dividido sobre esta ação, com análises neutras predominando.', | |
| technicalTrend: 'A ação está em uma fase de consolidação após queda recente.', | |
| recommendation: 'Aguardar melhores oportunidades de entrada.', | |
| detailedAnalysis: 'A ação PETR4 apresenta um momento de indecisão no mercado. Nos últimos 15 dias, o volume negociado ficou 12% abaixo da média histórica, indicando cautela dos investidores. Analistas apontam que o preço do petróleo e a política de dividendos são os principais fatores que estão influenciando o sentimento no momento. Recomenda-se acompanhar os próximos balanços trimestrais.' | |
| }, | |
| 'VALE3': { | |
| name: 'Vale S.A.', | |
| price: 68.90, | |
| change: 2.3, | |
| sentiment: 'positive', | |
| generalSentiment: 'Sentimento positivo devido à alta no preço do minério de ferro.', | |
| technicalTrend: 'Tendência de alta com volume crescente.', | |
| recommendation: 'Pode ser uma boa oportunidade de compra.', | |
| detailedAnalysis: 'A VALE3 tem se beneficiado do aumento nos preços internacionais do minério de ferro. A demanda chinesa e a recuperação da indústria global estão impulsionando os resultados. O último trimestre mostrou crescimento nos lucros e os analistas estão revisando suas projeções para cima.' | |
| }, | |
| 'ITUB4': { | |
| name: 'Itaú Unibanco Holding S.A.', | |
| price: 27.45, | |
| change: -0.5, | |
| sentiment: 'negative', | |
| generalSentiment: 'Preocupações com aumento da inadimplência afetam o sentimento.', | |
| technicalTrend: 'Testando suporte importante após queda.', | |
| recommendation: 'Cautela até novo sinal de reversão.', | |
| detailedAnalysis: 'O setor bancário está sob pressão devido ao aumento nas taxas de inadimplência. O ITUB4, apesar de ser um dos bancos mais sólidos, não está imune a esse movimento. Os resultados do próximo trimestre serão cruciais para determinar se a queda é momentânea ou o início de uma tendência mais prolongada.' | |
| } | |
| }; | |
| analyzeBtn.addEventListener('click', function() { | |
| const stockCode = stockInput.value.trim().toUpperCase(); | |
| if (stockCode === '') { | |
| alert('Por favor, digite o código de uma ação.'); | |
| return; | |
| } | |
| if (!stockDatabase[stockCode]) { | |
| alert('Ação não encontrada em nossa base de dados. Tente PETR4, VALE3 ou ITUB4.'); | |
| return; | |
| } | |
| // Display results | |
| displayStockAnalysis(stockCode); | |
| }); | |
| stockInput.addEventListener('keypress', function(e) { | |
| if (e.key === 'Enter') { | |
| analyzeBtn.click(); | |
| } | |
| }); | |
| newAnalysisBtn.addEventListener('click', function() { | |
| resultsSection.classList.add('hidden'); | |
| stockInput.value = ''; | |
| stockInput.focus(); | |
| }); | |
| function displayStockAnalysis(stockCode) { | |
| const stock = stockDatabase[stockCode]; | |
| const now = new Date(); | |
| // Update UI with stock data | |
| document.getElementById('stockSymbol').textContent = stockCode; | |
| document.getElementById('stockName').textContent = stock.name; | |
| document.getElementById('currentPrice').textContent = `R$ ${stock.price.toFixed(2).replace('.', ',')}`; | |
| const changeElement = document.getElementById('priceChange'); | |
| changeElement.textContent = `${stock.change > 0 ? '+' : ''}${stock.change.toFixed(1).replace('.', ',')}%`; | |
| changeElement.className = `ml-3 px-2 py-1 rounded text-sm font-medium ${ | |
| stock.change > 0 ? 'bg-green-100 text-green-800' : 'bg-red-100 text-red-800' | |
| }`; | |
| // Update sentiment | |
| const sentimentBadge = document.getElementById('sentimentBadge'); | |
| sentimentBadge.className = `px-4 py-2 rounded-full text-white font-medium sentiment-${stock.sentiment}`; | |
| sentimentBadge.textContent = | |
| stock.sentiment === 'positive' ? 'Positivo' : | |
| stock.sentiment === 'negative' ? 'Negativo' : 'Neutro'; | |
| // Update analysis texts | |
| document.getElementById('generalSentiment').textContent = stock.generalSentiment; | |
| document.getElementById('technicalTrend').textContent = stock.technicalTrend; | |
| document.getElementById('recommendation').textContent = stock.recommendation; | |
| document.getElementById('detailedAnalysis').innerHTML = `<p>${stock.detailedAnalysis}</p>`; | |
| // Update time | |
| document.getElementById('updateTime').textContent = | |
| `${now.getDate().toString().padStart(2, '0')}/${(now.getMonth()+1).toString().padStart(2, '0')}/${now.getFullYear()} ` + | |
| `${now.getHours().toString().padStart(2, '0')}:${now.getMinutes().toString().padStart(2, '0')}`; | |
| // Show results | |
| resultsSection.classList.remove('hidden'); | |
| // Scroll to results | |
| resultsSection.scrollIntoView({ behavior: 'smooth' }); | |
| } | |
| }); | |
| </script> | |
| <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=moosee/teste" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> | |
| </html> |