Text Generation
Transformers
GGUF
English
recommendation
media-server
plex
jellyfin
structured-output
qwen3
conversational
Run this model with HF Jobs
Run KernelMedia/marquee-ai on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/KernelMedia/marquee-ai. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/KernelMedia/marquee-ai on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/KernelMedia/marquee-ai. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Instructions to use KernelMedia/marquee-ai with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use KernelMedia/marquee-ai with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="KernelMedia/marquee-ai")# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("KernelMedia/marquee-ai", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use KernelMedia/marquee-ai with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf KernelMedia/marquee-ai:Q6_K # Run inference directly in the terminal: llama cli -hf KernelMedia/marquee-ai:Q6_K
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf KernelMedia/marquee-ai:Q6_K # Run inference directly in the terminal: llama cli -hf KernelMedia/marquee-ai:Q6_K
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf KernelMedia/marquee-ai:Q6_K # Run inference directly in the terminal: ./build/bin/llama cli -hf KernelMedia/marquee-ai:Q6_K
Use Docker
docker model run hf.co/KernelMedia/marquee-ai:Q6_K
- Llama new
- LM Studio
- Jan
- vLLM
How to use KernelMedia/marquee-ai with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "KernelMedia/marquee-ai" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "KernelMedia/marquee-ai", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/KernelMedia/marquee-ai:Q6_K
- SGLang
How to use KernelMedia/marquee-ai with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "KernelMedia/marquee-ai" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "KernelMedia/marquee-ai", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "KernelMedia/marquee-ai" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "KernelMedia/marquee-ai", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Ollama
How to use KernelMedia/marquee-ai with Ollama:
ollama run hf.co/KernelMedia/marquee-ai:Q6_K
- Unsloth Desktop
- Pi
How to use KernelMedia/marquee-ai with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf KernelMedia/marquee-ai:Q6_K
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "KernelMedia/marquee-ai:Q6_K" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use KernelMedia/marquee-ai with Docker Model Runner:
docker model run hf.co/KernelMedia/marquee-ai:Q6_K
- Lemonade
How to use KernelMedia/marquee-ai with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull KernelMedia/marquee-ai:Q6_K
Run and chat with the model
lemonade run user.marquee-ai-Q6_K
List all available models
lemonade list
- Hermes Agent
How to use KernelMedia/marquee-ai with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf KernelMedia/marquee-ai:Q6_K
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:9931/v1 hermes config set model.default KernelMedia/marquee-ai:Q6_K
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use KernelMedia/marquee-ai with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf KernelMedia/marquee-ai:Q6_K
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:9931/v1 \ --custom-model-id "KernelMedia/marquee-ai:Q6_K" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
real API examples, plug-and-play quickstart
Browse files123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183# Running Marquee on your own server**Marquee-4B v1.0**Complete setup, start to finish. Roughly an hour, most of it unattended.## What you are building```your media server| exports {id, tmdb_id, media_type}vmarquee ingest ------> library index (titles, cast, crew, embeddings)|vmarquee serve <-----> Ollama (the model)| HTTPvyour media server UI```The model decides which rows to show and names them. The **retriever** — the index —decides what goes in them. Both matter; the model on its own is not useful.## 1. Install```bashpip install marquee-aicurl -fsSL https://ollama.com/install.sh | sh # if you do not have it```## 2. Get the model```bashhuggingface-cli download KernelMedia/marquee-ai --local-dir marquee-modelcd marquee-model && ollama create marquee -f Modelfile && cd ..```Do not edit the `Modelfile`'s `TEMPLATE` block or raise `temperature`. Both areload-bearing — see Troubleshooting.## 3. Get a TMDB keyFree, two minutes: https://www.themoviedb.org/settings/api — choose Developer,non-commercial.```bashecho 'TMDB_API_KEY=your_key' >> .env```TMDB is free for non-commercial use and requires attribution. **Commercial use needs awritten agreement with TMDB** — if you charge for access to this, talk to them first.## 4. Harvest metadata```bashmarquee harvest --out tmdb_full.jsonl```~55 minutes, ~120,000 titles, ~210 MB. It caches every response, so re-runs are freeand an interrupted run resumes.This keeps titles with 10+ votes (plus all anime regardless, which skews to low votecounts). That drops TMDB's 1.4M entries to ~120k by removing shorts, unreleased stubsand uploads with no credits — none of which can form a recommendation row anyway.`--min-votes 0` takes everything: 1.4M titles, ~10 hours, ~108 GB of cache, and about27 GB of RAM to load. Not advised.## 5. Export your libraryOne JSON object per line. Only `tmdb_id` and `media_type` are required:```json{"id": "myserver-04471", "tmdb_id": 335984, "media_type": "movie"}{"id": "myserver-04472", "tmdb_id": 1396, "media_type": "tv"}```Include `id` and recommendations come back keyed the way your server already refers tothings, so you need no lookup table.**Jellyfin**: `/Items?Recursive=true&Fields=ProviderIds` gives `ProviderIds.Tmdb`.**Plex**: `/library/sections/{id}/all` — the `guid` field carries the TMDB id onrecent agents.## 6. Build the library index```bashmarquee ingest --server library.jsonl --catalog tmdb_full.jsonl \--out lib.jsonl --mode requestable```| mode | contents ||---|---|| `owned` | only what is on your server — every recommendation is playable || `requestable` | your items **plus** unowned titles flagged `owned: false`, so the UI can offer a Request button |`requestable` plus `owned_only` at query time is the flexible setup: one index servesboth, and you can flip per user.Anything whose `tmdb_id` is not in the harvest is fetched from TMDB on the spot, socoverage is complete however you filtered. `--no-fetch` disables that.## 7. Serve```bashmarquee serve --library lib.jsonl --model marquee --port 8080```First start builds embeddings (~3 min for 120k titles) and caches them next to thelibrary. Later starts take ~15 s.Watch for the startup line:```[marquee] contract v1 self-test: PASS - contract v1 OK (3/3 clean)```FAIL means the model and the package disagree, or the chat template is wrong. It willsay which.## API```bashcurl -X POST localhost:8080/recommend \-H 'Content-Type: application/json' \-d '{"seed_id": "myserver-04471", "row_size": 20}'curl 'localhost:8080/search?q=Scorsese' # titles and peoplecurl 'localhost:8080/person?name=Roger+Deakins'curl localhost:8080/healthcurl -X DELETE localhost:8080/cache # after a library rescan````/recommend` takes `seed_id` (exact) or `title`. Ambiguous titles return **409 with thecandidates** rather than guessing — `Godzilla` matches three films. Narrow with `year`and `media_type`, or write `"Top Gun (1986)"` directly.`/search` and `/person` are index lookups with no model call, so they are instant. Only`/recommend` uses the GPU.### CachingRecommendations for an item are stable until the library changes, so they are cached.`/health` reports hits and misses. **Call `DELETE /cache` after a rescan** or you willserve rows referring to items you no longer have.## Hardware| | ||---|---|| VRAM | ~3.5 GB. A 4 GB card is fine. CPU works but is slow — cache matters more there. || RAM | ~2.2 GB for a 120k catalog || Disk | 2.4 GB model, ~210 MB catalog, ~190 MB embeddings, ~2.6 GB API cache |## Troubleshooting**Every row comes back typed `director`, titles look like item names.**The chat template is missing. Ollama ignores the Jinja template inside GGUF and fallsback to a raw passthrough, so the model never sees the `<|im_start|>` markers it wastrained on. Confirm your Modelfile has the `TEMPLATE` block:```bashollama show --template marquee # must NOT be just "{{ .Prompt }}"```**Output is valid sometimes and not others.**`temperature` is too high. Structured output needs near-greedy decoding: 0.1 gave 8/8clean in testing, 0.3 gave 5/8.**Self-test fails at startup.**Model and package are on different contract versions. Both must be contract v1.**Server items are being dropped at ingest.**They have no TMDB id, or the id is wrong. The ingest reports the count and samples. On-demand fetch handles anything merely missing from the harvest.**Rows are thin, or missing entirely.**The library is small. A director with one other credit present gets no row — that isdeliberate, the model is trained not to pad. Harvest more, or use `requestable` mode.## AttributionThis product uses the TMDB API but is not endorsed or certified by TMDB.123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269# MarqueeRecommendation rows for a media server.## Install```bashpip install marquee-ai```You also need [Ollama](https://ollama.com) to run the model.## Download```bashhf download KernelMedia/marquee-ai --local-dir marqueecd marqueeollama create marquee -f Modelfile```~2.8 GB: the model, plus a catalog of ~122,000 films and shows with full cast and crew.## Run```bashmarquee serve --library catalog.jsonl --port 8080```Loads in about 15 seconds.## Use it```bashcurl -X POST localhost:8080/recommend \-H 'Content-Type: application/json' \-d '{"title": "The Sopranos", "row_size": 20}'``````Shows like The Sopranos Gomorrah, Boardwalk Empire, The Wire, ZeroZeroZeroMore from Tim Van Patten Game of Thrones, Black Mirror, Boardwalk EmpireMore with Edie Falco Nurse Jackie, OzShot by Alik Sakharov Game of Thrones, House of Cards```Or from the command line:```bashmarquee recommend --library catalog.jsonl --seed "Blade Runner 2049" --row-size 20marquee person --library catalog.jsonl --name "Roger Deakins"```Set `MARQUEE_LIBRARY` once and drop the flag:```bashexport MARQUEE_LIBRARY=$PWD/catalog.jsonlexport MARQUEE_MODEL=marqueemarquee recommend --seed "Dune (2021)"```## API### `POST /recommend````bashcurl -X POST localhost:8080/recommend -H 'Content-Type: application/json' \-d '{"title": "The Sopranos", "row_size": 20}'``````json{"seed": {"id": "tmdb:tv:1398", "title": "The Sopranos", "year": 1999,"media_type": "tv", "rating": 8.7, "owned": true},"rows": [{"type": "thematic", "title": "Shows like The Sopranos","items": [{"id": "tmdb:tv:31050", "title": "The Last Don", "year": 1997,"media_type": "tv", "rating": 7.1, "owned": true},{"id": "tmdb:tv:12822", "title": "The Octopus", "year": 1984,"media_type": "tv", "rating": 7.8, "owned": true}]},{"type": "director", "title": "More from Tim Van Patten","items": [{"id": "tmdb:tv:1399", "title": "Game of Thrones", "year": 2011,"media_type": "tv", "rating": 8.5, "owned": true},{"id": "tmdb:tv:1438", "title": "The Wire", "year": 2002,"media_type": "tv", "rating": 8.6, "owned": true}]}]}```Body fields: `seed_id` **or** `title`, plus optional `year`, `media_type`, `row_size`(items per row), `owned_only`, `semantic_k`.Rows arrive in a fixed order — thematic, franchise, director, cast, crew — so a UI canrender them top to bottom without sorting.An ambiguous title returns **409** with the candidates rather than guessing:```json{"error": "5 items match 'Godzilla'; pass seed_id, or narrow with year/media_type","matches": [{"id": "tmdb:movie:124905", "title": "Godzilla", "year": 2014, "media_type": "movie"},{"id": "tmdb:movie:929", "title": "Godzilla", "year": 1998, "media_type": "movie"},{"id": "tmdb:movie:1678", "title": "Godzilla", "year": 1954, "media_type": "movie"}]}````{"title": "Godzilla", "year": 2014}` or `{"title": "Godzilla (2014)"}` resolves it.### `GET /search?q=`Matches titles **and** people, because "Scorsese" is not a title but has 109 credits.```bashcurl 'localhost:8080/search?q=Scorsese&limit=3'``````json{"query": "Scorsese","titles": [{"id": "tmdb:tv:292130", "title": "Mr. Scorsese", "year": 2025,"media_type": "tv", "rating": 8.1, "owned": true}],"people": [{"key": "tmdb:person:1032", "name": "Martin Scorsese","roles": {"director": 47, "actor": 50, "writer": 12}, "credits": 109}],"count": 6}````kind=title` or `kind=person` narrows it. Names are matched loosely: `samuel l jackson`,`Jackson Samuel` and `Inarritu` all resolve.### `GET /person?name=`Everything someone is credited on, films and shows in one list, best first.```bashcurl 'localhost:8080/person?name=Roger%20Deakins&limit=3'``````json{"person": "Roger Deakins","count": 3,"credits": [{"id": "tmdb:movie:278", "title": "The Shawshank Redemption", "year": 1994,"media_type": "movie", "rating": 8.7, "score": 8.66, "votes": 31061,"owned": true, "roles": ["cinematographer"]},{"id": "tmdb:movie:146233", "title": "Prisoners", "year": 2013,"media_type": "movie", "rating": 8.1, "score": 8.04, "votes": 13352,"owned": true, "roles": ["cinematographer"]}]}````score` is what the ranking uses: the raw rating damped toward the catalog mean by votecount, so an 8.2 from 600 votes sits below a 7.6 from 4,300. Someone who both directedand wrote a title appears once with both roles.Options: `media_type`, `owned_only`, `limit`, `by_role=true` for per-role shelves.### `GET /health````json{"status": "ok","contract_version": 1,"model_self_test": {"passed": true, "detail": "contract v1 OK (3/3 clean)"},"cache": {"entries": 0, "hits": 0, "misses": 0, "max": 2048},"library_items": 121727,"owned": 121727,"requestable": 0,"model": "marquee","backend": "http://localhost:11434/v1"}````status` is `degraded` if the self-test fails — the model and package disagree, or thechat template is wrong.### `DELETE /cache`Responses are cached per seed. Call this after a library rescan or you will serve rowsreferring to items you no longer have.`/search` and `/person` are index lookups with no model call, so they are instant. Only`/recommend` uses the GPU.## Restricting results to your own library (optional)By default it recommends from the whole 122k catalog, whether or not you own the title.To mark what is actually on your server -- so a UI can show a Request button on the rest-- export your library and join it:```bashmarquee ingest --server library.jsonl --catalog catalog.jsonl \--out lib.jsonl --mode requestablemarquee serve --library lib.jsonl```Your export needs one JSON object per line; `tmdb_id` and `media_type` are enough:```json{"id": "myserver-04471", "tmdb_id": 335984, "media_type": "movie"}```Every item then carries `"owned": true|false`. Pass `"owned_only": true` on a request todrop the ones you do not have:```bashcurl -X POST localhost:8080/recommend -H 'Content-Type: application/json' \-d '{"seed_id": "myserver-04471", "row_size": 20, "owned_only": true}'````/health` reports the split:```json{"library_items": 121727, "owned": 1670, "requestable": 120057}```**Jellyfin**: `/Items?Recursive=true&Fields=ProviderIds` gives `ProviderIds.Tmdb`.**Plex**: `/library/sections/{id}/all` -- the `guid` carries the TMDB id on recent agents.## Requirements| | ||---|---|| VRAM | ~3.5 GB. A 4 GB card is fine; CPU works but is slower. || RAM | ~2.2 GB for the 122k catalog || Disk | ~2.8 GB || Latency | ~1 s per request on an RTX 3060; cached responses are instant |## Troubleshooting**Every row comes back typed `director`, titles look like item names.**The chat template is missing. Ollama ignores the template inside GGUF metadata and fallsback to a raw passthrough, so the model never sees the tokens it was trained on:```bashollama show --template marquee # must NOT be just "{{ .Prompt }}"```Recreate from the supplied `Modelfile`, and do not remove its `TEMPLATE` block.**Output is valid sometimes and not others.**`temperature` is too high. Structured output needs near-greedy decoding: 0.1 gave 8/8clean in testing, 0.3 gave 5/8. The Modelfile ships 0.1.**Self-test fails at startup.**The model and the package are built against different contract versions. Both must becontract v1.**A title I own is missing.**The catalog covers ~122k titles with 10+ TMDB votes, plus all anime. Genuinely obscurereleases may not be there. `marquee harvest --min-votes 0` rebuilds a wider catalog withyour own free TMDB key.## DataCatalog metadata is from TMDB. This product uses the TMDB API but is not endorsed orcertified by TMDB.## LicenceApache-2.0.
SETUP.md+190-104