#Build an AI Agent - not bin file

1 messages Β· Page 1 of 1 (latest)

last harness
#

Going through this example "https://docs.dagger.io/quickstart/agent" Should there not be an executable in the app folder of the container generated? When I do the following in dagger shell I see no executable file: go-program "write a curl clone" | terminal

dusty quiver
last harness
#

Thanks... I have this at the end, if that is any help: β”‚πŸ’­ Checking the exit code to confirm if the build was successful.
β”‚ ┃ 0.0s
β”‚
β”‚πŸ€– save(
β”‚ β”‚ β”‚ completed: βœ” Binding.asContainer: Container! 0.0s
β”‚ β”‚ ): String! 0.0s
Container@xxh3:3ea6944ae0aca7ee

#

And did you use this main.go: package main

import (
"dagger/coding-agent/internal/dagger"
)

type CodingAgent struct{}

// Write a Go program
func (m *CodingAgent) GoProgram(
// The programming assignment, e.g. "write me a curl clone"
assignment string,
) *dagger.Container {
environment := dag.Env().
WithStringInput("assignment", assignment, "the assignment to complete").
WithContainerInput("builder",
dag.Container().From("golang").WithWorkdir("/app"),
"a container to use for building Go code").
WithContainerOutput("completed", "the completed assignment in the Golang container")

work := dag.LLM().
    WithEnv(environment).
    WithPrompt(`
        You are an expert Go programmer with an assignment to create a Go program
        Create files in the default directory in $builder
        Always build the code to make sure it is valid
        Do not stop until your assignment is completed and the code builds
        Your assignment is: $assignment
        `)

return work.
    Env().
    Output("completed").
    AsContainer()

}

#

I used Ollama model: llm | model 0.0s
qwen2.5-coder:14b

dusty quiver
#

@last harness any chance you can share a Dagger Cloud trace?

#

Dagger Cloud is free for individuals

last harness
#

Yes, I will try try that

dusty quiver
last harness
#

Ok got the trace, but how can I share it - just copy the link?

dusty quiver
#

yep

#

you can share it here, I can check it since I have access to do so :godmode: