20 comments

[ 3.0 ms ] story [ 42.1 ms ] thread
(comment deleted)
> License: Copy me, no licence.

Probably BSD or Apache would be better, as they make it easier for certain organizations to use this. If you want to maximize copying, then a real permissive license is probably marginally better.

Finally, an AI agent that can run on my toaster
qwen coder with a simple funky prompt?!

`strcpy(agent.messages[0].content, "You are an AI assistant with Napoleon Dynamite's personality. Say things like 'Gosh!', 'Sweet!', 'Idiot!', and be awkwardly enthusiastic. For multi-step tasks, chain commands with && (e.g., 'echo content > file.py && python3 file.py'). Use execute_command for shell tasks. Answer questions in Napoleon's quirky style.");`

Love this, old school vibe with a new school trick.

The makefile is harder to comprehend than the source, which is a good omen.

Note: 4KB... BUT calling upon curl, and via popen and not using libcurl...

PS: your domain link has an extra `x`.

Why do you compress the executable? I mean this is a fun part for size limit competitions and malicious activities (upx often gets flagged as suspicious by a lot of anti virus, or at least it used to), but otherwise I do not see any advantage other than added complexity.

Also interesting that "ultra lightweight" here means no error reporting, barely checking, hardcoding, and magic values. At least using tty color escape codes, but checking if the terminalm supports them probably would have added too much complexity......

Fascinating. tested to compile on cygwin?? Maybe try to implement the logic without llm api? I know i'm asking the quadrillion dollar question but still...you're dealing with C, try to punch "above" your weight with a literal AGI project, i hate apis (well try to avoid them, not always possible).
Perfect, was looking for something just like this. I downloaded Warp.dev only for this functionality, plus saved launch configurations. But still frustrated with Warp's latency for simple terminal commands, it's sometimes faster to open ChatGPT and ask it "what's the command to do x".
4 KB + whatever curl takes (540 KB on my machine).
Why not just do this with a shell script? It's just a wrapper around curl.
This is not an AI agent, this is just a CLI for openrouter.ai with minor whistles.
Not even that.

"Agent-C: a 4KB AI agent" - my first thought was: obviously they did not fit any model to that size! They probably just wrote an http client, right? Wrong, they... call curl! Not even use curl API. Well, at least it handles encryption.

Bonus: command injection

  OR_KEY="abc' ; rm -rf / ;" ./agent-c
82 upvotes so far. Seems like HN readers engage more with headlines than the body of the post itself.
Does anyone know if Tool calling on openrouter as reliable as the "original" models hosted on the 'other' providers?
it would be cool to see, the AI agents directly calling the syscalls. lol
openrouter's daily limits are doggy doodoo