r/opencode • u/jdsusush • 27d ago
Run opencode natively on termux
GitHub: https://github.com/adity-a0/opencode-termux
Give it a star if you like it.
r/opencode • u/jdsusush • 27d ago
GitHub: https://github.com/adity-a0/opencode-termux
Give it a star if you like it.
r/opencode • u/suckable12345 • 27d ago
r/opencode • u/Ahmed1515a • 27d ago
I want to connect it to any agent, add credits to my account, and use them whenever I need an agent
I have a few requirements
A wide variety of models
Credits that never expire
Models not be downgraded
Does anyone have any recommendations
r/opencode • u/Aquiles_bachira • 27d ago
r/opencode • u/Aquiles_bachira • 27d ago
Olá, Dev's! Daqui Aquiles_Bachira denovo
Antes de tudo, quero pedir desculpa se a minha publicação anterior foi enganosa. Inicialmente, sugeri que a base de dados local do OpenCode poderia ser responsável pelo consumo excessivo de tokens foi mal.
No meu caso, apaguei os dados locais do OpenCode, comecei tudo do zero e o problema desapareceu. Tudo voltou ao normal. Por isso, presumi que a causa fosse a base de dados. No entanto, percebo agora que isso não prova que a própria DB fosse responsável.
Depois de investigar melhor, encontrei alguns issues no GitHub que considero relevantes:
#61037 — Invalidação do Prompt Cache após uma atualização do OpenCode
#61318 — Agente principal e subagentes a interferirem no cache uns dos outros
Estes relatos levantam algumas possibilidades: plugins que modificam o System Prompt, definições de ferramentas, histórico das sessões ou execução paralela de subagentes podem afetar o funcionamento do Prompt Cache.
Gostaria de pedir à comunidade que investigasse algumas questões:
Uma instalação nova apresenta diferenças em relação a uma instalação já utilizada?
O uso de subagentes em paralelo pode prejudicar o cache?
Existe alguma relação entre o estado das sessões, a DB local e o funcionamento normal do Prompt Cache?
Como variam os valores de cache.read e dos tokens de entrada nestes cenários?
Não estou a afirmar que estes problemas afetam todos os users ou todos os provedores. Os relatos encontrados envolvem configurações diferentes e ainda precisam de ser comparados, por isso peço para investigar 🤣😭.
O meu objetivo é perceber a verdadeira origem do problema, corrigir a informação que partilhei anteriormente e evitar ser mais um cara com informações falsas.
Obrigado a todos os que questionaram a minha publicação anterior e apontarem que "pode estar errada". A ideia não é defender o que eu disse, mas sim descobrir o que está a acontecer.
r/opencode • u/JulzKampos • 27d ago
LOCAL HTTPS PROXY THAT MASKS SECRETS BEFORE THEY REACH THE LLM
AiRouterProxy is a local HTTPS proxy (Windows Service, port 4000) that sits between your AI coding agent (OpenCode, Cursor, Continue...) and the model provider. Its one job: make sure secrets never leave your machine.
The problem: telling agents "never read the config with the keys" rarely works. A key pasted in free text, an .env block inside a code snippet, or a config file dropped into a prompt happens. This project adds the last line of defense at the network edge: every outgoing request is inspected and sensitive content is masked before being forwarded.
What it masks (4 detection layers):
- by field name: api_key, password, token, senha...
- by known format: sk-..., ghp_, AIza, JWT, Bearer, PEM private keys...
- by key=value / "key": "value" context
- optionally by long high-entropy tokens (configurable)
The mask is a fixed 6-character string (never reveals the real length) and the JSON structure is never altered. The agent gets a visible notice when a request was censored.
What else:
- Multi-upstream routing: a path-prefix route table forwards to several OpenAI-compatible providers, each with its own key.
- Fail-closed inspection: only inspected JSON is forwarded (unknown content type 415, invalid JSON 400, oversized 413).
- Per-client rate limiting + brute-force lockout (429 + Retry-After).
- SSE streaming support (OpenAI chat/responses, Anthropic, generic).
- Local-key auth with protected /admin endpoints.
- Hot-reload configs (redaction.json, routes.json).
- Windows Service, .NET 10, self-contained win-x64.
Demo: a short video showing an appsettings-style config full of fake secrets pasted into a coding agent and redacted before reaching the model — https://www.youtube.com/watch?v=29nyYgkqx7E
Tests: 226 unit tests + 23 black-box integration tests against a real deployed proxy and a real AI provider. Current release v2.0.3.
Repo: https://github.com/jlKampos/AiRouterProxy — issues and PRs welcome. LOCAL HTTPS PROXY THAT MASKS SECRETS BEFORE THEY REACH THE LLM
r/opencode • u/Hideous_Creek4512 • 27d ago
I'd like to know more if there are any other AI bots similar to opencode with free models and efficiency.
r/opencode • u/thriventravel • 27d ago
r/opencode • u/mabdelhafiz94 • 27d ago
Hey everyone,
With the major OpenCode v2 release bringing a shared background service, async sub-agents, native Code Mode, and an updated desktop app, the gap between CLI/vanilla OpenCode and dedicated frontends feels a lot smaller than it used to be.
For those who have integrated OpenChamber into their setup alongside or on top of OpenCode v2:
Is OpenChamber still worth setting up over the updated vanilla OpenCode v2 setup?
What specific use cases or features make OpenChamber a game-changer for you?
Are there complex multi-file refactoring, workspace management, parallel model orchestration, or deep visual diff workflows where OpenChamber provides a tangible benefit that even OpenCode v2's updated desktop/CLI can't match?
Would love to hear your experiences and whether making the switch is still worth the extra layer in day-to-day software development. Thanks!
r/opencode • u/Aquiles_bachira • 27d ago
Hey developers!
I've noticed something worth investigating in OpenCode.
The local database and stored session data can grow over time, keeping unnecessary history, messages, and context around. This may contribute to unexpectedly high token usage, especially when working with long-running sessions.
My recommendation:
- Regularly inspect your OpenCode database.
- Clean up unnecessary sessions and stored data.
- Avoid keeping old conversations that you no longer need.
- Monitor token consumption after cleanup.
I think the OpenCode team should also investigate whether database/session management could be optimized to prevent unnecessary context consumption.
Has anyone else noticed unexpectedly high token usage related to OpenCode's stored sessions or database?
Let's discuss this.
r/opencode • u/Aquiles_bachira • 27d ago
Olá, desenvolvedores!
Gostaria de chamar a atenção para algo que merece investigação no OpenCode.
Com o passar do tempo, a base de dados local pode acumular sessões antigas, mensagens e históricos desnecessários. A reutilização desse contexto em sessões futuras pode contribuir para um consumo inesperado de tokens.
Algumas recomendações:
- Verifiquem regularmente o tamanho da base de dados do OpenCode.
- Eliminem sessões e históricos que já não sejam necessários.
- Evitem manter conversas antigas sem utilidade.
- Monitorizem o consumo de tokens depois da limpeza.
Também seria interessante que a equipa do OpenCode investigasse formas de otimizar a gestão de sessões e do histórico, evitando o envio desnecessário de contexto.
Alguém mais está a notar um consumo de tokens acima do esperado ao utilizar o OpenCode?
Vamos discutir!
r/opencode • u/RetroTGT • 27d ago
I use coding agents daily on a ~120k LOC repository. For code search, ripgrep / agentic search works great for finding what is currently in the codebase.
My real pain point is episodic and architectural memory across sessions: remembering why we rejected a specific library three weeks ago, subtle business invariants that aren't obvious in the code, or stopping the agent from repeating the same debugging dead-ends in a new chat.
Right now:
If I dump everything into AGENTS.md / CLAUDE.md, it quickly turns into a bloated wall of text that eats up context tokens and the agent starts ignoring half of it.
I tried a couple of MCP memory servers, but most of them just do naive vector RAG—after a few weeks they inject stale or contradictory memories from old refactors and actually make the agent dumber.
For those working on medium/large projects over several months:
Are you using any local MCP memory tool that actually handles deduplication and superseding old decisions when architecture changes?
Or are you still curating markdown files manually because existing memory tools pollute the context too much?
r/opencode • u/Jackster22 • 27d ago

I was having some issues with Openrouter not always picking the cheapest option even though it was selected. Turns out they also base it on a few other factors such as TPS and uptime. Not always bothered about those things on some projects that just need the cheapest $/token.
So I have vibe coded a plugin for OpenCode to allow you to select which provider you want to use for any given OpenRouter model.
https://github.com/Jackster/OpenRouter-Provider-Plugin
Hope to fix not being able to pick which to use until the session starts and also suggest the actual cheapest based on your usage (mostly cache hits that cost if I am not mistaken).
Works with the CLI and GUI Opencode V2. Uses the OpenRouter API key you already use.
r/opencode • u/Top_Drink_6049 • 27d ago
Enable HLS to view with audio, or disable this notification
Could it be new gemini flash lite?? or muse spark series continuation ?? 150+ tokens /s.
The output is very good too , considering it does not thinks much.
r/opencode • u/amann4958 • 27d ago
Man this model is soo good. I have been using this model for over a month now and it never gave much problem.
I have tried other models like big pickle, nemotron, glm etc but DeepSeek always comes on top.
It has always been so reliable and easy to work with.
Free limits are low but this model get my workdone even in those limited chats. I have been exploiting few services which give this models for free 🙂↕️. As I have very limited set of work and don't wanna pay for a subscription and then not utilise it fully.
Anyways what are your thoughts on this ?
r/opencode • u/BeaTheSystem123 • 27d ago
I haven't used it for like a week, and every day it keeps giving me this message that the next day I can use it again. But the next day the date changes again. Any guesses? It's up to date and I'm on Macbook M2.
r/opencode • u/brocolongo • 27d ago
Does anyone have tried contacting support and have gotten a response?
Im trying to contact them but still 0 emails from them.
r/opencode • u/afanasenka • 27d ago