Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public static void main(String[] args) {
List<ToolDef> tools = ToolRegistry.fromInstance(new AgentTools());

Agent agent = Agent.builder()
.name("weather_stock_agent")
.name("weather_stock_agent_02")
.model(Settings.LLM_MODEL)
.tools(tools)
.instructions("You are a helpful assistant. Use tools to answer questions.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public static void main(String[] args) {
List<ToolDef> tools = ToolRegistry.fromInstance(new AssistantTools());

Agent agent = Agent.builder()
.name("weather_stock_agent")
.name("weather_stock_agent_02a")
.model(Settings.LLM_MODEL)
.tools(tools)
.instructions("You are a helpful assistant. Use tools to answer questions.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ public static void main(String[] args) {

// Orchestrator with handoff strategy
Agent support = Agent.builder()
.name("support")
.name("support_05")
.model(Settings.LLM_MODEL)
.instructions("Route customer requests to the right specialist: billing, technical, or sales.")
.agents(billingAgent, technicalAgent, salesAgent)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public static void main(String[] args) throws Exception {
.build();

Agent support = Agent.builder()
.name("support")
.name("support_09b")
.model(Settings.LLM_MODEL)
.instructions("Route any database task to the dba sub-agent.")
.agents(dba)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public static void main(String[] args) {
ToolRegistry.guardrailsFromInstance(new PiiGuardrails());

Agent agent = Agent.builder()
.name("support_agent")
.name("support_agent_10")
.model(Settings.LLM_MODEL)
.instructions(
"You are a customer support assistant. Use the available tools to "
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public static void main(String[] args) {
// ── Front-line support with SWARM strategy ───────────────────────

Agent support = Agent.builder()
.name("support")
.name("support_17")
.model(Settings.LLM_MODEL)
.instructions(
"You are the front-line customer support agent. Triage customer requests. "
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ public static void main(String[] args) {

// Pipeline: attack → respond → evaluate
Agent pipeline = Agent.builder()
.name("security_test_pipeline")
.name("security_test_pipeline_42")
.model(Settings.LLM_MODEL)
.agents(redTeam, target, evaluator)
.strategy(Strategy.SEQUENTIAL)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public static void main(String[] args) {
// ── Full pipeline (flat 8-agent sequential list) ───────────────────

Agent mlPipeline = Agent.builder()
.name("ml_pipeline")
.name("ml_pipeline_55")
.model(Settings.LLM_MODEL)
.agents(dataAnalyst, modelExploration, evaluator,
optimizerR1, validatorR1, optimizerR2, validatorR2,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ public static void main(String[] args) {
+ "countries by GDP.";

Agent coordinator = Agent.builder()
.name("coordinator")
.name("coordinator_58")
.model(Settings.SECONDARY_LLM_MODEL)
.instructions(instructions)
.tools(List.of(workerTool))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ public static void main(String[] args) {

// Both analysts run concurrently
Agent analysis = Agent.builder()
.name("parallel_analysis")
.name("parallel_analysis_65")
.model(Settings.LLM_MODEL)
.agents(financialAnalyst, orderAnalyst)
.strategy(Strategy.PARALLEL)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public class Example00HelloWorld {
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
LlmAgent greeter = LlmAgent.builder()
.name("greeter")
.name("adk_greeter_00")
.description("A friendly greeter that says hello and shares a fun fact.")
.model(Settings.LLM_MODEL)
.instruction("You are a friendly greeter. Reply with a warm hello and one fun fact.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public class Example01BasicAgent {
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
LlmAgent researcher = LlmAgent.builder()
.name("greeter")
.name("adk_greeter_01")
.description("A friendly assistant that gives concise, helpful answers.")
.model(Settings.LLM_MODEL)
.instruction("You are a friendly assistant. Keep your responses concise and helpful.")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ public static Map<String, Object> applyCoupon(
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
LlmAgent shopper = LlmAgent.builder()
.name("shopping_assistant")
.name("adk_shopping_assistant_09")
.description("Helps users search products, check stock, calculate shipping, and apply coupons.")
.model(Settings.LLM_MODEL)
.instruction("""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static void main(String[] args) {

// All three analysts dispatched concurrently by native ParallelAgent.
ParallelAgent parallelAnalysis = ParallelAgent.builder()
.name("parallel_analysis")
.name("adk_parallel_analysis_12")
.description("Fan-out to three analysts running in parallel.")
.subAgents(marketAnalyst, techAnalyst, riskAnalyst)
.build();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public static void main(String[] args) {
.build();

LlmAgent securityTest = LlmAgent.builder()
.name("security_test_pipeline")
.name("adk_security_test_pipeline_27")
.description("Sequential pipeline: red-team → target → security evaluator.")
.model(Settings.LLM_MODEL)
.instruction("""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public static void main(String[] args) {
.build();

LlmAgent coordinator = LlmAgent.builder()
.name("coordinator")
.name("adk_coordinator_29")
.description("Routes summarization to the independent summarizer and questions to the helper.")
.model(Settings.LLM_MODEL)
.instruction(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public static Map<String, Object> clearList() {
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
LlmAgent stateAgent = LlmAgent.builder()
.name("shopping_assistant")
.name("adk_shopping_assistant_31")
.description("Manages a shopping list shared across tool calls via add/get/clear tools.")
.model(Settings.LLM_MODEL)
.instruction(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ Based on the entire conversation (data analysis, model exploration,

// ── Full Pipeline ────────────────────────────────────────────────
LlmAgent mlPipeline = LlmAgent.builder()
.name("ml_pipeline")
.name("adk_ml_pipeline_34")
.description("End-to-end ML pipeline orchestrating EDA, exploration, evaluation, refinement, and reporting.")
.model(Settings.LLM_MODEL)
.instruction("""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class Example01BasicAgent {
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
Agent agent = OpenAIAgent.builder()
.name("greeter")
.name("openai_greeter_01")
.instructions("You are a friendly assistant. Keep your responses concise and helpful.")
.model(Settings.LLM_MODEL)
.build();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public String searchKnowledgeBase(String query) {
public static void main(String[] args) {
AgentRuntime runtime = new AgentRuntime();
Agent agent = OpenAIAgent.builder()
.name("support_agent")
.name("openai_support_agent_07")
.instructions(
"You are a customer support agent. Use the knowledge base to answer "
+ "questions accurately. If you can't find the answer, say so honestly.")
Expand Down
Loading