# Hello World - Getting Started Examples

> A minimal Tactus program demonstrating the core workflow without the formal `Procedure` structure. This example shows how to: - Define an agent with a provider and model - Write simple Tactus code that just returns an agent call - Include an embedded BDD specification with Gherkin syntax - Use fuzz…

Canonical: https://tactus.anth.us/examples/getting-started/hello-world/

::band{columns="document-hero wide"}

[Examples](/examples/) / [Getting Started](/examples/getting-started/) / Hello World

# Hello World

- Has Specs
- **Requires API Keys**

A minimal Tactus program demonstrating the core workflow without the formal \`Procedure\` structure. This example shows how to: - Define an agent with a provider and model - Write simple Tactus code that just returns an agent call - Include an embedded BDD specification with Gherkin syntax - Use fuzzy matching to validate agent responses flexibly

::band{tone="muted" columns="example"}

## Source Code

```lua
World = Agent {
  model = "openai/gpt-4o-mini",
  system_prompt = "Your name is World."
}

Specification([[
Feature: Hello World

  Scenario: Greeter returns greeting
    Given the procedure has started
    And the message is "Hello, World!"
    And the agent "World" responds with "Hello! I'm World, nice to meet you!"
    When the procedure runs
    Then the output should fuzzy match any of ["Hello", "Hi", "Hey"] with threshold 0.9
]])

local result = World({message = "Hello, World!"})
return (result and (result.output or result)) or ""
```

## Quick Start

Run the example:

```bash
tactus run 01-getting-started/01-hello-world.tac
```

Test with mocks:

```bash
tactus test 01-getting-started/01-hello-world.tac --mock
```

> **Note.** This example requires API keys. Set your `OPENAI_API_KEY` environment variable before running.

[View source on GitHub →](https://github.com/AnthusAI/Tactus-examples/blob/main/01-getting-started/01-hello-world.tac)

::band{columns="neighbors"}

-
- [*Next Example →* **Simple Logic**](/examples/getting-started/simple-logic/)

::band{columns="cta"}

## Explore more examples

Learn Tactus through practical, runnable examples organized by topic.

::button{href="/examples/" label="View All Examples" size="lg"}
