moondream 0.1.1

Client for interacting with the Moondream API
Documentation

Moondream

An async Rust client for the Moondream API.

This library wraps the HTTP endpoints exposed by the service, providing a simple interface for point detection, object detection, captioning and visual question answering.

Usage

Add the crate to your Cargo.toml:

moondream = "0.1"

Instantiate the client

For a local deployment:

use moondream::MoonDream;

let md = MoonDream::local("http://localhost:8000");

For the hosted service:

let md = MoonDream::remote("YOUR_TOKEN");

Examples

The examples directory contains runnable samples. Execute one with:

cargo run -p moondream --example points

Features

  • /point - detect objects and return centre points
  • /detect - bounding box detection
  • /caption - generate captions for images
  • /query - visual question answering

Testing

cargo test -p moondream