-module(glean). -compile([no_auto_import, nowarn_unused_vars, nowarn_unused_function, nowarn_nomatch, inline]). -define(FILEPATH, "src/glean.gleam"). -export([version/0]). -if(?OTP_RELEASE >= 27). -define(MODULEDOC(Str), -moduledoc(Str)). -define(DOC(Str), -doc(Str)). -else. -define(MODULEDOC(Str), -compile([])). -define(DOC(Str), -compile([])). -endif. -file("src/glean.gleam", 33). ?DOC( " Glean — A Gleam-native AI agent SDK for the BEAM.\n" "\n" " ## Quick Start\n" "\n" " ```gleam\n" " import glean/agent\n" " import glean/run\n" " import glean/tool\n" " import glean/schema\n" "\n" " // 1. Create a provider (e.g., from glean/providers/openai)\n" " let provider = my_provider()\n" "\n" " // 2. Define tools\n" " let calculator = tool.new(\n" " name: \"add\",\n" " description: \"Add two numbers\",\n" " input_schema: schema.object(\n" " properties: [#(\"a\", schema.int()), #(\"b\", schema.int())],\n" " required: [\"a\", \"b\"],\n" " ),\n" " execute: fn(_ctx, args_json) { Ok(\"42\") },\n" " )\n" "\n" " // 3. Build an agent\n" " let my_agent = agent.new(provider)\n" " |> agent.system(\"You are a helpful calculator.\")\n" " |> agent.tools(tool.toolset([calculator]))\n" "\n" " // 4. Run it\n" " let result = run.generate(my_agent, Nil, \"What is 2 + 2?\")\n" " ```\n" ). -spec version() -> binary(). version() -> <<"0.1.0"/utf8>>.