Can you guys help me here, the code below runs wit...
# koog-agentic-framework
v
Can you guys help me here, the code below runs without errors, but I do not see any kind of outputs ,
Copy code
val agentGemini = AIAgent(
    executor = simpleGoogleAIExecutor(System.getenv("GEMINI_API_KEY")),
    systemPrompt = "You are a helpful assistant. Answer user questions concisely.",
    llmModel = GoogleModels.Gemini2_0Flash ,
    temperature = 0.7,
    toolRegistry = ToolRegistry {
        tool(SayToUser)
    },
    maxIterations = 100
)



fun main() = runBlocking {
//    val result = agentOpenAI.run("Hello! How can you help me?")
    val result2 = agentGemini.run("Hello! How can you help me?")
}
k
Hi, Vamsi You may try agent events https://docs.koog.ai/agent-events/ . Is logging enabled? Do you print results?
c
Hi, @Konstantin you're right I don't see @visakha print or log any information from their code snippet explaining perfectly why they don't get any output as expected
a
Yes, that’s right: 1. With the current version of Koog, you should call
runAndGetResult
to get the output. Note: this is about to change in the new soon-to-be-released Koog version, there will be only
run
left that would return the result 2. You don’t print
result2
, that’s why you get no output. 3. If you would like to get more info about how the execution is going on, you can indeed use event handler, as was already suggested
v
Thank you, the fix is the model: I used
gemini-2.5-pro-preview-05-06
and it started working. btw
there is no need to print the result
as its a Unit. The take away is I got responses from you all and I thank you . which is what I wanted. its nice to know that there is help out there
btw, the 2.5-Pro Gemini is released, no more a pre-view
I will work on the events, thank you