Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

orama

БесплатноБез исполняемых скриптовНе проверен

Orama is an in-process search engine for JavaScript and TypeScript: full-text, vector and hybrid search that runs in the browser, on a server or at the edge…

TerminalSkillsот TerminalSkills★ 221 звезда на GitHub

Об этом скилле

Orama — Full-Text & Vector Search Engine

Overview

Orama is an open-source search engine written in TypeScript with zero dependencies. The index lives in memory inside your own process — browser tab, Node.js server, or edge worker — so there is no search server to run. It supports full-text search (BM25 ranking, typo tolerance, prefix matching), filters, facets, sorting, geosearch, and vector or hybrid search over embeddings you provide.

Since v3.0.0 create, insert and search are synchronous; they only return promises when a plugin with async hooks is installed. Their TypeScript return type is a union of both, so await the call (harmless when it is sync) to get a typed result. This skill covers the open-source @orama/orama library, not the hosted Orama Cloud product, which uses a different SDK (@orama/core).

Instructions

Basic Full-Text Search

// src/search/index.ts — Create and populate a search index
import { create, insertMultiple, search } from "@orama/orama";

// Only "string" and "string[]" properties are full-text searchable; the rest are for filters, facets and sorting
export const db = create({
  schema: {
    title: "string",
    content: "string",
    category: "enum",              // Exact-match filter value (not searchable)
    tags: "enum[]",                // Filterable list of values
    publishedAt: "number",         // Unix timestamp for range filters
    author: "string",
    views: "number",
  },
});

await insertMultiple(db, [
  {
    title: "Getting Started with Orama Search",
    content: "Orama is a full-text search engine that works in the browser, on the server, and at the edge.",
    category: "tutorial", tags: ["search", "javascript", "performance"],
    publishedAt: Date.parse("2026-09-12"), author: "Alex Chen", views: 1250,
  },
  {
    title: "Building Real-Time Search with React",
    content: "Implement instant search in a React application with typo tolerance.",
    category: "tutorial", tags: ["react", "search", "ui"],
    publishedAt: Date.parse("2026-09-25"), author: "Marta Lopez", views: 890,
  },
]);

const results = await search(db, {
  term: "serch engne",
  tolerance: 1,                     // Max edit distance per word. Default is 0: typos match nothing
  properties: ["title", "content"], // Which fields to search (default: all string fields)
  boost: { title: 2 },              // Matches in the title count double
  limit: 10,                        // Default 10
  offset: 0,
});

console.log(`Found ${results.count} results in ${results.elapsed.formatted}`); // "Found 2 results in 380μs"
for (const hit of results.hits) {
  console.log(`${hit.score.toFixed(2)} | ${hit.document.title}`);          // "0.62 | Getting Started with Orama Search"
}

Other calls from the same package: insert, update, upsert, remove, getByID, count. Omitting term matches every document. exact: true matches whole words only and overrides tolerance.

Filters and Facets

// src/search/filtered.ts — Search with filters, facets, and sorting
import { search } from "@orama/orama";
import { db } from "./index.js";

const filtered = await search(db, {
  term: "search",
  where: {
    category: { eq: "tutorial" },                       // enum: eq, in, nin
    publishedAt: { gt: Date.parse("2026-09-01") },      // number: gt, gte, lt, lte, eq, between
    views: { between: [100, 10000] },                   // One operator per property — use between for a range
    tags: { containsAll: ["react"] },                   // enum[]: containsAll, containsAny
  },
  sortBy: { property: "views", order: "DESC" },         // Most popular first
  limit: 20,
});

// Faceted search — get aggregated counts for filters
const faceted = await search(db, {
  term: "search",
  facets: {
    category: { limit: 10 },               // Top 10 categories
    tags: { limit: 20 },
    views: { ranges: [{ from: 0, to: 100 }, { from: 100, to: 1000 }, { from: 1000, to: 100000 }] },
  },
});
console.log(faceted.facets);
// {
//   category: { count: 1, values: { tutorial: 2 } },
//   tags: { count: 5, values: { react: 1, search: 2, ui: 1, javascript: 1, performance: 1 } },
//   views: { count: 3, values: { "0-100": 0, "100-1000": 1, "1000-100000": 1 } },
// }

string properties are filtered with a plain value or a list of alternatives (author: "Chen", author: ["Chen", "Lopez"]), matched token by token. Boolean properties take true or false. Conditions on different properties are ANDed.

Hybrid Search (Keyword + Vector)

Orama stores and compares vectors but does not create them. Generate embeddings with any model, declare the dimension in the schema, and pass the query vector at search time:

// src/search/hybrid.ts — Hybrid search combining BM25 and vector similarity
import { create, insertMultiple, search } from "@orama/orama";
import { embed } from "./embed.js"; // Your function: (text: string) => Promise<number[]>,
Полный SKILL.md на GitHub

Установить orama в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

_scores.json

FAQ

Что делает скилл orama?

Orama is an in-process search engine for JavaScript and TypeScript: full-text, vector and hybrid search that runs in the browser, on a server or at the edge with no external service. Use when someone asks to "add search to my docs site", "client-side search", "typo-tolerant search", "faceted search in JavaScript", "vector search without a database", or mentions Orama or @orama/orama. Covers schemas, filters, facets, sorting, embeddings, React, and saving an index to a file.

Как установить скилл orama?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл orama запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить orama с