LLM Frameworks vs. the Raw SDK in Java
📰 Dev.to · Puneet Gupta
Learn to evaluate LLM frameworks by building the same tool twice, once with the raw SDK and once with a framework, and comparing the costs and benefits
Action Steps
- Build a small tool using an agent on the raw Anthropic Java SDK
- Build the same tool using a framework such as LangChain4j or Spring AI
- Compare the costs and benefits of each approach
- Evaluate the trade-offs between abstraction and control
- Choose the best framework for your specific use case
Who Needs to Know This
Software engineers and AI developers can benefit from this approach to evaluate LLM frameworks and make informed decisions about which ones to use
Key Insight
💡 Evaluating LLM frameworks requires a hands-on approach, building the same tool twice to compare costs and benefits
Share This
🤖 Evaluate LLM frameworks by building the same tool twice: once with raw SDK, once with a framework. Compare costs & benefits to make informed decisions #LLM #AI #Java
Key Takeaways
Learn to evaluate LLM frameworks by building the same tool twice, once with the raw SDK and once with a framework, and comparing the costs and benefits
Full Article
Title: LLM Frameworks vs. the Raw SDK in Java
URL Source: https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj
Published Time: 2026-07-05T18:42:15Z
Markdown Content:
[Skip to content](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#main-content)
[](https://dev.to/)
[Powered by Algolia](https://www.algolia.com/developers/?utm_source=devto&utm_medium=referral)
[Log in](https://dev.to/enter?signup_subforem=1)[Create account](https://dev.to/enter?signup_subforem=1&state=new-user)
## DEV Community
0 Add reaction
0 Like 0 Unicorn 0 Exploding Head 0 Raised Hands 0 Fire
0 Jump to Comments 0 Save Boost
Copy link
Copied to Clipboard
[Share to X](https://twitter.com/intent/tweet?text=%22LLM%20Frameworks%20vs.%20the%20Raw%20SDK%20in%20Java%22%20by%20Puneet%20Gupta%20%23DEVCommunity%20https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)[Share to LinkedIn](https://www.linkedin.com/shareArticle?mini=true&url=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj&title=LLM%20Frameworks%20vs.%20the%20Raw%20SDK%20in%20Java&summary=Building%20the%20same%20small%20tool-using%20agent%20on%20the%20raw%20Anthropic%20Java%20SDK%2C%20LangChain4j%2C%20and%20Spring%20AI%2C%20to%20see%20honestly%20where%20each%20framework%20earns%20its%20weight.&source=DEV%20Community)[Share to Facebook](https://www.facebook.com/sharer.php?u=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)[Share to Mastodon](https://s2f.kytta.dev/?text=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)
[Share Post via...](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#)[Report Abuse](https://dev.to/report-abuse)
[](https://dev.to/gpuneet)
[Puneet Gupta](https://dev.to/gpuneet)
Posted on Jul 5 • Originally published at [pg-blogs.netlify.app](https://pg-blogs.netlify.app/posts/26-llm-frameworks-vs-the-raw-sdk-in-java/)
# LLM Frameworks vs. the Raw SDK in Java
[#java](https://dev.to/t/java)[#ai](https://dev.to/t/ai)[#llm](https://dev.to/t/llm)[#langchain4j](https://dev.to/t/langchain4j)
## [](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#introduction) Introduction
Every LLM ecosystem now has at least one framework promising to make agents easier to build, and every framework post either oversells the abstraction or dismisses it outright. Neither is useful. The only honest way to evaluate a framework is to build the same thing twice — once on the vendor's raw SDK, once on the framework — and compare what each version actually cost you and actually gave you back.
This post builds the small tool-using agent from [Building Agentic Workflows in Java](https://pg-blogs.netlify.app/posts/14-building-agentic-workflows-in-java/) three ways: on the raw Anthropic Java SDK, on [
URL Source: https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj
Published Time: 2026-07-05T18:42:15Z
Markdown Content:
[Skip to content](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#main-content)
[](https://dev.to/)
[Powered by Algolia](https://www.algolia.com/developers/?utm_source=devto&utm_medium=referral)
[Log in](https://dev.to/enter?signup_subforem=1)[Create account](https://dev.to/enter?signup_subforem=1&state=new-user)
## DEV Community
0 Add reaction
0 Like 0 Unicorn 0 Exploding Head 0 Raised Hands 0 Fire
0 Jump to Comments 0 Save Boost
Copy link
Copied to Clipboard
[Share to X](https://twitter.com/intent/tweet?text=%22LLM%20Frameworks%20vs.%20the%20Raw%20SDK%20in%20Java%22%20by%20Puneet%20Gupta%20%23DEVCommunity%20https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)[Share to LinkedIn](https://www.linkedin.com/shareArticle?mini=true&url=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj&title=LLM%20Frameworks%20vs.%20the%20Raw%20SDK%20in%20Java&summary=Building%20the%20same%20small%20tool-using%20agent%20on%20the%20raw%20Anthropic%20Java%20SDK%2C%20LangChain4j%2C%20and%20Spring%20AI%2C%20to%20see%20honestly%20where%20each%20framework%20earns%20its%20weight.&source=DEV%20Community)[Share to Facebook](https://www.facebook.com/sharer.php?u=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)[Share to Mastodon](https://s2f.kytta.dev/?text=https%3A%2F%2Fdev.to%2Fgpuneet%2Fllm-frameworks-vs-the-raw-sdk-in-java-1ldj)
[Share Post via...](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#)[Report Abuse](https://dev.to/report-abuse)
[](https://dev.to/gpuneet)
[Puneet Gupta](https://dev.to/gpuneet)
Posted on Jul 5 • Originally published at [pg-blogs.netlify.app](https://pg-blogs.netlify.app/posts/26-llm-frameworks-vs-the-raw-sdk-in-java/)
# LLM Frameworks vs. the Raw SDK in Java
[#java](https://dev.to/t/java)[#ai](https://dev.to/t/ai)[#llm](https://dev.to/t/llm)[#langchain4j](https://dev.to/t/langchain4j)
## [](https://dev.to/gpuneet/llm-frameworks-vs-the-raw-sdk-in-java-1ldj#introduction) Introduction
Every LLM ecosystem now has at least one framework promising to make agents easier to build, and every framework post either oversells the abstraction or dismisses it outright. Neither is useful. The only honest way to evaluate a framework is to build the same thing twice — once on the vendor's raw SDK, once on the framework — and compare what each version actually cost you and actually gave you back.
This post builds the small tool-using agent from [Building Agentic Workflows in Java](https://pg-blogs.netlify.app/posts/14-building-agentic-workflows-in-java/) three ways: on the raw Anthropic Java SDK, on [
DeepCamp AI