Connect an AI to Social Stream Ninja

Run a free model on your own computer, or plug in a paid API key. Then point the chat bot at it.

Which setup is right for you?

Every option on this page is the same idea. A server runs a language model and answers requests. Social Stream Ninja sends it the chat message and your instructions, then posts the reply. The Provider setting only tells Social Stream which API style to speak. Ollama has its own native API. Almost everything else, local or cloud, speaks the OpenAI chat format, which is what Custom API is for.

You want…UseWhere to start
Free, private, and the easiest installOllamaOllama tab
A point-and-click app with a built-in model browserLM StudioLM Studio tab
Full control, or you already have .gguf filesllama.cppllama.cpp tab
A Linux GPU server, or one model shared by many botsvLLMvLLM tab
Jan, KoboldCpp, LocalAI, a server on another PC, or a cloud service with an OpenAI-style APICustom APIOther servers tab
No install, pay per use or a free tierOpenAI, Gemini, Groq, OpenRouter, and othersHosted APIs tab
To try it in the next two minutesSSN Hosted Trial LLMHosted APIs tab
No install and nothing leaves your browserLocal Qwen 3.5 (Browser)Pick it in the provider list. The model downloads once and runs on your GPU inside the browser. Slower than a real server, fine for testing.
Speed matters more than smarts for live chat. A reply that lands in one or two seconds feels natural. A reply that takes ten seconds feels broken, even if it is cleverer. Small models like Gemma 4 E2B and E4B are usually the right call. See Pick a model.

Set up your backend

Pick the tab for the server or service you want to use. Each one ends with the exact values to enter in Social Stream Ninja.

Ollama: free and local

Ollama is the simplest way to run a model on Windows, macOS, or Linux. It works on NVIDIA and AMD GPUs and on Apple Silicon, and falls back to the CPU for small models.

  1. Download and install Ollama, then open it. Keep it running while you stream.
  2. Download a model. Open PowerShell or Command Prompt on Windows, or Terminal on macOS and Linux, and run:
    ollama pull gemma4:e4b

    Want the fastest replies on a small GPU or laptop? Use ollama pull gemma4:e2b. Have a 24 GB GPU or a 32 GB Mac? Try ollama pull gemma4:26b. More choices are in Pick a model and the Ollama library.

  3. Check it is installed with ollama list. Copy the exact name shown, tag included.
  4. Enter these values in Social Stream Ninja (see Connect and test):
ProviderOllama (Native Local API)
Ollama API endpointhttp://localhost:11434
Ollama Model to usegemma4:e4b, or whatever ollama list shows
Keep-alive model time-1 keeps the model loaded so replies stay fast. The default unloads it after 5 idle minutes.

Chrome extension or web version? Ollama refuses requests from browser origins it does not know, so you must set OLLAMA_ORIGINS. The desktop app does not need this. Steps for each operating system are in Fix CORS and connection errors.

Ollama on another computer: set OLLAMA_HOST=0.0.0.0 on that machine, restart Ollama, and use http://ITS-IP-ADDRESS:11434 as the endpoint. Ollama also serves an OpenAI-style API at /v1, so Custom API works with it too, but the native option above is the better fit.

Pick a model: fast beats smart for live chat

A chat bot has a few seconds to answer before the conversation moves on. You do not need the best model, you need one that fits in your GPU memory and starts talking quickly. The Gemma 4 family is a good place to start. Every size understands images, and the same models exist as .gguf files for LM Studio and llama.cpp.

ModelOllama tagDownloadRuns well onGood for
Gemma 4 E2Bgemma4:e2b4.6 to 7.5 GBLaptops, 6 to 8 GB GPUs, even CPU onlyFastest replies. Moderation, short chat answers, the voice co-host.
Gemma 4 E4Bgemma4:e4b (also plain gemma4)6.6 to 9.5 GB8 to 12 GB GPUs, 16 GB MacsThe default pick for a live chat bot.
Gemma 4 12Bgemma4:12babout 8 GB12 GB GPUs, 16 to 24 GB MacsMore knowledge, still quick.
Gemma 4 26B (mixture of experts, 3.8B active)gemma4:26b16 to 19 GB24 GB GPUs, 32 GB MacsNoticeably better conversation that is still quick per word, because only a slice of the model runs for each token.
Gemma 4 31Bgemma4:31b19 to 20 GB24 GB GPUs with room to spareHighest quality, slowest. Not needed for chat.

Download sizes are the ranges Ollama lists for each tag. You need roughly that much free GPU or unified memory, plus a few GB for context.

  • Fits in GPU memory means fast. After a test reply, run ollama ps. It should say 100% GPU. If it shows CPU, pick a smaller model.
  • Keep it loaded. The first reply after a few idle minutes is slow because the model reloads from disk. Set Ollama keep-alive to -1 in Social Stream, or turn off auto-unload in LM Studio.
  • Skip thinking modes. Reasoning adds seconds before the first word. Social Stream hides the reasoning text, but it still has to wait for it. Thinking settings vary by model and server. Social Stream uses the server's default thinking behavior for Ollama. If replies are too slow, choose a non-thinking model or configure a non-thinking default on your server. Ollama thinking controls.
  • Other families work too. Qwen 3.5, Llama, Mistral, and Phi are all fine. Pick an instruction-tuned chat model (often marked -it or instruct) and paste its exact tag.
  • Bigger is not safer. A model that spills out of GPU memory can be ten times slower than one that fits. When in doubt, go one size down.

Connect and test in Social Stream Ninja

  1. In Social Stream settings, open Bots & AI → Chat Bots and AI services → Configure LLM Service Provider.
  2. Under Configure LLM, pick your provider and fill in the endpoint, model, and key from your tab above.
  3. Click Test selected chat bot and wait for a reply. The first reply can take a while when the model is still loading. Read any error that appears under the button. It usually names the problem.
  4. Open Chat Bot - Primary and turn on Enable the LLM AI chat bot.
  5. For your first live test, turn on Bot replies ONLY go to the bot overlay page and open the bot overlay link under Overlay Page and TTS for Chat Bot. Nothing is posted to your real chat until you turn that off.

The chat bot setup guide covers trigger words, reply targets, bot names, and why a connected AI can still stay silent in chat.

Fix CORS and connection errors

CORS is a browser rule. A web page may only call another address if that server says the page is allowed. Whether it affects you depends on where Social Stream Ninja is running.

Where it runsDoes CORS apply?What to do
Desktop appNo. Requests leave from the app itself, not from a web page.Read the test error: check the server address, model name, API key and quota. For connection failures, confirm the server is running and reachable on that computer.
Chrome extensionMostly no. The extension is allowed to call any local address, so LM Studio, llama.cpp, and vLLM work without changes.Ollama is the exception. It checks the request origin and answers 403 unless OLLAMA_ORIGINS includes chrome-extension://*. Steps are below.
Web version in a browser tabYes, the full browser rules.The server must allow the origin https://socialstream.ninja. Ollama: add it to OLLAMA_ORIGINS. LM Studio: turn on Enable CORS. llama.cpp and vLLM allow it by default. If Chrome asks for permission to reach devices on your local network, allow it. Current Chrome can allow HTTP requests to a private IP address or .local hostname after local-network permission is granted. If your browser still blocks the connection as mixed content, use the desktop app or an HTTPS endpoint. Chrome local-network access.

Set OLLAMA_ORIGINS

Use chrome-extension://*,https://socialstream.ninja to allow the extension and Social Stream website. A value of * allows requests from any website. Ollama only reads the variable when it starts, so always quit and reopen it afterwards.

Windows

  1. Quit Ollama from the system tray.
  2. Open the Start menu and search for Edit environment variables for your account.
  3. Add a user variable named OLLAMA_ORIGINS with the value chrome-extension://*,https://socialstream.ninja, then click OK.
  4. Start Ollama again and click Test selected chat bot.

macOS (Ollama app): run this in Terminal, then quit and reopen Ollama. Repeat it after a reboot.

launchctl setenv OLLAMA_ORIGINS "chrome-extension://*,https://socialstream.ninja"

Linux (systemd service): run sudo systemctl edit ollama.service, add the lines below, then run sudo systemctl daemon-reload && sudo systemctl restart ollama.

[Service]
Environment="OLLAMA_ORIGINS=chrome-extension://*,https://socialstream.ninja"

Quick test on any system: quit Ollama, then start it from a terminal with the variable set for that session only.

# PowerShell
$env:OLLAMA_ORIGINS="chrome-extension://*,https://socialstream.ninja"; ollama serve

# macOS or Linux
OLLAMA_ORIGINS="chrome-extension://*,https://socialstream.ninja" ollama serve

What the error means

You seeLikely causeFix
403 Forbidden from OllamaOrigin blockedSet OLLAMA_ORIGINS as above and restart Ollama.
Failed to fetch, or a CORS message in the browser consoleServer not running, wrong port, or CORS off on a browser surfaceOpen the endpoint in a browser. Ollama shows “Ollama is running”. OpenAI-style servers list models at /v1/models. For browser-page requests, enable CORS on the server; for Ollama, check its allowed origins as above.
404 or model not foundModel not downloaded, or the name does not matchCompare with ollama list or /v1/models. For Custom API the model must be the server's id, not the .gguf file name.
401 or 403 from a cloud providerMissing or wrong key, or no billing set upMake a fresh key, paste it without spaces, and add credit or a payment method.
429Rate limit or quota reachedAdd credit, pick a cheaper model, or make the bot reply less often.
The first reply takes 20 to 60 seconds, then it is fineThe model is loading from diskSet keep-alive to -1, or choose a smaller model.
Every reply is slow or times outThe model does not fit in GPU memory and is running on the CPURun ollama ps. Go one size down, or use a hosted API.
Empty or rambling repliesA base model instead of a chat model, or a thinking model that ran out of timeUse an instruction-tuned model and turn thinking off.
Test works, but the bot never replies in chatThe AI is fine. The bot settings decide which messages it answers.See Fix problems in the chat bot guide.

Images, voice, and realtime AI

Vision

Social Stream Ninja sends pictures to the AI when a feature attaches them. The private chat bot can attach screenshots, and the voice co-host can send one still image from your camera or screen share with each request. It never streams live video. For that to work, the model has to understand images.

  • Ollama: every Gemma 4 size, Gemma 3 from 4B up, Qwen 2.5 VL, and LLaVA all accept images.
  • LM Studio and llama.cpp: use a vision model and make sure its mmproj file is loaded alongside it.
  • vLLM: serve a vision model such as Gemma 4.
  • Hosted: OpenAI, Gemini, and OpenRouter vision models accept images. Grok and Groq only with their vision models. DeepSeek and Bedrock are text only in Social Stream, so images are not sent to them.

If the model is text only, the picture is dropped or the request fails, so check this before relying on it on stream.

Voice co-host and realtime

The voice co-host listens to your microphone and talks back on stream. There are two routes, and the model you picked on this page matters for the second one.

  • Speech-to-speech services: OpenAI Realtime (uses your ChatGPT API key), xAI Realtime, and Google Gemini Live. Lowest delay and the most natural voice, billed per minute of audio.
  • SSN Configured LLM: uses whatever you set up on this page. The desktop app transcribes your voice locally with Whisper (a 42 MB download on first use), sends the text to your model, and reads the reply with text-to-speech. In the Chrome extension, Chrome's speech recognition does the listening. Here speed is everything, so use Gemma 4 E2B or E4B, or a hosted mini or flash model, and keep it loaded.
  • Local Qwen or Gemma (Browser): the co-host page can also run a small model inside the browser with no server at all. Good for trying it, not the fastest.

Chat bot replies have the same time budget. A model that answers in one or two seconds keeps up with chat. One that needs ten seconds does not, however smart it is.

Text-to-speech

Bot replies can be read aloud from the bot overlay page. Turn it on under Overlay Page and TTS for Chat Bot, then capture that page's audio in OBS. The voice is separate from the AI model, so you can mix a local model with a cloud voice or the other way around.

  • TTS setup guide: browser voices, OBS audio, and the main options in plain language.
  • Local AI TTS guide: private voices that run on your own computer, voice cloning, and self-hosted servers.
  • TTS voice reference: every provider, URL parameter, and troubleshooting step.