npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@framers/agentos-ext-vision-pipeline

v0.5.0

Published

Vision & OCR pipeline extension for AgentOS — PaddleOCR, TrOCR, Florence-2, CLIP, and cloud vision

Readme

Vision pipeline

This pack gives an agent OCR, handwriting recognition, document layout, image descriptions and CLIP embeddings through AgentOS's createVisionPipeline. The pipeline uses local OCR and vision packages and can use cloud vision providers.

Installation

npm install @framers/agentos-ext-vision-pipeline

Peer dependency: @framers/agentos with range >=0.13.40.

Usage

import { AgentOS } from '@framers/agentos';

const agentos = await AgentOS.create({
  extensionManifest: {
    packs: [
      {
        package: '@framers/agentos-ext-vision-pipeline',
        options: {
          openaiApiKey: process.env.OPENAI_API_KEY,
          imageDir: process.env.AGENTOS_IMAGE_DIR,
        },
      },
    ],
  },
});

Configuration

| Option | Secret id | Environment variable | Required | Default | | --- | --- | --- | --- | --- | | openaiApiKey | openai.apiKey | OPENAI_API_KEY via AgentOS | No | AgentOS detects the cloud provider when neither option nor secret supplies a nonblank key | | imageDir | None | AGENTOS_IMAGE_DIR | No | A user-specific agentos-images-<uid> directory under os.tmpdir() on POSIX, or AppData/Local/Temp/agentos-images under the user's home on Windows | | priority | None | None | No | 45 | | None, cloud provider detection by AgentOS | None | OPENAI_API_KEY, ANTHROPIC_API_KEY, GOOGLE_API_KEY or GEMINI_API_KEY, OPENROUTER_API_KEY | No | Provider and key detected by AgentOS |

A nonblank openaiApiKey takes precedence over getSecret('openai.apiKey') and selects OpenAI for cloud vision. Otherwise, AgentOS reads provider credentials from the environment. The pack lists the provider variables above but does not implement their selection order itself.

Tools

| Tool | What it does | | --- | --- | | vision-pipeline | Reads printed text, handwriting and document layout, describes images or returns a CLIP embedding vector. |

vision-pipeline parameters

| Parameter | Type | Required | Description | | --- | --- | --- | --- | | imageUrl | string | Yes | The image: an http(s) URL, a data:image URL, or the file: URL of an image the image tools saved. | | mode | string, enum: ocr, handwriting, layout, describe, embed, auto | No | ocr for printed text, handwriting, layout for the lines of text with their boxes, describe for what the image shows, embed for a CLIP vector, or auto (default) to let the pipeline decide. | | maxTier | number, enum: 1, 2, 3 | No | The highest tier to use: 1 local OCR only, 2 local vision models, 3 cloud vision (default). |

Notes

Local OCR needs ppu-paddle-ocr or tesseract.js. Handwriting, layout and embeddings need @huggingface/transformers for TrOCR, Florence and CLIP. embed loads CLIP on demand. Cloud vision needs provider credentials and can send the image to a cloud model.

ocr runs OCR alone. handwriting runs TrOCR alone, layout runs the document layout tier alone, and describe runs cloud vision alone. maxTier restricts the allowed processing, and a mode that needs a higher tier returns an error. If no text tier runs, the tool returns an error naming failed tiers or the packages and credentials the call can use.

HTTP images are fetched through AgentOS's imageToBuffer with untrusted: true, which checks public addresses and redirects, limits images to 50 * 1024 * 1024 bytes and applies a 30000 ms fetch timeout. Local and private network addresses are refused. Data URLs are decoded without fetching.

Local paths are refused. A file: URL must name a saved PNG, JPEG or WebP in the caller's subdirectory under imageDir, with the image saver's filename pattern. Saved images larger than 50 * 1024 * 1024 bytes are refused. The directory ownership and write permissions are checked. The caller scope comes from context.userContext.userId, with shared used when it is absent.

Pipelines are built on first use and reused per strategy. Failed builds are retried on the next call. Deactivation disposes of built pipelines and prevents new pipeline creation until activation.

License

Apache-2.0