npx skills add ...
npx skills add giuseppe-trisciuoglio/developer-kit --skill langchain4j-ai-services-patterns
Provides patterns to build declarative AI Services with LangChain4j for LLM integration, chatbot development, AI agent implementation, and conversational AI in Java. Generates type-safe AI services using interface-based patterns, annotations, memory management, and tools integration. Use when creating AI-powered Java applications with minimal boilerplate, implementing conversational AI with memory, or building AI agents with function calling.
npx skills add giuseppe-trisciuoglio/developer-kit --skill langchain4j-ai-services-patterns
This skill provides guidance for building declarative AI Services with LangChain4j using interface-based patterns, annotations for system and user messages, memory management, tools integration, and advanced AI application patterns that abstract away low-level LLM interactions.
LangChain4j AI Services define AI functionality using Java interfaces with annotations, providing type-safe, declarative AI with minimal boilerplate.
Use this skill when:
Follow these steps to create declarative AI Services with LangChain4j:
Create a Java interface with method signatures for AI interactions:
Use @SystemMessage and @UserMessage annotations to define prompts:
Use AiServices builder or create to instantiate the service:
Add memory management using @MemoryId for multi-user scenarios:
Register tools using @Tool annotation to enable AI function execution:
Test AI services with concrete validation patterns:
See examples.md for comprehensive practical examples including:
Complete API documentation, annotations, interfaces, and configuration patterns are available in references.md.