GitHub Stars
0
User Rating
Not Rated
Favorites
0
Views
5
Forks
0
Issues
0
🧠 Name Analyzer with AI
This project is a Proof of Concept (POC) for implementing the Model Context Protocol (MCP) to track the full lifecycle of an API request, enrich it with structured data, and use AI (GPT-4o / GPT-3.5) to generate an automatic technical summary.
🚀 Features
- 🧾 Request lifecycle trace using the
MCPContext
abstraction - 🌐 External API integrations:
agify.io
→ estimate agegenderize.io
→ estimate gender
- 🧠 AI-powered analysis using OpenAI's GPT models
- 📄 OpenAPI 3.0 documentation served via Swagger UI
- 📦 Clean architecture using Spring Boot 3 + Java 17
📐 Architecture
Client
|
v
/analyze [POST] <----> AnalyzeController
|
v
AnalyzerService
|
+------------+------------+
| |
AgifyClient GenderizeClient
| |
+------------+------------+
|
MCPContext ← records full trace
|
v
IAService → OpenAI call
|
v
AnalyzeResponse (enriched)
🔧 Tech Stack
- Java 17 ☕️
- Spring Boot 3 ⚙️
- Spring WebFlux (WebClient) 🌐
- Lombok 🧬
- OpenAI API (Chat Completions – GPT-4o / GPT-3.5) 🤖
📥 How to Run
# Clone the repository
git clone https://github.com/your-username/anthropic-mcp-ai.git
cd anthropic-mcp-ai
# Make sure you have Java 17 installed
./mvnw spring-boot:run
🔐 Environment Configuration
Set these variables in your environment or in a .env
file:
OPENAI_API_KEY=sk-XXXXXXXXXXXXXXXXXXXXXXXXXXX
These values will be loaded via the AIProperties
class using @ConfigurationProperties
.
🧪 Try It
Once the server is running, access:
- Swagger UI: http://localhost:8080/swagger-ui.html
- Try a POST to
/analyze
with:
{
"name": "gabriel"
}
You will receive a structured response with the AI-generated explanation in the technicalExplanation
field.
Enjoy! 😉
6
Followers
28
Repositories
0
Gists
0
Total Contributions
Java AI(智能体) 全场景应用开发框架(LLM,Function Call,RAG,Embedding,Reranking,Flow,MCP Server,Mcp Client,Mcp Proxy)。同时兼容 java8 ~ java24。也可嵌入到 SpringBoot2、jFinal、Vert.x 等框架中使用。。支持 MCP_2025_03_26(mcp streamable)
The official Java SDK for Model Context Protocol servers and clients. Maintained in collaboration with Spring AI