npx claudepluginhub avsm/ocaml-claude-marketplace --plugin ocaml-devThis skill uses the workspace's default tool permissions.
The `logs` library provides structured logging with per-module sources.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Checks Next.js compilation errors using a running Turbopack dev server after code edits. Fixes actionable issues before reporting complete. Replaces `next build`.
The logs library provides structured logging with per-module sources.
Every module that logs should create its own source:
let log_src = Logs.Src.create "project.module_name"
module Log = (val Logs.src_log log_src : Logs.LOG)
This is the standard idiom. Do NOT attempt to abstract or deduplicate this boilerplate.
| Level | Function | Use Case |
|---|---|---|
| App | Log.app | Always shown to user (startup, completion) |
| Error | Log.err | Handled but critical errors |
| Warning | Log.warn | Potential issues, operation continues |
| Info | Log.info | State transitions, progress |
| Debug | Log.debug | Verbose debugging details |
Log.info (fun m -> m "Processing %d items" count);
Log.err (fun m -> m "Failed to connect: %s" reason);
Log.debug (fun m -> m "Request: %a" Request.pp req)
Add context with tags for filtering/analysis:
Log.info (fun m ->
m "Event received: %s" event_type
~tags:(Logs.Tag.add "channel_id" channel Logs.Tag.empty))
In CLI applications, set up the reporter in bin/common.ml:
let setup_log style_renderer level =
Fmt_tty.setup_std_outputs ?style_renderer ();
Logs.set_level level;
Logs.set_reporter (Logs_fmt.reporter ())
open Cmdliner
let setup_log =
Term.(const setup_log
$ Fmt_cli.style_renderer ()
$ Logs_cli.level ())