# Send Elixir Dev to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "elixir-dev",
    "name": "Elixir Dev",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/gchapim/elixir-dev",
    "canonicalUrl": "https://clawhub.ai/gchapim/elixir-dev",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/elixir-dev",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=elixir-dev",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "references/mix-commands.md",
      "references/otp-patterns.md",
      "SKILL.md"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-04-30T16:55:25.780Z",
      "expiresAt": "2026-05-07T16:55:25.780Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=network",
        "contentDisposition": "attachment; filename=\"network-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/elixir-dev"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/elixir-dev",
    "downloadUrl": "https://openagent3.xyz/downloads/elixir-dev",
    "agentUrl": "https://openagent3.xyz/skills/elixir-dev/agent",
    "manifestUrl": "https://openagent3.xyz/skills/elixir-dev/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/elixir-dev/agent.md"
  }
}
```
## Documentation

### Running Mix Commands

See references/mix-commands.md for full command reference.

### Test

# Run all tests
mix test

# Specific file or line
mix test test/my_app/accounts_test.exs:42

# By tag
mix test --only integration

# Failed only (requires --failed flag from prior run)
mix test --failed

# With coverage
mix test --cover

Interpreting failures:

** (MatchError) — Pattern match failed; check return value shape.
** (Ecto.NoResultsError) — Repo.get! with non-existent ID; use Repo.get or seed data.
** (DBConnection.OwnershipError) — Missing async: true or sandbox setup.
no function clause matching — Wrong arity or unexpected arg type.

### Credo

mix credo --strict
mix credo suggest --format json
mix credo explain MyApp.Module  # Explain issues for specific module

Common Credo fixes:

Credo.Check.Readability.ModuleDoc — Add @moduledoc.
Credo.Check.Refactor.CyclomaticComplexity — Extract helper functions.
Credo.Check.Design.TagTODO — Address or remove TODO comments.

### Dialyzer

mix dialyzer
mix dialyzer --format short

Common Dialyzer warnings:

The pattern can never match — Dead code or wrong type in pattern.
Function has no local return — Crashes on all paths; check internal calls.
The call will never return — Calling a function that always raises.
Fix: Add @spec annotations; use @dialyzer {:nowarn_function, func: arity} as last resort.

### Format

mix format
mix format --check-formatted  # CI mode — exit 1 if unformatted

### Module Generation

Always include @moduledoc, @doc, and @spec on public functions.

### Context Module

defmodule MyApp.Notifications do
  @moduledoc """
  Manages notification delivery and preferences.
  """
  import Ecto.Query
  alias MyApp.Repo
  alias MyApp.Notifications.Notification

  @doc "List notifications for a user, most recent first."
  @spec list_notifications(String.t(), keyword()) :: [Notification.t()]
  def list_notifications(user_id, opts \\\\ []) do
    limit = Keyword.get(opts, :limit, 50)

    Notification
    |> where(user_id: ^user_id)
    |> order_by(desc: :inserted_at)
    |> limit(^limit)
    |> Repo.all()
  end
end

### Schema Module

defmodule MyApp.Notifications.Notification do
  @moduledoc """
  Schema for push/email/sms notifications.
  """
  use Ecto.Schema
  import Ecto.Changeset

  @type t :: %__MODULE__{}

  @primary_key {:id, :binary_id, autogenerate: true}
  @foreign_key_type :binary_id
  @timestamps_opts [type: :utc_datetime_usec]

  schema "notifications" do
    field :channel, Ecto.Enum, values: [:push, :email, :sms]
    field :title, :string
    field :body, :string
    field :delivered_at, :utc_datetime_usec
    field :user_id, :binary_id

    timestamps()
  end

  @required ~w(channel title body user_id)a

  @doc false
  def changeset(notification, attrs) do
    notification
    |> cast(attrs, @required ++ [:delivered_at])
    |> validate_required(@required)
    |> validate_length(:title, max: 255)
  end
end

### OTP Patterns

See references/otp-patterns.md for GenServer, Supervisor, Agent, Task patterns.

### When to Use What

PatternUse WhenGenServerStateful process with sync/async calls (cache, rate limiter, connection pool)AgentSimple state wrapper with no complex logicTaskOne-off async work, fire-and-forget or awaitedTask.SupervisorSupervised fire-and-forget tasksSupervisorManaging child process lifecyclesRegistryProcess lookup by name/keyDynamicSupervisorStarting children at runtime

### GenServer Template

defmodule MyApp.RateLimiter do
  @moduledoc "Token bucket rate limiter."
  use GenServer

  # Client API
  def start_link(opts) do
    name = Keyword.get(opts, :name, __MODULE__)
    GenServer.start_link(__MODULE__, opts, name: name)
  end

  @spec check_rate(String.t()) :: :ok | {:error, :rate_limited}
  def check_rate(key), do: GenServer.call(__MODULE__, {:check, key})

  # Server callbacks
  @impl true
  def init(opts) do
    {:ok, %{limit: Keyword.get(opts, :limit, 100), window_ms: 60_000, buckets: %{}}}
  end

  @impl true
  def handle_call({:check, key}, _from, state) do
    now = System.monotonic_time(:millisecond)
    {count, state} = increment(state, key, now)
    if count <= state.limit, do: {:reply, :ok, state}, else: {:reply, {:error, :rate_limited}, state}
  end

  defp increment(state, key, now) do
    # Implementation
  end
end

### Common Compilation Errors

ErrorCauseFixmodule X is not availableMissing dep or typoCheck mix.exs deps, verify module nameundefined function X/NNot imported/aliasedAdd import, alias, or full module path(CompileError) redefining moduleDuplicate module nameRename one of themprotocol not implementedMissing protocol implAdd defimpl for your structcannot use ^x outside of matchPin in wrong positionMove to pattern match context

### Dynamic Filters

def list(filters) do
  Enum.reduce(filters, base_query(), fn
    {:status, val}, q -> where(q, [r], r.status == ^val)
    {:since, dt}, q -> where(q, [r], r.inserted_at >= ^dt)
    {:search, term}, q -> where(q, [r], ilike(r.name, ^"%#{term}%"))
    _, q -> q
  end)
  |> Repo.all()
end

### Preloading

# Query-time preload (single query with join)
from(p in Post, join: a in assoc(p, :author), preload: [author: a])

# Separate query preload
Post |> Repo.all() |> Repo.preload(:author)

# Nested
Repo.preload(posts, [comments: :author])

### Aggregates

from(o in Order,
  where: o.tenant_id == ^tenant_id,
  group_by: o.status,
  select: {o.status, count(o.id), sum(o.amount)}
)
|> Repo.all()

### Mount + Handle Events

defmodule MyAppWeb.DashboardLive do
  use MyAppWeb, :live_view

  @impl true
  def mount(_params, _session, socket) do
    {:ok, assign(socket, items: [], loading: true)}
  end

  @impl true
  def handle_event("delete", %{"id" => id}, socket) do
    MyApp.Items.delete_item!(id)
    {:noreply, assign(socket, items: MyApp.Items.list_items())}
  end

  @impl true
  def render(assigns) do
    ~H"""
    <div :for={item <- @items}>
      <span><%= item.name %></span>
      <button phx-click="delete" phx-value-id={item.id}>Delete</button>
    </div>
    """
  end
end

### PubSub for Real-time

# Subscribe in mount
def mount(_, _, socket) do
  if connected?(socket), do: Phoenix.PubSub.subscribe(MyApp.PubSub, "items")
  {:ok, assign(socket, items: list_items())}
end

# Broadcast from context
def create_item(attrs) do
  with {:ok, item} <- %Item{} |> Item.changeset(attrs) |> Repo.insert() do
    Phoenix.PubSub.broadcast(MyApp.PubSub, "items", {:item_created, item})
    {:ok, item}
  end
end

# Handle in LiveView
def handle_info({:item_created, item}, socket) do
  {:noreply, update(socket, :items, &[item | &1])}
end
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: gchapim
- Version: 1.0.0
## Source health
- Status: healthy
- Source download looks usable.
- Yavira can redirect you to the upstream package for this source.
- Health scope: source
- Reason: direct_download_ok
- Checked at: 2026-04-30T16:55:25.780Z
- Expires at: 2026-05-07T16:55:25.780Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/elixir-dev)
- [Send to Agent page](https://openagent3.xyz/skills/elixir-dev/agent)
- [JSON manifest](https://openagent3.xyz/skills/elixir-dev/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/elixir-dev/agent.md)
- [Download page](https://openagent3.xyz/downloads/elixir-dev)