SkillAgentSearch skills...

Hybooru

Hydrus-based booru-styled imageboard in React

Install / Use

/learn @funmaker/Hybooru
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Hybooru

<p align="center"> <img src="static/logo.svg" width="256"><br/> <a href="https://github.com/funmaker/Hybooru/releases/latest"><img src="https://github.com/funmaker/Hybooru/actions/workflows/release_build.yml/badge.svg"></a> <a href="https://github.com/funmaker/Hybooru/pkgs/container/hybooru"><img src="https://github.com/funmaker/Hybooru/actions/workflows/docker_build.yml/badge.svg"></a> </p>

Hydrus-based booru-styled imageboard in React, inspired by hyve.

Demo: https://booru.funmaker.moe/

API Documentation

Changelog

Hybooru allows you to create an online booru-styled imageboard and REST API on top of Hydrus client, allowing you to access your collection from anywhere, without the need for running Hydrus instance. It uses its own PostgreSQL database, populated using metadata from Hydrus' SQLite database. Files are not cloned and instead served directly from Hydrus's database. You need to regenerate the Hybooru's database every time you want to update it. Make sure to properly configure configs.json file. Stop Hydrus when you regenerate HyBooru's database if you plan to use live Hydrus' database (use hydrus backup instead if possible)

Features

  • Searching by tags
  • Negative search
  • Ratings
  • Sorting (date imported, rating, size, etc)
  • Searching tags and autocomplete
  • Notes and translation overlays
  • tag and post relations (parents/siblings, duplicates/alternatives)
  • Colored tags
  • Blurhash
  • REST API
  • Mobile support
  • OpenGraph and OpenSearch
  • Supports browsers without JS

Minimum Hydrus Version: v586

Keep in mind this project is not a standalone, fully-fledged booru, but rather a read-only interface to your Hydrus database. It does not provide any way to manage your posts or tags. The only way to add/modify your data is to do these changes in Hydrus and then rebuild Hybooru's database again(can be done from the cog menu on search/post page).

Currently, only Hydrus Client database is supported. You cannot use Hybooru on top of Hydrus Server.

Setup

  1. Install NodeJS, npm and PostgreSQL.
  2. Create new Postgresql database and user.
  3. Allow user to use pg_trgm and intarray extensions. Either:
    • Grant the user permission to create trusted extensions: GRANT CREATE ON DATABASE <database> TO <user>.
    • Create the extensions yourself: CREATE EXTENSION IF NOT EXISTS pg_trgm; CREATE EXTENSION IF NOT EXISTS intarray;.
  4. Download latest Release production build or build it yourself.
  5. Extract server files.
  6. Edit configs.json to specify database credentials, hydrus db location and other options. See Configuration.
  7. (Optional) Configure reverse proxy.
  8. Run npm install to install dependencies.
  9. Run npm start to start server.

Searching Query Syntax

Searching tries to imitate classical booru's syntax. All tags are lowercase and use _ instead of space character. You can also use ? to match for single character(eg: ?girl) and * to match number of characters(eg: blue_*). Patterns prefixed with - will be excluded from results. Patterns are matched against tag's name, but Hydrus's namespace:subtag syntax is also supported.

Additionally you can sort results by including order:* in query. Supported sorts are: order:date, order:id, order:rating, order:size. You can also append _desc or _asc to specify order(eg: order:date_asc). If not specified, post are sorted by date descending.

If you use a numeric rating service and successfully imported the ratings, you can also filter posts by their ratings using rating: namespace. You can search posts with specific rating(rating:3), range(rating:2-4) or query posts that have not been rated(rating:none).

system: tags from Hydrus are not real tags and are not fully supported. Hybooru only supports system:inbox, system:archive and a non-standard system:trash for filtering posts that are respectively in inbox, are not in inbox and are in trash. You can use them in the blacklist/whitelist and you can also negate them using - prefix in searches.

Eg: 1girl blue_* -outdoors rating:3-5 order:rating_desc

Configuration

Hybooru's config is stored in configs.json file in the project's root directory. Restart Hybooru to apply changes.

| Name | Type | Default | Comment | |------------------------------|---------------------------|---------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | port | number | 3939 | HTTP server port. You can use PORT envvar to override this. | | host | string or null | null | HTTP server host. null will listen on all interfaces. Set to "localhost" if you are not going to connect to it directly over network. You can use HOST envvar to override this. | | hydrusDbPath | string or null | null | Hydrus db or backup location. If null, default platform-dependent locaton is used: %appdata%/hydrus/db(Windows), ~/.local/share/hydrus/db(Linux), ~/Library/Preferences/hydrus/db(MacOS) | | appName | string | "Hybooru" | Specify name of your booru (appears as logo). | | appDescription | string | "Hydrus-based booru-styled imageboard in React" | Booru's description used in OpenGraph. | | adminPassword | string or null | null | Password used to regenerate database (can be accessed from the cog button). Null disables manual database regeneration. You can also use environmental variable HYDRUS_ADMIN_PASSWORD to override the password | | isTTY | boolean or null | null | Overrides colorful/fancy output. true forces, false disables, null automatically determines. Useful when piping output. | | importBatchSize | number | 8192 | Base batch size used during importing. Decrease it if hybooru crashes during import. | | db | PoolConfig | local database | node-postgres config object. See https://node-postgres.com/apis/client for more details. By defaults it attempts to connect to hybooru database at localhost using hybooru as password. Can be overridden with DB_* environment variables (see below). | | posts | object | see below | Options related to posts and files. | | posts.services | (string/number)[] or null | null | List of names or ids of file services to import. Use null to import from all services. | | posts.filesPathOverride | string or null | null | Overrides location of post's files. If null, client_files inside hydrus's db folder is used. | | posts.thumbnailsPathOverride | string or null | null | Overrides location of post's thumbnails. If null, filesPathOverride is used. | | posts.thumbnailsMode | "fit" or "fill" | "fit" | Specifies thumbnail scale mode. Change it to "fill" if you are using scale to fill in hydrus thumbnail options. | | posts.pageSize | number | 72 | Number of posts on single page.

View on GitHub
GitHub Stars139
CategoryDevelopment
Updated4h ago
Forks22

Languages

TypeScript

Security Score

100/100

Audited on Mar 27, 2026

No findings