HiveLang v5

Production patterns

Use these patterns when the goal is not a toy chatbot, but a useful digital worker that runs repeatedly and safely.

The digital worker loop

  1. Learn context: store stable preferences and requirements.
  2. Retrieve context: use memory and knowledge before acting.
  3. Act safely: call tools only after checking permission and risk.
  4. Record state: remember what changed so future runs do not repeat work.
  5. Recover clearly: explain failure and next steps.

Pattern: recurring research worker

bot JobSearchAgent {
  description: "Finds relevant jobs and sends new matches"

  capabilities {
    web.search
    ai.generate
    general.respond
  }

  instructions {
    Find legitimate job posts that match the user's target role.
    Deduplicate old jobs and explain why each match is relevant.
  }

  schedule DailyJobSearch at "0 9 * * *" timezone "Africa/Lagos" {
    criteria = recall "job_criteria"
    seen = recall "seen_jobs"
    results = call web.search with { query: f"recent jobs matching {criteria}" }
    summary = call ai.generate with {
      prompt: f"Return only new jobs. Seen: {seen}. Results: {results.summary}"
    }
    remember "seen_jobs" as summary
    say summary
  }

  on user.message {
    remember "job_criteria" as input
    say "Saved. I will use this for future job searches."
  }
}

Common production bots

Support agent

Search knowledge, answer, escalate uncertainty.

Social assistant

Learn voice, draft posts, request approval.

Lead researcher

Find leads, dedupe, summarize fit.

Executive assistant

Read inbox/calendar, draft next actions.

Ops monitor

Poll systems, alert only on meaningful changes.

Trading monitor

Research and alert. Do not execute trades without a dedicated high-risk connector.

Next: review the standard library and the tools model.

How helpful was this page?

Not helpfulExcellent