logoalt Hacker News

If you don't run your own LLM proxy, how do you know whats going on?

292 points • by amrrs • yesterday at 9:09 PM • 203 comments • view on HN

Comments

CharlieDigital • today at 11:38 AM

You don't need a proxy to do this. I would argue you should not use a proxy to do this because the end result is a single point of failure direct in the line of your productivity.

Both Codex[0] and Claude Code[1] output OTEL traces that you can ingest and process.

Other harnesses like OpenCode, Pi, etc. you can hook into their plugin architecture and implement your own OTEL emission from a plugin (or use an off the shelf plugin[2]).

Host an OpenTelemetry collector[3][4] or rely on your existing collector infra (e.g. Datadog (no affiliation), AppInsights, etc.)

The OTEL traces will have exactly what you need. Tool calls, full prompts, token usage/cost, etc. It is less intrusive and does not become a single-point-of failure since the OTEL emission and collection is best-effort whereas a failing/overloaded proxy is going to strand your team until resolved. It's OK if you lose some OTEL traces; no productivity lost.

The configuration to enable this for Codex and CC is very straightforward (see [0][1] + [5])

--

[0] https://learn.chatgpt.com/docs/config-file/config-advanced#o...

[1] https://code.claude.com/docs/en/monitoring-usage

[2] https://github.com/DEVtheOPS/opencode-plugin-otel

[3] Open source collector: https://opentelemetry.io/docs/collector/

[4] Sample configuration for filtering noise: https://github.com/zeeq-ai/zeeq-app/blob/main/build/otel-col...

[5] Concrete examples of .codex/config.toml and .claude/settings.json: https://zeeq.ai/docs/key-features/session-telemetry#configur...

➕ show 3 replies
NeutralWanted • today at 1:30 AM

I'd love to do something like this, or use API keys, but I still don't understand how people justify the cost of using API keys vs. subscription.

I tested it once, I'm in on the 20x claude max ($200/month) and I either max my weekly limit every week or come really close. But it only took 2-3 days to hit $200 spend with api keys.

➕ show 15 replies
jakozaur • today at 3:19 AM

Proxies are good if you pay API prices.

For subscriptions, it is easier to collect the JSONL files from ~/.claude/projects/ and similar directories. They are better organized (e.g., subagents) than what the proxy sees.

However, the best value comes from collecting agent sessions across the whole organization. You'll need to scrub credentials and handle security.

➕ show 4 replies
passive • today at 2:20 AM

Tailscale makes Aperture available for free, and while it's not something you own, it is in your tailnet, so at least you have a certain amount of control over how things access it. It gives a nice view of what agents are doing, with lots of configurability and extensions, and the team behind it has been updating pretty steadily.

I happen to be working on an extension to Aperture, so I have my own reason to promote it. But I do think it's a nice easy solution, and I promoted it to people before I was extending it.

➕ show 1 reply
soared • today at 1:07 AM

One man’s fun is another man’s “idk what any of these words mean, I pay $20/mo for some company to abstract this complexity away”

For clarity, I do like blog posts like these.

variety8675 • today at 1:39 AM

I’m not sure what people are doing with these subscriptions to feel the need to monitor what’s going on this closely. A $100 OpenAI subscription feels effectively infinite for my usage at home

➕ show 5 replies
hoppp • today at 12:46 AM

Yup. Setting up liteLLMProxy on some servers as we speak and will start playing around.

I can't orchestrate agents in sandboxes without it.

1. It can issue virtual keys, so provider API keys never go near the sandbox

2. I can see everything

3. Guardrails

And much more

Looking forward to it.

➕ show 2 replies
jubilanti • today at 1:27 AM

Yeah you should run an LLM proxy, but imagine a world where LiteLLM and all the other LLM shovels weren't buggy vibecoded messes. And with the velocity of updates I feel there has to be vulnerabilities there. Or am I just holding it wrong? Anyone got a good alternative?

➕ show 2 replies
gbdubs • today at 5:23 PM

Posting in case it is useful to others - I've built a OSS Mac App that handles this across various providers and lets you examine usage in exacting detail.

The App: https://github.com/Pythia-Software/pharos Blog Post: https://grady.dev/projects/pharos/

impure • today at 1:01 AM

OpenRouter does all this for you. It's pretty nice. Although for apps I use another server to lock down the requests even more and prevent the client from seeing my API key.

ndom91 • today at 3:45 AM

Want to shamelessly self promote my self hosted proxy, supports subs and API usage.

Primaily designed as a local LLM ops project, but will definitely do proxying for claude-code, opencode, codex, etc

https://llama-dash.dev

jqdsouza • today at 3:24 PM

We've tackled the core problem of agent telemetry normalization with our open-source project Beacon! https://github.com/Asymptote-Labs/agent-beacon

Beacon is a harness-agnostic, environment-agnostic framework for capturing, normalizing, and storing the full session history of AI agents. We extend the OpenTelemetry GenAI standard and have done the heavy lifting of integrating with 25+ agent harnesses through a combination of OTel instrumentation, hooks, and local session database capture.

This gives you a unified view of agent activity across environments, including local agents, cloud agents, browser-based chat, and agent SDKs, with the ability to track and retain complete session histories across all of them.

Would love your feedback!

Havoc • today at 9:14 AM

Toyed around with it back when claude code showed up, but never really got any useful actionable insights from it so stopped

(Aside from ditching CC & it's bloated sys prompts that is)

➕ show 2 replies
jsphweid • today at 3:19 AM

I don't do this but I do have a system that imports all my conversations with AI (claude code, chatgpt, claude app, etc.) to a storage system I call Chatacombs: a unified storage of most conversations I've had with AI, as detailed as I can easily get.

➕ show 2 replies
awsanswers • today at 2:42 PM

My org is using https://visiqlabs.com/ for this. not a proxy, agent integration with rules engine

pwillia7 • today at 12:29 PM

Until they quit subsidizing my personal tokens I don't think I want this. I do love having insight when I run qwen locally through Claude Code Router so I do agree it's so valuable to have, just not valuable enough to pay API rates lol

left-struck • today at 2:41 AM

I like the content but I have to say the Mark Manson writing style is off putting.

➕ show 1 reply
zaptheimpaler • today at 5:10 AM

I agree its so important to proxy and capture all the data. I've been very happy with bifrost as a proxy. It's a quality piece of software, unlike LiteLLM. You also get this one interface to access all your models, across all services, including self-hosted, STT models, everything. There are ways to use subscriptions with proxies too, but they are discouraged because of grey-hat uses..

➕ show 1 reply
garou • today at 2:37 AM

https://github.com/gumieri/nenya

my own ai gateway/proxy

chopete3 • today at 2:34 AM

This is the best one I found https://github.com/kenn-io/agentsview

It is a not proxy. It can clearly show whats going on across all agents. The proxy's are generally inconvenient and yet another point of failure. I think the author got to the resort option quickly

kristianpaul • today at 3:25 PM

I do know checking both agent session and logging at the inference side...

jeena • today at 11:44 AM

As long the harness is not open source a proxy won't help, it's easy to phone home on a different subdomain also.

voodooEntity • yesterday at 9:35 PM

Well that was one of the reasons why i build my own agent/harness - to have actual full observability of what it is doing and why it is doing what it is doing.

Don't really understand why other agents to give those insights but well found my solution.

Lucasoato • today at 11:12 AM

Just one info for many: if you’re a big company and have enterprise needs, subscriptions aren’t a solution. OpenAI, Anthropic, Google (ain’t sure about them tbh), GitHub Copilot aren’t offering subsidized subscription prices in their enterprise plans; discounts are calculated differently and these services are much more expensive.

For example, Github Copilot has these AI credits that are insane in terms of costs with the usual token-based pricing.

Feel free to prove me wrong, I really wish I was.

➕ show 1 reply
sroerick • today at 1:25 AM

Seeing some good stuff in the comments, but how are people doing this?

➕ show 2 replies
crossroadsguy • today at 3:47 AM

Some don't need to. Not yet anyway. There's config, there's control, and then there's setup-theatre as a hobby.

jFriedensreich • today at 11:12 AM

what proxy is he using? i support not trying to support a specific product in a post but not even mentioning what you use after writing this seems pretty odd.

➕ show 1 reply
pluc • today at 10:01 AM

It's LLM, of course they don't know what's going on.

joshheitzman • today at 2:37 AM

By running my own agent harness that provides detailed API metrics in the GUI and logs very verbosely.

another_twist • today at 2:28 PM

Umm, observability ? I think the article means to say how do you know the agents arent talking nonsense to each other if you use a multi-agent system. Here again a thin layer of o11y would do the trick and also hooking into the wider ecosystem. Thats without having to bother with a proxy.

jedisct1 • today at 3:52 PM

Agents can log traces, which can be super useful for RL, prompt optimization, tool improvements, etc.

Check out Calibra for example: https://calibra.swival.dev which turns traces from Swival into nice web pages, allows diff'ing traces, etc.

quixoticelixer- • today at 2:54 AM

What is the use case for these sorts of things?

ok_major_9889 • today at 2:03 AM

Why not just grab it from the kernel?

➕ show 1 reply
aa-jv • today at 1:06 PM

Anyone know an easy, out of the box method of doing this inspection on DGXOS (the OS for DGX Spark devices)?

I'm a little miffed that this isn't just an immediate OOBE, but I'm prepared to do some nc/ssh tunnel magic if that'll work properly .. just wondering what other DGX users have vis a vis best practices ..

joaquieneCnix • today at 10:13 AM

> how do you know what's going on

there's the kind of people who care and the kind who doesn't ...

your local politicians and landlords do all kinds of normal, non-funky stuff you don't know about ... as do your local ISP-techies and hobbyists with access to supply chains and sub-distributing units ...

or your local school teachers and some parents and their widdle vintage schemes and circumambient tales they tell some kids but not others ... Lord, some guy even caught teachers and parents running schemes on teens to prep them for gay homo fag stuff, despair, frustration ... running for years ...

and you wonder how peeps don't what is going on xD?<

even those hackies and hackers and programmers and brogrammers and AI superusers who think they know and care and wield some power really really don't

but there you go, AI augmented diluted delusions

stavros • today at 12:57 AM

Does anyone here use LiteLLM for this? How well does it do? Can I use it with my Claude subscription?

➕ show 2 replies
vasco • today at 6:55 AM

All that posturing for the purpose to be manually monitoring cache hits and misses. This can't be serious. Buy a larger plan or reduce some instructions and you don't have to deal with this waste of time.

kennywinker • today at 2:08 AM

> Own your infrastructure

...proceeds to use codex.

With just a 12gb VRAM GPU + 64gb of CPU RAM, and you can actually own your own infrastructure. I can't wait for hardware prices to fall so that becomes even more accessible.

➕ show 2 replies
knodi • today at 1:23 PM

vibes

roosterIllusi0n • today at 3:10 AM

I am boggled how the first step of an llm after you make an orchestrator isn't some kind of proxy that records your personal internet surfing to be used by your personal AI later. Every college should be running in house AI with their own in house search engines and in house any service. Don't go to any college that wants you to use chatgpt or other corporate nonsense. If they can't make local LLMs work, they are not a real college.

yeag123 • today at 6:36 PM

[flagged]

ferozelalani • today at 3:44 PM

[flagged]

jDucky • today at 6:03 PM

[flagged]

News2Use • today at 3:14 PM

[flagged]

CircuitsFit44 • today at 4:09 PM

[flagged]

wheeeeel • today at 12:54 PM

[flagged]

inom155 • today at 4:46 PM

[flagged]

0xguenther • today at 7:51 AM

[flagged]

claud_ia • today at 10:01 AM

[flagged]

sarmedshafi • today at 2:07 PM

[flagged]

🔗 View 6 more comments