For the complete documentation index, see llms.txt. This page is also available as Markdown.

Agent Tools

Using web search as an AI agent tool with auto-registration and multi-tool workflows

The BoxLang AI module auto-registers webSearch@bxai at startup, so agents can use web search without custom tool boilerplate.

Auto-Registered Tool

// Add the built-in web search tool by key
agent = aiAgent(
    name: "ResearchAgent",
    instructions: "Use web search when you need current information.",
    tools: [ "webSearch@bxai" ]
)
response = agent.run(
    "Find the latest BoxLang AI release details and summarize key updates."
)

Combine with Other Built-in Tools

agent = aiAgent(
    name: "MultimodalResearcher",
    instructions: "Research, summarize, and if needed produce audio and image assets.",
    tools: [
        "webSearch@bxai",
        "speak@bxai",
        "transcribe@bxai",
        "translate@bxai",
        "generateImage@bxai"
    ]
)

Research + Memory Pattern

Explicit Provider Hints in Prompts

You can guide the agent by giving provider constraints in instructions.

Safety Practices

  1. Keep strict system instructions about source quality.

  2. Ask the agent to cite URLs in final answers.

  3. Validate tool output before storing into long-term memory.

  4. Filter untrusted domains in high-risk workloads.

Inspecting Tool Availability

Last updated