Build and demo Java AI agent systems with langchain4j-agentic: workflow patterns, supervisor, custom Planner strategies (incl. the flagship typed-verdict / CriticResult-style critic pattern), plus MCP tools, A2A remote agents, build setup, and conference-demo storylines. Pinned to 1.15.0 / 1.15.0-beta25.
84
89%
Does it follow best practices?
Impact
100%
4.76xAverage score across 2 eval scenarios
Passed
No known issues
A media analytics company publishes several hundred articles per day across multiple channels and needs an automated quality-assurance pipeline to keep standards high without bottlenecking editorial staff. Each incoming article must be classified for sentiment and assigned a quality score, and those that score below an editorial threshold need to go through a refinement loop: an editor agent rewrites the article, the scorer re-evaluates it, and the cycle continues until the score is acceptable or a maximum number of revision attempts is exhausted.
Speed matters: the classification and initial scoring phase should process a whole batch of articles at once rather than one at a time down a serial queue. The engineering team wants to build this pipeline with the LangChain4j agentic framework in Java. They've been burned before by thread-safety bugs, runaway token bills, and refinement loops that never terminate, so reliability under load is a stated priority.
Produce a self-contained Java project with the following files:
build.gradle.kts — Gradle build configurationsrc/main/java/pipeline/ — Java source files including:
Pipeline.java that:
The project must compile cleanly. The execution report file should be written to the project directory so it is visible after running.