Skip to content

feat: add Agent desktop UI with real-time web search (GDELT)#1099

Open
sjkncs wants to merge 2 commits intokoala73:mainfrom
sjkncs:feat/agent-desktop-ui
Open

feat: add Agent desktop UI with real-time web search (GDELT)#1099
sjkncs wants to merge 2 commits intokoala73:mainfrom
sjkncs:feat/agent-desktop-ui

Conversation

@sjkncs
Copy link

@sjkncs sjkncs commented Mar 6, 2026

Summary

Adds a full-featured AI Agent interface to WorldMonitor, accessible via a new button in the main dashboard header.

New Files

  • \�gent.html\ Vite multi-page entry point
  • \src/agent/agent-app.ts\ Main UI controller
  • \src/agent/main.ts\ Entry point
  • \src/agent/services/chat-service.ts\ OpenAI-compatible SSE streaming client
  • \src/agent/services/conversation-store.ts\ localStorage persistence
  • \src/agent/services/i18n.ts\ EN/ZH UI strings
  • \src/agent/services/news-context.ts\ Real-time news via GDELT DOC API v2
  • \src/agent/styles/agent.css\ Full dark theme CSS

Modified Files

  • \�ite.config.ts\ Add agent entry to rollupOptions.input
  • \index.html\ Add AI Agent navigation button to header

Features

  • Multi-provider: custom OpenAI-compatible API, Ollama, Groq, OpenRouter
  • Real-time web search: GDELT DOC API v2 injected into system prompt (CORS:*, no auth, 10-min cache)
  • Animated search indicator during news fetch
  • Tool modes: intel, deep-think, research, code, market
  • Qwen-inspired dark theme, localStorage conversation history

Testing

  • tsc --noEmit: 0 errors
  • vite build: dist/agent.html output confirmed

Adds a full-featured AI Agent interface accessible from the main dashboard.

## New Files
- agent.html  Vite multi-page entry point for Agent
- src/agent/main.ts  Entry point
- src/agent/agent-app.ts  Main UI controller: sidebar, chat, welcome screen,
  settings panel, splash screen, tool modes (intel/research/code/market/deep-think)
- src/agent/services/chat-service.ts  OpenAI-compatible SSE streaming client
  supporting custom API, Ollama, Groq, OpenRouter providers
- src/agent/services/conversation-store.ts  localStorage persistence + settings
- src/agent/services/i18n.ts  EN/ZH UI strings
- src/agent/services/news-context.ts  Real-time news via GDELT DOC API v2
  (CORS:*, no auth, 10-min cache, 24h->3d fallback, rate-limit guard)
- src/agent/styles/agent.css  Full dark theme CSS, Qwen-inspired UI

## Modified Files
- vite.config.ts  Add agent entry to rollupOptions.input; auto-detect Windows
  system proxy from HKCU registry so Node.js fetch routes through VPN
- index.html  Add AI Agent navigation button to header

## Features
- Multi-provider: custom OpenAI-compatible, Ollama, Groq, OpenRouter
- Real-time web search: GDELT news injected into system prompt before each reply
  with animated search indicator (🔍 Searching...  ✅ Found N results)
- Conversation history persisted in localStorage
- Tool modes with specialized system prompts
- Responsive dark theme with animated splash screen
@vercel
Copy link

vercel bot commented Mar 6, 2026

@sjkncs is attempting to deploy a commit to the Elie Team on Vercel.

A member of the Team first needs to authorize it.

@koala73
Copy link
Owner

koala73 commented Mar 6, 2026

@sjkncs can you please put some screenshots ?

@sjkncs
Copy link
Author

sjkncs commented Mar 6, 2026

ok

@sjkncs
Copy link
Author

sjkncs commented Mar 6, 2026

Screenshots

Main Dashboard WorldMonitor with AI Agent button (top-right header)

Main Dashboard

Agent Welcome Screen

Dark theme, sidebar with conversation history, tool mode shortcuts (Intel Analysis, Deep Research, Code, Market Analysis, Discover)
Agent Welcome

Agent Input Ready (query typed)

Input activated with send button highlighted, tool mode chips visible below input
Agent Input Ready

Agent Tool Mode Cards

Quick-access cards for each analysis mode with icons
Agent Tools


Live demo: accessible at /agent.html when running
pm run dev

Real-time web search: Before each LLM reply, the agent fetches recent headlines from GDELT DOC API (no auth required, CORS: *) and injects them into the system prompt similar to Qwen/Doubao web search feature.

@koala73
Copy link
Owner

koala73 commented Mar 6, 2026

Good stuff, I will review this by tomorrow and see how to integrate the look & feel
Thank you @sjkncs

@koala73 koala73 added enhancement New feature or request area: AI/intel AI analysis, intelligence findings, summarization community Community contribution High Value Meaningful contribution to the project labels Mar 6, 2026
@sjkncs
Copy link
Author

sjkncs commented Mar 6, 2026

No problem! Ready to help with the integration whenever you're ready.
By the way, I've pushed a newer version with an improved UI and more features here: https://github.com/sjkncs/worldmonitor-promoted
Seeing how powerful this tool is, I'm thinking about building a viable community around World Monitor. It could be a great space for users to share data sources, customization tips, and analysis workflows. What are your thoughts on starting something like this?
THANK YOU!

@sjkncs
Copy link
Author

sjkncs commented Mar 6, 2026

And I believe the World Monitor agent has the potential to significantly impact military and financial sectors globally. Moreover, it can be a game-changer for staff in various departments, drastically improving efficiency in tasks like drafting research analysis reports and creating high-quality presentation decks for briefings.THANK YOU!😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: AI/intel AI analysis, intelligence findings, summarization community Community contribution enhancement New feature or request High Value Meaningful contribution to the project

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants