Skip to content

Repository files navigation

OpenCode for Home Assistant

OpenCode

GitHub Release GitHub Downloads (all assets, all releases) License Python Docs

Talk to your home with AI. OpenCode turns OpenCode Zen — a curated AI gateway with fast, free, OpenAI-compatible models — into Home Assistant conversation agents. Add DeepSeek, MiniMax, GLM, Kimi, Big Pickle, and the free models, then chat with your home from Assist, the voice pipeline, or the conversation UI.

👀 New here? Start with the documentation site for a guided tour, or jump straight to Setup below — it only takes a few minutes and a free API key.

Features

  • 🤖 Conversation Agent — Add unlimited agents, one per model, via config subentries
  • ⚙️ AI Tasks — Generate structured data on demand via the ai_task.generate_data service
  • 🎤 Voice Pipeline Ready — Works with Assist and the voice pipeline
  • 🏠 Home Assistant Control — Let the model call tools to control devices & entities
  • 📎 Attachments — Send images/PDFs with your message
  • 💬 Chat Log Streaming — Real-time token streaming in the conversation UI
  • 🆓 Free Models — Use the free OpenCode Zen models out of the box

Installation

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.

HACS (Recommended)

  1. Open Home Assistant → HACSIntegrationsCustom repositories
  2. Add https://github.com/pranjal-joshi/opencode with category Integration
  3. Click InstallRestart Home Assistant

Manual

  1. Download the latest release
  2. Extract custom_components/opencode into config/custom_components/
  3. Restart Home Assistant

Setup

  1. Get a free API key from opencode.ai/auth
  2. Go to Settings → Devices & Services → Add Integration → OpenCode
  3. Enter your API key (optionally override the Zen endpoint)
  4. Click Add conversation agent, pick a model, and you're done
  5. (Optional) Click Add AI task, pick a model for structured data generation

Documentation

Full instructions, screenshots, and troubleshooting are available on the documentation site.

License

MIT — see LICENSE.

About

Use OpenCode Zen models for conversation agents and AI tasks in Home Assistant

Topics

Resources

Code of conduct

Contributing

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages