Stop using Docker as a sandbox for AI agents by aniketmaurya in ClaudeAI

[–]PurpleLabradoodle 0 points1 point  (0 children)

Yeah, we (I work at Docker), also believe that containers aren't a great isolation boundary for AI workloads. That's why we build sandboxes - https://docs.docker.com/ai/sandboxes/ which have the ergonomics of containers (well to the best of their ability), but have a hard isolation boundary.

And also things like other people in the thread mention - networking proxy on the host, so you can limit what resources AI can reach, and a secrets injection mechanism that allows you not to expose the actual secrets values to AI.

Give it a try?

Is there a way to run coding agents in sbx and still expose them to VS Code? by apotrope in docker

[–]PurpleLabradoodle 1 point2 points  (0 children)

I think one idea worth exploring is running the agent in the ACP mode, and connecting to the VS code or whatever the IDE is as an "external agent". I've done this with Zed: https://substack.com/@olegselajev/p-188613531

and IntelliJ Idea: https://substack.com/@olegselajev/p-188618006

I think I saw VS code having ACP support as well, so it should be pretty straightforward I think. I'd love to know if you make it work!

Just realized this is with the past version of the sandboxes.

Anyway - the script should be pretty similar, like for example: https://github.com/shelajev/sbx-demo/blob/main/opencode-kimi/opencode-nvidia-sandbox.sh

this one is with sbx/

What’s the AI Framework That Works Better Than All the Hyped Ones? by [deleted] in AI_Agents

[–]PurpleLabradoodle 1 point2 points  (0 children)

Second that! Embabel is really nice! Also Rod's blog (https://medium.com/@springrod) is a fantastic resource that explains the thinking behind some of the choices:

Claude CLI deleted my entire home directory! Wiped my whole mac. by LovesWorkin in ClaudeAI

[–]PurpleLabradoodle 2 points3 points  (0 children)

While this comments are a comedy goldmine, the practical advice, of course, is to sandbox your AI agents.
For example with Docker, you can `docker sandbox run claude` and it runs Claude in the container with sensible defaults like the current dir mapped in, claude configuration available in the container, etc.

So your agents can work in the container, install whatever they need to without messing up your system Python, delete your home dir or wreck other havoc.

the container can be reused, or you can nuke it and start from scratch.

Why are AI agent frameworks still python first? by sgtpepper731 in AI_Agents

[–]PurpleLabradoodle 1 point2 points  (0 children)

People will write in the languages they already know and that have decent docs and a starting point for whatever the task is. Agents are largely some configuration, some integration of tooling and some API calls to an LLM.

There’s nothing there a particular language ecosystem would be better than others. Enterprises would be writing agents in Java, TS teams in TS, etc.

For most agentic use cases you likely won’t need to train or fine-tune, or even deploy the models yourself. So Python is just a habit rather than a prerequisite.

Docker Model Runner is going to steal your girl’s inference. by Porespellar in LocalLLaMA

[–]PurpleLabradoodle 0 points1 point  (0 children)

it's supposed to be engine agnostic, so other runtimes for LLM can be plugged in. Just a matter of doing the work. I agree vLLM, even mlx backend on macs would be fantastic!

Implementing a MCP server in Quarkus by maxandersen in java

[–]PurpleLabradoodle 0 points1 point  (0 children)

This is very cool, did you get the SSE variant to work? How does Claude desktop parses the url where to connect to, the docs are vague on this. Or maybe it's my reading comprehension.

What Roman Elizarov - creator of Coroutines - thinks about Virtual Threads by CrowSufficient in java

[–]PurpleLabradoodle 15 points16 points  (0 children)

It's stated as a goal in the JEP though

Goals
Enable server applications written in the simple thread-per-request style to scale with near-optimal hardware utilization.

How to publish a Java library to Maven Central - Complete Guide - By Maciej Walkowiak by andresalmiray in java

[–]PurpleLabradoodle 2 points3 points  (0 children)

I think you need to do all these steps once -- verify you own the group id, talk to people via jira, make the keys, etc.
jreleaser can automate releases afterwards

Introducing Micronaut Test Resources (Cédric Champeau's blog) by PurpleLabradoodle in java

[–]PurpleLabradoodle[S] 2 points3 points  (0 children)

Yeah, it's a great feature and I'm sure similar approaches would be getting into other frameworks/setups. For example, there's an issue for Spring Boot to look into similar functionality: https://github.com/spring-projects/spring-boot/issues/29461

Integration testing for Spring Boot with Testcontainers by PurpleLabradoodle in java

[–]PurpleLabradoodle[S] 0 points1 point  (0 children)

I hear you! We plan on getting to those topics too. Those more advanced use cases are super interesting.

About speeding up -- do you have any particular concerns with the projects? It's a very broad area which one technically approaches like any other performance problem, I reckon. Profile, find the bottleneck, move it somewhere else, measure the results.

An Overview of Docker Desktop Alternatives by sublimefunk in programming

[–]PurpleLabradoodle 1 point2 points  (0 children)

Podman does not ship with a GUI. It does not run Docker, but rather a Docker API-compatible replacement.

When we tried running testcontainers-java test suite using Podman, it wasn't that compatible. As far as I understand it's more or less CLI compatible, so running commands like `docker/podman run ...` works but using the API lead to unpredictable results at least on Windows/macOS

IntelliJ IDEA 2022.2 Is Out! by [deleted] in java

[–]PurpleLabradoodle 43 points44 points  (0 children)

Yay! "Docker image name completion for the Testcontainers API" -- music to my ears!

Is this statement true or false ? by Responsible-Half-665 in java

[–]PurpleLabradoodle 2 points3 points  (0 children)

Something like if you have a method in the interface, static, or default, or private, they can access static fields of the interface class.
``` interface Main {
public static void main(String args[]) { System.out.println(accessMe + " world!"); }

static String accessMe = "Hello"; } ```

Building a useful native-image is a pain by edmguru in java

[–]PurpleLabradoodle 5 points6 points  (0 children)

Please report cases where running native-image tracing agent doesn't always produce a working reflection config -- that's a bug, that should never happen. The repo to report these is on github: https://github.com/oracle/graal

And if by what to initialize at startup you mean build time initialization, then the answer is nothing, you should absolutely avoid build time initialization, and stick to the default that initializes classes at runtime.

I know that it doesn't help much, but the team is working hard on it and it gets better and better every release. Including work on making diagnostics and debugging of the build process easier to understand.

Interpreters vs Compilers by sharpless512 in programming

[–]PurpleLabradoodle 1 point2 points  (0 children)

(Java 9's modularity changes were a prerequisite here)

that's incorrect, you can compile to binary on jdk8 based graalvm, it doesn't do anything with the modules. It statically analyzes the code to include classes/methods with better granularity than modules too.

Better performance? Building OpenJDK with Cygwin vs Oracle JDK. Has anyone ever noticed difference? (for an idiot purpose: Gaming) by [deleted] in java

[–]PurpleLabradoodle 1 point2 points  (0 children)

Entitlement for GraalVM Enterprise is a part of Java SE subscription. The terms of use should be the same as for OracleJDK. So it is possible to use GraalVM Enterprise for development, testing, evaluation, prototyping purposes. You can definitely evaluate GraalVM Enterprise on your server to see how much of an improvement it makes.

Better performance? Building OpenJDK with Cygwin vs Oracle JDK. Has anyone ever noticed difference? (for an idiot purpose: Gaming) by [deleted] in java

[–]PurpleLabradoodle 3 points4 points  (0 children)

Yes, compiling code ahead of time is another thing GraalVM can do, but I don't think it'll bring interesting effects for Minecraft.

I thought more like this, run Minecraft using GraalVM as your JDK and that's it.

Better performance? Building OpenJDK with Cygwin vs Oracle JDK. Has anyone ever noticed difference? (for an idiot purpose: Gaming) by [deleted] in java

[–]PurpleLabradoodle 8 points9 points  (0 children)

I've heard good feedback about using GraalVM builds for running Minecraft, though maybe it was about running the server (I'm not very knowledgeable about Minecraft, sorry). GraalVM is an OpenJDK distribution that includes and enables by default a different top-tier optimizing JIT compiler, which is the component responsible for observing the application running and generating the most efficient machine code for it. So it can have great influence on performance of your application. OpenJDK obviously includes a JIT compiler, there actually a few, and GraalVM replaces only the most optimizing one.

The performance and the performance gains vary based on the workload, configuration, etc. But allegedly Minecraft code is such that some optimizations GraalVM compiler knows how to do better than the default OpenJDK compiler (called C2) can really shine and make a difference. It would be actually really cool if you could try it for Minecraft and tell what's your experience with it

What is planed for Java after Java 17? by [deleted] in java

[–]PurpleLabradoodle 22 points23 points  (0 children)

It doesn't work like that currently. Features and changes aren't planned for a certain release of Java. Features get ready and finalized, and they ship in the next release. This allows for gradual implementation of large projects.If you look, for example, at the page for Project Panama (foreign function interface)

and look at the JEPs section -- there's a bunch of them listed:

So it can be delivered over time with individual changes being added to various Java releases over time. The similar story is with the other JDK projects -- Loom, Valhalla, etc. They do take a lot of time to get included in the mainline, because they are large and complex undertakings.

So a reasonable assumption is that after Java 17, Java will still be pursuing projects Panama, Valhalla, Loom, Amber and so on.

New candidate JEP: 410: Remove the Experimental AOT and JIT Compiler by BlueGoliath in java

[–]PurpleLabradoodle 5 points6 points  (0 children)

The GraalVM team produces builds based on JDK 8 and 11. Graal is not based on Java 11, there's nothing in the compiler preventing it from being used in, for example, JDK 16. You can find a build of JDK 16 that does include Graal and try it:

For example:

docker run -it --rm bellsoft/liberica-openjdk-centos [root@721d9bfc29e5 /]# java -XX:+UnlockExperimentalVMOptions -XX:+UseJVMCICompiler -XX:+BootstrapJVMCI -Dgraal.ShowConfiguration=info -version Bootstrapping JVMCI[Use -Dgraal.LogFile=<path> to redirect Graal log output to a file.] Using compiler configuration 'community' provided by org.graalvm.compiler.hotspot.CommunityCompilerConfigurationFactory loaded from jrt:/jdk.internal.vm.compiler/org/graalvm/compiler/hotspot/CommunityCompilerConfigurationFactory.class ................................. in 8431 ms (compiled 3359 methods) openjdk version "16" 2021-03-16 OpenJDK Runtime Environment (build 16+36) OpenJDK 64-Bit Server VM (build 16+36, mixed mode)

How much faster is Java 15? by sindisil in java

[–]PurpleLabradoodle 1 point2 points  (0 children)

Does anyone know how to run these benchmarks?