[PR #871] feat: add AI Knowledge Explorer generative UI agent #14039

Open
opened 2026-07-11 19:30:20 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Shubhamsaboo/awesome-llm-apps/pull/871
Author: @katrinalaszlo
Created: 6/9/2026
Status: 🔄 Open

Base: mainHead: feat/ai-knowledge-explorer-v2


📝 Commits (5)

  • 6cba82e feat: add AI Knowledge Explorer generative UI agent
  • 9987fd2 docs: fix knowledge-explorer README port (3002 -> 3000)
  • 625ecc9 fix: improve graph edge and label visibility on dark background
  • 26081f2 fix: handle upload failure, remove dead types and unused prop
  • d67e5ad fix: add Windows agent scripts and document uv/Python 3.12 prereq

📊 Changes

37 files changed (+17002 additions, -0 deletions)

View changed files

generative_ui_agents/ai-knowledge-explorer/.env.example (+2 -0)
generative_ui_agents/ai-knowledge-explorer/.gitignore (+10 -0)
generative_ui_agents/ai-knowledge-explorer/README.md (+106 -0)
generative_ui_agents/ai-knowledge-explorer/agent/.gitignore (+4 -0)
generative_ui_agents/ai-knowledge-explorer/agent/.python-version (+1 -0)
generative_ui_agents/ai-knowledge-explorer/agent/langgraph.json (+10 -0)
generative_ui_agents/ai-knowledge-explorer/agent/main.py (+35 -0)
generative_ui_agents/ai-knowledge-explorer/agent/pyproject.toml (+19 -0)
generative_ui_agents/ai-knowledge-explorer/agent/src/__init__.py (+0 -0)
generative_ui_agents/ai-knowledge-explorer/agent/src/state.py (+34 -0)
generative_ui_agents/ai-knowledge-explorer/agent/src/tools.py (+456 -0)
generative_ui_agents/ai-knowledge-explorer/agent/uv.lock (+2080 -0)
generative_ui_agents/ai-knowledge-explorer/next-env.d.ts (+6 -0)
generative_ui_agents/ai-knowledge-explorer/next.config.ts (+8 -0)
generative_ui_agents/ai-knowledge-explorer/package-lock.json (+12724 -0)
generative_ui_agents/ai-knowledge-explorer/package.json (+37 -0)
generative_ui_agents/ai-knowledge-explorer/postcss.config.mjs (+5 -0)
generative_ui_agents/ai-knowledge-explorer/scripts/run-agent.bat (+3 -0)
generative_ui_agents/ai-knowledge-explorer/scripts/run-agent.sh (+3 -0)
generative_ui_agents/ai-knowledge-explorer/scripts/setup-agent.bat (+3 -0)

...and 17 more files

📄 Description

Summary

Adds a new CopilotKit generative UI agent: AI Knowledge Explorer.

Drop files — documents or source code — into a chatbot. The agent extracts entities, concepts, and relationships, then renders an interactive force-directed knowledge graph you can explore.

Two modes

  • Document analysis: entities, concepts, and relationships (e.g. drop markdown files about AI agents and get a concept map)
  • Codebase analysis: modules, classes, functions, imports/calls/extends (e.g. drop Python files and get an architecture graph)

Key interactions

  • Click a node to see details in a side panel
  • Double-click to expand — the agent extracts sub-concepts and grows the graph
  • Chat to steer — ask questions, request deeper analysis, or explore connections

Built-in examples

Two starter datasets so reviewers can try it immediately without preparing files:

  1. AI Agent Docs — 3 markdown files covering agent concepts, frameworks, and challenges. Produces ~24 nodes, ~40 edges.
  2. FastAPI Auth System — 3 Python files (auth, routes, models). Produces ~20 nodes showing modules, classes, functions, and their relationships.

Tech stack

Layer Technology
Frontend Next.js 16, React 19, TailwindCSS 4
Agent LangGraph (Python), CopilotKit v2 Middleware
Graph react-force-graph-2d
LLM OpenAI gpt-4o (configurable via OPENAI_MODEL env var)
Protocol AG-UI (bidirectional state streaming)

How to test

cd generative_ui_agents/ai-knowledge-explorer
cp .env.example .env
# Add your OPENAI_API_KEY
npm install
npm run dev

Frontend: http://localhost:3000 | Agent: http://localhost:8125

Agent tools

Tool Purpose
extract_knowledge Parse documents or code, extract entities/concepts/relationships
find_connections Discover deeper links between existing nodes
expand_node Deep-dive into a node — adds sub-concepts and detail

Files added

generative_ui_agents/ai-knowledge-explorer/
├── agent/                     # Python LangGraph agent
│   ├── main.py                # Entry point + system prompt
│   └── src/
│       ├── state.py           # KnowledgeState schema (nodes, edges, selected)
│       └── tools.py           # extract, connect, expand tools
├── src/                       # Next.js frontend
│   ├── app/page.tsx           # Main page — chat + graph canvas + file drop
│   ├── components/
│   │   ├── KnowledgeGraph.tsx # Force-directed graph visualization
│   │   ├── NodeDetail.tsx     # Detail panel on node select
│   │   └── ToolReasoning.tsx  # Tool call status indicators
│   └── lib/
│       ├── types.ts           # KnowledgeNode, KnowledgeEdge types
│       └── example-content.ts # Built-in example documents and code
├── README.md
└── .env.example

No existing files modified — purely additive.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Shubhamsaboo/awesome-llm-apps/pull/871 **Author:** [@katrinalaszlo](https://github.com/katrinalaszlo) **Created:** 6/9/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `feat/ai-knowledge-explorer-v2` --- ### 📝 Commits (5) - [`6cba82e`](https://github.com/Shubhamsaboo/awesome-llm-apps/commit/6cba82ecaf2ec20c630c7051405b31cefbfdd0c9) feat: add AI Knowledge Explorer generative UI agent - [`9987fd2`](https://github.com/Shubhamsaboo/awesome-llm-apps/commit/9987fd2dd577c9a9cb430d8e619a5eda7cda8937) docs: fix knowledge-explorer README port (3002 -> 3000) - [`625ecc9`](https://github.com/Shubhamsaboo/awesome-llm-apps/commit/625ecc9576db66ebd3abff35ed7666d450e6db47) fix: improve graph edge and label visibility on dark background - [`26081f2`](https://github.com/Shubhamsaboo/awesome-llm-apps/commit/26081f24a6010083887bcdea2ec871caeb2be694) fix: handle upload failure, remove dead types and unused prop - [`d67e5ad`](https://github.com/Shubhamsaboo/awesome-llm-apps/commit/d67e5ad2f24e849d412986eaec8d7f7416eaff65) fix: add Windows agent scripts and document uv/Python 3.12 prereq ### 📊 Changes **37 files changed** (+17002 additions, -0 deletions) <details> <summary>View changed files</summary> ➕ `generative_ui_agents/ai-knowledge-explorer/.env.example` (+2 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/.gitignore` (+10 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/README.md` (+106 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/.gitignore` (+4 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/.python-version` (+1 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/langgraph.json` (+10 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/main.py` (+35 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/pyproject.toml` (+19 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/src/__init__.py` (+0 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/src/state.py` (+34 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/src/tools.py` (+456 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/agent/uv.lock` (+2080 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/next-env.d.ts` (+6 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/next.config.ts` (+8 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/package-lock.json` (+12724 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/package.json` (+37 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/postcss.config.mjs` (+5 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/scripts/run-agent.bat` (+3 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/scripts/run-agent.sh` (+3 -0) ➕ `generative_ui_agents/ai-knowledge-explorer/scripts/setup-agent.bat` (+3 -0) _...and 17 more files_ </details> ### 📄 Description ## Summary Adds a new CopilotKit generative UI agent: **AI Knowledge Explorer**. Drop files — documents or source code — into a chatbot. The agent extracts entities, concepts, and relationships, then renders an interactive force-directed knowledge graph you can explore. ### Two modes - **Document analysis**: entities, concepts, and relationships (e.g. drop markdown files about AI agents and get a concept map) - **Codebase analysis**: modules, classes, functions, imports/calls/extends (e.g. drop Python files and get an architecture graph) ### Key interactions - **Click** a node to see details in a side panel - **Double-click** to expand — the agent extracts sub-concepts and grows the graph - **Chat** to steer — ask questions, request deeper analysis, or explore connections ### Built-in examples Two starter datasets so reviewers can try it immediately without preparing files: 1. **AI Agent Docs** — 3 markdown files covering agent concepts, frameworks, and challenges. Produces ~24 nodes, ~40 edges. 2. **FastAPI Auth System** — 3 Python files (auth, routes, models). Produces ~20 nodes showing modules, classes, functions, and their relationships. ## Tech stack | Layer | Technology | |---|---| | Frontend | Next.js 16, React 19, TailwindCSS 4 | | Agent | LangGraph (Python), CopilotKit v2 Middleware | | Graph | react-force-graph-2d | | LLM | OpenAI gpt-4o (configurable via `OPENAI_MODEL` env var) | | Protocol | AG-UI (bidirectional state streaming) | ## How to test ```bash cd generative_ui_agents/ai-knowledge-explorer cp .env.example .env # Add your OPENAI_API_KEY npm install npm run dev ``` Frontend: http://localhost:3000 | Agent: http://localhost:8125 ## Agent tools | Tool | Purpose | |---|---| | `extract_knowledge` | Parse documents or code, extract entities/concepts/relationships | | `find_connections` | Discover deeper links between existing nodes | | `expand_node` | Deep-dive into a node — adds sub-concepts and detail | ## Files added ``` generative_ui_agents/ai-knowledge-explorer/ ├── agent/ # Python LangGraph agent │ ├── main.py # Entry point + system prompt │ └── src/ │ ├── state.py # KnowledgeState schema (nodes, edges, selected) │ └── tools.py # extract, connect, expand tools ├── src/ # Next.js frontend │ ├── app/page.tsx # Main page — chat + graph canvas + file drop │ ├── components/ │ │ ├── KnowledgeGraph.tsx # Force-directed graph visualization │ │ ├── NodeDetail.tsx # Detail panel on node select │ │ └── ToolReasoning.tsx # Tool call status indicators │ └── lib/ │ ├── types.ts # KnowledgeNode, KnowledgeEdge types │ └── example-content.ts # Built-in example documents and code ├── README.md └── .env.example ``` No existing files modified — purely additive. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-07-11 19:30:20 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/awesome-llm-apps#14039